memtomem
Supports LangGraph's long-term memory contract via an optional MemtomemBaseStore that implements tuple-namespace memory storage.
Integrates with local Ollama models for embedding generation, enabling semantic search without external API dependencies.
Integrates with OpenAI's embedding models for dense vector search capabilities.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@memtomemsearch my notes for ideas on async Python"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
memtomem
Markdown-first long-term memory for AI coding agents โ your files stay yours, and core usage is hook-free by default.
๐ง Alpha โ APIs, defaults, and on-disk config surfaces may still change between
0.xreleases. Feedback and issue reports are especially welcome: Issues ยท Discussions.
memtomem turns your markdown notes, documents, and code into a searchable knowledge base that any AI coding agent can use. Write notes as plain .md files โ memtomem indexes them and makes them searchable by both keywords and meaning.
flowchart LR
A["Your files\n.md .json .py"] -->|Index| B["memtomem"]
B -->|Search| C["AI agent\n(Claude Code, Cursor, etc.)"]First time here? Follow the Getting Started guide โ you'll have a working setup in under 5 minutes. Claude Code or Codex CLI user? See the Korean vibe-coding quickstart.
Why memtomem?
Problem | How memtomem solves it |
AI forgets everything between sessions | Index your notes once, search them in every session |
Keyword search misses related content | Hybrid search: exact keywords + meaning-based similarity |
Notes scattered across tools | One searchable index for markdown, JSON, YAML, Python, JS/TS |
Vendor lock-in | Your |
Hidden automation is hard to reason about | Core memory operations run only when you call them; optional client hooks are explicit, removable integrations |
Related MCP server: agent-memory
Quick Start
1. Install
uv tool install 'memtomem[all]' # or: pipx install 'memtomem[all]'
mm --version # verify install[all] bundles the features the sections below describe โ ONNX dense embeddings, Korean tokenizer, Ollama / OpenAI providers, code chunker, and the Web UI. For a BM25-only install without those downloads (~40 MB vs ~250 MB), see the minimal install option in the Getting Started guide.
If
mm --versionshows an older version than the latest release,uvis likely serving cached PyPI metadata โ re-run withuv tool install 'memtomem[all]' --refresh, or clear the cache first:uv cache clean memtomem.
mm: command not found?uv tool installdrops the shim into~/.local/bin, which isn't on$PATHin fresh shells on macOS/Linux. Runuv tool update-shell, then open a new shell and re-runmm --version.
2. Setup
After upgrading the Claude plugin: re-check
/mcpafter reloading. The plugin launchesmemtomem[onnx]==0.6.4. A manual registration whose launch differs โ base-onlymemtomem, or the ONNX launch pinned to an earlier release โ no longer matches for deduplication and may expose duplicate tools. Confirm the manual entry's name and scope, then align its launch command with the plugin or remove that redundant registration.
mm init # preset picker, then memory_dir + MCPThe interactive picker starts with three presets โ Minimal (BM25, no downloads), English (Recommended) (ONNX multilingual-e5-small + English reranker + auto-discover providers), Korean-optimized (ONNX multilingual-e5-small + kiwipiepy tokenizer + multilingual reranker) โ plus an Advanced entry that opens the full 10-step wizard. Preset paths only ask about the memory directory and MCP registration; everything else is set from the preset.
Choose Minimal for the fastest no-download first proof; rerun mm init
later when you are ready to add semantic search.
Indexing vs. discovery (Claude Code): provider memory folders that setup auto-discovers (e.g.
~/.claude/projects/*/memory/) are added to the search index. That is separate from the Web UI's opt-in Context Gateway scan of~/.claude/projects/, which discovers project roots for Skills, Custom Commands, and Subagents โ see Configuration โ Context Gateway for the distinction and the lossy-slug caveats.
For automation / CI:
mm init --non-interactive # minimal preset, no prompts
mm init --preset korean --non-interactive # Korean-optimized bundle, no prompts
mm init --advanced # force the full 10-step wizardSee Embeddings for the full model/provider matrix.
3. Verify a complete memory round trip
The first success path does not require an existing notes directory or a connected editor:
mm status
mm add "Deployment checklist uses blue-green rollout" --tags ops
mm search "blue-green"mm add writes to your configured user memory directory and indexes the entry immediately. The final command should return the sentence you just added.
Then verify the editor connection:
"Call the mem_status tool"To bring existing notes into the same index, point mm index at a directory that already exists:
mm index /path/to/your/notesmm status --json (or --format json) provides the same status as machine-readable output for scripts and CI.
4. Open the Web UI (optional)
mm web # polished dashboard on http://127.0.0.1:8080
mm web -b # run in the background; logs go to ~/.memtomem/logs/web.log
mm web status # show pid/port/start time
mm web stop # stop the tracked Web UI process
mm web --dev # maintainer surface (adds opt-in pages)mm web shows the polished page set by default. Pass --dev (or set
MEMTOMEM_WEB__MODE=dev in your shell profile) to expose maintainer pages
like Namespaces, Sessions, Working Memory, and Health Report.
Minimal (BM25-only, ~40 MB):
uv tool install memtomem # no extras โ dense search, web UI, Korean tokenizer unavailable until you add themOpt in later per-feature: uv tool install --reinstall 'memtomem[onnx,web]' (see the extras table).
Project-scoped (per-project isolation):
uv add 'memtomem[all]' && uv run mm init # all commands need `uv run` prefixNo install (uvx on demand):
claude mcp add memtomem -s user -- uvx --isolated --from "memtomem[all]==0.6.4" memtomem-serverSee MCP Client Setup for OpenCode / Codex / Cursor / Windsurf / Claude Desktop / Gemini CLI / Kimi Code.
Key Features
Hybrid search โ BM25 keyword + dense vector + RRF fusion in one query
Semantic chunking โ heading-aware Markdown, AST-based Python, tree-sitter JS/TS, structure-aware JSON/YAML/TOML
Incremental indexing โ chunk-level SHA-256 diff; only changed chunks get re-embedded
Namespaces โ organize memories into scoped groups with auto-derivation from folder names; review and label them (colour, description) from Settings โ Namespaces in the Web UI
Maintenance โ near-duplicate detection, time-based decay, TTL expiration, auto-tagging
Web UI โ visual dashboard for search, sources, tags, timeline, dedup, and more (
mm web --devfor the full maintainer surface)Context Gateway โ keep canonical Skills, Commands, and Subagents in a project or user Store, optionally install reusable assets from a separate Wiki, then push them to supported AI runtimes. See Context Gateway.
MCP tools โ
mem_dometa-tool routes all non-core actions incoremode for minimal context usagePredictable core โ memory operations run on explicit CLI/MCP calls (
mm add,mem_add,mem_index, etc.). Optional client hooks are installed and removed separately rather than being a hidden runtime default.Scriptable CLI โ
--jsonoutput onmm statusand write commands (mm add/mm reset/mm purge);mm warmuppre-loads local models so the first query skips the cold-start costScheduled jobs โ
mm schedule add/list/run-now/delete(ormem_do(action="schedule_*")) for cron-driven compaction, importance decay, dead-link cleanup, and dedup scansPinned Context โ keep small user/project/agent Markdown blocks ahead of retrieved results with
mm pinned composeLangGraph Store โ optional
MemtomemBaseStoreimplements LangGraph's tuple-namespace long-term-memory contractHybrid LangGraph Store โ
MemtomemHybridStoreadds dedicated SQLite persistence, BM25/dense/RRF retrieval, TTL, and diagnostics
Ecosystem
Package | Description |
Core โ MCP server, CLI, Web UI, hybrid search, storage | |
OpenCode โ exact-pinned MCP, commands, read skills, safe permissions | |
STM proxy โ proactive memory surfacing via tool interception |
Documentation
Hosted at memtomem.com โ also available as Markdown in this repo. New to memtomem? The guides have a suggested reading order. The table below follows it:
Guide | Description |
Install, configure, save and find your first memory | |
Claude CodeยทCodex CLI์์ 10~15๋ถ ์์ ๊ธฐ์ต ์ ์ฅยท๊ฒ์ | |
Start with 00: recover decisions, code, and settings across 150 synthetic files without a model (Korean); 01โ04 teach APIs, 05โ06 teach LangGraph | |
Recover a decision and its ADR source across sessions; isolated CLI proof and copyable prompts | |
๊ฐ๋ฐ ์์ ์ธ๊ณยท์ ํ ์์ฌ๊ฒฐ์ ยท์จ๋ณด๋ฉ: ๋ชจ๋ธ ์๋ ์ฒดํ, ๊ธฐ๋ก ์์, 2์ฃผ ํ์ผ๋ฟ | |
Editor-specific configuration | |
Claude CodeยทCodex CLIยทKimi Code ์์ฐจ ๊ณต๋ ๊ฐ๋ฐ | |
Index existing notes, search, and manage memories | |
Supported config files, precedence, and | |
ONNX, Ollama, and OpenAI embedding providers | |
Ollama, OpenAI, Anthropic, and compatible endpoints | |
Share Skills, Commands, and Subagents across your AI tools from one Store | |
Sync markdown memories across personal devices via a private git repo | |
Web UI, privacy audits, diagnostics, and recovery | |
Complete tool and workflow reference | |
Clean removal steps |
Contributing
See CONTRIBUTING.md for setup instructions and the contributor guide.
License
Apache License 2.0. Contributions are accepted under the terms of the Contributor License Agreement.
This server cannot be deployed
Maintenance
Related MCP Connectors
Hosted MCP memory for coding agents: persistent across sessions, editable markdown, team sharing.
Token-efficient MCP memory for Markdown vaults. Tiered search, GraphRAG, AI memories.
One memory, every AI. A shared, user-owned markdown memory your AI clients read and write over MCP.
Persistent memory and knowledge management for AI agents with semantic search and 50+ tools.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenancePersonal unified memory system for AI coding agents, providing persistent memory with hybrid RAG retrieval via MCP integration, allowing agents to store, search, and manage memories locally.1MIT
- AlicenseAqualityBmaintenanceLocal, searchable project memory for AI coding agents. Markdown source of truth, MCP interface, safe structured updates311Apache 2.0
- AlicenseBqualityBmaintenanceLocal-first memory server for AI coding agents that stores work sessions, tasks, and durable memories in Markdown files, exposed through MCP tools for session management and memory retrieval.106 npm1MIT
- FlicenseNot gradedqualityFmaintenancePersistent memory for MCP-powered coding agents, allowing LLMs to remember preferences, project context, and decisions across sessions via Markdown files.9 npm-