How do I make Claude Code remember project decisions across sessions?
Keep the decisions in a file that Claude Code is given again in the next session: you can write a CLAUDE.md by hand, or let jevmem do it, which saves the decisions, rules and failed approaches from your Claude Code chats to JEVMEM.md in your repo, and brings the relevant ones back next session.
In 72 real Claude Code sessions, Claude followed the project's saved decision in 66 with jevmem (66/72), in 28 with no project memory (28/72) and in 67 with the same lines in a hand-written CLAUDE.md (67/72). That was measured on 24 tasks in three small projects of 34 to 42 saved lines, 3 runs each, with Claude Code 2.1.281 and claude-sonnet-5, on 2026-09-28 and 2026-09-29 (no memory and CLAUDE.md, jevmem; method and limits).
Why a file #
Each Claude Code session starts with a fresh context, so what you decided last week lives in last week's chat.
A CLAUDE.md file helps if you keep it up to date. jevmem keeps a file like it up to date for you, as you work.
How jevmem does it #
- You decide something in a chat: "We use Postgres."
- jevmem asks Jev by TypeSafe AI, a model that answers yes/no questions with probabilities, whether it's worth keeping.
- If it is, jevmem writes one line to
JEVMEM.mdin your repo. - Next session, the lines that matter for your prompt go back to Claude.
Change your mind, and the old line is crossed out: kept for history, not sent to Claude. Your team gets the same file through git.
jevmem keeps decisions, rules, bugs, to-dos and dead ends (an approach that was tried and failed, with the reason).
- [superseded] We'll use SQLite as the primary store for now. → id:cuasaq
- [decision] Switch the primary store to Postgres 16.
- [constraint] Node 20 is the minimum supported version, and CI runs Node 20 and 22.
About these lines
Each line also carries a comment with its id, time and confidence, left out above. The full lines:
- [superseded] We'll use SQLite as the primary store for now. → id:cuasaq <!-- id:21ycba ts:2026-09-26T13:46:34.703Z conf:1.00 by:cuasaq -->
- [decision] Switch the primary store to Postgres 16. <!-- id:cuasaq ts:2026-09-26T13:46:35.240Z conf:1.00 -->
- [constraint] Node 20 is the minimum supported version, and CI runs Node 20 and 22. <!-- id:tollba ts:2026-09-26T13:46:35.763Z conf:0.90 -->
Real lines from 0.5.7's default writer, which 0.5.8 to 0.5.10 did not change (the run, 2026-09-26). It kept one sentence of each turn: the Postgres turn also said "SQLite locks up under concurrent writes", and that reason was left out. Since 0.6.0 the line is made from the sentences Jev picks, the one that states the memory and the one that gives its reason (What's new). With writer set, an OpenAI or Anthropic model condenses the whole turn instead.
Set it up #
You need a TypeSafe API key and Claude Code 2.1.273 or later.
- In the Claude app: Plugins → Discover → jevmem → Add.
- Install the CLI the plugin runs:
npm install -g jevmem - Save your key (paste it when asked; it isn't shown):
jevmem key - In your project's folder, turn jevmem on:
jevmem enable
Start Claude Code in that project. jevmem doctor checks the setup.
Other ways to install: the jevmem marketplace, npm, Cursor, Codex
From the jevmem marketplace:
npm install -g jevmem
claude plugin marketplace add Avinash-jetwani/jevmem
claude plugin install jevmem@jevmem
cd your-project && jevmem enable
With npm only (also sets up Cursor and Codex):
npm install -g jevmem
cd your-project
jevmem init --tool claude # or cursor, codex, claude-desktop, all
Already have a CLAUDE.md? jevmem import shows what it would add from it; --apply writes it.
Every step, and what to do if the plugin can't find the CLI: docs/install.md.
CLAUDE.md, auto memory and jevmem side by side #
There are two kinds of memory besides Jevmem, and it replaces neither. Auto memory is per tool and per machine. Project instruction files are per repository, and one of them is not tied to a tool: AGENTS.md is read by Claude Code (2.1.277 or later), Cursor and Codex. What Jevmem adds is a file that is kept current for you and read per prompt.
Built-in auto memory (e.g. Claude Code's, under ~/.claude/projects/… on your machine) |
Project instruction files (CLAUDE.md, AGENTS.md, .cursor/rules/) |
Jevmem | |
|---|---|---|---|
| Scope | Per tool, per machine. Claude Code's is on by default, machine-local, and one folder per repository (its worktrees share it) | Per repo. AGENTS.md is read by Claude Code (v2.1.277 and later; by default only when there is no CLAUDE.md), Cursor and Codex; CLAUDE.md by Claude Code; .cursor/rules/ by Cursor |
One JEVMEM.md per repo, read by Claude Code, Cursor, Codex and Claude Desktop |
| Shared with the team | No | Yes, committed files reviewed in PRs | Yes, a committed file reviewed in PRs |
| What a session sees | Claude Code: the first 200 lines or 25 KB of its MEMORY.md index at the start of every session; the notes it points to when Claude opens them |
The whole file (Claude Code: up to 4 MiB), at the start of every session | The lines Jev judges relevant to each prompt, at most five (The read side) |
| Who keeps it current | The tool (Claude Code: Claude, when it judges a note worth keeping) | You, by hand | Jevmem, after every Claude Code turn (and Codex turns under watch, and agent add_memory calls) |
| Why a line exists | No per-line scores that we know of | You wrote it | Per-line scores on the machine that saved it: jevmem why <id> shows every noul, the kind distribution, importance, and which threshold it cleared |
| What happens on a reversal | Not measured here | You edit it (history if the file is in git) | The old line stays, tagged [superseded] … → id:new, so history and blame survive |
| Corrections | Edit its files | Edit the file | right / wrong / missed labels, and fit retunes the thresholds to your judgement |
Claude Code's auto memory and instruction files are described at https://code.claude.com/docs/en/memory (read 2026-09-28; its AGENTS.md section, read 2026-09-29, gives v2.1.277 and when AGENTS.md loads instead of CLAUDE.md). AGENTS.md in Cursor: https://cursor.com/docs/context/rules; in Codex: https://developers.openai.com/codex/guides/agents-md; the format: https://agents.md (all read 2026-09-29). The instruction files are shareable today; Jevmem's difference is that it maintains its file automatically and scores each line. Both can run at once; the end-to-end harness checks that Jevmem behaves the same with Claude Code's auto-memory present or cleared.
Rules that must apply to every task belong in CLAUDE.md. Jevmem puts a line in front of Claude when Jev judges it relevant to the prompt at hand. A rule that holds for a whole class of changes, with nothing in a given prompt pointing at it, can be missed. In the outcome A/B, the convention that every user-facing string goes through t() was never injected for a prompt to add a button, and Claude followed it in 0 of 3 sessions; with the same line in CLAUDE.md it did in 3 of 3 (Benchmark). So put the rules every task must follow (a convention for all code, how every commit is made, what must never be run) in CLAUDE.md or AGENTS.md, which the tools load at the start of every session. Leave the rest to Jevmem: the decisions, dead ends, bugs and facts that pile up as you work, which change as the project moves, are soon too many to load whole, and matter only when a prompt touches them. The two work side by side. Jevmem neither reads nor changes CLAUDE.md (only jevmem import reads it, when you run it).
The same comparison with other memory tools for Claude Code: jevmem compared.
The limits, in short #
- jevmem needs a TypeSafe API key (where to get one, and the install steps).
- Message text is sent to TypeSafe to be scored, with common secrets scrubbed first (what leaves your machine).
- It is automatic in Claude Code, automatic in Codex while
jevmem watchruns, and in Cursor only when the agent calls it (what each tool does). - Rules every task must follow still belong in
CLAUDE.md(jevmem next to CLAUDE.md). - The guard is a backstop, not a sandbox (what it misses).
Every limit, with the numbers: the FAQ.