Expand description
MCP server (stdio + HTTP/SSE) for trusty-memory.
Why: Claude Code and other MCP-aware clients integrate with trusty-memory
through the standardized Model Context Protocol; we expose memory + KG
tools so they can be called by name.
What: Provides run_stdio (JSON-RPC 2.0 over stdin/stdout) and run_http
(axum HTTP/SSE stub), plus an AppState that carries the shared
PalaceRegistry, on-disk data root, and a lazily-initialized embedder.
Test: cargo test -p trusty-memory-mcp validates handshake + dispatch.
Re-exports§
pub use service::MemoryMcpService;pub use tools::MemoryMcpServer;
Modules§
- commands
- Per-subcommand handlers for the
trusty-memorybinary. - openrpc
- OpenRPC 1.3.2 service description for
trusty-memory-mcp. - service
ServiceDescriptorimpl for the trusty-memory MCP service.- tools
- MCP tool surface for trusty-memory.
- web
- HTTP API + embedded SPA shell for the trusty-memory admin UI.
Structs§
- AppState
- Shared application state passed to every request handler.
Enums§
- Daemon
Event - Live daemon events broadcast to connected SSE subscribers.
Functions§
- handle_
message - Handle a single MCP JSON-RPC message and produce its response.
- run_
http - Convenience: bind
addrand serve viarun_http_on. - run_
http_ on - Run the optional HTTP/SSE + web admin server.
- run_
stdio - Run the MCP stdio JSON-RPC 2.0 server loop.