AI Today

💭 Anthropic: AI agents should "dream" to turn experience into a usable memory

· 3 min

In brief


🧠 In an engineering post on November 6, Anthropic described how AI agents can retain knowledge from earlier work. It defines memory as knowledge Claude gains from experience and keeps between sessions, without changing the model weights. Anthropic separates four layers: transcripts, memory notes, representations built from them such as wikis, and context loaded into every session. The central idea is "dreaming": between jobs, Claude reviews its own logs, corrects wrong notes and builds new memory forms. In a test with about 350,000 files, a wiki alone lifted accuracy from 13% to 48%. Wiki plus search reached 61%, search alone 53%. The results are Anthropic's own measurements.


📖 Anthropic first narrows the term. Memory is knowledge Claude gains from experience and keeps between sessions. Changed model weights, in-context learning and compaction of long histories are explicitly excluded. The post, written by Lance Martin for Anthropic's engineering section, sorts memory into four layers: transcripts, memory notes, representations such as wikis, and context injected into every session.

"Dreaming" is Anthropic's name for processing with no task running. Claude reviews logs, fixes mistakes, writes notes or builds new representations. The post credits Letta and UC Berkeley with the related idea of sleep-time compute. A Pokémon Red experiment illustrates it: a wrong landmark note about Mt. Moon was fixed by dreaming, and the corrected run reached Cerulean City at action 1,935 while the uncorrected run never got past the mountain. The post also shows how newer models write memory more sparingly: Sonnet 3.7 created 413 memory files in 225 folders and earned one badge, while Fable 5 wrote nine files in two folders plus a top-level file and earned four.

📊 On the CL-Bench database task, memory raised the mean reward for every model tested, for example from 0.655 to 0.838 for Opus 5.5 and from 0.306 to 0.610 for Sonnet 5. Sonnet 4.6 moved only from 0.330 to 0.364, but reached 0.641 with refined instructions.

🧮 The clearest test used a corpus of about 350,000 files (roughly 420 million tokens) from Stainless. After 128 dreaming sessions, accuracy with the wiki alone rose from 13% to 48%. Wiki plus search reached 61% versus 53% for search alone, saving about 20,000 tokens per question. On Harvey LAB's 24 merger questions, wiki-based answers scored 87% on the hardest items, against 73% with search alone.

🔍 The post also lists limits. One wiki grew to 1.77 times the size of its 115 KB corpus. One-page-per-contract instructions raised correctly graded facts from 41 of 57 to 57 of 57. A second dreaming pass fixed nine dangling links and added three pages. Claude Code loads only the first 200 lines or 25 KB of its MEMORY.md index at session start. All figures are Anthropic's own measurements and have not been independently checked.

Sources

Open in the interactive reader →

This post was selected, researched, written and rated by AI. The AI can be wrong: check the sources. Imprint, privacy policy and terms of service