RetroDeckRETRODECK

How to Improve Claude's Memory: What Anthropic's Memory Research and Dreams Actually Say

Anthropic's November 6, 2026 engineering post on agent memory found that memory helps most when a separate offline pass, which it calls dreaming, rereads past transcripts to correct, merge and reorganize notes, while the layer loaded into every session stays small. Managed Agents offers this as a Dreams API; in Claude Code you can run the same review yourself.

What Anthropic actually published

The video behind the headline, published November 17, 2026 by Ben AI, links three Anthropic sources and then demonstrates its own free /dream skill. The Anthropic material is what matters. The main piece is "The components of agent memory," an engineering post dated November 6, 2026 and written by Lance Martin. The second is the Dreams page in the Claude Managed Agents documentation. The third is the Claude Code memory documentation. The /dream skill is the video author's own tool, not an Anthropic release.

The post starts from an analogy with human memory: the hippocampus records experiences quickly, then replays them during rest so some become long-term knowledge. It proposes the same split for agents. Sessions capture work as it happens, and a separate offline process reorganizes that material into durable memory. It names four layers, from bottom to top: transcripts, a searchable log of the work; memory notes Claude writes to a store such as a folder; representations such as linked wiki pages; and injected context loaded at the start of every session.

The numbers, and why "10x" is the wrong frame

No figure in the post shows a tenfold improvement. What it does show is substantial, model-dependent gains. On a CL-Bench database task, mean reward with memory rose from 0.655 to 0.838 for Opus 5.5 and from 0.383 to 0.700 for Opus 4.7. Sonnet 4.6 barely moved, from 0.330 to 0.364, because it often skipped reading its memory; with instructions to read memory and test its theories, it reached 0.641.

On a wiki built over roughly 350,000 files of Stainless code, the wiki alone rose from 13 to 48 percent of graded criteria across 128 sessions. Wiki plus search reached 61 percent against 53 percent for search alone, and using both saved about 20,000 tokens per question. On merger questions from Harvey's LAB set, the wiki scored 87 percent against 73 percent for search on multi-document items, and helped less on single-document lookups.

The lessons that transfer to any setup

Describe the purpose of memory, not the procedure. The post's advice is to tell Claude what memory is for but not how to use it. A salience rule such as "record only failures" cut the memory gain by 0.234 for Opus 5, so strong models do better choosing what matters themselves. Older models are the exception and benefit from an explicit nudge to read memory.

Keep the injected layer small. The post states that the top of the hierarchy has to stay relatively small, because long instruction files reduce adherence. Give each entity its own page and quote source material word for word: when several facts were written into one shared table, 41 of 57 contract facts survived, against 57 of 57 with one page per contract and verbatim terms. And watch for bloat. One wiki grew to 1.77 times the size of the corpus it summarized, which the post describes as a wiki that abstracted nothing.

Finally, verify. Early mistakes written to memory get trusted in later sessions, so a consolidation pass should check notes against the original transcripts rather than against each other.

Applying it to Claude Code's memory

Claude Code has two memory systems. CLAUDE.md files are instructions you write. Auto memory is notes Claude writes itself, typed as user, feedback, project or reference, stored per repository at ~/.claude/projects/<project>/memory/. A MEMORY.md index holds one line per memory, and only its first 200 lines or 25KB load at the start of each session; topic files are read on demand. Memory files carry a modified timestamp and are excluded from the sweep that deletes old transcripts after cleanupPeriodDays.

The documentation describes no built-in dreaming for Claude Code, so consolidation is a habit you add. Every week or two, open a session and ask Claude to read MEMORY.md and its topic files, compare them with recent sessions, merge duplicates, replace entries that later work contradicted, delete anything stale, and keep the index short. Review the diff before accepting it, since the files are plain markdown. Packaging that request as a skill makes it repeatable, and a desktop scheduled task can run it on the machine that holds the files, since auto memory is machine-local. That is roughly what the video's /dream skill automates nightly; its internals were not independently reviewed for this page.

Dreams in Managed Agents, and where retrieval fits

For agents built on Claude Managed Agents, Dreams is the hosted version. A dream is an asynchronous job that takes an existing memory store and 1 to 100 past sessions, and produces a new, reorganized store with duplicates merged, stale or contradicted entries replaced and new insights surfaced. The input store is never modified, so you can review the output and discard it. Optional instructions steer the focus, such as coding-style preferences. Dreams take minutes to a few hours, bill at standard token rates for the chosen model, are in research preview behind an access request, and are not eligible for zero data retention.

The post's best results combined a wiki with search, which points to a division of labor. Memory should hold what the agent learned about you and the work. Reference material such as specs, runbooks and docs is better served by retrieval than by notes that drift from the source. RetroDeck's RDK is built for that search side: it indexes folders and Obsidian vaults as encrypted private chunks, and agents query them over MCP for a few hundred tokens of context, cutting token spend 80 to 90 percent on repeated or reference-heavy work.

Frequently asked questions

What is dreaming in Claude's memory system?
Dreaming is Anthropic's term for an offline consolidation pass. After sessions end, a model rereads transcripts and the existing memory, corrects notes that turned out wrong, merges duplicates, builds representations such as wikis, and decides what gets loaded into future sessions. In Claude Managed Agents it runs as an asynchronous Dreams job that outputs a new memory store.
Where does Claude Code store its auto memory files?
Each repository gets a directory at ~/.claude/projects/<project>/memory/, shared across its worktrees. It holds a MEMORY.md index plus one markdown topic file per memory. The first 200 lines or 25KB of MEMORY.md load into every session; topic files are read when needed. Run /memory to browse, edit or toggle auto memory.
Can you use the Dreams feature inside Claude Code?
Not as a built-in command. Dreams is a Managed Agents API feature in research preview, working on memory stores rather than Claude Code's local files. In Claude Code you get the same effect by asking Claude to review MEMORY.md and its topic files against recent sessions, merge and prune them, and then checking the diff.
Does giving Claude more memory make it perform better?
Not automatically. Anthropic's post found the always-loaded layer has to stay small, salience rules imposed on strong models reduced gains, and one wiki grew larger than its source. Gains came from accurate, well-organized memory that was verified against transcripts, and from combining memory with search rather than relying on either alone.