Current collected state Current
Observed since 21 Oct, 10:18 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
ai-core-mcp-server
Ai-Core MCP Server - Model Context Protocol server for Ai-Core API
这是一个 Model Context Protocol (MCP) 服务器,提供对 AiCore 知识管理 API 的访问。
推荐直接参考 MCP配置说明,无需进行以下操作。
pip install -r requirements.txt
# Linux/macOS
export AI_CORE_BASE_URL="http://localhost:8080/api/v1"
export AI_CORE_API_KEY="your_api_key_here"
# Windows PowerShell
$env:AI_CORE_BASE_URL="http://localhost:8080/api/v1"
$env:AI_CORE_API_KEY="your_api_key_here"
# Windows CMD
set AI_CORE_BASE_URL=http://localhost:8080/api/v1
set AI_CORE_API_KEY=your_api_key_here
推荐方式 - 使用主入口点:
python main.py
其他运行方式:
# 使用原始启动脚本
python run_server.py
# 使用便捷脚本
python run.py
# 直接运行服务器模块
python ai_core_mcp_server.py
# 作为 Python 模块运行
python -m ai_core_mcp_server
python main.py --help # 显示帮助信息
python main.py --check-only # 仅检查环境配置
python main.py --verbose # 启用详细日志
python main.py --version # 显示版本信息
pip install -e .
安装后可以使用命令行工具:
ai-core-mcp-server
# 或
ai-core-server
pip install .
# 使用 setuptools
python setup.py sdist bdist_wheel
# 使用现代构建工具
pip install build
python -m build
运行测试脚本验证模组是否正常工作:
python test_module.py
该 MCP 服务器提供以下工具:
create_tenant - 创建新空间list_tenants - 列出所有空间create_knowledge_base - 创建知识库list_knowledge_bases - 列出知识库get_knowledge_base - 获取知识库详情delete_knowledge_base - 删除知识库hybrid_search - 混合搜索create_knowledge_from_url - 从 URL 创建知识list_knowledge - 列出知识get_knowledge - 获取知识详情delete_knowledge - 删除知识create_model - 创建模型list_models - 列出模型get_model - 获取模型详情create_session - 创建聊天会话get_session - 获取会话详情list_sessions - 列出会话delete_session - 删除会话chat - 发送聊天消息list_chunks - 列出知识块delete_chunk - 删除知识块如果遇到导入错误,请确保:
mcp.py 作为文件名)Download counts and popularity will appear here as the collector receives them.
| Package / target | Requirement | Relationship |
|---|---|---|
mcpEnvironment{
"extras": "",
"marker": null,
"requires_python": ">=3.10",
"evaluation": "NOT_EVALUATED"
} | mcp<2,>=1.0.0 | runtime |
requestsEnvironment{
"extras": "",
"marker": null,
"requires_python": ">=3.10",
"evaluation": "NOT_EVALUATED"
} | requests>=2.31.0 | runtime |
pytestEnvironment{
"extras": "",
"marker": "extra == \"dev\"",
"requires_python": ">=3.10",
"evaluation": "NOT_EVALUATED"
} | pytest>=7.0; extra == "dev" | runtime |
pytest-asyncioEnvironment{
"extras": "",
"marker": "extra == \"dev\"",
"requires_python": ">=3.10",
"evaluation": "NOT_EVALUATED"
} | pytest-asyncio>=0.21.0; extra == "dev" | runtime |
blackEnvironment{
"extras": "",
"marker": "extra == \"dev\"",
"requires_python": ">=3.10",
"evaluation": "NOT_EVALUATED"
} | black>=23.0; extra == "dev" | runtime |
flake8Environment{
"extras": "",
"marker": "extra == \"dev\"",
"requires_python": ">=3.10",
"evaluation": "NOT_EVALUATED"
} | flake8>=6.0; extra == "dev" | runtime |
mypyEnvironment{
"extras": "",
"marker": "extra == \"dev\"",
"requires_python": ">=3.10",
"evaluation": "NOT_EVALUATED"
} | mypy>=1.0; extra == "dev" | runtime |
pytestEnvironment{
"extras": "",
"marker": "extra == \"test\"",
"requires_python": ">=3.10",
"evaluation": "NOT_EVALUATED"
} | pytest>=7.0; extra == "test" | runtime |
pytest-asyncioEnvironment{
"extras": "",
"marker": "extra == \"test\"",
"requires_python": ">=3.10",
"evaluation": "NOT_EVALUATED"
} | pytest-asyncio>=0.21.0; extra == "test" | runtime |
pytest-covEnvironment{
"extras": "",
"marker": "extra == \"test\"",
"requires_python": ">=3.10",
"evaluation": "NOT_EVALUATED"
} | pytest-cov>=4.0; extra == "test" | runtime |
bdist_wheel · 26.5 KB · Python py3
sdist · 29.54 KB · Python source
Observed since 21 Oct, 10:18 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package_version:bd55b34e864747ec00ee475f481365519c380b78d9413ccb475d819c65aa2704