Claude Code 接入Ragflow mcp
2026/4/17小于 1 分钟
安装 uv
# macOS / Linux (推荐)
curl -LsSf https://astral.sh/uv/install.sh | sh
# Windows (PowerShell)
irm https://astral.sh/uv/install.ps1 | iex
# Homebrew
brew install uv
# Scoop (Windows)
scoop install uv安装 ragflow-mcp
git clone https://github.com/Juxsta/ragflow-mcp.git
cd ragflow-mcp
uv venv --python 3.12
uv pip install -e .接入 Claude Code
编辑文件~/.claude/settings.json
{
"mcpServers": {
"ragflow": {
"command": "python",
"args": ["-m", "src.server"],
"cwd": "/path/to/ragflow-mcp",
"env": {
"RAGFLOW_API_KEY": "your-api-key",
"RAGFLOW_URL": "http://localhost:9380/api/v1"
}
}
}
}接入 Opencode
修改 opencode.json
{
"ragflow": {
"command": "python",
"args": ["-m", "src.server"],
"cwd": "/path/to/ragflow-mcp",
"env": {
"RAGFLOW_API_KEY": "your-api-key",
"RAGFLOW_URL": "http://localhost:9380/api/v1"
}
}
}