Skip to content

feat(adapters): add Kimi Code MCP memory adapter#370

Open
XiZu233 wants to merge 2 commits into
TencentCloud:mainfrom
XiZu233:feat/kimicode-adapter-issue-235
Open

feat(adapters): add Kimi Code MCP memory adapter#370
XiZu233 wants to merge 2 commits into
TencentCloud:mainfrom
XiZu233:feat/kimicode-adapter-issue-235

Conversation

@XiZu233

@XiZu233 XiZu233 commented Jul 2, 2026

Copy link
Copy Markdown

Summary

  • Add a Gateway-backed Kimi Code MCP adapter for TencentDB Agent Memory.
  • Expose memory recall, capture, memory search, conversation search, and session flush as stdio MCP tools.
  • Keep Kimi Code as a thin adapter: it forwards tool calls to the existing TDAI Gateway HTTP API instead of initializing TdaiCore directly.
  • Add platform comparison documentation for Codex and Kimi Code MCP integrations.

Architecture

Kimi Code CLI -> stdio MCP server -> TDAI Gateway HTTP API -> TdaiCore

Tools

  • tdai_recall -> POST /recall
  • tdai_capture -> POST /capture
  • tdai_memory_search -> POST /search/memories
  • tdai_conversation_search -> POST /search/conversations
  • tdai_session_end -> POST /session/end

Comparison Doc

  • Added docs/platform-adapter-comparison.md
  • Documents shared Gateway-backed architecture
  • Compares Codex and Kimi Code installation, MCP registration, tool exposure, and lifecycle limitations

Test

  • npm test
  • npm run build
  • npx vitest run src/adapters/codex src/adapters/kimicode

Refs #235

XiZu233 added 2 commits July 2, 2026 17:10
Implement the Kimi Code CLI adapter as a thin stdio MCP server that
forwards tool calls to the TDAI Gateway over HTTP, instead of embedding
TdaiCore in-process.

- Add KimiCodeGatewayClient (default http://127.0.0.1:8420) with Bearer
  token support, timeout, and typed error handling.
- Add Zod tool schemas for the five memory tools plus limit normalization.
- Add registerKimiCodeMemoryTools / createKimiCodeMcpServer / runKimiCodeMcpServer.
- Add bin/kimicode-memory-mcp.mjs entry point and kimi-plugin/ manifest.
- Wire package.json exports, bin, scripts, files, and keywords.
- Add tsdown entry for src/adapters/kimicode/mcp-server.ts.
- Add unit tests covering default URL, auth, all endpoints, errors,
  timeout, tool registration, and limit normalization.
- Update README.md / README_CN.md with Kimi Code CLI quick-start section,
  capability table, and roadmap.

Issue TencentCloud#235
Signed-off-by: XiZu233 <XiZu233@users.noreply.github.com>
@Maxwell-Code07

Copy link
Copy Markdown
Collaborator

Thank you for submitting this PR and participating in Tencent Rhino-bird Open-source Training Program!
We have successfully received your submission. The program is currently in full swing, and we will complete the Code Review for you as soon as possible. Please keep an eye on the status notifications for this PR so you can follow up promptly once the review feedback is provided.
Thanks again for your contribution and open-source spirit! 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants