通用 AI 搜索 MCP 服务器,支持任何兼容 OpenAI API 格式的 AI 模型
Project description
AI Search MCP Server
通用 AI 搜索 MCP 服务器,支持任何兼容 OpenAI API 格式的 AI 模型进行联网搜索。
特性
- 支持任何 OpenAI API 兼容的模型
- 支持流式和非流式响应
- 自动过滤 AI 思考内容
- 完全可配置
- Windows 平台完美支持中文显示
安装
# 使用 uvx(推荐)
uvx ai-search-mcp
# 或使用 pip
pip install ai-search-mcp
更新
# 使用 pip 更新
pip install --upgrade ai-search-mcp
# 使用 uvx 会自动使用最新版本
uvx ai-search-mcp
卸载
# 使用 pip 卸载
pip uninstall ai-search-mcp
# uvx 不需要卸载,每次运行都是独立环境
快速开始
Kiro IDE
编辑 .kiro/settings/mcp.json:
{
"mcpServers": {
"ai-search": {
"command": "uvx",
"args": ["ai-search-mcp"],
"env": {
"AI_API_URL": "http://localhost:10000",
"AI_API_KEY": "your-api-key",
"AI_MODEL_ID": "Grok"
}
}
}
}
Claude Desktop
编辑 claude_desktop_config.json:
{
"mcpServers": {
"ai-search": {
"command": "uvx",
"args": ["ai-search-mcp"],
"env": {
"AI_API_URL": "http://localhost:10000",
"AI_API_KEY": "your-api-key",
"AI_MODEL_ID": "Grok"
}
}
}
}
配置
必需环境变量
| 变量 | 说明 |
|---|---|
AI_API_URL |
AI API 地址 |
AI_API_KEY |
API 密钥 |
AI_MODEL_ID |
模型 ID |
可选环境变量
| 变量 | 默认值 | 说明 |
|---|---|---|
AI_TIMEOUT |
60 |
超时时间(秒),复杂查询建议设为 120 |
AI_STREAM |
true |
流式响应 |
AI_FILTER_THINKING |
true |
过滤思考内容 |
超时配置建议
如果遇到复杂查询超时,可以增加超时时间:
{
"mcpServers": {
"ai-search": {
"command": "uvx",
"args": ["ai-search-mcp"],
"env": {
"AI_API_URL": "http://localhost:10000",
"AI_API_KEY": "your-api-key",
"AI_MODEL_ID": "Grok",
"AI_TIMEOUT": "120"
}
}
}
}
支持的服务
任何兼容 OpenAI API 格式的服务都可以使用,例如:
- Grok(本地部署)
- OpenAI(GPT-4、GPT-3.5)
- 本地模型(Ollama、LM Studio)
- 其他兼容服务
命令行工具
# 查看版本
ai-search-mcp --version
# 验证配置
ai-search-mcp --validate-config
开发
git clone https://github.com/lianwusuoai/ai-search-mcp.git
cd ai-search-mcp
pip install -e .
许可证
MIT License
链接
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ai_search_mcp-1.0.0.tar.gz.
File metadata
- Download URL: ai_search_mcp-1.0.0.tar.gz
- Upload date:
- Size: 10.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3bd115559b1077189945e783fd6b4a20863ef11ca538803aa7ed7fcbb39f0418
|
|
| MD5 |
fec52ea1d53aef0d605d60d6ae63af27
|
|
| BLAKE2b-256 |
decd5c51fe4b9b554ef3bea7039c1bcf3fab68aa54fca54ed5d8440b2f459693
|
Provenance
The following attestation bundles were made for ai_search_mcp-1.0.0.tar.gz:
Publisher:
publish.yml on lianwusuoai/ai-search-mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ai_search_mcp-1.0.0.tar.gz -
Subject digest:
3bd115559b1077189945e783fd6b4a20863ef11ca538803aa7ed7fcbb39f0418 - Sigstore transparency entry: 1004480571
- Sigstore integration time:
-
Permalink:
lianwusuoai/ai-search-mcp@0ee57c250ae4c0507b9f47ace3ca58361a3bf7a2 -
Branch / Tag:
refs/tags/v1.0.0 - Owner: https://github.com/lianwusuoai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@0ee57c250ae4c0507b9f47ace3ca58361a3bf7a2 -
Trigger Event:
release
-
Statement type:
File details
Details for the file ai_search_mcp-1.0.0-py3-none-any.whl.
File metadata
- Download URL: ai_search_mcp-1.0.0-py3-none-any.whl
- Upload date:
- Size: 13.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
90d640e1661d2b6cc0c92279c053dcd3a69def67ddefac47a68029eca34e4f35
|
|
| MD5 |
406176fefc8c3b070574f6943e45c32f
|
|
| BLAKE2b-256 |
91f0bc91c6f80cae4be8bd7f147950977ece7e206c6b067800a93e38b756a75b
|
Provenance
The following attestation bundles were made for ai_search_mcp-1.0.0-py3-none-any.whl:
Publisher:
publish.yml on lianwusuoai/ai-search-mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ai_search_mcp-1.0.0-py3-none-any.whl -
Subject digest:
90d640e1661d2b6cc0c92279c053dcd3a69def67ddefac47a68029eca34e4f35 - Sigstore transparency entry: 1004480603
- Sigstore integration time:
-
Permalink:
lianwusuoai/ai-search-mcp@0ee57c250ae4c0507b9f47ace3ca58361a3bf7a2 -
Branch / Tag:
refs/tags/v1.0.0 - Owner: https://github.com/lianwusuoai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@0ee57c250ae4c0507b9f47ace3ca58361a3bf7a2 -
Trigger Event:
release
-
Statement type: