Skip to content

Overview

memtomem gives your AI agent memory that persists across sessions and across agents. It runs as a local MCP server — your agent uses the same tool-calling it already does, and past information becomes searchable.

  • You keep re-explaining yesterday’s decisions in today’s session — memtomem solves the “every new session is a blank slate” problem. Walk through the flow in Memory Persistence Across Sessions.
  • You want notes or docs to be searchable by your agent — point mm index ~/notes at a folder of Markdown / structured files and every MCP-connected agent can query it.
  • Multiple agents need to share the same knowledge — Claude Code, Cursor, Codex CLI, and any other MCP client share one memory store.
Terminal window
uv tool install 'memtomem[all]'
mm init --preset minimal --non-interactive --mcp skip
mm status
mm add "Release smoke tests run before cutover" --tags release,decision
mm search "release smoke tests"

This proves storage and search before a client is involved. Continue with Quick Start and then Connect an AI Client.

  • Hybrid Search — BM25 keyword + dense vector search merged via RRF, so exact identifiers and meaning-based queries both land. See Hybrid Search.
  • Namespaces — Per-agent routing scopes (agent-runtime:{id}) plus a shared scope for cross-agent knowledge. They organize retrieval and are not access-control boundaries. See Multi-Agent Collaboration.
  • Lifecycle Policiesauto_archive / auto_expire / auto_promote / auto_tag run on a background scheduler, so memories are aged and promoted automatically.
AI Agent (Claude Code, Cursor, Antigravity CLI, …)
↕ MCP protocol
memtomem server
SQLite (FTS5 + sqlite-vec)

memtomem runs as a local-first MCP server. SQLite storage and ONNX embeddings stay on your machine and need no GPU or account. Optional remote embedding, rerank, LLM, and observability providers contact the endpoints you configure.

LTM (memtomem)STM (memtomem-stm)
RolePersistent storage & searchReal-time proxy & compression
Required?Yes (core)Optional
How it worksAgent calls mem_search when neededRelevant memories can be injected into calls routed through the STM proxy or supported hooks

The default setup is LTM alone. If you want token-optimized responses with proactive memory injection, add memtomem-stm as a proxy in front.

PyPImemtomem
Latest release0.3.12
CLImm
LicenseApache 2.0
GitHubmemtomem/memtomem