## The Power of Orchestration: How to Run 100+ Coding Agents in Parallel
In the rapidly evolving landscape of AI-assisted development, the true power of coding agents lies not just in their individual capabilities, but in their ability to work together at scale. I’ll discuss how to orchestrate a lot of different agents using Claude Code or any other coding agents, and how you can move up an additional abstraction level to manage them effectively.
### Why Orchestrate Multiple Agents?
The primary benefit of orchestrating multiple agents is simple: **doing more work in less time**. When you work with coding agents, you want to run as many agents in parallel as possible. This parallelization is what makes working with agents so effective—the fact that you can do work simultaneously means you get more total work done.
However, running multiple agents simultaneously presents several challenges:
* How do you define and scope specific tasks for different agents to prevent interference?
* How do you keep track of all your agents?
* How do you answer the agents’ questions while maintaining context for each one?
The solution is to move one abstraction layer up: instead of managing every agent yourself, you need to talk to one agent that can itself orchestrate a set of other agents.
### How to Orchestrate a Lot of Agents
The key to effective orchestration is using **headless mode**. Both Claude Code and Codex support headless mode, which allows you to spin up a session via the command line where an agent works on a task independently and only returns the final result.
**Starting Headless Sessions:**
With Claude Code:
“`bash
claude -p “your prompt here”
“`
With Codex:
“`bash
codex exec “your prompt here”
“`
When you run these commands, a separate session spins up to work on the specified task. The orchestrator agent only sees the logs (if you choose to provide them) and receives the final result once the work is complete. You can also configure these sessions with various settings like permissions, tool access, model selection, and maximum turns.
### Techniques for Effective Orchestration
To be effective with headless mode, focus on three main techniques:
**1. Providing Verification Mechanisms**
Since you can’t directly control all decision-making at this abstraction level, you need to prompt agents to verify their own work. This is crucial for maintaining quality when operating at scale.
**2. Finding Suitable Tasks**
Not all tasks are equally suited for headless mode. Complex, vague tasks that require significant input are better handled through direct interaction. However, **refactoring** is particularly well-suited for headless mode.
You can use commands like:
“`
look for refactor opportunities in this repository and provide
them to me in a prioritized manner in an HTML file and make a plan on how
to fix it
“`
After discovering refactoring opportunities, convert the plan into executable tasks:
“`
Take the plan and structure a way for us to implement it.
I’ll be using the most powerful coding agent as an orchestrator, and that
coding agent should spin up a bunch of Claude Code headless sessions using
Claude Opus to get each individual task done. Make sure that tasks that
can be done in parallel are spun up in parallel and continue working until
you finish the refactoring completely.
“`
**3. Providing All Necessary Tools**
When agents work in headless mode, they can’t easily interact with you. Therefore, you must give the orchestrating agent all the tools it needs—including MCP access, autonomous action permissions, and clear instructions on when to report back. This autonomy is essential for effective large-scale orchestration.
## FAQ
**Q: What is headless mode, and why is it important for orchestrating multiple agents?**
A: Headless mode allows you to spin up agent sessions via the command line that work independently on specific tasks and only return final results. This is crucial for orchestration because it enables you to run many agents in parallel without constant manual oversight, significantly increasing productivity.
**Q: Can I use this technique with both Claude Code and Codex?**
A: Yes, the article explains how to use headless mode with both tools. The commands differ slightly (`claude -p` for Claude Code vs. `codex exec` for Codex), but the orchestration concept applies to both.
**Q: What types of tasks are best suited for headless mode?**
A: Refactoring is highlighted as particularly well-suited for headless mode. More complex or vague tasks generally require more direct human input and are less appropriate for this autonomous approach.
**Q: How do I prevent agents from interfering with each other’s work?**
A: Clear task scoping is essential. You need to define specific, independent tasks that agents can work on without overlapping responsibilities. The orchestrating agent plays a key role in distributing these appropriate tasks.
**Q: Why is agent verification important in this model?**
A: When operating at scale with headless agents, you have less direct control. Teaching agents to verify their own work ensures quality control and reduces the need for constant human intervention.
## Conclusion
In this article, I’ve discussed how to orchestrate 100+ agents by utilizing agents as orchestrating agents to spin up numerous parallel sessions. This powerful technique allows you to move up an abstraction layer, managing multiple coding agents through a single orchestrator rather than handling each session individually.
I believe this is a transformative approach that you can apply immediately to boost your productivity. By leveraging headless mode, proper task scoping, agent verification, and appropriate tool access, you can run dozens or even hundreds of agents in parallel effectively.
The future of programming increasingly involves moving up abstraction layers, and the orchestration techniques presented here represent a significant step forward in that evolution. Start applying these methods today to gain a substantial advantage in your development workflow.
👋 **Get in Touch**
* 📚 **Get my free Vision Language Models ebook**
* 💻 **My webinar on Vision Language Models**
* 🔗 **Find me on socials:** Substack, LinkedIn, X/Twitter
With this approach, you’re not just using AI tools—you’re building a scalable, autonomous development system that can tackle complex coding challenges far more efficiently than traditional methods.



