About how-it-works
how-it-works is a claude-mem skill that records Claude’s file and shell actions as compressed observations, then brings relevant past work into later sessions. It is for preserving project context across sessions; its memory data is stored locally.
Key features
- 01Compressed observations from Read, Edit, and Bash
- 02Session-end summaries
- 03Relevant memory injected into later prompts
- 04Optional whole-repository memory seeding
- 05Local SQLite database and vector index
Use cases
- 01Resume project work with prior decisions in context
- 02Seed memory from an existing repository
- 03Keep session memory data on the local machine
Install
Copy the command and run it in a terminal.
npx skills add https:/ / github.com/ thedotmack/ claude-mem --skill how-it-worksAfter installing, type/how-it-worksin Claude Code to confirm it loaded.
Bundled filesonboarding-explainer.md
Details
From the project READMEHow 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). Local installs contact cmem.ai once, at signup, to create the sign-in link; nothing else is sent to cmem.ai. The SQLite database, vector index, logs, and settings all live under that directory and are removed cleanly on npx claude-mem uninstall.