GitHub Trending: thedotmack/claude-mem — persistent memory for your coding agent
2 min readGitHub Trending · AI Agents · Claude Code0 views
Every coding agent has the same flaw: it wakes up amnesiac. You spend a session debugging the same thing it solved for you last Tuesday and it has no idea. thedotmack/claude-mem attacks exactly that gap — it watches your agent's session, compresses what mattered, and feeds the relevant parts back into the next session as context. As of this week it has 113,226 stars and gained 8,822 this week — the most-starred trending repository on GitHub right now.
What it actually does
- Lifecycle hooks — SessionStart, UserPromptSubmit, PreToolUse, PostToolUse, Stop, SessionEnd. Each is one shell-free command run by a small launcher the installer puts on your PATH.
- A local worker service — a local HTTP API with a web viewer and search endpoints, managed by Bun.
- SQLite + Chroma — sessions, observations and summaries in SQLite; hybrid semantic + keyword search via Chroma for intelligent context retrieval.
- MCP search tools — a three-layer workflow (
search→timeline→get_observations) that fetches full details only for filtered IDs, which the project claims is roughly 10x more token-efficient than fetching everything. - Works across Claude Code, Codex, Cursor, OpenCode, Gemini, Hermes, Copilot, Grok Bot and OpenCode — install per harness with
npx claude-mem install --ide <harness>or the/plugin marketplace addcommands inside Claude Code.
Why it's trending this week
Agent memory is the obvious next layer once everyone has a coding agent. The Claude Code plugin ecosystem is booming, and 'persistent context across sessions' is the feature people keep asking for in every Discord and GitHub discussion I see. Claude-Mem is the most complete open-source attempt I've seen, which is why the stars followed. Note that memory runs off-plan by default via a hosted observer with a 30-day free trial; you can opt into your own OpenRouter or Gemini key, or your Anthropic plan instead.
Who it's for
- Anyone living in Claude Code / Codex / Cursor who re-explains the same project context every session.
- Teams running long, multi-session agentic work where decisions and bugfixes should be remembered.
- People who want a local-first memory layer rather than a hosted service for everything.
What to check before you install
- Read the hooks and privacy model — observations include tool outputs;
<private>tags exclude sensitive content, but understand what lands in~/.claude-mem/. - Node 20+ is required; Bun and uv are auto-installed if missing.
- The
npx claude-mem installcommand signs you up for the hosted observer by default — pass--provideror setCLAUDE_MEM_ONLINE_OPTIN=falseif you'd rather not. - Apache-2.0 licensed; the author is Alex Newman. It's actively maintained (3,900+ commits) — read the docs at docs.claude-mem.ai before wiring it into a production box.
I haven't run this in anger on a long project yet — this is a careful reading of the README, not a benchmark. But of everything on the trending page this week, this is the one I'd actually try first. Repository: github.com/thedotmack/claude-mem.

Written by
Shihab Hossain — Full-Stack Developer
I build fast, thoughtful products end-to-end — web experiences with React & Next.js, Android apps with Flutter, and the infrastructure behind them.
Work with me