Persistent memory for Claude Code β offline, single-file, hybrid search.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
We haven't yet run this listing's install command through our automated sandbox check. This isn't a red flag β we're steadily working through the catalog.
π‘ Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
Persistent memory for Claude Code. Automatically indexes every conversation and provides production-grade hybrid search (BM25 + vectors + reranker) via MCP tools. 100% local, zero config, zero API keys, zero invoice.
Claude Code forgets everything between sessions - and knows nothing about your other projects. Melchizedek fixes both.
It runs silently in the background - indexing your conversations as you work - then gives Claude the ability to search across your entire history, across all projects: past debugging sessions, architectural decisions, error solutions, code patterns.
No cloud. No API keys. No config. Plug and ask.
Every layer is optional. The plugin works with BM25 alone and gets better as more components are available.
| Level | Component | What it adds | Dependency |
|---|---|---|---|
| 1 | BM25 (FTS5) | Keyword search with stemming | None (always active) |
| 2 | Dual vectors (sqlite-vec) | Semantic search - text (MiniLM 384d) + code (Jina 768d) | @huggingface/transformers (optional) |
| 3 | RRF fusion | Merges BM25 + text vectors + code vectors via Reciprocal Rank Fusion | Vectors enabled |
| 4 | Reranker | Cross-encoder re-scoring of top results | Transformers.js or node-llama-cpp (optional) |
Measured with npm run bench - 100 sessions, 1 000 chunks, on a single SQLite file.
| Metric | Result | Target |
|---|---|---|
| Indexation (100 sessions) | ~80 ms | < 10 s |
| BM25 search (mean) | ~0.2 ms | < 50 ms |
| DB size (100 sessions) | ~1.4 MB | < 30 MB |
| Tokens per search | ~125 | < 2 000 |
Add the MCP server to Claude Code:
Plugin review pending. In the meantime, use npm or npx install above.
The MCP server provides search tools, but hooks trigger automatic indexing. Without hooks, you'd need to manually index sessions.
For marketplace installs, hooks are configured automatically. For npm/npx/source installs, add hooks to ~/.claude/settings.json.
See docs/installation.md for the full JSON configuration, hook reference, and troubleshooting.
After setup, restart Claude Code. Indexing starts automatically.
| Tool | Description |
|---|---|
m9k_search | Search indexed conversations. Returns compact snippets. Current project boosted. Supports since/until date filters and order (score, date_asc, date_desc). |
m9k_context | Get a chunk with surrounding context (adjacent chunks in the same session). |
m9k_full | Retrieve full content of chunks by IDs. |
Progressive retrieval pattern - search returns ~50 tokens/result, context ~200-300, full ~500-1000. Start with m9k_search, drill down only when needed. 4x token savings vs loading everything.
Context-aware ranking - results from your current project (Γ1.5) and current session (Γ1.2) are automatically promoted. Cross-project results remain visible.
| Tool | Description |
|---|---|
m9k_file_history | Find past conversations that touched a specific file. |
m9k_errors | Find past solutions for an error message. |
m9k_similar_work | Find past approaches to similar tasks. Prioritizes rich metadata. |
| Tool | Description |
|---|---|
m9k_save | Manually save a memory note for future recall. |
m9k_sessions | List all indexed sessions, optionally filtered by project. |
m9k_info | Show memory index info: corpus size, search pipeline, embedding worker, usage metrics. |
m9k_config | View or update plugin configuration. |
m9k_forget | Permanently remove a chunk from the index. |
m9k_delete_session | Delete a session from the index. |
m9k_ignore_project | Exclude a project from indexing. Future sessions won't be indexed, existing ones optionally purged. |
m9k_unignore_project | Re-enable indexing for a previously ignored project. Purged data is not restored. |
m9k_restart | Restart the MCP server to load fresh code after npm run build. Supports force: true for stuck processes. |
| Tool | Description |
|---|---|
__USAGE_GUIDE | Phantom tool. Its description teaches Claude the retrieval pattern and available tools. |
Zero config by default. Everything is tunable via m9k_config or environment variables.
| Setting | Default | Env var |
|---|---|---|
| Database path | ~/.melchizedek/memory.db | M9K_DB_PATH |
| Daemon mode | enabled | M9K_NO_DAEMON=1 to disable |
| Log level | warn | M9K_LOG_LEVEL |
| Embeddings enabled | true | M9K_EMBEDDINGS=false to disable |
| Reranker enabled | true | M9K_RERANKER=false to disable |
See docs/configuration.md for the full settings reference (20+ options, env vars, config file examples).
Melchizedek works out of the box with BM25 keyword search. Text embeddings (MiniLM) download automatically on first use for semantic search.
For GPU-accelerated code embeddings (Ollama), cross-encoder reranking (GGUF models), platform-specific setup guides, and the full model reference, see Enhanced Search Setup.
No reviews yet β be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/melchizedek)<a href="https://allmcps.com/mcp/melchizedek"><img src="https://allmcps.com/api/badge/melchizedek?style=directory" alt="Melchizedek on AllMCPs" /></a>