feat(mcp): add memory search MCP server#451
Conversation
|
Duplicate/scope cleanup triage: This overlaps the #235 MCP/adapter lane that already has narrower canonical PRs:
This PR introduces a second MCP server implementation as a new Python package, which duplicates the integration surface while adding another packaging/runtime/protocol matrix to maintain. I would not keep this open as another #235 implementation candidate while #372 is already the approved MCP bridge path. Suggested cleanup path: close this as superseded by #372 for the current #235 work. If maintainers still want a Python MCP package after #372 lands, reopen it as a follow-up with a narrower delta: why a separate Python package is needed, how it stays protocol/tool-compatible with the approved MCP bridge, ownership of packaging/release, and a security/transport validation matrix. |
|
Thank you for submitting this PR and participating in Tencent Rhino-bird Open-source Training Program! |
概述
本 PR 新增一个独立的 Python MCP server 包:
packages/tdai-memory-mcp。它用于把 TencentDB Agent Memory 的记忆检索能力暴露给 MCP 客户端。MCP server 本身不启动、不管理 Gateway,只连接一个已经运行中的 TDAI Gateway,并通过 Gateway HTTP API 提供查询能力。
关联 Issue
Part of #235
提供的 MCP 能力
本 PR 暴露两个 LLM-callable MCP tools:
tdai_memory_searchtdai_conversation_search另外提供一个 side-channel 诊断命令:
tdai-memory-mcp health实现范围
本 PR 包含:
设计说明
MCP server 默认假设 Gateway 已经由用户或部署环境启动。
整体调用链路是:
这样可以让 Codex、Claude Desktop、Claude Code 或其他 MCP client 通过标准 MCP tool 使用 TencentDB Agent Memory 的查询能力,同时保持 Gateway 生命周期管理和 MCP server 解耦。
自测结果
cd packages/tdai-memory-mcp && python3 -m pytest tests/unit -q16 passed可选 e2e 测试需要本地已经运行 TDAI Gateway,因此不作为默认自测要求。