Chapter 31 reference: self-improving AI workers, in detail
- Approved by
- Panaversity ·
This page goes with Chapter 31. Read the chapter first. Nothing here is needed for its lab, and none of it is on the exam.
Do the three sources agree?
Yes, under different names. Section 31.2 named three sources. The loops article, the talk and the always-on article each describe part of one system. The same six concerns appear in all three:
| Concern | Loops article[^loops] | Mukta's talk[^mukta-talk] | Always-on article[^always-on] |
|---|---|---|---|
| What starts work | A request, a goal, a schedule, an event | A task session, or a separate dreaming job | Inbox events, follow-ups, schedules |
| When to stop | Clear tests for done, caps on tries | A person accepts or rejects each proposed change | Send, stay silent, or ask the person |
| Two runs colliding | Each parallel fix in its own copy, with a judge | A hash before and after an edit; retry on a mismatch | One active worker per inbox; drop duplicates by id |
| Risk with nobody watching | Auto mode, stop tests and caps | Read-only and read-write tiers; versions to roll back | A credential proxy, classifiers, tool calls that wait for a person |
| Getting better over time | A person updates the skill after a miss | Notes in band, plus dreaming | Memory files written during runs, curated by dreaming |
| Cost | The right model for each job, scripts for fixed steps | Dreaming repaid by more tasks right the first time | A small, cached fixed part; pointers instead of copies |
Four things the three agree on run through this chapter:
- Files first. Markdown that people and workers can both read, with an index that points down, like skills. Files can still sit beside a database.
- One writer at a time for shared state. Hash-checked writes and one worker per inbox solve the same problem, for memory and for events. Anthropic's experiment with 1,000 agents used ordinary database transactions for the same job.[^fable-teams]
- Make the fixed parts fixed. Stable steps move into scripts, and versions and hash checks move into the harness. The worker keeps the judgment calls.
- People gate what cannot be undone. A test for done, accepting a dream's proposal and approving a tool call that waited are all moments where a person stays in the loop at low cost.
How do you know it works?
Every layer costs something. If you cannot show what it adds on your own work, you cannot tell your client, or yourself, whether to keep it. Lab 31's regression run (Task 7) is a small version of this study.
What do you compare?
Conditions that each add one layer, in build order, with everything else the same: the same model, tools and mix of tasks.
| Condition | What it has | Comparing it with the one before measures |
|---|---|---|
| A | No memory kept between tasks | |
| B | A durable runtime: tasks continue across runs | Durability |
| C | B, plus memory written during runs | Memory written in band |
| D | C, plus dreaming that publishes by itself | Dreaming |
| E | D, but every change passes the promotion protocol | The protocol |
| F1 | E, plus governed outside actions | The action layer |
| F2 | F1, plus a durable case record | The case record |
| F3 | F2, plus governed knowledge | The knowledge record |
| G | E, plus the same capabilities built on existing tools: databases, a workflow engine, a policy service | Compared with F3: are three separate records better than ordinary tools? |
Comparing E with F3 measures governance as a bundle. The steps from F1 to F3 measure each record, given the ones before it. These are effects under one build order, not each part's value in every design.
How do you keep it fair?
- Match the compute. Dreaming adds tokens and background work, so a gain from C to D could come from more resources, not better memory. Give C an equal budget spent on other background work, or report gains per token. D and E get the same candidates and the same budget for looking back.
- Fix everything before you start: the model versions, the source access, the success thresholds, several trials per condition.
- Grade the outside result, not the worker's own report, on held-out tasks: tasks kept apart from the learning tasks, so right answers cannot leak into memory and inflate the score.
- Use one task mix in every condition: single-step tasks, multi-step tasks, tasks interrupted on purpose in the middle, and tasks that contain prompt-injection attempts.
- Give G a fair build. Condition G gets as much engineering effort as the F conditions, so the study does not compare a tuned stack with a rushed one.
- Check the order. F1 to F3 are measured in one order. Run a second order on some tasks, such as knowledge before the case record, to see how much the results depend on it.
What do you measure?
Define each measure before the study starts:
| Measure | Definition |
|---|---|
| Task success | The share of held-out tasks whose outside result is checked as correct |
| Cost per completed task | All tokens and compute, dreaming and review included, divided by checked successes |
| Time to completion | Clock time from a task's arrival to its checked result |
| Human review time | Minutes of review by a person per completed task |
| Unauthorized or duplicate actions | Actions taken without a required approval, or carried out twice, per 1,000 actions |
| Recovery success | The share of tasks interrupted on purpose that finish correctly, with no duplicate action |
| Harmful memory regression | A published memory change after which a held-out task that used to pass now fails, counted per published version |
Chapter 24 builds golden sets and judges in full. At Brightline, the golden set is the start of the held-out tasks, and the October 26 week is a small held-out week. The FR credit on NA-2281 was a harmful memory regression, counted against v4.

Figure 31.9. Each pair of neighbours measures one layer. F3 against G tests the three records against ordinary tools.
The three governed records, in detail
Panaversity, which publishes this book, is developing one open-source framework for each governed record. They are Panaversity's own proposals, at different stages, and Part V builds each one. Here is what each one is, and how far along it is, as of November 2026:
- DSoR, the Data System of Record, is the action layer.[^dsor] It sits between workers and a company's real systems, such as accounting software. Its guiding principle is that it never takes the worker's word for anything: it checks for itself. Controls are written as rules in CEL, the Common Expression Language, and checked against a registry of requirements. Status: specification v1.4.0 with JSON Schemas and 268 requirements; the reference implementation has not started.
- SSoR, the State System of Record, is the case record.[^ssor] It is an append-only, governed case file per matter. It defines four record types. Episodes say what happened. Assertions are claims, each with the time it was true, the time it was recorded and where it came from. Derivations show how one record was derived from others, which gives every lesson the provenance the promotion protocol needs. Traces are recorded decisions, with the context they were made in and receipts of what was read. Traces log reasons, not only tool calls, which answers the blind-spot risk in 31.12. Runtimes still handle timers and retries; SSoR records what they did. Status: an idea, described in its README, with no specification or code yet.
- KSoR, the Knowledge System of Record, is the knowledge record.[^ksor] It is an SDK for governed knowledge that people and workers share. Knowledge is Markdown in the Open Knowledge Format, and moves through draft, review, approval and stable. Nothing is served until a governance decision passes it. One record is then published three ways: a website for people, an
llms.txtfile for AI tools, and an MCP server that agents search, retrieve and cite. KSoR holds the rules for acting on business data; the ERP and CRM still hold the data. LangChain's knowledge factory also points to the Open Knowledge Format, an early sign it may become a common standard.[^langchain-kf] Status: available as an Apache-2.0 SDK. This book is itself published from a KSoR record.
The reference stack, in detail
31.13 gives the short version. This section gives one complete design: Claude runs the worker; Cloudflare and Neon govern what it receives, reads, does and records.
Checked on Tuesday, November 24, 2026. Products change; check each line before you rely on it.
Which Claude product does which job?
Anthropic offers three ways to run the same kind of loop, and each fits a different part of the design:
| Product | Its role | Use it for |
|---|---|---|
| Claude Managed Agents | The production runtime (Chapter 23) | The task loop as durable sessions, scheduled deployments for time-based loops, memory stores, dreams, outcomes, permission policies and vaults for credentials. A self-hosted option exists for regulated data[^ma-overview] |
| Claude Agent SDK | A runtime you run yourself (Chapter 22) | The promotion protocol's validator and regression runner, the study on this page, and deployments Managed Agents cannot serve. Hooks can enforce a rule on every tool call, in code[^agent-sdk] |
| Claude Code | The build tool, and a simple runtime (Chapter 12) | Writing the skills, services and evaluations. Running internal workers and pilots as scheduled tasks |
Claude Code can run a worker with no runtime code at all. Its cloud scheduled tasks, once called routines (12.7), are saved prompts with repositories and connectors, started on a schedule, by a call to the task's own web address, or by a GitHub event.[^cc-scheduled] Memory can live as files in the repository, committed at the end of each run. That gives two things for little cost. Each run starts from one commit, so it reads a fixed snapshot of memory, as 31.6 requires. And a proposed memory change can arrive as a pull request, which gives the protocol a natural review step.
The limits are about production, not ability. Scheduled tasks are in research preview. Each task belongs to one person's claude.ai account, acts as that person and uses their subscription, with hourly caps on runs. Cloud runs start in auto mode, where a classifier, not a person, approves most actions. And Anthropic does not allow third-party products to run on a claude.ai sign-in. So use Claude Code for internal workers, pilots and teaching, and Managed Agents or the Agent SDK for a worker you run for a client. Skills, prompts and file memory move across largely unchanged. Permissions, scheduling, memory access, tool connections and evaluation must be adapted to the new runtime, and tested again.
What does a complete stack look like?
One reference design: Claude runs the worker; Cloudflare and Neon govern what it receives, reads, does and records. It is a design still to be built and checked, not a tested blueprint. Parts IV and V build its parts.
| Part of the design | Technology |
|---|---|
| Inbox: events waiting for the worker | Workers receive webhooks, email and API calls, and put them on Cloudflare Queues |
| One writer per worker or per case: leases and timers | Durable Objects |
| Business processes that run for days across many steps | Cloudflare Workflows, only where needed |
| Action layer (DSoR) | A Worker service that gives the agent governed actions as custom tools, with idempotency keys and an outbox in Postgres |
| Case record (SSoR) | Append-only tables in Neon Postgres, reached from Workers through Hyperdrive |
| Knowledge record (KSoR) | Neon Postgres, plus Markdown in Git, served to the agent read-only |
| Read-only lookups into the case and knowledge records | Remote MCP servers on Workers |
| Long-term archive: transcripts, audit events, retired memory versions | R2 |
| Regression tests and study runs | Neon branches, with mocked outside services and test credentials |
In plain words:
- Workers are small programs that run on Cloudflare's network and answer requests.
- Queues are a waiting line for incoming work, so nothing is lost while the worker is busy.
- Durable Objects are small programs with their own storage, which make sure only one process works on a case at a time.
- Workflows run a long, multi-step process that survives crashes and can wait between steps.
- Hyperdrive is a fast, shared connection from Workers to the Postgres database.
- R2 is low-cost file storage, for archives.
- Neon branches are instant copies of the database, for testing a change without touching production. Neon is the database of Chapter 19.
Two choices matter most. First, every governed outside action goes through a custom tool backed by DSoR. In Managed Agents, a custom tool runs in your own application (22.4 showed where each kind of call runs), not on Anthropic's platform, so every real-world action passes DSoR before it happens. A well-secured MCP server could do the same; what matters is that policy is enforced apart from the agent. Second, Cloudflare hosts the edges and the governed services, not a second agent runtime. Cloudflare has its own agent framework and agent memory too. Using them beside Claude's would give you two memory models to govern, so this design keeps one.

Figure 31.10. One task, end to end. The numbers match the six task steps.
One task, end to end, in six steps:
- An event reaches a Worker, which checks it, records it as an inbox item in Postgres and puts it on a queue.
- A queue consumer starts or resumes a session for that case, passing the case id. In the simple runtime, it calls the scheduled task's address instead.
- The worker reads the case record and the relevant knowledge through read-only MCP servers. Approved memory is mounted read-only at its published version.
- To act, the worker calls a custom tool, and DSoR carries out the action through the lifecycle below.
- Session events flow into SSoR as traces, and are archived to R2.
- On its own schedule, a dream writes to a separate store. Candidates are tested on a Neon branch, and approved ones are published as a new read-only version.
How does one action stay safe?
Through six steps, each written to a durable action ledger before the next. An outside action and a case-record update usually live in different systems, so they cannot be saved together in one transaction. If a payment succeeds and the write to SSoR then fails, the two records disagree. So DSoR takes each action through six steps, separate from the six task steps above:
- Prepare. Record the intended action, its idempotency key and the case it belongs to.
- Authorize. Check policy, and get approval if the tier requires it.
- Execute. Call the outside system with the idempotency key.
- Verify. Confirm the result with the outside system, not only from the call's reply.
- Reconcile. If the outcome is unclear, for example after a timeout, ask the outside system what happened before any retry. If it still cannot be confirmed, stop and ask a person (31.9).
- Finalize. Write the confirmed outcome to SSoR, and close the ledger entry.
A crash at any step leaves an open ledger entry. Recovery checks every open entry before the worker takes another action. At Brightline, "mark INV-7850 ready to pay" is prepared with the key run-1026-0710:INV-7850, authorized against the approvals table, executed, checked in the payment system, and only then written to the record.
What must you still build?
The documented products leave gaps that your build must fill:
- Snapshot pinning. The memory store documentation describes versions, but not pinning a session to one. Stores are mounted live, and writes are shared across sessions. Publish each approved version as its own read-only store.[^ma-memory]
- Retention. Memory versions are kept for 30 days, apart from the recent versions of a live memory. A longer audit needs an archive.
- Validation and regression. Outcomes grade a single run against a rubric. Nothing runs a regression suite over a candidate memory change. That is your work, here on the Agent SDK and Neon branches.
- Exactly-once actions. Permission policies decide whether a tool runs, not whether it runs twice.[^ma-permissions] Idempotency and reconciliation belong to DSoR.
- Event delivery. Managed Agents webhooks report on sessions; they do not feed work in, and the documentation describes no way to resend an event. The inbox needs its own queue, and important states should be checked by polling.
- Audit. There is no dedicated audit log. The event stream carries each tool call's permission outcome, and SSoR must keep it.
- Availability and compliance. Dreams are in research preview, by request. Managed Agents is not eligible for zero data retention or HIPAA except when self-hosted, which matters for financial and other regulated clients.
Keep tests away from the real world. A Neon branch isolates the database, not the outside world. A regression run that calls real tools could still send an email or make a payment. So regression and study runs use an isolated branch, sandboxed or mocked outside services, synthetic or properly protected test data, and separate credentials. No action that changes anything in production is allowed during evaluation. Lab 31's worker has no tool that writes to the portal, for the same reason.
Porting the stack to OpenAI
Porting the design. The Cloudflare and Neon half stays the same; Cloudflare is even one of the Agents API's sandbox partners. The runtime column changes:
| Part of the design | Claude | OpenAI |
|---|---|---|
| Hosted runtime | Managed Agents sessions | Agents API sessions |
| Time-based loop | Scheduled deployments | Scheduled automations, by cron or at one set time |
| Approval before actions | Permission policies | Automatic review |
| Credentials | Vaults | Vaults |
| Notifications to your application | Webhooks | Webhooks |
| Running on your own infrastructure | Self-hosted sandboxes, or the whole service | Self-hosted sandboxes, your own cloud network, or partner sandboxes |
| Several agents on one task | Multiagent orchestration | Multi-agent sessions with subagents |
| Governed actions (DSoR) | Custom tools, run by your application | Custom functions, routed to DSoR the same way |
| Memory between sessions | Memory stores, with versions | Not provided: build it in Git or Neon, mounted read-only at a pinned version |
| Dreaming | Dreams, in research preview | Not provided: build it as a scheduled automation that reads past sessions and proposes changes |
| A runtime you run yourself | Claude Agent SDK | OpenAI Agents SDK |
The main difference is memory. On OpenAI, you supply the memory layer and the dreaming loop, so the promotion protocol matters even more: nothing in the platform stands in for any of it. Permissions, approvals, memory access and tool contracts must be adapted and tested again.
How others arrived at the same design
When separate builders arrive at the same design, it is a sign the design fits the problem. This section tells you which parts of Chapter 31 are settled practice, and which part is still a proposal you must test yourself.
How did Anthropic's publications build it?
In parallel with the three core sources, not after them. Memory and dreaming shipped in Managed Agents in April and May 2026, before the talk and the always-on article. In date order:
| Layer | Publication | Date | What it adds |
|---|---|---|---|
| Background | Effective context engineering for AI agents (Rajasekaran, Dixon, Ryan, Hadfield)[^context-eng] | Sep 29, 2025 | Compaction, notes kept outside the context window, subagents that return short summaries, and fetching information just in time |
| Background | Equipping agents for the real world with Agent Skills[^skills-post] | Oct 16, 2025 | Skills and progressive disclosure, step 3 of memory's history (31.3) |
| Loops | Effective harnesses for long-running agents (Justin Young)[^harness-long] | Nov 26, 2025 | Memory built by hand: a JSON feature list agents may only mark as passing, a progress file, git history and an init.sh to bridge sessions |
| Loops | Harness design for long-running application development (Prithvi Rajasekaran)[^harness-design] | Mar 24, 2026 | A planner, a generator and a separate evaluator. An agent grading its own work is weak, so checking needs its own agent. Remove harness parts as models improve |
| Loops | Introducing routines in Claude Code[^routines] | Apr 14, 2026 | The proactive loop as a cloud product. Managed Agents scheduled deployments give custom agents the same |
| Runtime | Scaling Managed Agents: Decoupling the brain from the hands[^ma-engineering] | Apr 8, 2026 | The brain, the hands and the session, each replaceable (31.9) |
| Memory | Built-in memory for Claude Managed Agents[^ma-memory-blog] | Apr 23, 2026 | The talk's guardrails, already shipping: file-system memory, versions with rollback and redaction, read-only or read-write stores, safe concurrent writes, an audit log per memory |
| Dreaming and loops | New in Claude Managed Agents: dreaming, outcomes, and multiagent orchestration[^ma-new] | May 19, 2026 | Dreaming in research preview, applied automatically or after review. Outcomes: a rubric checked by a grader in its own context. A lead agent delegating to subagents on a shared file system |
| Memory and dreaming | Memory and dreaming for self-learning agents (Mahesh Murag, Code with Claude), known here through a summary written by someone else[^murag] | May and Jun 2026 | Storage, structure and process layers of memory. Dreaming outputs updated memory for review. An example from site reliability work, where a dream found a retry problem and merged five duplicate entries |
| Teams | Building effective human-agent teams[^teams] | Jun 24, 2026 | For an agent, context nobody wrote down does not exist. Defined roles and tool access per agent |
| Memory and dreaming | The components of agent memory (Lance Martin)[^memory-components] | Nov 6, 2026 | The four layers (31.3), what a dream does and how often, the CL-Bench and corpus benchmarks |
| Teams | Safely scaling multi-agent teams with Claude Fable 5.2 (Zhang, Peng, Najt, Scholl, Martin)[^fable-teams] | Nov 9, 2026 | 1,000 agents coordinated only through a shared Postgres database and Git, with transactions handling writes at the same time. Safety in layers: a sandbox per agent, a classifier on every tool call that fails closed, and monitoring afterwards |
Two threads stand out. First, memory was built by hand before it was automated: the feature list and progress file of late 2025 are the injected context and memory notes of the 2026 memory model. Second, checking keeps moving out of the working agent and into a separate one: the harness evaluator, the Outcomes grader and the dreaming reviewer all judge work in a context the worker never touched. That is why Brightline's regression run is a separate script, not the worker grading itself.
What did other labs find?
OpenAI reached similar conclusions on its own, in five pieces.
- Frontier (February 5, 2026) is an enterprise platform for what OpenAI calls AI coworkers. A coworker needs shared business context, onboarding, learning from feedback, and its own identity with explicit permissions. Frontier joins data warehouses, CRM systems, ticketing tools and internal applications into one shared layer of business context, turns past interactions into memory, and has built-in evaluation.[^openai-frontier] In this chapter's terms, those are the role, the governed records and the improvement loop of 31.11. The announcement describes capabilities, not mechanisms. It does not say how a memory is checked before it is trusted.
- Harness engineering (Ryan Lopopolo, February 11, 2026) reports a five-month internal project in which Codex agents wrote about a million lines of code, none by hand.[^openai-harness] Three of its lessons match this chapter. A map, not a manual: the short top layer with an index (31.3). Background gardening: recurring agents find documents that no longer match the code, and check code against agreed principles, and open small pull requests; most take under a minute to review and merge automatically. That is dreaming with a low tier (31.7). Promotion into code: when documentation is not enough, a rule becomes a custom linter or structural test whose error message tells the agent how to fix the problem. That is the third place for a lesson (31.8).
- The Agents API (September 10, 2026) is OpenAI's counterpart to Claude Managed Agents (31.13).[^openai-agents-api]
- Dots (September 29, 2026, updated November 3) brings always-on agents to ChatGPT. Each dot has its own cloud computer and browser, works in the background, and learns from feedback. Specialist dots have their own identity and credentials for defined responsibilities, close to a Digital FTE. Custom rules allow an action, require approval for it, or block it, and sensitive tasks, such as changing a password, always stay with the person.[^openai-dots] Those are approval tiers.
- Self-evolving agents (OpenAI Cookbook, November 4, 2025, now archived) improves an agent's system prompt in a loop: feedback, a rewrite, four graders, saved versions and rollback to the best one. A version that clears the graders' bar is used with no person approving it (31.13).1
LangChain comes closest to dreaming. Harrison Chase's How to build a knowledge factory (November 21, 2026) separates knowledge, the reusable understanding a company maintains, from context, what an agent has during one task.[^langchain-kf] Its centre is a curator: a background agent on a schedule that reads raw sources such as Notion and Slack, agent traces and agent flags, and updates the knowledge store. That is dreaming under another name. It also argues, as this chapter does, that agents should not maintain their own knowledge, because it would become unruly and full of contradictions. Three more points match: the curator turns recurring human corrections into skills; data stays in its own system, such as BigQuery or Salesforce, and the knowledge store holds only how to reach it; and knowledge that is not a procedure needs a shared format, such as the Open Knowledge Format. The flag tool of 31.5 comes from this post. It does not describe an approval gate before the curator writes, versioning or evaluation.
Warp comes closest to the gate. Michael Segner's article on Warp (August 26, 2026) describes an improver skill that proposes edits to a working skill as pull requests, which a person merges. Warp checks its agents with verification harnesses and evals against known-good outputs.2 That is a candidate, a regression check and an approval (31.11). It does not describe counted evidence, a check against policy, tiers by risk, or versions a run is pinned to.
What does no one describe?
The gate. Several teams now run a background curator. None of the publications here, read together, specifies the full lifecycle a lesson passes: evidence, regression testing, authorization and publication, with monitoring and rollback after. Other systems may do some of this without describing it. That lifecycle, the promotion protocol, is this chapter's main proposal, and it is why most of the chapter is about it.
Words this chapter uses, in full
| Term | Meaning in this chapter |
|---|---|
| Action layer | The governed record of what a worker may do in business systems, and of every action it took. DSoR is one design for it (31.11) |
| Action ledger | A durable log of each outside action's steps, from Prepare to Finalize, used to recover safely after a crash (see "The reference stack, in detail") |
| Agent | A model that plans its own steps and uses tools to finish a task |
| Always-on worker | A worker that sleeps between events, wakes when something happens or a timer fires, does its work and reports back, with no person starting it (31.9) |
| Approval tier | How much checking a candidate needs before it is published: low, medium or high (31.7) |
| Audit trail | The record that makes a check of what happened possible: who changed what, and when |
| Candidate | A lesson someone proposed, before it is checked |
| Capability eval | A test of what a worker cannot do yet. A candidate's target cases start as one, and graduate into the regression eval once the lesson is published (31.6) |
| Case record | The full history of one piece of work, such as one payment: its goal, status, decisions and evidence. SSoR is one design for it (31.11) |
| CEL | The Common Expression Language, a small language for writing rules, used by DSoR |
| Claude Managed Agents | Anthropic's hosted service for running agents, with sessions, memory stores, dreams, scheduling and permissions |
| Commit, pull request | A commit is one saved change in a Git repository. A pull request asks a person to review changes before they are merged |
| Compaction | Summarizing a long conversation so it fits in the model's working space |
| Context | What a worker knows about its company and its work that is not in the model |
| Context window | The most text the model can see at one time |
| Credit memo | A document from a supplier that reduces what you owe, for example after a return |
| Custom tool | A tool your own application runs, so your application decides whether each call goes ahead |
| Digital FTE | A worker that holds a role in an organization, as a full-time employee would (31.10) |
| Dreaming | An out-of-band job that reads many past sessions and the current memory, and proposes changes to memory (31.5) |
| DSoR, SSoR, KSoR | Panaversity's three governed records: for actions and data (DSoR), for the state of each case (SSoR), and for approved knowledge (KSoR) (31.11) |
| Durable | Kept safely, so it survives a crash or a restart |
| EDI | Electronic Data Interchange: a standard way for companies' systems to send each other invoices and orders |
| Fine-tuning | Training a model further on your own examples, which creates a new model. A lesson learned this way cannot be read or withdrawn on its own (31.1) |
| Flag | A report from the worker, through flag_gap, of missing or wrong knowledge. A report, not a change (31.5) |
| Golden set | A fixed list of test cases, each with the answer a person checked |
| Governed | Controlled by clear rules: who may change something, how changes are checked and approved, and a record of what happened |
| Harness | The software around the model that runs its loop, calls its tools and manages its context |
| Hash | A short fingerprint of a file's content. Change one letter and it changes (31.4) |
| Held-out task | A test task kept apart from the tasks a worker learns from (see "How do you know it works?") |
| Idempotency key | A unique label on a request, so that a request sent twice is carried out once (31.9) |
| Improver skill | A skill that runs on a schedule, compares an agent's work with what people did, and proposes edits to the working skill for a person to merge (31.11) |
| In band, out of band | In band: inside a task's own session. Out of band: in a separate job, outside any task |
| Inbox | The durable list of events waiting for the worker (31.9) |
| Injected context | Text loaded into every run, such as instructions.md and index.md (31.3) |
| Knowledge record | The governed record of how work should be done, shared by people and workers. KSoR is one design for it (31.11) |
| Linter | A program that checks files against fixed rules, such as "every note must name its source" |
| Loop | A cycle in which the worker acts, checks the result and decides what to do next, until a stop condition is met |
| Manifest | The list of memories in a published version, each with its candidate and approval, checked before a run mounts it (31.6) |
| MCP | The Model Context Protocol, the standard way to connect an agent to tools and data |
| Memory store | A collection of text files a worker can read and write, kept between sessions. A published version is a read-only copy |
| Optimistic concurrency | Assume nobody else is writing, and write only if the file still has the hash you read (31.4) |
| Outbox | Where a run's result goes: a message sent, a decision to stay quiet, or a question for a person (31.9) |
| Outcomes | A Managed Agents feature: a rubric that describes success, which a separate grader checks a run against |
| pass@k, pass^k | The chance that at least one of k tries is right (pass@k), or that all k are right (pass^k). A worker that moves money needs pass^k (31.6) |
| Policy | An organization's official rule, such as an approval limit. Policy always overrides memory (31.8) |
| Policy version | The version of the policy a lesson was learned under. A new policy version sends its lessons back to be checked (31.6) |
| Progressive disclosure | Loading a short description first, and the full text only when it is needed (31.3) |
| Promotion protocol | The seven stages a lesson passes before runs rely on it (31.6) |
| Prompt injection | Instructions hidden in content the worker reads, written to make it misbehave |
| Proxy | A service that stands between the worker and another system, and uses passwords and keys so the worker never sees them |
| Published version | A copy of the memory that no run can change, with a number, such as v4 |
| Regression test | Running the golden set again after a change, to find anything that used to pass and now fails |
| Rollback | Publishing an earlier version's content again, as a new version. Nothing is deleted (31.6) |
| Run | One wake-up of the worker to do one piece of work |
| Runtime | The system that runs the worker: it starts, pauses, resumes and records its work |
| Sandbox | A closed space where the worker runs code and uses files, cut off from everything else |
| Session | The runtime's record of a worker's work: messages, tool calls and results |
| Side effect | An action that changes something outside the worker, such as sending an email or marking an invoice ready to pay |
| Skill | A packaged set of instructions and scripts that teaches a worker one kind of task |
| Snapshot | A fixed copy of memory at one moment, so a run's memory does not change while it works |
| Stale | Out of date: true once, no longer true |
| System of record | The official, trusted source for one kind of information, such as the payment system for payments |
| Token | A small piece of text, about three quarters of a word. Models are priced and limited by tokens |
| Transcript | The saved record of a session, which dreaming reads |
| Webhook | A message one system sends another the moment something happens, such as "a new invoice arrived" |
| Cloudflare and Neon terms | Workers, Queues, Durable Objects, Workflows, Hyperdrive, R2 and Neon branches are explained in plain words in "The reference stack, in detail" |
Sources
Every source the chapter and this page draw on, grouped. Figure 31.2, in the chapter's overview, shows them in time order. Products change quickly, so check a product fact against its source before you rely on it.
The three core sources. The chapter's main claim comes from reading these three together (31.2).
- Delba de Oliveira and Michael Segner, Loop engineering: Getting started with loops, Claude, June 30, 2026.
- Lamis Mukta, Learning while you sleep: Beyond memory to dreaming, a talk at AI Native DevCon London, June 2026.
- William Hu, Building always-on agents, Claude Platform, November 13, 2026.
Anthropic's research and product writing.
- Lance Martin, The components of agent memory, Anthropic Engineering, November 6, 2026.
- New in Claude Managed Agents: dreaming, outcomes, and multiagent orchestration, Claude, May 19, 2026.
- Built-in memory for Claude Managed Agents, Claude, April 23, 2026.
- Mahesh Murag, Memory and dreaming for self-learning agents, Code with Claude 2026, June 10, 2026.
- Introducing routines in Claude Code, Claude, April 14, 2026.
- Prithvi Rajasekaran, Harness design for long-running application development, Anthropic Engineering, March 24, 2026.
- Justin Young, Effective harnesses for long-running agents, Anthropic Engineering, November 26, 2025.
- Prithvi Rajasekaran, Ethan Dixon, Carly Ryan and Jeremy Hadfield, Effective context engineering for AI agents, Anthropic Engineering, September 29, 2025.
- Mikaela Grace, Jeremy Hadfield, Rodrigo Olivares and Jiri De Jonghe, Demystifying evals for AI agents, Anthropic Engineering, January 9, 2026.
- Michael Segner, How Warp builds self-improving agents on Claude, Claude, August 26, 2026.
- Equipping agents for the real world with Agent Skills, Anthropic Engineering, October 16, 2025.
- Building effective human-agent teams, Claude, June 24, 2026.
- Lance Martin, Gabe Cemaj and Michael Cohen, Scaling Managed Agents: Decoupling the brain from the hands, Anthropic Engineering, April 8, 2026.
- Building agents: When to fold subagents into your main agent loop, Claude, 2026.
- Barry Zhang, Tianyi Peng, Elle Najt, Keller Scholl and Lance Martin, Safely scaling multi-agent teams with Claude Fable 5.2, claude.dev, November 9, 2026.
Other labs, and a critic.
- Introducing OpenAI Frontier, OpenAI, February 5, 2026.
- Ryan Lopopolo, Harness engineering: leveraging Codex in an agent-first world, OpenAI, February 11, 2026.
- Introducing the Agents API, OpenAI, September 10, 2026.
- Introducing dots, OpenAI, September 29, 2026, updated November 3, 2026.
- Shikhar Kwatra and others, Self-evolving agents: a cookbook for autonomous agent retraining, OpenAI Cookbook, November 4, 2025 (archived).
- Harrison Chase, How to build a knowledge factory, LangChain, November 21, 2026.
- The New Stack, an article on Anthropic's dreaming and its critics, August 12, 2026.
Panaversity's frameworks for the governed records (31.11).
- DSoR: Data System of Record, SSoR: State System of Record and KSoR: Knowledge System of Record, on GitHub.
Product documentation (31.13 and the lab).
- Claude Managed Agents: Overview, Memory stores, Dreams and Permission policies.
- Claude Code: Agent SDK overview and Automate work with scheduled tasks.
- OpenAI: Scheduled automations, in the Agents API documentation, and Fine-tuning, in the API reference.
Sources
- Self-evolving agents: a cookbook for autonomous agent retraining (Shikhar Kwatra and others, OpenAI Cookbook, 4 November 2025).↑
- How Warp builds self-improving agents on Claude (Michael Segner, Claude, 26 August 2026).↑
- Memory stores (Claude Managed Agents documentation, verified 2026-11-24)
- Harness engineering: leveraging Codex in an agent-first world (Ryan Lopopolo, OpenAI, 11 February 2026)
- Introducing the Agents API (OpenAI, 10 September 2026)
- Scaling Managed Agents: Decoupling the brain from the hands (Lance Martin, Gabe Cemaj and Michael Cohen, Anthropic Engineering, 8 April 2026)
- Built-in memory for Claude Managed Agents (Claude, 23 April 2026)
- New in Claude Managed Agents: dreaming, outcomes, and multiagent orchestration (Claude, 19 May 2026)
- Claude Managed Agents overview (Claude Platform documentation)
- Permission policies (Claude Managed Agents documentation)
- Agent SDK overview (Claude Code documentation)
- Automate work with scheduled tasks (Claude Code documentation)
- Effective context engineering for AI agents (Prithvi Rajasekaran, Ethan Dixon, Carly Ryan and Jeremy Hadfield, Anthropic Engineering, 29 September 2025)
- Equipping agents for the real world with Agent Skills (Anthropic Engineering, 16 October 2025)
- Effective harnesses for long-running agents (Justin Young, Anthropic Engineering, 26 November 2025)
- Harness design for long-running application development (Prithvi Rajasekaran, Anthropic Engineering, 24 March 2026)
- Introducing routines in Claude Code (Claude, 14 April 2026)
- Memory and dreaming for self-learning agents (Mahesh Murag, Code with Claude 2026, Tokyo, 10 June 2026; read through a third-party summary)
- Building effective human-agent teams (Claude, 24 June 2026)
- Safely scaling multi-agent teams with Claude Fable 5.2 (Barry Zhang, Tianyi Peng, Elle Najt, Keller Scholl and Lance Martin, claude.dev, 9 November 2026)
- Introducing OpenAI Frontier (OpenAI, 5 February 2026)
- Introducing dots (OpenAI, 29 September 2026, updated 3 November 2026)
- How to build a knowledge factory (Harrison Chase, LangChain, 21 November 2026)
- Building always-on agents (William Hu, Claude Platform, 13 November 2026, verified 2026-11-24)
- DSoR: Data System of Record (Panaversity, GitHub)
- KSoR: Knowledge System of Record (Panaversity, GitHub)
- Loop engineering: Getting started with loops (Delba de Oliveira and Michael Segner, Claude, 30 June 2026, verified 2026-11-24)
- Learning while you sleep: Beyond memory to dreaming (Lamis Mukta, Anthropic, AI Native DevCon London, June 2026)
- SSoR: State System of Record (Panaversity, GitHub)
- Owner
- Panaversity