# Agent Memory: Less Saved, More Recalled

> Published 2026-11-27T17:25:39.966Z on https://youblog.app/p/agent-memory-less-saved-more-recalled/
> Source video: https://www.youtube.com/watch?v=RmRfRhLABaU

Agent memory works better when it is small, curated, and rewritten between sessions. Anthropic November 6, 2026 write-up on agent memory components reports that in its own Pokémon Red test a Claude variant keeping a nine-file dashboard reached four gym badges while a variant hoarding 413 files managed one.

## What Anthropic agent memory research actually found

Anthropic November 6, 2026 write-up on agent memory components reports that a Claude build hoarding 413 files earned one gym badge in Pokémon Red while a build keeping a nine-file dashboard earned four. The result comes from Anthropic own test, which the video notes has not been reproduced independently.

The mechanism behind the gap matters more than the badge count. Money and map position were visible on screen every turn, so recording them cost memory budget without adding information. The gym plan had to be worked out in advance, and that is the part worth keeping.

Anthropic [agent memory post](https://www.anthropic.com/engineering/building-effective-agents) frames memory as four layers. Their write-up appeared in November 2026 and describes transcripts, notes, representations and injected context as separate stores with different costs and lifetimes.

In the Pokémon run, the models shared a memory folder through managed agents and played roughly 10,000 steps. The hoarding build wrote detailed notes on its own wallet. The lean build wrote a dashboard file holding the current goal, a pre-written gym plan and its own rules for using memory.

## The four-layer memory stack behind injected context

The four layers separate a raw record from what actually loads when a session starts, and only the top layer consumes tokens on every turn. Anthropic describes the hierarchy as a desk with drawers, where each layer up costs more and holds less.

- **Transcripts** are the searchable log of each session. This is the ground truth a reflection pass checks against.
- **Memory notes** are observations the agent decides are worth writing down itself.
- **Memory representations** are larger organized structures, such as a wiki built from many notes.
- **Injected context** loads before any work starts, and in Claude Code that means `CLAUDE.md` plus auto memory.

The 200-line guidance belongs to the injected layer, and it applies to auto memory specifically. The transcript's reading of the [Claude Code memory documentation](https://docs.claude.com/en/docs/claude-code/memory) is that auto memory hits a 200-line or size cutoff, while a `CLAUDE.md` you write yourself is not chopped at that line.

Anthropic stated case for keeping the top layer small is direct. Injected memories cost tokens every session, a wrong note gets carried forward indefinitely, and loading a note does not guarantee the model acts on it.

## What a Dream pass does to a wrong note

A Dream is a between-session pass that reads stored memory plus past transcripts and writes a new, corrected memory store without editing the original. Anthropic [managed agents documentation](https://docs.claude.com/en/docs/agents-and-tools/managed-agents) describes it as a research preview that must be requested.

The Pokémon run shows why a check against ground truth matters. A Claude build lost track of its position near a Pokémon center, announced the mountain was behind it, and saved a note reading Mount Moon done. It was not done. With the note uncorrected, the agent kept reloading a false fact.

During a Dream, the agent compared that note against the session transcript, caught the error and rewrote it. The corrected agent returned to Mount Moon and reached Cerulean City. Runs with the uncorrected note or with no memory at all never got past the mountain.

The reference implementation is a separate store, not in-place editing. A Dream reads the existing store and between 1 and 100 past transcripts, then writes a reorganized copy with duplicates merged, stale entries replaced and new insights surfaced. You can review the result or discard it.

Mechanically, a Dream is extra model work run while the agent is idle, and the cost is real. The managed agents docs put a Dream at minutes to a few hours at standard token rates. The sleep framing comes from sleep-time compute, a 2025 research direction on letting a model reason about a context before questions arrive.

## How CL-Bench measures cross-session learning

CL-Bench is a benchmark for agents that keep learning across sessions, and in Anthropic database task every question starts fresh with only a memory folder carried over. The setup tests whether an agent can turn a failure into a rule that survives into the next session.

When Claude got a question wrong, it could record the failure, propose theories, test them and promote what held up into a rule. Anthropic calls this closing the loop. The benchmark checks whether the saved rule reflects tested reasoning or an untested guess.

Anthropic reported that Opus 5 was the first model in its runs to close the loop, saving a rule together with the evidence for it. Sonnet 4.6 stored guesses it had not tested. Opus 5.5 and Sonnet 5.5 also closed the loop, and with memory they landed roughly level with Opus 5.

The practical difference is between a fact and a guess wearing a fact's clothes. A rule saved with its supporting evidence can be rechecked later. A guess saved plainly becomes another stale note waiting to load.

## Why telling the agent less beats fixing rules for it

On CL-Bench, simply telling Claude memory folder existed gave Opus 4.7 and Opus 5 a noticeable boost, while a fixed rule to record only failures cost both models much of that gain. Anthropic result runs against the instinct to constrain memory with stricter instructions.

That finding fits a wider pattern from practice. On the Claude subreddit, one user added a rule each time Claude ignored one, growing a `CLAUDE.md` from 45 to 190 lines. Trimming it back, by their own report, improved compliance quickly.

A second user described the cost side: the agent rereads the file every turn, so short stays cheap and long gets expensive. They also found their own rules contradicting each other with no clear winner.

Anthropic own framing is that these files are context rather than enforced configuration. The Claude Code docs advise aiming under 200 lines because longer files use more context and reduce adherence, without explaining why length hurts at the model level.

## What Harvey reported with Dreaming

Harvey, a legal AI company, told Anthropic that its agents use Dreaming to carry five-flight workarounds and tool-specific patterns between sessions. Anthropic managed agents announcement reports completion rates around six times higher with Dreaming enabled.

Treat that figure as Harvey's own test, as reported by Anthropic setup details or baseline numbers were published alongside it, so the six-times figure does not generalize to other workloads.

The informative part is what survived across sessions. The remembered material was workarounds, the things an agent had to figure out, which is the same pattern the Pokémon run rewarded.

## A practical checklist for your Claude.md and memory

Start by cutting the injected layer down to what an agent cannot look up. Trim `CLAUDE.md` under 200 lines and delete anything the agent can read from the repository itself, because every line reloads on each turn.

1. Count the lines in `CLAUDE.md` and remove rules the agent can infer from the codebase.
2. Delete rules that contradict each other rather than adding a tiebreaker above them.
3. Record what took reasoning, along with how you know it is true.
4. Tell the agent what memory is for and leave the method to the agent.
5. Read the top memory layer yourself periodically, as you would review a Dream's output.

The last step is the one people skip. A Dream produces a revised store you can read and reject, and an auto memory store deserves the same review. The agent's notes are claims, not verified facts until something checks them against the transcript.

If you run a local agent, the same shape probably carries over: a raw log at the bottom, a small file on top and a pass between sessions that reconciles the two. That is an inference from the design, and the sources discussed here do not test it on local models.

## Frequently asked questions about agent memory

- **What is agent memory in Anthropic framework?** Anthropic splits agent memory into four layers: transcripts, memory notes, memory representations and injected context. Only injected context loads at session start, which is why it carries the token cost on every turn.

- **Does a longer Claude.md make Claude forget?** Anthropic Claude Code documentation advises aiming under 200 lines because longer files use more context and reduce adherence. The docs do not explain the mechanism, and the 200-line auto-memory cutoff applies to auto memory rather than a file you write.

- **What is Dreaming in Claude managed agents?** Dreaming is a between-session pass that reads stored memory and past transcripts and writes a new reorganized store. The original is left untouched so you can review the result or discard it.

- **Was the Pokémon Red result independently verified?** No. The comparison came from Anthropic own test and has not been reproduced by an outside party, so treat the badge gap as a demonstration of a principle rather than a measured benchmark.

- **Should I install a memory plugin before trimming Claude.md?** Trimming comes first. A memory plugin adds more to the injected layer, and a bloated file already reduces how consistently Claude follows instructions.

## Turning a video into a written article

The lesson running through this research is curation: the agent that kept a short, true dashboard outperformed the one that archived everything. A technical talk recorded on video has the same problem, with hours of useful reasoning buried inside a single upload.

If you have explanations, interviews or lessons sitting in a YouTube video, [YouBlog](https://youblog.app/) turns that recording into a publishable article. Paste the URL, let it transcribe the video, and generate a draft you can edit. Dev doido workflows and Crazystack TypeScript projects can use the same route, with [Crazystack](https://crazystack.com.br) as the reference for the stack itself.

YouBlog keeps the structured reasoning from the source and drops the filler, which is the same principle that made the nine-file dashboard win.

[Source video](https://www.youtube.com/watch?v=RmRfRhLABaU)
