Start HereDemo, Decoded
Fix a Failing Test, Decoded
Here is a demo people watch me run in under a minute: a test is broken, I ask an to fix it, and a moment later it is green. To anyone who has not seen it before, it looks like magic — or like nonsense words. It is neither.
This is the same thing, slowed down, with every move decoded as it happens. No code required. By the end you will be able to name what you are looking at.
The task
One automated test — a small script that checks the code still does what it should — is failing. The checkout is supposed to take 10% off a $100 order and charge $90. The test says it is charging the wrong amount.
I type one instruction: "Fix the failing test in the checkout flow." Then I hand it to the agent.
Watch the loop
The agent does not produce the fix in one shot. It works in a loop: think about what to do, do one thing, look at the result, repeat. Step through it yourself — press the button one turn at a time and watch what happens on the right.
The agent loop · Fix the failing test
turn 0/9- Press Step to run the loop one turn at a time.
Context window
0 / 4,000 tok (0%)
Phases
- Think
- Act
- Observe
Ready.
Two things are worth naming as you step through it.
What happened, decoded
Read back through the trace and it is no longer mysterious:
- It read the test to learn what "correct" means — a tool call that pulled the test into its .
- It formed a hypothesis about the bug — that is the model reasoning, the only part that happens "inside" the model.
- It read the code, confirmed the bug (
price * 0.1returns the discount, not the discounted price), and made the one-line fix — another tool call. - It ran the tests to check its own work, saw green, and stopped. That last part matters: the loop ended because the goal was met, not because it ran out of things to try.
The agent kept going until the test passed, then quit. That "keep going until the goal is met" behaviour is the whole difference between an agent and a single answer — and the reason a good harness (the scaffolding around the model) also sets its own limits, so an agent that cannot reach the goal does not loop forever.
What it did not do — and why that matters
The honest version, because the hype usually skips it:
- It did not "understand" the checkout the way you do. It predicted likely next steps from patterns. That works strikingly well here and fails in surprising places — so the human stays in the loop.
- It can produce a wrong fix with exactly the same confidence. A person would hesitate; an agent often will not. That is why you review the change before it ships, not after.
- This is a clean, well-scoped task — exactly the kind agents are good at today. Point the same agent at a vague, sprawling goal and the 2025 reality is messier. Useful, not autonomous.
The three-sentence version
An agent is a model running tool calls in a loop toward a goal, using its context window as working memory, until a stop condition ends it. It generates likely next steps rather than truly understanding — so it is fast and capable on scoped work, and needs a human reviewing the important parts. That is the entire demo.
Want the words on their own? Open the Decoder. Want the real mechanics? The Harness pillar builds this loop from the floor up.