使用说明
下载克劳德桌面
https://claude.com/download
下载npm
https://docs.npmjs.com/downloading-and-installing-node-js-and-npm
安装UV
https://docs.astral.sh/uv/getting-started/installation/
创建OpenAPI密钥
https://platform.openai.com/settings/organization/general
MCP服务器列表
https://github.com/modelcontextprotocol/servers?tab=readme-ov文件
启动新项目
UV加热HelloWorld
创建虚拟环境
紫外线真空
激活虚拟环境
source.ven/bin/activate
添加mcp-cli
uv添加“mcp[cli]”
在本地运行以进行测试
mcp-dev-weather.py
添加到Claude-->开发工具-->编辑配置
"mcpServers": {
"weather": {
"command": "/Users/manu/anaconda3/bin/uv",
"args": [
"--directory",
"/Users/manu/Documents/MyApplications/Python/MCP/HELLO",
"run",
"python",
"weather.py"
]
}
}
}
另一种跑步方式:
mcp安装weather.py
这将自动将所需的命令添加到配置文件中
运行客户端
uv运行客户端.py
