WhoBuilt

Anthropic Workshop: Build Agents That Run for Hours

May 18, 2026· 1 h 16 min· 105K views·Watch on YouTube

Speakers

Anthropic Applied AI engineers Ash Prabaker and Andrew Wilson present at the AI Engineer conference on building agents that work autonomously for hours, with examples from Claude Code and experimental app-building harnesses.

Why long-running agents need support

Andrew identifies three challenges: finite context, weak planning, and models that often overestimate how complete their work is. He describes context anxiety near the end of a session and gives the example of a finished-looking button with no working backend. Model improvements help, but harnesses provide additional support.

How Claude Code’s harness evolved

Andrew surveys the Agent SDK primitives, including the agent loop, tools, subagents, skills, context files, and permissions. Ash and Andrew trace changes such as checkpoints, context improvements, agent teams, and server-side compaction alongside model releases. They describe performance growing from about one hour on Opus 3.7 to 12 hours on Opus 4.6 in a minimal scaffold.

Separate builders from evaluators

Ash describes a pattern inspired by adversarial systems: one agent builds while a separate evaluator tests the live app with Playwright and returns specific critiques. For visual quality, the team scores design, originality, craft, and functionality, using reference sites to calibrate the evaluator. With a retro game maker prompt, a six-hour run costing about $200 produced working gameplay and a more complete app than a solo run.

Use contracts and traces to improve the loop

A planner turns a short prompt into a high-level spec, while the builder and evaluator agree on testable feature contracts before implementation. Ash says 27 criteria made feedback on the game maker actionable, and that tuning the evaluator required reading traces and adjusting prompts. The team now simplifies loops as models improve, while keeping shared state and learnings in files.

Choose the harness for the model and task

Ash says harness patterns should adapt to each model’s strengths: their Opus 4.6 setup moved from fresh sessions and frequent evaluation to a continuous session with compaction and fewer rounds. For long-lived projects, Andrew and Ash recommend leaving filesystem breadcrumbs such as JSON state, dated logs, and live documentation. They describe the approach as best suited to greenfield apps unless teams add project-specific rubrics and testing for existing codebases.

Takeaways

  • Give evaluation its own context, tools, and clear criteria instead of asking the builder to approve its own work.
  • Test the running application with realistic interactions; passing unit tests may miss broken routes or controls.
  • Turn broad product goals into negotiated, testable contracts before implementation.
  • Read agent traces to find judgment failures, then improve prompts and rubrics based on what happened.
  • Revisit the harness as models change, and persist state in files so future sessions and people can pick up the work.

Mentioned in this talk

Search inside this talk

What was claimed 9

  • works at
    Solutions Architect, Applied AI
    “working as a solutions architect with many of our digital native and industry customers”
    YouTube
    Verified2 sources· Talk, Web· archived
  • works at
    Member of Technical Staff (RL and applied AI; Claude Code, Claude Agent SDK)
    “We both work as engineers on the Applied AI team here at Anthropic.”
    YouTube
    Verified2 sources· Talk, Web· archived
  • metric
    Anthropic: 12 hours on 50% of tasks with a minimal scaffold
    12 hours on 50% of tasks with a minimal scaffold
    “With Opus 4.6, it's 12 hours”
    YouTube
    Unverified1 source· Talk
  • feature
    Anthropic: provides primitives for agents, including a core loop, tools, subagents, context, and permissions
    provides primitives for agents, including a core loop, tools, subagents, context, and permissions
    “We have the Agent SDK, which ships with all the primitives we've been building over time.”
    YouTube
    Unverified2 sources· Talk
  • feature
    Ralph: A stop hook can continue a run until an iteration limit or safe word is reached
    “A stop hook intercepts when Claude would typically stop, and if it isn’t finished, it continues”
    YouTube
    Unverified1 source· Talk
  • metric
    Anthropic: about 30 hours in the described harness
    about 30 hours in the described harness
    “At this point, we could run for about 30 hours or so with Claude Sonnet 4.5.”
    YouTube
    Unverified1 source· Talk
  • launched
    “Along with that, and with some of the research we'd done, we released agent teams.”
    YouTube
    Unverified1 source· Talk
  • feature
    Anthropic: agents can communicate and coordinate with each other before reporting to the main agent
    agents can communicate and coordinate with each other before reporting to the main agent
    “The sub-agents could communicate with each other, so they had their own way to coordinate”
    YouTube
    Unverified1 source· Talk
  • feature
    Planner-generator-evaluator pattern: Separate contexts let an evaluator critique implementation and prompt revisions or a restart
    “This GAN-style harness will throw the whole thing out and try again from scratch.”
    YouTube
    Unverified1 source· Talk

Related talks