
How It Works
Answer how claude-mem captures session observations, when injection starts, and where local data lives before you rely on it across coding sessions.
Install
npx skills add https://github.com/thedotmack/claude-mem --skill how-it-worksWhat is this skill?
- Compresses Read, Edit, and Bash actions into observations summarized at session end
- Auto-injects relevant past observations starting on the second project session
- Optional `/learn-codebase` front-load (~5 minutes) for full-repo seeding
- Local-only store under ~/.claude-mem (SQLite, vectors, logs); uninstall via npx claude-mem uninstall
- Compression may call configured AI providers; otherwise data stays on machine
Adoption & trust: 1.2k installs on skills.sh; 81.2k GitHub stars; 3/3 security scanners passed (skills.sh audits).
Recommended Skills
Microsoft Foundrymicrosoft/azure-skills
Azure Aimicrosoft/azure-skills
Azure Hosted Copilot Sdkmicrosoft/azure-skills
Lark Eventlarksuite/cli
Running Claude Code Via Litellm Copilotxixu-me/skills
Setup Matt Pocock Skillsmattpocock/skills
Journey fit
Common Questions / FAQ
Is How It Works safe to install?
skills.sh reports 3 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.
SKILL.md
READMESKILL.md - How It Works
# How claude-mem works ## What it does Every Read, Edit, and Bash that Claude makes turns into a compressed observation. Observations get summarized at session end. Relevant ones get auto-injected into future prompts so the next session starts with context from the last one — no re-explaining the codebase, no re-discovering decisions. ## When it kicks in Memory injection starts on your second session in a project. The first session in a fresh project seeds memory; subsequent sessions receive auto-injected context for relevant past work. Run `/learn-codebase` if you want to front-load the entire repo into memory in a single pass (~5 minutes, optional). ## Where data lives Everything stays in ~/.claude-mem on this machine. Nothing leaves your machine except calls to whichever AI provider you configured for compression (Claude / OpenRouter / Gemini). The SQLite database, vector index, logs, and settings all live under that directory and are removed cleanly on `npx claude-mem uninstall`. --- name: how-it-works description: Explain how claude-mem captures observations, when memory injection kicks in, and where data lives. Use when the user asks "how does claude-mem work?" or "what is this thing doing?". --- # How claude-mem works ## What it does Every Read, Edit, and Bash that Claude makes turns into a compressed observation. Observations get summarized at session end. Relevant ones get auto-injected into future prompts so the next session starts with context from the last one — no re-explaining the codebase, no re-discovering decisions. ## When it kicks in Memory injection starts on your second session in a project. The first session in a fresh project seeds memory; subsequent sessions receive auto-injected context for relevant past work. Run `/learn-codebase` if you want to front-load the entire repo into memory in a single pass (~5 minutes, optional). ## Where data lives Everything stays in ~/.claude-mem on this machine. Nothing leaves your machine except calls to whichever AI provider you configured for compression (Claude / OpenRouter / Gemini). The SQLite database, vector index, logs, and settings all live under that directory and are removed cleanly on `npx claude-mem uninstall`.