Summary note: This is a summary of kvro’s (@0xkvro) X article from 9 November 2026, “Agent Reliability Engineering: Architecture, Verification, and Recovery Loops”, not a reprint of the original. Original link: https://x.com/0xkvro/status/2119480383620149518

On 9 November, kvro published a 7-minute article on X unpacking a Claude paper he had recently read, on agent reliability engineering. It had about 19,600 impressions, 66 likes and 71 bookmarks — more bookmarks than likes, a sign many readers saved it as reference material. The core argument: the gap between a good agent and a great one is usually not the model, but the reliability loop around it. He breaks that loop into three pillars: architecture is the foundation, verification is the proof, and recovery is what keeps the system from falling apart.

1. Architecture: reliability is designed, not bolted on

In the author’s view, an agent architecture without verification is essentially just a prompt chain with good intentions. Reliability cannot be bolted on after the fact — you have to design for failure modes before you design for success cases. Architecture has three principles:

1. Separation of concerns. An agent should never be a monolith that tries to do everything. Split it into layers with a single job each: a planner (decides what to do), an executor (carries out actions), and a verifier (checks the work). Each layer has one job, and each can fail independently without taking down the whole system.

2. Explicit state. Agents that keep state in their head (in the context window) are fragile. State should live outside the model, in a structured format that can be inspected, resumed, and rolled back. In the author’s words: if you can’t print the agent’s state at any point and understand exactly where it is, you don’t have an agent. You have a hope.

3. Bounded autonomy. Give the agent clear limits: what it can touch, what it can’t, how many times it can retry, when it must stop and ask a human. Autonomy without bounds is just a bug waiting to happen.

2. Verification: a passing test doesn’t mean the system works

This is where most agents fall apart. The author stresses that a test passing only means the test passed — it doesn’t mean the system works. That is the difference between a demo and a product. Verification needs to happen at three levels:

  1. Contract verification: does the output match the agreed interface? If the agent was supposed to return a JSON object with specific fields, did it? If it was supposed to modify a file in a specific way, did it?
  2. Behavioral verification: does the system actually do what it was supposed to do? This is harder, because it requires understanding intent, not just syntax. A test can pass while the feature is broken.
  3. Invariant verification: are the things that must always be true still true? No data loss, no broken references, no silent failures?

He cites an example from the Claude paper: an agent can edit the repo, pass 42/42 tests, pass type checks, pass the build, and the actual checkout can still be broken. That is why the workflow changes from “prompt → code → green tests” to “contract → work → verify → recover”.

3. Recovery: the pillar people skip most often

Things will fail — the question is what happens next. Does the agent retry blindly? Give up? Ask for help? A good recovery loop has three stages:

  1. Detect: notice the failure quickly. Don’t wait for a user to report it.
  2. Diagnose: figure out what went wrong. Was it a bad input? A missing dependency? A logic error?
  3. Repair: fix it, or roll back to a known good state, or escalate to a human.

The key insight is that recovery should be a first-class part of the design, not an afterthought. If you design for failure, failure becomes a normal part of operation, not a crisis.

The author gives a database migration as an example: without a recovery loop, a failed migration leaves the database in an unknown state; with one, the agent detects the failure, diagnoses the cause (say, a constraint violation), rolls back to the previous schema, and reports what happened. That is the difference between a tool and a system.

4. A pattern you can use directly

The author offers a simple pattern that ties the three pillars together:

def run_agent(task):
    state = load_state(task)
    while not state.is_complete():
        try:
            plan = planner.plan(state)
            result = executor.execute(plan)
            verifier.verify(result, state)
            state = update_state(state, result)
        except VerificationError as e:
            state = recover(state, e)
            if state.retries_exceeded():
                escalate_to_human(state)
                break
        save_state(state)

The verifier is not optional — it is the part that turns a chain of guesses into a reliable system. And the recovery loop is not a fallback. It is the main loop.

5. 90% of agent failures come down to three missing pieces

The author concludes that most agent failures he has seen come down to one of three things:

  1. No verification: the agent assumed its work was correct because nothing complained.
  2. No state: the agent lost track of where it was, and started over or repeated work.
  3. No recovery: when something broke, the agent either gave up or kept trying the same thing.

Fix those three, and you’ve fixed 90% of agent reliability problems. The rest is details.

The article closes by saying the future of agents isn’t better models — it’s better engineering around the models we already have. Readers who want to go deeper are pointed to the Claude paper itself, which covers the specific failure modes and how to design around them.

Written byAuthor

Buy me a coffee~

Solana

Solana

Solana

Solana

Solana

Solana

Background music
Jump to comments
Settings
Back to top
Go to bottom
Collapse toolbox