Memex

io.github.pragneshbagary由 GitHub 帳號 pragneshbagary 發布v0.1.9更新於 Oct 24, 2026

Persistent session memory for Claude Code. Local SQLite, no LLMs, no network.

已驗證STDIO僅桌面知識與記憶開發者工具

概覽

AI 產生的概覽

Memex 為 Claude Code 提供依專案隔離的持久工作階段記憶,將任務、檔案、決策與警告等結構化紀錄存放在本機 SQLite 資料庫。

可以做什麼
在工作階段開始時載入最近與相關的記憶項目,依關鍵字和檔案路徑比對;在完成有意義的工作後儲存包含任務、檔案、決策、警告與標籤的結構化項目。更新既有項目的指定欄位,對所有項目做全文搜尋,並依標籤列出項目。依 id 刪除過期項目。在助理之外,命令列工具可查看狀態、列出與搜尋歷史,並將項目匯出為帶雙向連結與標籤的 Markdown 筆記。
適用情境
適合在多個 Claude Code 工作階段中持續開發同一專案、不想反覆說明上次做了什麼、決定了什麼或哪裡出問題的人。它補足靜態專案文件,記錄工作階段之間變動的內容。
執行需求
以 stdio 本機程序執行;需要 Python 3.10+、mcp 套件(自動安裝)以及支援 FTS5 的 SQLite。README 另要求 Claude Code CLI。可選環境變數 MEMEX_DIR、MEMEX_GLOBAL、MEMEX_RECENT 與 MEMEX_MATCHED 可覆寫預設值。無需網路或帳號。
安裝前請注意
助理可以寫入、更新與刪除記憶項目,安裝指令會將說明寫入專案的 .claude/CLAUDE.local.md 檔案。儲存的項目可能包含檔案路徑、決策與警告,並保存在家目錄下的本機 SQLite 資料庫,需手動刪除。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Memex,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

memex

Every Claude Code session starts without knowing what you built last time - which files you changed, what decisions you made, what broke. You re-explain. Claude re-reads. You start over.

memex keeps a structured log of every session. Claude reads it at the start of the next one.

No cloud. No LLM extraction. No cost per save. Just local SQLite and one command to install.

Install

bash
# with uvuvx mcp-memex install
# with pippip install mcp-memexmemex install

Restart Claude Code. That's it.

What gets saved

Each entry has structure - not a blob of text:

python
mem_save(    task="Replaced JWT auth with session cookies",    files=["src/auth.py", "src/middleware.py"],    decisions=["Session cookies over JWT - simpler, no token refresh needed"],    warnings=["Redis required - app won't start without REDIS_URL set"],    tags=["auth", "sessions"])

Claude calls mem_save when it finishes something meaningful. You can also just tell it: "save what we just did."

What Claude sees at session start

=== memex: session context (db: my_project.db) ===
--- Recent (2) ---[1] #4 - 2026-06-14T10:32  Task      : Replaced JWT auth with session cookies  Files     : src/auth.py, src/middleware.py  Decision  : Session cookies over JWT - simpler, no token refresh needed  Warning   : Redis required - app won't start without REDIS_URL set  Tags      : auth, sessions
[2] #3 - 2026-06-13T15:10  Task      : Added rate limiting to /api/login  Files     : src/middleware.py  Warning   : Rate limiter is in-memory per process - resets on restart  Tags      : auth, rate-limiting

Claude calls mem_load automatically at the start of every session. It returns the most recent entries plus any entries that match what you're working on - by keyword and by file path.

Browse from the terminal

You don't need to be inside Claude to look at your history:

bash
memex status                     # entry count, DB size, top tagsmemex list                       # recent entries for this projectmemex list --tag auth            # filter by tagmemex list --since 7d            # entries from the last 7 daysmemex list --since 2026-06-01 --until 2026-06-15  # date rangememex search "rate limit"        # full-text searchmemex version                    # print installed version

Export to markdown

Turn your history into portable, human-browsable notes - one .md file per entry, with [[wikilinks]] connecting related entries and files, plus tags as #hashtags. Works in Obsidian or any tool that understands [[links]]:

bash
memex export ./my-project-notes/

Entries that share a tag or a touched file are cross-linked under a Related section, so you can navigate your project history as a graph.

Six MCP tools

ToolWhat it does
mem_loadCalled at session start - returns recent + relevant entries
mem_saveSaves a structured entry after meaningful work
mem_updatePatches specific fields of an existing entry (keeps id and timestamp)
mem_searchFull-text search across all entries
mem_listLists entries, optionally filtered by tag
mem_deleteRemoves a stale entry by id

Why not just CLAUDE.md?

CLAUDE.md is for static project documentation - architecture, conventions, how to run tests. It doesn't change much and it isn't session-aware.

memex captures what's changing session to session: what you built yesterday, the decision you made this morning, the warning you discovered an hour ago. It's the difference between "here's the project" and "here's what happened last time."

memex install writes Claude's instructions into .claude/CLAUDE.local.md - a file Claude Code loads automatically without touching your project's own CLAUDE.md.

Memory is scoped per project

Each project gets its own SQLite database at ~/.memex/<project>.db based on the working directory. Sessions from different projects never mix.

Configuration

Set these in the MCP env block in ~/.claude.json if you need to override defaults:

VariableDefaultDescription
MEMEX_DIR~/.memexWhere DBs are stored
MEMEX_GLOBAL0Set to 1 to share one DB across all projects
MEMEX_RECENT5Max recent entries loaded per session
MEMEX_MATCHED5Max FTS-matched entries loaded per session

Uninstall

bash
memex removepip uninstall mcp-memex

Memory DBs are kept at ~/.memex/ - delete that directory manually if you want to wipe everything.

Requirements

  • Python 3.10+
  • mcp package (installed automatically)
  • SQLite with FTS5 (standard since Python 3.8)
  • Claude Code CLI

License

MIT

來源:README.md,提交 281809d

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v0.1.9最新Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分