Expand description
MCP (Model Context Protocol) server for Solo.
Exposes eighteen tools to MCP clients (Claude Desktop, Cursor, etc.):
Episode tools (v0.1+, with v0.9.2 additions):
memory_remember(content, source_type?, source_id?, salience?)— store an episode. Returns the new MemoryId.salience(v0.9.2+) is optional in [0.0, 1.0] and defaults to 0.5.memory_remember_batch(items)(v0.9.2+) — atomically store N episodes in one writer-actor transaction. Each item has the same fields asmemory_remember. Returns an ordered array of MemoryIds; either all items persist or none do.memory_recall(query, limit?)— vector search. Returns the top-K matches with content + tier + status.memory_context(query, subject?, window_days?, limit?)— combined recall + themes + facts + contradictions bundle for agent context.memory_update(memory_id, content)— correct/supersede an active episode’s content and refresh its embedding/index row.memory_forget(memory_id, reason?)— soft-delete an episode.memory_inspect(memory_id)— return the full episode record.
Derived-layer tools (v0.4.0+):
memory_themes(window_days?, limit?)— list cluster themes.memory_facts_about(subject, ...)— query the structured-fact knowledge graph (subject-predicate-object triples).memory_entities(query, limit?)— discover entity ids from the structured-fact graph.memory_contradictions(limit?)— disagreements flagged during consolidation.memory_contradiction_resolve(...)— mark a contradiction resolved, unresolved, or reopened.
Derived-layer tools (v0.5.0+):
memory_inspect_cluster(cluster_id, full_content?)— drill into one cluster’s abstraction + source episodes (truncated).
Document tools (v0.7.0+):
memory_ingest_document(path)— read a file from disk, split it into chunks, embed each, and store under documents/document_chunks.memory_search_docs(query, limit?)— vector search restricted to document chunks; returns chunk content + parent-doc context.memory_inspect_document(doc_id)— show one document’s metadata plus a previewed list of its chunks.memory_list_documents(limit?, offset?, include_forgotten?)— paginate over ingested documents, newest first.memory_forget_document(doc_id)— soft-delete a document; chunks stop appearing inmemory_search_docsand tombstone in HNSW.
§Transport
serve_stdio wires the server to stdin/stdout for use as a subprocess
(“claude_desktop_config.json or ~/.cursor/mcp.json invokes
solo mcp-stdio”). The function awaits a graceful shutdown when stdin
closes (parent disconnects) — same lifecycle as solo daemon’s
Ctrl+C path.
§What’s deferred
- SSE/HTTP transports —
rmcpships them, but v0.1 ships stdio only. prompts/andresources/capabilities — not needed for the four-tool surface; ServerHandler defaults return empty lists.- Tool argument validation beyond JSON Schema typing — we trust rmcp to deserialize per the schema, then serde-deserialize into our typed param structs. Bad inputs surface as clear errors.
Structs§
- Contradiction
Resolve Args - Contradictions
Args - Entities
Args - Facts
About Args - Forget
Args - Forget
Document Args - Ingest
Document Args - Inspect
Args - Inspect
Cluster Args - Args for
memory_inspect_cluster(v0.5.0 Priority 3).cluster_idis required;full_contentis opt-in for the rare power-user case where 200-char-per-episode truncation is too aggressive. - Inspect
Document Args - List
Documents Args - Memory
Context Args - Recall
Args - Remember
Args - Remember
Batch Args - v0.9.2 — args for the new
memory_remember_batchMCP tool. - Remember
Item - v0.9.2 — one item in a
memory_remember_batchrequest. - Search
Docs Args - Solo
McpServer - The MCP server. Cheap to clone — every field is
Arc-cloneable. - Themes
Args - Update
Args
Enums§
- Initialize
Decision - v0.9.0 P2: outcome of inspecting the tenant’s
[llm]config + the peer’ssamplingcapability at MCPinitializetime.
Constants§
- ENV_
MCP_ PRINCIPAL_ TOKEN - v0.8.1 P2: env var name MCP clients set when launching the server
process to attribute audit rows on the stdio transport. Closes the
v0.8.0 known-issue gap where MCP audit rows always carried
principal_subject = NULLon the daemon path.
Functions§
- initialize_
decision - v0.9.0 P2: decide the initialize outcome given the tenant’s
[llm]config and whether the peer advertised thesamplingcapability. - resolve_
mcp_ principal - v0.8.1 P2: resolve the MCP-session principal at
initialize-time. - sampling_
capability_ missing_ error_ message - v0.9.0 P2: locked error message body for both the daemon-startup
rejection guard and the MCP
initializecapability gate (plan §3 Decision 4 / BLOCKER 2 resolution). Returned verbatim to the operator so the commented-out TOML snippets are copy-pasteable. - serve_
stdio - Convenience: run the server over stdio and await its termination. Returns when stdin closes (parent disconnect) or the runtime exits.
- tool_
names - Names of every tool this server exposes, in registration order.