Quickstart (MCP)
The fastest way to use mnesio is over the Model Context Protocol. The
mnesio-mcp binary speaks JSON-RPC over stdio and exposes three tools any
MCP-capable agent can call.
-
Build the MCP server.
Terminal window cargo build --release -p mnesio-mcpThe binary lands at
target/release/mnesio-mcp. -
Register it with your agent. Add an entry to the client’s MCP config, pointing
commandat the built binary:{"mcpServers": {"mnesio": {"command": "/abs/path/to/mnesio/target/release/mnesio-mcp","args": []}}} -
Restart the client and use the tools. The agent can now persist and recall memories across sessions.
The three tools
Section titled “The three tools”| Tool | What it does |
|---|---|
mnesio_write_memory | Append a memory to the log (returns its id). |
mnesio_search | Hybrid retrieve the top-k relevant memories for a query. |
mnesio_record_outcome | Record a task outcome that feeds the procedural compiler. |
Verify the handshake
Section titled “Verify the handshake”You can probe the server by hand — it follows MCP protocol version
2024-11-05:
printf '%s\n' \ '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{}}' \ '{"jsonrpc":"2.0","id":2,"method":"tools/list","params":{}}' \ | ./target/release/mnesio-mcpYou should see an initialize result followed by the three tool descriptors.
Next: the full agent integration guide, or learn how the substrate works in Architecture.