Building a Better AI Agent

Harness Engineering 2.0

An annotated talk on designing the system around an AI model, from tool design and memory to verification, teams, and self-evolving harnesses.
Agents
Coding Agents
Harness Engineering
AI Engineering
Annotated Talk
Author

Rajiv Shah

Published

November 28, 2026

Start with the same model and the same bug. Give that model to three different coding agents and watch what happens. One batches its shell commands, one reads files separately, and one adds behavioral checks. They can arrive at the same patch with very different evidence about whether it works.

That difference is what I mean by harness engineering. The harness is the software that loads context, exposes tools, executes actions, and decides what evidence is required before the agent can finish. Better models change some of those decisions. I can give a capable model a more general interface and let it compose its own actions. I still want the application to be clear about what the agent is allowed to do and what counts as success.

This is the written companion to my talk Building a Better AI Agent. It follows all 140 slides in the published video, in order. Each slide comes with a written explanation and a link to that point in the talk. You can skim the headings and text or watch along.

Harness basics · Harness choice · Tools · Context and memory · Model routing · Verification · Multiple agents · Evolving harnesses · Recap

Watch the talk

Watch the full talk on YouTube

What is an AI agent harness?

I started with a car analogy. An engine gives you power. A car’s design determines how you can use that power. With an AI agent, the same model can behave differently depending on what it sees, which actions it can take, and what happens when it hits a problem. Watch from 0:00

Building a better AI agent

Start with the job you want the agent to do. The tools, context, and checks you give it will shape how well it does that job.

Watch at 0:00

Building a better AI agent

Why revisit harness engineering?

As models improve, I revisit which procedures the harness needs to supply and which the model can work out. The rest of the talk shows how I make that call.

Watch at 0:07

Why revisit harness engineering?

Six decisions to test

The talk moves through harness choice, tools, context and memory, model routing, goals and stopping, and multi-agent design. The workshop examples give each decision a concrete task.

Watch at 0:28

Six decisions to test

The engine is one part of the car

Toyota’s 3.5-liter V6 gives us a fixed starting point. Watch what happens when the surrounding vehicle is designed for different jobs.

Watch at 1:07

The engine is one part of the car

Same engine family, different jobs

I use the Camry, RAV4, and Lotus to get at one design choice. Start with what you want the vehicle to do, then build around the engine. For an agent, the equivalent is to start with the job and decide what environment, tools, and feedback it needs.

Watch at 1:36

The slide compares cars from Toyota and Lotus that use versions of the Toyota V6 family.

The model and the harness

The model proposes the next action. The harness assembles the input, gives the action somewhere to run, and brings the result back. A test failure, a tool error, or a changed file becomes evidence for the model’s next decision. Agent = model + harness is shorthand for that loop.

Watch at 1:48

A robot diagram labels the model at the head and the harness around the body.

Design for the environment

A programming task may call for a repo, a terminal, and a test runner. A data task might need query access, schema information, and a way to check the result against the underlying data. The job determines what the model can see and do.

Watch at 2:01

Four robot illustrations show a coding workspace, a data engineering setting, a GTM example, and another work environment.

Why build a custom harness?

A small model with training and search can be competitive on a narrow task. The synthetic hospital results vary both training and tool access, so they show the potential of the whole setup.

Watch at 2:22

Why build a custom harness?

What a custom harness lets you control

Hosting a model yourself can give you control over where computation runs. Check the model license, deployment requirements, and the cost of operating that stack.

Watch at 2:35

What a custom harness lets you control

How to follow the exercises

The workshop includes recorded conversations you can inspect. Rerunning the same examples requires the separate model setup.

Watch at 2:47

How to follow the exercises

Choosing a harness

When I compare agents, I keep the model and task fixed first. That makes it easier to see where the surrounding system changes the run. Watch from 2:50

What changes when you swap harnesses?

Hold the model and task fixed. Then watch which files each agent reads, how it issues tool calls, and what it checks before it stops.

Watch at 2:51

What changes when you swap harnesses?

Identify the harness in your comparison

Record the agent or CLI, the model, the reasoning settings, and the tool configuration. Otherwise, it is hard to reproduce the comparison.

Watch at 2:59

Identify the harness in your comparison

Benchmarks test a complete setup

The benchmark example pairs Claude models with Claude Code and GPT models with Codex CLI. Reasoning settings vary as well. A result belongs to that complete setup. Before carrying a number over to your own application, check which harness, reasoning settings, and tools produced it.

Watch at 3:00

A FrontierCode chart shows results for model and harness combinations.

Workshop 1 setup

OpenHands, Pi, and OpenCode get the same prompt and model. Inspect each trace for reads, tool requests, and verification.

Watch at 3:24

Workshop 1 setup

The pagination bug

The app drops the last item of a full page. The prompt asks each agent to fix the off-by-one issue, preserve the tests, run them, and inspect the diff.

Watch at 3:31

The pagination bug

Look inside the tool calls

In the pagination exercise, OpenHands batches some repo inspection into a shell request. OpenCode makes separate reads. Pi adds behavioral checks before finishing. Compare what each request does and what evidence it returns. That tells you more than a count of calls.

Watch at 3:44

An OpenHands trace shows several operations grouped into one terminal request.

OpenCode reads files separately

OpenCode requests the source and test files in separate tool calls. Those calls make the trace easy to follow and show which evidence the agent requested first.

Watch at 3:56

OpenCode reads files separately

Pi adds behavior checks

Pi checks edge cases while repairing the same bug. Look at which cases it checked and what those checks add to the existing suite.

Watch at 4:03

Pi adds behavior checks

Compare the evidence in the three traces

OpenHands batches reads, OpenCode separates them, and Pi adds checks. A short trace can still contain several operations in one call.

Watch at 4:11

Compare the evidence in the three traces

Read the repair and the checks together

The patch tells you what changed. The tool trace tells you how the agent found the problem and what it confirmed before finishing.

Watch at 4:28

Read the repair and the checks together

The harness effect varies by model

Some of the results in this table move by double-digit percentage points when the harness changes. The size and direction of the effect depend on the pairing. The study ran 113 tasks twice per pairing, so I treat small gaps cautiously. The practical question is whether a pairing is repeatable on tasks like yours.

Watch at 4:32

A benchmark table highlights different results when the same model runs in different harnesses.

What else should a harness comparison measure?

Harness-Bench reports task quality, robustness, security, token use, and turns. Choose metrics that match the work you intend to run.

Watch at 5:12

What else should a harness comparison measure?

Compare accuracy and cost together

The Snowflake CoCo example plots pass rate against cost per trial for several model setups. Read both axes when choosing a configuration.

Watch at 5:23

Compare accuracy and cost together

Harvey’s RLM harness

Harvey and Baseten compared a standard tool loop with a recursive language model harness on diligence work. The rubric scores are vendor-reported and specific to that setup.

Watch at 6:26

Harvey’s RLM harness

How Harvey queries a data room

The root agent can search documents held in a Python REPL and delegate bounded batches of work. It uses the returned findings to assemble the diligence memo.

Watch at 6:42

How Harvey queries a data room

Why Ramp built its own harness

Ramp’s example uses Temporal for durable workflows and activities. Product requests, sessions, model choice, and results all belong to the system the team has to operate.

Watch at 7:10

Why Ramp built its own harness

A prompt and its tool set have to agree

A prompt carried over from Codex told the model to use an action Pi did not expose. Check that the prompt names tools the current harness actually provides.

Watch at 7:24

A prompt and its tool set have to agree

Retry policy can change the result

In the FrontierCS 2 comparison shown in the talk, the authors traced some Gemini 4 Argon failures in Pi to provider refusals that ended the run. Antigravity retried some of those requests. The reported pass rate for Argon moved from 40% in Pi to 54% in Antigravity. A trace can show where the implementation contributed to a benchmark result. Original comparison · FrontierCS

Watch at 8:40

A FrontierCS 2 bar chart compares results across model and harness runs.

Compare harnesses at the source level

Harness Lens lines up prompts and tool behavior across coding agents. It can help you identify concrete implementation differences worth testing.

Watch at 8:55

Compare harnesses at the source level

Why source access can matter

David Crawshaw argues that open development tools make it easier for people to inspect, adapt, and maintain the tools they use.

Watch at 9:21

Why source access can matter

What to take from the harness comparison

Choose a pairing for your own work. Watch what changes in the trace and measure whether those changes improve the result.

Watch at 9:50

What to take from the harness comparison

Designing tools for agents

How much of the procedure should the agent work out, and how much should the tool provide? The answer depends on how much the work varies and how often it repeats. Watch from 9:56

What should the tool handle?

Tool design is where I decide which steps to package and how much freedom to give the model.

Watch at 9:57

What should the tool handle?

How SWE-agent designed its tools

SWE-agent gave the model commands for searching, navigating, and editing a repository. Those commands return feedback the model can use to decide its next action.

Watch at 10:00

How SWE-agent designed its tools

A stronger model can use a simpler interface

The mini-SWE-agent team simplified its model-facing tool interface to bash. A shell still reaches files, programs, and APIs. Their design explains why a general tool can be useful when the model is good at composing actions. I still package a procedure when it repeats often enough and the important evidence is known in advance.

Watch at 10:18

The slide contrasts the original SWE-agent tool interface with mini-SWE-agent’s bash interface.

Revisit scaffolding as models improve

Philipp Schmid describes four rebuilds, from a fixed workflow to an agent with a single general tool. Each rebuild moved some decisions into the model.

Watch at 10:40

Revisit scaffolding as models improve

Workshop 2 setup

Keep the model and job fixed. Compare a terminal, a set of GitHub operations, and one custom tool for the whole collection step.

Watch at 11:01

Workshop 2 setup

One PR, three tool designs

For the same PR explanation, a terminal gives the agent more freedom to assemble requests. Four GitHub operations define a smaller vocabulary. A custom PR tool supplies the procedure and returns a bundle with the information the agent needs. These are three places to draw the line between what the model figures out and what the tool handles.

Watch at 11:08

The exercise compares a terminal, four GitHub operations, and a custom PR tool for gathering evidence about the same pull request.

With a terminal, the agent assembles the requests

The terminal run builds its own sequence for collecting PR details and checking the diff. That freedom helps when the evidence varies from one PR to the next.

Watch at 11:55

With a terminal, the agent assembles the requests

With structured tools, arguments matter

A GitHub tool call fails schema validation when a required field is missing. A clear error tells the model what value it needs to supply on the next try.

Watch at 12:08

With structured tools, arguments matter

With a custom tool, package repeated collection

The custom operation collects the usual PR evidence in one place. It makes sense when the inputs and required evidence recur across many runs.

Watch at 12:19

With a custom tool, package repeated collection

Measure what each tool gives back

The custom tool used two calls and about 53,000 tokens in this example. The terminal used ten calls and about 135,000 tokens. These were individual runs. I’d also test a PR that needs evidence outside the custom bundle and check whether the tool helps the agent recover when it comes up short.

Watch at 12:28

A table compares calls, tokens, time, and evidence for the three tool approaches.

Choose retrieval for the question

Keyword search matches terms, semantic search finds related passages, and graph queries follow relationships. An agent can inspect a result and search again when evidence is missing.

Watch at 13:00

Choose retrieval for the question

Use relationships to navigate a codebase

GitNexus lets an agent query code relationships. That can help answer questions about dependencies and call paths before opening a long list of files.

Watch at 13:44

Use relationships to navigate a codebase

The same operation can have different interfaces

A CLI and an MCP tool can reach the same underlying system. Evaluate the arguments, permissions, response size, and error messages. When a call fails, the response should help the agent make a useful decision about what to do next.

Watch at 14:04

The slide compares a CLI call and an MCP tool that reach the same operation.

Discover tools when they are needed

A long list of tool definitions consumes context on every call. A search step can load a smaller set relevant to the job in front of the agent.

Watch at 14:13

Discover tools when they are needed

Search and execute across a large API

Cloudflare’s Code Mode example searches a catalog of roughly 2,600 endpoints, composes the needed calls in a program, and returns the selected result.

Watch at 14:35

Search and execute across a large API

Use a decision model to narrow the tool set

The SDK example selects three relevant GitHub tools from a catalog of 50. The right comparison includes selector overhead and whether it ever leaves out a tool the task needs.

Watch at 14:51

Use a decision model to narrow the tool set

What a tool-choice cascade changes

The Jev experiment reports lower cost and similar task success, with a modest latency increase. A cheaper decision step can be worthwhile if the end-to-end run still meets your needs.

Watch at 15:30

What a tool-choice cascade changes

How to evaluate a tool choice

Check the selected tool, its arguments, and the order of calls. Also check whether the agent can recover when one request leaves it short of evidence.

Watch at 15:40

How to evaluate a tool choice

What to take from tool design

Use broader tools for work that varies. Package procedures that repeat, return useful evidence and errors, and judge the design by the finished task.

Watch at 16:04

What to take from tool design

Context, compaction, and memory

I use four verbs to think about an agent’s working state. Load, save, check, reset. Across a long task, the harness has to keep useful evidence available as earlier calls fall out of the working context. Watch from 16:09

What should carry forward?

The context and memory section follows the information an agent needs now and the state it should save for the next session.

Watch at 16:09

What should carry forward?

What the model sees on a call

Files can exist on disk without being in the model’s current input. For the pagination repair, I’d load the report, relevant code, and tests first. The model can ask for more evidence once it knows where to look.

Watch at 16:15

The slide breaks working context into instructions, request, history, tools, and relevant evidence.

Context quality can move accuracy

The query example reports a 19-point gain after improving the supplied context. When an agent is wrong, check whether it had the schema, examples, and verification evidence it needed.

Watch at 16:24

Context quality can move accuracy

A context lifecycle for a coding task

Save a reproduction and a next step once they’re worth keeping. When you pick the task up again, check that the saved paths, commands, and claims still match the current repo. Then use the checked state to rebuild the working context. That check is especially valuable after a branch or dependency change.

Watch at 16:32

A diagram follows a task through load, save, check, and reset.

Why the transcript keeps growing

A tool result joins the history and is available on later model calls. Repeatedly carrying old results can make each subsequent call larger.

Watch at 16:49

Why the transcript keeps growing

A bigger context window still needs curation

A larger window lets us supply more. The retrieval example in the talk illustrates how the availability of information and reliable use of it can diverge. Keep key facts and constraints easy for the model to find, then test recall on the parts of your task that matter.

Watch at 17:06

A study chart plots how recall varies as the input gets longer.

Start fresh with /clear

A reset gives the model a clean context. Save or reload the goal and verified progress first if the task needs to continue.

Watch at 17:24

Start fresh with /clear

Five ways to handle a full context window

You can keep going, rewind, clear, compact, or delegate to a separate context. Pick based on which information the next step needs.

Watch at 17:32

Five ways to handle a full context window

What a compacted context needs

A useful compaction keeps the user’s actual constraint, the current state of the work, and the unresolved decision. I’d preserve exact commands, paths, or expected outputs when the next action depends on them. The test is whether the agent can resume correctly.

Watch at 17:45

A long conversation is reduced to a summary for the next turn.

Keep exact excerpts, then drop older blocks

CliffCompaction keeps selected fragments and recent turns. At the next threshold, the agent can discard an older compacted block and reread files if needed.

Watch at 18:05

Keep exact excerpts, then drop older blocks

Improve the instructions for summarizing

ACON learns compression instructions from trajectories. Evaluate the resulting summaries by checking whether the agent can still complete the next part of the task.

Watch at 18:31

Improve the instructions for summarizing

Choose what compaction can afford to lose

Summaries rewrite older history. Learned compression changes what a summary prioritizes. Excerpt-based compaction preserves chosen wording while dropping other material.

Watch at 18:43

Choose what compaction can afford to lose

A constraint can disappear from working context

Summer Yue reported that an email agent acted after a confirmation rule was lost during compaction. Keep a rule that must apply on every run in a place the harness reliably loads or enforces.

Watch at 18:56

A constraint can disappear from working context

Save a procedure you can use again

After finding headphones on a store, the agent might keep the procedure for finding and using the search box. A later search for a keyboard can reuse that procedure with a different query. Which procedure, decision, or constraint would actually change how the next task starts? That’s a good candidate for memory.

Watch at 19:58

The slide compares two shopping tasks that share search steps and have different queries.

Where saved experience can live

Conversation history preserves detail. A note, skill, or other external file makes the useful part inspectable and editable, but it has to be written and found later.

Watch at 20:56

Where saved experience can live

Let the model manage part of its context

A model-controlled context file lets the model choose what to keep. Check what ends up in the next call and whether critical state survives.

Watch at 21:24

Let the model manage part of its context

Match instructions to their scope

Use the system prompt for standing behavior, repo guidance for local conventions, skills for reusable procedures, and checkpoints for progress on an individual task.

Watch at 22:00

Match instructions to their scope

Save a checkpoint you can resume

Write down what you reproduced, what you ruled out, and the next open step. On resume, verify that the referenced files still match the note.

Watch at 22:24

Save a checkpoint you can resume

Keep standing repo guidance in AGENTS.md

A checked test command or stable architecture decision can help many future tasks. Store it with the repo so it can change alongside the code.

Watch at 23:01

Keep standing repo guidance in AGENTS.md

Load skill details when the task calls for them

A small catalog helps the agent find a procedure. Once selected, the skill can supply its instructions, references, and scripts.

Watch at 23:26

Load skill details when the task calls for them

Workshop 3 setup

The exercise supplies no note, a useful note, or an obsolete note for the same task. Compare the first check and the eventual outcome in each run.

Watch at 23:44

Workshop 3 setup

What happened with no memory

The agent started by running the full suite. That gave it a baseline and several failures to investigate.

Watch at 23:57

What happened with no memory

Useful memory points to a better first check

In the useful-memory run, the note points the agent to focused zone tests. One of those tests fails and gives it evidence to work from. The agent later runs the full suite too. In the paired runs we examined, memory changed the first check while the main matched runs reached the same passing outcome.

Watch at 23:57

A trace highlights the focused zone tests in a run with a useful saved note.

What happened with stale memory

The saved command pointed to an obsolete check and ran zero behavior tests. Verify what a reused command actually tests before counting it as evidence.

Watch at 23:58

What happened with stale memory

Compare the three memory runs

All three runs eventually passed the same cases. Their first checks differed, which is where the note affected the work.

Watch at 23:59

Compare the three memory runs

Skills help some tasks and hurt others

SkillsBench reports an average benefit from curated skills, alongside regressions on some tasks. Evaluate the particular skill on the work it should improve.

Watch at 24:13

Skills help some tasks and hurt others

Test the work a skill was written for

Run the same task with and without the skill. Compare task success and runtime at the task and model level so an overall average does not hide regressions.

Watch at 24:56

Test the work a skill was written for

Test whether memory helps on a later task

FrontierMemory asks whether earlier feedback carries forward to new work. That tests whether a system finds and applies a useful preference when it comes up again.

Watch at 25:32

Test whether memory helps on a later task

What to take from context and memory

Load what the job needs, save progress worth reusing, check it, and then reset. The goal is to carry forward verified state.

Watch at 26:26

What to take from context and memory

Choosing and routing models

I look at the cost of getting a result that passes the checks. That total includes context, retries, escalation, and verification. Watch from 26:33

When is a model switch worthwhile?

Model routing is a decision about the cost of a result that passes your checks, including errors, retries, cache effects, and escalation.

Watch at 26:33

When is a model switch worthwhile?

Workshop 4 setup

Use Flash as the lower-cost baseline and Pro as the candidate for escalation. Give both the same SVG task and judge them against the same requirements.

Watch at 26:42

Workshop 4 setup

Check the result you asked for

Both models made runnable SVGs. Both missed part of how the accordion was supposed to move. In a routing system, the acceptance check needs to see that difference. A more polished-looking output can still fail a specific requirement.

Watch at 27:08

Two animated SVG accordion examples illustrate different motion errors.

Check the individual abilities a task needs

A model can generate runnable SVG and still get the motion wrong. For this example, verify that the moving parts stay connected.

Watch at 27:34

Check the individual abilities a task needs

Establish a routing baseline

Cursor reported 30–50% savings on routed requests for three high-volume accounts, against a baseline priced at Opus 4.8 rates. That’s a useful case to study. For your workload, start with the current cost and acceptance rate, then check what changes when you route some tasks to a lower-cost model.

Watch at 27:47

Cursor’s reported routing savings are shown alongside its measurement approach.

What if you routed at every step?

Frequent routing could match each step to a different model. Measure the cost of passing history between models before adopting that pattern.

Watch at 28:13

What if you routed at every step?

A model switch can cost cache reuse

When the history prefix matches, another call to the same model may reuse a cache. A different model generally has to process that history under its own cache rules. Switching at a task boundary can reduce how much context needs to move.

Watch at 28:24

A diagram compares continuing with the same model and reprocessing earlier context with a different model.

Compare a retry with escalation

Two cheaper attempts can compete with one pricier attempt. This works only if you can select the result that really meets the requirement.

Watch at 29:05

Compare a retry with escalation

Feed verified results into routing decisions

Record the task, model, score, and cost. Use relevant past outcomes to guide the next model choice.

Watch at 29:23

Feed verified results into routing decisions

Choose another model or train for the job

Routing changes which existing model you use. Fine-tuning changes weights for repeated work. Evaluate either choice in the harness that will run it.

Watch at 29:37

Choose another model or train for the job

Route after diagnosing the failure

Before switching models, look at why the attempt failed. Missing evidence may call for more context. A malformed tool response may call for a tool fix. Escalate if the checks point to a limitation the stronger model is likely to help with.

Watch at 30:01

The slide summarizes matching the model to the task, checks for escalation, and the cost of successful work.

Goals, verification, and stopping

A plan tells the agent what to try. A goal describes what the user needs, and a check provides evidence that they got it. Watch from 30:07

How does an agent know when to stop?

Give the agent an outcome and a check that can show whether it is done. That gives it a way to adapt the plan when something changes.

Watch at 30:08

How does an agent know when to stop?

Start with the user outcome

Suppose the task is to build an Android version of an existing iOS app. An installation or a clean build is an early checkpoint. The outcome is that a person can open the app and use the flow they expect.

Watch at 30:28

A phone screenshot shows the Android app from Cognition’s example.

A plan gives the agent a starting point

The agent can break a migration into steps and estimate which files need edits. Confirm the outcome separately after the plan has been executed.

Watch at 30:34

A plan gives the agent a starting point

Check the path a real user will take

A passing build says little about launch, sign-in, or the distribution channel. Open the app in the intended environment and try the relevant workflow.

Watch at 30:49

Check the path a real user will take

Update the plan when the evidence changes

Unexpected behavior is a reason to revisit an earlier assumption. Keep the original user outcome in view when choosing the next step.

Watch at 31:02

Update the plan when the evidence changes

Turn a reference app into a check

Give the agent access to both apps. Repeat a specific user flow and capture what each app does. A concrete mismatch is evidence the agent can use on the next attempt. Allow for platform-specific conventions while checking the behavior the user cares about.

Watch at 31:14

The iOS and Android versions are compared on the same flow.

Compare the actual result with the expected behavior

Use the evidence to decide whether to accept the result or revise it. Keep enough of that evidence for someone else to understand the decision.

Watch at 31:35

Compare the actual result with the expected behavior

Checks can provide a learning signal

When an outcome can be verified, the pass or failure can guide another attempt or support training. Define the check before using it as a reward.

Watch at 31:59

Checks can provide a learning signal

Save a goal outside the conversation

An external goal lets the harness check whether the work is complete across turns. When it is blocked or reaches a limit, report what remains.

Watch at 32:39

Save a goal outside the conversation

Let the harness enforce part of the goal

A harness can track goal state and pause or resume work. The state becomes more useful when tied to observable acceptance criteria and clear execution limits.

Watch at 32:57

Let the harness enforce part of the goal

Hooks put checks at known points

A hook can run deterministic logic before or after an action, or when the agent tries to finish. Use those points to check permissions, collect observations, or require completion evidence. The exact hook names and behavior depend on the harness.

Watch at 33:19

A diagram marks hook points around agent actions and attempted completion.

Put each check where it can help

Check permission before a tool call, capture evidence after it, and verify acceptance before reporting completion.

Watch at 33:30

Put each check where it can help

Verify what happened in the browser

A Playwright check exercises the actual interface and asserts the new checkbox state. Save the evidence for the part of the workflow the user asked you to verify.

Watch at 33:43

Verify what happened in the browser

Workshop 5 setup

The migration moves from Pydantic 1 to 2. The exercise compares the agent’s own tests with a verifier that checks the API behavior a client sees.

Watch at 34:23

Workshop 5 setup

A passing self-test can miss a contract change

In the API migration exercise, the agent’s test checked a Python Decimal. The HTTP replay checked the response clients receive. Seven responses still returned 200, but the JSON value had changed from the number 25.0 to the string "25.00". The contract at the boundary was the check that mattered.

Watch at 34:32

The self-test passes while the HTTP replay finds a JSON number returned as a string.

Make a failure specific enough to act on

The HTTP verifier showed what was wrong with the serialized response. That evidence pointed the agent to the serializer it needed to change.

Watch at 34:38

Make a failure specific enough to act on

Rerun the same evidence after the fix

The agent repaired the behavior and reran the frozen replay. All 15 cases in that replay passed. The agent invoked the checker itself and eventually hit its iteration cap. Those results support the tested HTTP contract and show why I track the outcome check alongside the agent’s run status.

Watch at 34:42

The frozen HTTP replay passes all 15 recorded cases.

Keep changes that improve a measured result

AutoResearch gives the agent an experiment loop with a score. It logs each run and keeps changes that improve the result under the stated limits.

Watch at 34:49

Keep changes that improve a measured result

Most experiments can be discarded

One reported AutoResearch run tried 83 experiments and kept 15. The record gives you the running best and the attempts that failed to improve it.

Watch at 35:07

Most experiments can be discarded

Set limits on what the agent can do

Choose the files, actions, and approvals the job needs. Keep those controls in the harness so they still apply during a long run.

Watch at 35:34

Set limits on what the agent can do

Follow the Android app example through delivery

The build was one checkpoint in Cognition’s project. The example puts that work in the context of a wider goal to deliver a usable Android app.

Watch at 35:50

Follow the Android app example through delivery

What to take from goals and stopping

Keep the outcome fixed as the plan changes. Give the agent feedback, a way to verify completion, and a clear point at which to stop or report a blocker.

Watch at 36:17

What to take from goals and stopping

When to use multiple agents

I’d start with work that divides cleanly, clear ownership, and a lead that can check and combine the results. Then I’d measure the cost of getting the work back together. Watch from 36:26

When should you add a second agent?

A team can divide work or isolate context. Test whether that benefit outweighs coordination, duplicate work, and the cost of the additional runs.

Watch at 36:26

When should you add a second agent?

Separate work by context or responsibility

Parallel research is a natural candidate when each worker can look at a separate set of sources. A builder and reviewer can also work in separate contexts to give each role clearer responsibilities. In either case, define what the lead must receive and who owns the final result.

Watch at 36:32

Two diagrams show a lead with similar workers and a builder with a separate reviewer.

Research can divide cleanly

Anthropic reported a 90.2% gain on its internal research evaluation against a single Opus 4 agent. The system used more compute. The comparison shows what that setup achieved and gives us a reason to test team designs under a comparable budget.

Watch at 37:10

Anthropic’s internal evaluation compares a multi-agent research system with one Opus 4 agent.

Workshop 6 setup

A single agent and a lead with three workers get the same repair, starting code, and Flash model. Follow when the code first became correct and what each run cost.

Watch at 37:41

Workshop 6 setup

Include the lead’s integration work

The workers can overlap on codec, reducer, and checkpoint work. The lead still has to align interfaces, integrate changes, and validate the result. Count those actions, handoffs, and tokens when comparing this setup with a single agent.

Watch at 37:45

The same coding task is assigned to a single owner or a lead coordinating three workers.

What the single agent did

The first passing repair took 80.5 seconds in this run. The trace provides a baseline for judging whether parallel work helps on the same fixture.

Watch at 37:59

What the single agent did

What the parallel workers did

Three workers repaired separate modules. The lead still had to collect those changes and check that the modules worked together.

Watch at 38:03

What the parallel workers did

Compare the whole run

Both patches passed the recorded checks. The single owner produced correct code around 81 seconds and the team around 115 seconds. The team used 56% more tokens in this pair. Its lead also hit the cap without a final integration report. I’d measure a series of tasks before generalizing from this one pair.

Watch at 38:18

A table compares a single owner with the team on time to correct code, tokens, and cost.

Requested budgets need a reality check

The single-agent estimate was higher in five of eight rows here. These are reasoning tasks, some results are close, and requested budgets can differ from actual usage. For a team comparison, record actual cost and decide which outcomes count as finished before the run.

Watch at 38:35

A bar chart compares single- and multi-agent results with the same requested thinking budget.

Multi-agent results depend on the task

The scaling study compares several team structures across benchmarks. Look for work that divides cleanly and track where coordination slows down a sequential task.

Watch at 38:50

Multi-agent results depend on the task

What additional inference can buy

Cohere Labs reports higher coding scores in team runs at three to seven times the inference cost. Compare the quality gain with the cost you are willing to pay.

Watch at 39:33

What additional inference can buy

A team increase was significant in one tested setting

Vibe Code Bench found a significant score gain for one model and effort pairing in the table. Costs went up across the team runs.

Watch at 39:50

A team increase was significant in one tested setting

Parallelize investigation and coordinate edits

Factory’s example gives investigation to parallel workers while handing code changes off in sequence. That reduces overlap when workers need to touch the same files.

Watch at 40:01

Parallelize investigation and coordinate edits

Separate the team’s contribution from the model’s

Noam Brown’s comment on the Navier-Stokes result offers one interpretation of the team’s role. To attribute a gain on your task, change the orchestration while holding the model fixed.

Watch at 40:20

Separate the team’s contribution from the model’s

Try a simpler loop when everyone shares context

A single agent with a small tool set is a useful baseline. Keep separate contexts where the work is independent or where you want a fresh verification pass.

Watch at 40:40

Try a simpler loop when everyone shares context

Three ways to simplify coordination

Merge agents working from the same context, invoke a separate agent as a tool with a defined return value, or move repeatable steps into skills and tools.

Watch at 40:53

Three ways to simplify coordination

The harness user interface

There’s also an interface for the person who gives the agent work and checks how it’s going. Watch from 41:16

Put the pieces together

Once the internal loop works, look at what the user can see and correct, and at which parts of the harness might change as the agent learns.

Watch at 41:16

Put the pieces together

Give people a chance to correct the agent early

Bruce Liu’s intra-turn interaction demo shows ways the user can correct an assumption early or supply missing detail while a response is in progress. For a coding agent, I’d use the same idea to expose assumptions about the target repo, relevant workflow, or success criteria before the agent spends time acting on them.

Watch at 41:28

Bruce Liu’s feedforward interface demonstrates how intentions can be surfaced while a user types.

Self-evolving harnesses

We can give an agent tools it can use today. Some of the work I cover here asks whether an agent can propose changes to its own tools and instructions, then test those changes. Watch from 42:09

From supplied tools to tools adapted for the job

In the animation, the robot starts with equipment a human put in place. Then it changes what it can do as the task changes. That’s the idea behind the examples that follow. Their improvements come from specific experiments with limits on what the harness could change and how success was measured.

Watch at 42:22

The robot animation illustrates a harness adapting its equipment for a new task.

Keep enforceable conditions in the harness

Model behavior can improve with training. The harness can still require evidence, check authorization, and apply execution and state limits every time.

Watch at 42:32

Keep enforceable conditions in the harness

Propose changes and test them

Meta-Harness lets a proposer inspect previous harness code, logs, and scores before trying a revision. In the TerminalBench-2 comparison shown, the task model stays fixed and the pass rate rises from 74.7% to 76.4%. Include the cost of the search itself when deciding whether that improvement makes sense for your application.

Watch at 43:00

A Meta-Harness diagram shows a proposer editing harness code and evaluating the results against earlier runs.

Generate task-specific tools

The starting harness gives the model an IPython kernel and a short prompt. In Younes Belkada’s walkthrough, subagents can write task-specific Python tools and instructions. According to the walkthrough, those subagents don’t see the tests or solutions. This is one way to change how a model can work on a task while using the same task model.

Watch at 43:20

A walkthrough shows a minimal IPython harness alongside proposed Python tools and instructions.

A task-specific harness can improve one task and hurt another

Belkada’s examples show different results across tasks when the same agent can adapt its harness. Test on work outside the cases used to develop the change.

Watch at 43:38

A task-specific harness can improve one task and hurt another

Carry changes that worked into future runs

Harness² uses feedback from attempts to propose and test harness changes. It also provides a way to retain reusable lessons beyond the current task.

Watch at 43:47

Carry changes that worked into future runs

Use failed runs to propose repairs

Harness-R1 trains a separate harness engineer to propose repairs after failed runs. The displayed average success rises from 44.3% to 53.6% with a fixed task model. Its training reward comes from reruns of the same batch. Held-out tasks are the next check if you want evidence the improvements generalize.

Watch at 43:57

Harness-R1 uses failures to guide patches to the harness and reruns tasks to evaluate them.

What to change in your own harness

Six decisions to revisit

Pick a job you can run more than once. Write down what success looks like at the boundary the user cares about. Run a baseline and keep the trace. Then change one thing in the harness and rerun the same job. Look at what the agent did, what evidence it produced, and what it cost to get a successful result. Watch the recap from 44:09

Watch at 44:09

The recap labels harness choice, tools, context and memory, model choice, goals and checks, and multiple agents on the robot illustration.

Watch or share the talk

Use the YouTube link to watch the talk and subscribe for more walkthroughs.

Watch at 45:11

Watch or share the talk

Try it yourself