
Melchizedek
io.github.louis49由 GitHub 帳號 louis49 發布v1.0.2更新於 Oct 25, 2026
Persistent memory for Claude Code — offline, single-file, hybrid search.
概覽
本機 MCP 伺服器,將 Claude Code 對話紀錄索引到單一 SQLite 檔案,讓助理跨專案檢索歷史工作階段。
- 可以做什麼
- 檢索已索引的對話,回傳精簡片段,支援日期篩選與排序,並可進一步取得前後脈絡或完整內容。找出涉及特定檔案的過往工作階段、某個錯誤訊息的歷史解法,或類似任務先前的做法。手動儲存記憶筆記,列出已索引的工作階段,可依專案篩選。檢視索引統計與設定資訊,並調整設定。從索引中移除單一片段或整個工作階段,排除或重新納入專案,以及重新啟動伺服器。
- 適用情境
- 適合在 Claude Code 中橫跨多個工作階段與專案工作、希望自動回想過去除錯過程、架構決策與程式碼模式的軟體開發者,不必反覆說明背景。也適合要求這些歷史完全留在自己電腦上的使用者。
- 執行需求
- 以 npm 套件形式透過 stdio 在本機執行,需要 Node.js 20 以上版本、Claude Code 2.0 以上版本,支援 macOS、Linux 或 Windows。自動索引需要在 Claude Code 設定檔中加入 SessionEnd 掛鉤。選用的向量與重排模型會在首次使用時下載。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Melchizedek,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
Melchizedek
[npm version] [npm downloads] [CI] [License: MIT] [Donate] [Donate]
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.
Why Melchizedek?
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.
How it works
Search pipeline - 4 levels of graceful degradation
Every layer is optional. The plugin works with BM25 alone and gets better as more components are available.
Performance
Measured with npm run bench - 100 sessions, 1 000 chunks, on a single SQLite file.
Quick Start
npm (recommended)
Add the MCP server to Claude Code:
npx (no install)
From source
Claude Code plugin marketplace (coming soon)
Plugin review pending. In the meantime, use npm or npx install above.
Setting up hooks (automatic indexing)
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.
MCP Tools
Search (start here)
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.
Specialized search
Memory management
Usage guide
Configuration
Zero config by default. Everything is tunable via m9k_config or environment variables.
See docs/configuration.md for the full settings reference (20+ options, env vars, config file examples).
Enhanced Search
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.
How is this different?
Inspirations
This project stands on the shoulders of others. Key ideas borrowed from:
Known issues
- Session boost inactive - Claude Code currently sends an empty
session_idin the SessionStart hook stdin payload, preventing the ×1.2 session boost from working. The ×1.5 project boost is unaffected and provides the primary context-aware ranking. Related upstream issues: #13668 (emptytranscript_path), #9188 (stalesession_id). Melchizedek's session boost code is tested and ready, and will activate automatically when the upstream fix lands.
Privacy
- Zero telemetry. No tracking, no analytics, no network calls (except optional lazy model download).
- Read-only on transcripts. Never writes to
~/.claude/projects/. All data in~/.melchizedek/. <private>tag support. Content between<private>...</private>is replaced with[REDACTED]before indexing.- Local-only. Your conversations never leave your machine.
Requirements
- Node.js >= 20
- Claude Code >= 2.0
- macOS, Linux, or Windows
License
MIT
"Without father, without mother, without genealogy, having neither beginning of days nor end of life."
- Hebrews 7:3
Built by @louis49
來源:README.md,提交 3053612
工具
0版本歷史
1- v1.0.2最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分