Anthropic published a research post on 6 November called The components of agent memory, and it opens by borrowing Kierkegaard: life can only be understood backward, but it must be lived forward. The bind they describe has the same shape. An agent has to decide what is worth remembering before it knows which future will need it. Their definition of memory is experience that survives the session, stored as context it can read later, kept apart from changes to the model's weights, from what it learns inside one conversation, and from the summaries that replace its older turns when the window fills up.

The machinery they borrow is sleep. The hippocampus replays the day during quiet rest and folds part of it into long-term knowledge; researchers at Letta and UC Berkeley proposed the agent version as sleep-time compute, using idle time between interactions to reorganize what the agent already has. Anthropic's word for it is dreaming, and in their account the offline pass corrects wrong notes, writes new ones, builds linked wikis, and promotes a few lines to load before the next session starts. On CL-Bench, a test of whether an agent can use memory across long tasks, Sonnet 4.6 left files of untested guesses. Opus 4.7 consolidated the notes and marked which facts were checked and which were not. Opus 5 was the first to close the loop, its entries carrying a rule, the evidence that the rule was true, and warnings about traps it had found the hard way.

The game test asks what an agent should store at all. Claude played Pokémon Red with a folder of memory files it could read and write. Two runs, both about ten thousand steps in, came out differently. Sonnet 3.7 assumed everything might matter: a file for each battle, each item, each non-player character. It finished with 413 memory files in 225 folders and one badge, badges being the milestones that mark progress through the game. Fable 5 wrote nine files in two folders plus one top-level file, global.md, a dashboard holding its current goal, its plan for the gyms, and its own rules for using memory. Four badges. Opus 5.5 kept a small folder, rewrote its notes as it played, and beat the game.

Sonnet 3.7 413 files · 225 folders · 1 badge Fable 5 9 files + global.md · 2 folders · 4 badges accent dot: global.md, the dashboard Opus 5.5 small folder, rewritten as it played: it beat the game (no file count given in the post)

Each dot in the left field is one memory file Sonnet 3.7 wrote during a Pokémon Red run; 413 dots, drawn to count. The nine dots plus the accented dashboard file are Fable 5's memory at a comparable step count. File and badge counts are the post's own, and the figure was built for this note.

Most of what Sonnet 3.7 stored went stale before it could be used. Money in the wallet and position on the map can be read off the screen every turn, so storing them is redundant, while strategy, plans, and tested rules exist only if the agent works them out and writes them down. Combing through that record spent the budget of playing. At one point around step 10,000 it opened its fourth folder of master memory files. Over the next seventeen steps it created six files, deleted nine, and took no actions in the game itself.

The wrong-landmark story is told in full detail, and it is the heart of the post. In Mt. Moon there is a one-way ledge near the entrance, a drop with no clear way back up, and whether Claude walks off it depends on which side of the mountain it believes the PokéCenter is on. Claude wrote down, incorrectly, that the PokéCenter was on the east side. Walking out, it announced "Mt Moon is behind me," and updated its notes: "Mt Moon DONE." Mt. Moon was not behind it. A few actions later it went over the ledge and landed back on the route it had come from. The navigation tool did not show the drop, so Claude concluded it had "overshot far west" and had been on the correct side all along. It had not. In a second run, dreaming on the same folder had Claude check the note against the session transcript, catch the error, and rewrite the note; the transcript, as the post puts it, gave Claude a ground truth to validate its memory against. With the corrected note it went straight back into the cave and reached Cerulean City. In the run with the uncorrected note it dropped onto that earlier route three times, and after the third failure wrote "I'm going to stop rather than keep looping." An automatic reply told it to continue, and it walked all the way back to Pewter City, hoping to heal and restock. That run ended without Cerulean, and so did the run with no memory at all.

Mt. Moon west entrance east exit Cerulean City note: PokéCenter is on the east side incorrect, and trusted note rewritten after checking against transcripts the next session reads it and acts drops back on the old route three times, limps to Pewter, never reaches Cerulean session transcripts, the ground truth dreaming: check the note against the receipts

The dreaming loop, drawn from the post's Mt. Moon example: an incorrect landmark note, trusted by the next session, sends Claude over the one-way ledge three times; a dreaming pass re-reads the session transcripts, rewrites the note, and the run reaches Cerulean City. Cave, ledge and city positions are illustrative. The note, the error, the loop count and the outcomes are the post's account, and the figure was built for this note.

They also tested how to tell a model about its memory, and one finding complicates the usual setup. General guidance was enough: tell Claude what memory is for, not how to use it. When a fixed rule said "record only failures," both Opus 5 and Opus 4.7 lost most of the performance boost memory had been giving them. For stronger models, freedom to judge salience beat any rule set in advance, and some rules made performance worse. The steering helped where judgment was not yet there. Prompting Sonnet 4.6 to read its memory before answering, and to test its theories explicitly, nearly doubled its benchmark score. Sonnet 5 reads its memory before answering nine times out of ten, unprompted; Sonnet 4.6 did it less than half the time.

The third use of dreaming is building representations. A wiki, in their sense, is a collection of linked pages written and maintained by the agent itself. They built one from a corpus of about 350,000 internal files, roughly 420 million tokens, from Stainless, the company it acquired in May, over the 25 questions they wrote, with agents instructed to write or fix pages, merge duplicates, and check claims against sources. Scaling dreaming from two sessions to 128 moved graded criteria met from 13 percent to 48 percent. The combinations matter more: the wiki alone scored 48 percent at best, plain search 53, and search plus a growing wiki rose from 54 to 61 while saving about 20,000 tokens per question. On 24 questions about a merger, most of which needed information from several documents at once, the wiki route hit 87 percent against 73 for search alone. Where a single document held the answer, the wiki showed no clear gain. On another task the wiki grew larger than the documents themselves, a map the size of the empire, abstracting nothing, which is Borges, and they cite Borges. The same lesson lives in a small grid. Several agents summarizing contract terms into one shared table left only 41 of 57 facts in the brief graded from it. One agent per contract, each page quoting terms word for word, kept 57 of 57.

shared table, summarized by several agents at once 41 of 57 graded facts survived · 72% one agent per contract, terms quoted word for word 57 of 57 survived · 100%

Each dot is one graded contract fact from the post's merger task. Outlined dots are facts the summarizing agents lost: overwritten in a shared table in the top row, quoted verbatim and kept in the bottom row. Counts are the post's own, and the figure was built for this note.

The last role is promotion, and it comes with a price sheet. Dreaming floats some notes to the top of the hierarchy, where the harness preloads them into every session's context. Every injected token is spent every time, a wrong injected note rides along forever, and loading a note does not guarantee the model acts on it: their own Claude Code documentation warns that longer instruction files reduce adherence. So the top layer stays small, and much of dreaming's work is moving detail down the hierarchy and leaving links behind. Claude Code's auto memory runs the same budget by hand. It loads only the first 200 lines or 25 kilobytes of a MEMORY.md file, an index of what it knows and where to look.

injected into every session first 200 lines or 25 KB of MEMORY.md · an index, not a payload promoted notes floated up by dreaming, pushed down when the top gets costly wikis and memory notes read or searched when needed, links between pages raw session transcripts the ground truth every note is checked against promotion by dreaming detail pushed down, links left behind every token here is spent in every session

The memory hierarchy as the post describes it: dreaming moves content between layers, and the injected top stays small because longer instruction files reduce adherence, their own warning about Claude Code. Band widths and order are a drawing choice. The layers, the 200-lines-or-25-KB budget and the arrows' behaviors are the post's, and the figure was built for this note.

Editorial

The ledge story is the whole field in one cave, and I keep returning to what actually went wrong. The note was not malicious and not even unusual; it was confident. The failure came after, when the bad note made a flattering explanation possible: Claude had not taken the wrong path, it had merely overshot. A memory system that fails this way is not remembered as a bug. It is remembered as truth, and the interesting part was always the audit, not the storage. The fix Anthropic proposes has no poetry in it. Run the model over the transcripts offline and compare notes against receipts. That is the whole trick, and I think it is the right one.

The rulebook result is the awkward one to carry home. If a product ships memory the cheap way, it ships one rulebook for every model, and that is close to what their measurement punishes: bolt on a policy, record these kinds of things, never record those, hand the model a filing cabinet and call it a brain. For the two stronger models tested, the better policy was one sentence about purpose and a closed mouth about method. Weaker models did need the steering, which is the honest version of the finding: rules help the young and hurt the seasoned. One setting for all agents is the shape that result warns against.

Discount what you should. Every number in the post is Anthropic's. Some eval sets are the company's own, mostly twenty-five questions. The benchmarks are ones the post names rather than claims to have built. None of it has been reproduced by anyone else as far as I could find, and the model-ladder comparisons move the model and the memory tooling in the same step, so capability gains and design gains travel confounded. Search plus wiki buying eight points over search alone is a modest dividend for an entire offline wiki factory, and the token savings are the more durable claim in that set. The structural claims survive the discounting, and structure does not need a leaderboard. The transcript stays the ground truth. The injected layer earns its place as an index, and detail that costs more than it returns goes down a level with links left behind. In the contract grid, quoting the terms beat summarizing them outright.

The open questions they leave are the right ones, which is how you can tell the post is doing research rather than launch work. Write now or dream later, since logging in the moment taxes the attention of the task itself. How often to dream, since checking everything is unaffordable and their suggestion is to tune cadence to how often a memory gets read. And the sentence underneath all of it, that no model can really know what its future turns will need. Given that bind, memory is a loop, not a place. I expect most serious systems will land in the same shape: store less than you feel like storing, and keep the receipts. Run the two against each other when nobody is watching.