Claude Code's Dynamic Workflows: A Thousand Agents, One Script
The interesting part isn't the swarm. It's where the plan lives.
Anthropic's new "dynamic workflows" can fan a single request out to a thousand AI agents. The genuinely new part isn't the swarm; it's where the plan now lives.
In eleven days, the team behind the Bun runtime ported 750,000 lines of code from Zig to Rust, and 99.8% of the existing test suite still passed. That is the number Anthropic leads with when it talks about dynamic workflows, and it is the right number to be suspicious of. Eleven days. Three-quarters of a million lines. A test suite that barely flinched. It sounds less like a software project than like a weather event.
The feature that made it possible shipped into Claude Code on May 28, 2026, as a research preview, alongside Claude Opus 4.8 and a cheaper fast mode. The pitch is seductive and a little alarming: describe a task, and Claude writes a script that spins up "tens to hundreds of parallel subagents in a single session, checking its work before anything reaches you." Up to sixteen run at once; up to a thousand across a single run before a hard cap stops the thing from eating itself alive.
It is easy to read that as a story about scale, Anthropic's first real agent swarm. But the scale is the least interesting thing about it. The interesting thing is a quiet architectural move, the kind that doesn't photograph well: the plan moved out of the conversation and into a file.
Who holds the plan
Until now, every way Claude could delegate work shared one trait. Claude held the plan in its head. You could spawn subagents, invoke skills, even stand up a team of peer agents, but in each case the model decided, turn by turn, what to do next, and every result came flooding back into its context window. The orchestrator was a chat.
A dynamic workflow breaks that. It is, in Anthropic's own flat description, "a JavaScript script that orchestrates subagents at scale." Claude writes the script, and a separate runtime executes it in the background while your session stays free. The loop, the branching, the intermediate results, all of it lives in the script's variables, not in the model's memory.
That sounds like a plumbing detail. It is actually the whole game. When the plan lives in Claude's context, the context fills up with bookkeeping: every subagent's output, every dead end, every retry, until the model is spending its attention managing the mess instead of solving the problem. When the plan lives in code, the script absorbs all of that, and "Claude's context holds only the final answer." The difference between those two arrangements is the difference between a manager who personally remembers every task on the board and a manager who wrote the board down.
A workflow moves the plan into code. The orchestration becomes something you can read, diff, and rerun, not a performance you hope to reproduce.
Why it works
There are two honest reasons a workflow can beat a single industrious agent, and they pull in different directions.
The first is the obvious one: parallelism. A migration across thousands of files, a bug sweep over an entire service: these are jobs that no single conversation can hold in its head at once. Sixteen agents working simultaneously simply cover more ground.
The second is subtler and, I think, the more important claim. Because the plan is code, it can enforce a quality pattern instead of just running more bodies at the wall. Anthropic's framing is precise: "agents address the problem from independent angles, other agents try to refute what they found, and the run keeps iterating until the answers converge." The bundled /deep-research workflow does exactly this: it fans searches across several angles, cross-checks the sources against each other, votes on each claim, and returns a report "with claims that didn't survive cross-checking filtered out."
That is not more autonomy. It is less. It is adversarial review, baked into a script, applied mechanically. The swarm is impressive; the skepticism is what makes the output trustworthy.
Is it actually new?
Here is where the marketing and the engineering quietly disagree, and where the honest answer lives.
Go back to December 19, 2024. Anthropic published a guide called "Building Effective Agents," drawn from watching dozens of customer teams. In it, the company drew a line it is still drawing today: workflows are "systems where LLMs and tools are orchestrated through predefined code paths," while agents are "systems where LLMs dynamically direct their own processes." It then named five workflow patterns, including prompt chaining, routing, parallelization, orchestrator-workers, and evaluator-optimizer, and told developers to hand-code them.
Read the two releases side by side and the punchline writes itself. The 2024 guide described orchestration patterns and said: you build these. The 2026 feature takes the same patterns and says: Claude builds these, on the fly, for whatever you asked. The orchestrator-workers pattern, the evaluator-optimizer loop, which are right there in the dynamic-workflow machinery, just authored by the model instead of an engineer at 2 a.m.
So no, the idea is not new. What's new is the automation of it: the script writes itself. That is a real advance, and pretending it's a conceptual leap does it a disservice. The same line, drawn seventeen months apart, only now you don't have to draw it.
When to actually reach for one
The temptation, with a tool this powerful, is to reach for it constantly. Resist that. The sharpest critique of dynamic workflows isn't that they don't work; it's that people misjudge when they're worth it, and the bill arrives later.
The core problem is that autonomy has a steep token cost. Workflows look great in demos precisely because demos are short and well-scoped, which hides the expense. In the wild, the costs compound: every decision step carries accumulated context, and a run that hits a snag "might spend 5x more tokens recovering" instead of failing cleanly. Anthropic itself warns that a workflow "can use meaningfully more tokens than working through the same task in conversation," and recommends running on "a small slice first," meaning one directory, one narrow question, before you commit to the whole repo.
The shape of the decision is simple once you draw it. Workflows earn their keep on genuinely unpredictable, one-off, exploratory work, debugging an unfamiliar codebase, research that has to follow the evidence wherever it leads, a migration you'll run exactly once. They are the wrong tool for repetitive production tasks, for anything you'll run nightly, for work whose components you can already name and separate. For those, a plain pipeline of subagents is cheaper, more predictable, and easier to trust.
"Autonomy has a steep token cost." The discipline isn't to let Claude figure it out. It's to know when figuring-it-out is worth paying for.
That leaves two takeaways worth carrying out of all this. First: when you evaluate dynamic workflows, judge them on the verification, the adversarial cross-checking, the convergence, not the headcount. A thousand agents that don't check each other is just a thousand ways to be confidently wrong. Second: treat the feature the way Anthropic told you to treat agents back in 2024: start with the simplest thing that works, and add the swarm only when the task genuinely refuses to fit in one head. The Bun rewrite is real. So is the 5x recovery bill. The skill is telling those two futures apart before you press go.
Sources
[1] Introducing dynamic workflows in Claude Code, Anthropic / claude.com blog (May 28, 2026). https://claude.com/blog/introducing-dynamic-workflows-in-claude-code
[2] Orchestrate subagents at scale with dynamic workflows, Claude Code Docs (2026). https://code.claude.com/docs/en/workflows
[3] Building Effective Agents, Anthropic Engineering (Dec 19, 2024). https://www.anthropic.com/engineering/building-effective-agents
[4] Anthropic Ships Claude Opus 4.8 Alongside Dynamic Workflows and Cheaper Fast Mode, MarkTechPost (May 28, 2026). https://www.marktechpost.com/2026/05/28/anthropic-ships-claude-opus-4-8-alongside-dynamic-workflows-and-cheaper-fast-mode-with-workflows-capped-at-1000-subagents/
[5] Anthropic Dynamic Workflows: What Everyone Gets Wrong About When to Use Them, MindStudio (2026). https://www.mindstudio.ai/blog/anthropic-dynamic-workflows-when-to-use-them
[6] Claude Code Adds Dynamic Workflows for Parallel Agent Coordination, InfoQ (Jun 1, 2026). https://www.infoq.com/news/2026/06/dynamic-workflows-claude-code/
David Proctor is VP of AI at Trilogy. He writes about AI infrastructure, agent protocols, and what actually works in production.





