Anthropic Agent Memory: Dreaming, Wiki Scores and Design
Anthropic published a research post on November 6, 2026 that treats agent memory as a file design problem rather than a model feature. Memory, in this definition, is the experience knowledge that survives between sessions. A wiki built by an offline process Anthropic calls dreaming answered 48% of questions on its own after 128 dreaming sessions, up from 13% after 2 sessions, and search combined with the wiki reached 61%, ahead of search alone at 53%.
The sharper finding sits in a game evaluation. At roughly 10,000 steps into Pokemon Red, Claude Sonnet 3.7 had written 413 memory files across 225 folders and held 1 badge. Claude Fable 5, at the same point, kept 9 files in 2 folders plus a single global.md and held 4 badges. Claude Opus 5.5 kept a small memory folder and finished the game. More notes did not mean better memory. Curation did.
A Definition That Excludes Weights and Compaction
The post starts by narrowing the term. Agent memory is experience knowledge that remains between sessions. Weight changes are not memory under this definition, and neither are in-context learning or compaction. That boundary matters because it moves the design question out of training and into artifacts a team can inspect: which files exist, what each file claims, and how a later session decides what to load. A memory store built this way can be audited line by line, which a weight update cannot.
The hard part, as Anthropic frames it, is timing. At the moment an event happens, an agent usually cannot know whether that event will matter later. Human memory consolidation during sleep is the analogy the post uses, and the architecture follows it directly. During a session, the agent flags salient events. Between sessions, a separate offline pass does the slow work of checking, correcting and reorganizing.
Dreaming as an Offline Repair Pass
Dreaming is that offline pass. It replays logs after the session ends, corrects memory against the original record and creates new expressions that compress what was learned into reusable form. The concept comes from sleep-time compute, proposed by Letta and UC Berkeley researchers. The practical effect is a division of labor: fast, shallow note taking while work is happening, and slow verification when nothing is waiting on the answer.
That split also explains why the post resists fixed writing rules. If the offline pass exists to judge what mattered, then the in-session instruction only needs to capture candidates. Judging quality too early, before the outcome is known, throws away signal that the later pass could have used.
Pokemon Red and the Cost of Writing Everything Down
The Pokemon Red evaluation makes the curation point concrete. Claude Sonnet 3.7 wrote memory aggressively and ended up with 413 files in 225 folders at about 10,000 steps, with 1 badge to show for it. Claude Fable 5 wrote far less: 9 files in 2 folders, organized around one global.md, and held 4 badges at the same point. Claude Opus 5.5 also kept a small memory folder and completed the game.
Read as a design result, the folder count is the metric. A memory system that spawns a new file for every observation creates a retrieval problem identical to having no memory at all, because the next session still has to find the one note that matters. The models that performed better treated memory as a small, edited document set. For teams running coding agents today, that suggests reviewing memory files with the same discipline as documentation: merge aggressively, delete stale entries, and keep one obvious entry point.
CL-Bench and the First Closed Learning Loop
On CL-Bench 1.0 tasks, the post reports that Claude Opus 5 was the first model to close the learning loop. For each item, it recorded a rule together with the path by which it learned that rule, plus its previous answer and a warning about the trap involved. That structure is worth copying even outside Anthropic systems. A rule without provenance cannot be rechecked when it starts failing, and a warning about the specific mistake is more useful to a future session than a summary that everything went fine.
This is also where the definition pays off. Because memory here is plain files, the learning loop is visible: a rule, its origin, a prior answer and a caution, all stored where the next run can read them. Nothing about the loop requires retraining, which means a team can adopt the format before it adopts any particular model.
A Wiki Built by Dreaming, Tested on 350,000 Documents
The largest evaluation used dreaming to build a wiki over an internal corpus of about 350,000 documents and roughly 420M tokens, then scored answers to 25 questions. Scaling dreaming sessions from 2 to 128 lifted wiki-only answers from 13% to 48%. Combining search with the wiki moved scores from 54% to 61%, while search alone scored 53%.
Two cautions belong next to those numbers. First, the wiki alone at 48% still trails plain search at 53%, so a generated wiki is a complement to retrieval rather than a replacement for it. Second, the post notes cases where the wiki grew larger than the source documents it summarized. A representation layer that expands instead of compressing has failed at abstraction, and it will keep failing quietly unless someone measures wiki size against corpus size. Both cautions are stated in the post itself, and both are easy to miss if the headline percentages travel alone.
Fixed Rules That Hurt Stronger Models
One experiment in the post should unsettle anyone hand tuning agent instructions. When models were told to record only failures, both Opus 5 and Opus 4.7 lost a substantial part of the performance gain they had been getting from memory. A rule that sounds like common sense, keep the failures and drop the noise, removed context the models were apparently using: successful paths, partial progress and the reasons a failed attempt failed.
The broader lesson is that memory policy is itself a model dependent variable. Instructions written for a weaker model can cap a stronger one, because the stronger model was extracting value from material the rule discards. Letting the model judge what to write, then verifying offline through dreaming, is the alternative the post supports with its own numbers.
A Small Injection Layer in Claude Code
The design connects directly to a product detail. Claude Code automatic memory loads only the first 200 lines or 25 KB of MEMORY.md into session context. The injection layer is deliberately small, which puts pressure exactly where this research says it belongs: on keeping the top of the memory file curated, current and dense, rather than on accumulating a long archive that no session will ever read.
For any team maintaining a MEMORY.md style file for a coding agent, the operational rules follow from the numbers above. Keep the loaded slice small and edited. Store rules with the path that produced them and a warning about the known trap. Run an offline review pass that corrects notes against logs instead of trusting first drafts. And resist global writing rules, especially failure only rules, until an evaluation shows they help the model actually in use.
Open Questions on Cost, Cadence and Abstraction
Anthropic is explicit about what the post does not settle. The evaluations rest on internal tasks and benchmarks, and whether the same numbers appear in outside environments is unconfirmed. The post gives no cadence or cost criteria for dreaming, and it states plainly that checking every memory continuously is not practical. The wiki that outgrew its source corpus is a third open point: the representation step can fail at abstraction, and the post does not offer a general fix.
Those gaps limit how far the percentages should travel, but they do not weaken the structural claim. Memory split into fast capture, offline correction and a small curated injection layer is a design other agent builders can test today, with files they already control.
Related Reading
For another persistent agent design with memory at its center, see the report on Kiro Bots and persistent agents. For long lived agent workspaces, see Perplexity Teammates persistent agents.
FAQ
What counts as agent memory in the Anthropic research post?
Agent memory is the experience knowledge that remains between sessions. Weight changes, in-context learning and compaction are excluded from that definition.
What is dreaming in agent memory?
Dreaming is an offline process that replays logs between sessions, corrects memory against the original record and creates new reusable expressions. The term comes from sleep-time compute work proposed by Letta and UC Berkeley researchers.
How much did dreaming improve wiki answers?
As dreaming sessions grew from 2 to 128, answers based on the wiki alone rose from 13% to 48%. Search plus wiki rose from 54% to 61%, compared with 53% for search alone.
How much of MEMORY.md does Claude Code load into a session?
Claude Code automatic memory loads only the first 200 lines or 25 KB of MEMORY.md into session context, according to the Anthropic post.