How I Work with a Team of Coding Agents
A year ago I’d have described my job as writing code. Now it’s closer to running a small team. On a normal day I have a few agents working at once, each on a different part of the plan, and most of my time goes into deciding what they should work on, unblocking them, and reviewing what comes back.
I do this at work, where I’m a tech lead, and on my own projects. Earlier this month I used it to clean up this site and its blog, plus a pile of old side projects that live on the site. The amount of work I can get through has gone up a lot, both there and at work, and every change was still opened as a pull request by an agent and reviewed before I merged it.
This post covers how that workflow fits together. It’s for people who already use agents, and also for people who’ve only tried a chat window and wonder what the fuss is about. I’ll keep work examples generic.
- The tools
- Get grilled before anything gets built
- Fan out to parallel agents
- Review across models, not within one
- A throwaway command center
- Automate the friction away
- Guardrails
- Deterministic validation
- Auto-merging
- Packaging what works
- What I want to try next
- This is a leadership problem too
- If you’re just starting
- Sources
The tools
I’m not loyal to one tool. My main one is Claude Code, and I use OpenAI’s Codex a lot alongside it. When I run out of tokens on both, I drop to GitHub Copilot. For some kinds of web research I still just use ChatGPT in the browser, because it’s good at that and doesn’t need access to my code.
The fact that I mix them matters more than which ones I pick. Different models make different mistakes, and that turns out to be the most useful thing about having more than one. More on that in the review section.
This lineup will probably look different in a few months. Every harness and model keeps improving, and whichever is best at a given job changes often, so I try not to get too attached.
Get grilled before anything gets built
The most common way agent work goes wrong for me isn’t bad code. It’s good code for the wrong thing. If I give an agent a one-line ask, it fills in all the gaps with guesses, and it guesses with confidence.
So I start most real pieces of work by having the agent interview me. Matt Pocock has a set of open source skills for this. His grilling skill tells the agent to “interview the user relentlessly about a plan, decision, or idea until every branch of the design tree is resolved”. His wayfinder skill goes further for work that’s too big for one session. It plans the work as “a shared map of decision tickets on the issue tracker” and resolves them one at a time.
You don’t need the skills for this, though. It’s just as easy to tell the agent to “grill me” about the work until we have a plan, and then have it write everything down in a clean doc that the other agents can read later. Anthropic’s own Claude Code best practices suggest the same thing: ask Claude to interview you until it could write the spec, write it to a file, and then start a fresh session to build from it.
It feels slow for the first ten minutes. Then it saves hours, because every agent that picks up a piece of the plan later gets the answers instead of guesses.
Fan out to parallel agents
Once there’s a plan, I usually have one session act as a coordinator. It breaks the plan into tickets that don’t step on each other, then hands each ticket to a generic worker agent, several at the same time. As the coordinator sees a worker finish, it passes that worker the next unblocked ticket. Claude Code supports this directly: subagents each run in their own context window with their own instructions, so one can be deep in a migration while another writes tests and neither fills up the other’s context with noise. Anthropic calls this the orchestrator-workers pattern, where “a central LLM dynamically breaks down tasks, delegates them to worker LLMs, and synthesizes their results.”
It isn’t free. When Anthropic wrote up their multi-agent research system, a lead agent with parallel subagents beat a single Claude Opus 4 agent by 90.2% on their internal research eval, but multi-agent systems used about 15 times more tokens than a normal chat. Fan-out buys you speed and coverage, and you pay for it in tokens.
The part that took me a while to figure out is the standing instruction that makes that handoff happen. Without one, an agent finishes its task, reports back, and sits there until I notice. Now I almost always tell the coordinator something like “when a task is done, keep picking up the next unblocked piece of work”. That one sentence turns a batch of tasks into a queue that drains itself. “Unblocked” is the important word. It keeps agents from grabbing work that depends on something another agent hasn’t finished yet.
The other thing that makes fan-out work is splitting along boundaries that don’t overlap. Two agents editing the same file at the same time will make a mess, the same way two people would. If the plan can’t be split cleanly, I’d rather run fewer agents. When agents do need to work in the same repo at the same time, give each one its own checkout. Git worktrees are the cheap way to do that: extra working folders attached to the same repo, each on its own branch, and Claude Code can set them up for you. Once you’re running a lot of agents, it’s probably worth keeping a pool of worktrees that are already set up and get reused between tickets, so each new agent doesn’t wait on a fresh install and first build. treehouse is one tool that manages a pool like that.
Review across models, not within one
This is a habit I’d push on anyone using agents. I always have a standing instruction to bounce reviews between harnesses before a PR gets opened, and I’ve consistently gotten better results that way.
A model reviewing its own work tends to agree with itself. It made its choices for reasons that still seem good to it. There’s research backing this up: a 2024 paper, “LLM Evaluators Recognize and Favor Their Own Generations”, found that models rate their own outputs higher than other models’ outputs, and the better a model is at spotting its own writing, the stronger the bias. A different model doesn’t share those blind spots, so it catches different things. Even a fresh session of the same model helps. The Claude Code best practices call a second session “the easiest independent reviewer you can get”, since it never saw the reasoning that produced the code.
OpenAI ships an official Codex plugin for Claude Code that makes this easy. Claude can call /codex:review for a normal review or /codex:adversarial-review for “a steerable challenge review”, and it can also hand whole tasks to Codex.
In practice it goes one of two ways:
- Claude writes the code and asks Codex to review it.
- Codex writes the code, and then a separate Claude session and a fresh Codex session both review it. That way there’s always at least one reviewer that isn’t the model that wrote it.
Either way, the review comments go back to whoever wrote the code, they fix it, and it goes around again until the reviewers stop finding real problems. Only then does a PR get opened, and then the automated PR reviews run on top and get addressed too. On my personal projects, every PR also gets a final review from a separate, cheaper model before I merge.
None of this means I stop reviewing. I still review most of the PRs my agents generate, because every so often an obvious, confidently wrong mistake makes it through all of the automated reviews. What the loops buy me is that by the time a PR reaches me, most of the small stuff is gone and I can spend my attention on whether the change is the right one. I even reviewed this entire blog post before posting it!
A throwaway command center
With five or six agents going, the hard part stops being the code and starts being keeping track. Which agent is waiting on me? Which PR failed CI? What’s still blocked?
What’s worked for me is having an agent build a small visual command center for the project: one page that shows the plan, what each agent is doing, and what’s waiting on me. I’ve built a different one for each project so far, because each project had its own quirks. A migration wants to show progress per service. A side project cleanup wants to show which repos still need a deploy. Agents make this cheap enough that a one-off dashboard is fine. When the project ends, I throw it away.
Here’s a made-up example of the kind of thing I mean:
blocked
running
needs me
done
The “needs me” column is the one that matters. Agents are fast, so I’m usually the bottleneck, and anything that shows me where I’m holding things up pays for itself.
Automate the friction away
If I had to pick one main point for this whole post, it’s this: use the tools to take the friction out of the work, and then use the time you get back to run more things in parallel. My test is simple. If starting my day or picking a project back up takes more than typing “resume”, there’s friction left to remove. Once getting started is that cheap, the next step is adding more parallel work while the current work is running.
A few things that have helped the most:
- Scheduled jobs. The one I use every day is a morning brief. Before I sit down, an agent has already pulled together my setup for the day: my open tickets, what merged yesterday, and any announcements or news that matter to my work. I start the day reading one page instead of opening ten tabs. There’s an example below.
- PR watchers. Small scripts that keep my open PRs synced with the main branch and merge them once they’re approved and green. A PR that’s done shouldn’t need me to click a button (more on that in auto-merging).
- Cleanup scripts. Agents create a lot of mess: disk space, old branches, workspaces nobody is using anymore. I have scripts that clean that up on a schedule. Where I can, I run agents in remote execution environments instead, because a cloud container that gets thrown away when the session ends is the easiest cleanup there is. I still use local development where reuse matters more, like a big repo that’s slow to set up or a build cache that takes a long time to warm.
- Notifications. This builds on the command center. An agent that’s waiting on me is just sitting there, so I want to know right away. Some way of getting pinged, whether it’s a phone notification or a browser notification, keeps things from sitting for hours. In Claude Code you can hook into its
Notificationevent and send that wherever you’ll actually see it.
my tickets
merged yesterday
worth knowing
None of these are big projects. Most of them are a short script or a scheduled prompt, and agents are good at writing those too.
Guardrails
Agents are confident, and they’re confident about things that stopped being true. The guardrail I lean on most is redundant verification. I have the agents double- and triple-check their assumptions throughout the work, even when nothing seems to have changed. Is that branch still where you think it is? Did another agent already merge something that touches this file? Does the test actually fail without your fix? It’s cheap to ask an agent to check, and it’s expensive when one builds an hour of work on a stale assumption.
The second half of that is making agents loud about their assumptions. I put instructions about this into as many places as I can: the planning step, the task prompts, the review prompts. An assumption that’s written down can be cross-checked by me, by a reviewer model, or by another agent. One that stays in the agent’s head just quietly turns into a bug.
I think of it like an airport. It’s good to know which runway a pilot plans to land on, and which way they’ll taxi once they’re down, before it happens rather than after. Nobody in the tower is assuming the pilot is bad. It’s that saying the plan out loud is how two planes find out they were headed for the same spot.
Deterministic validation
Everything in the guardrails section is still an instruction, and an instruction is a request. Agents follow them nearly every time, but nearly isn’t always. Anthropic’s Claude Code best practices split instructions into two kinds. Non-deterministic ones (your prompt, an AGENTS.md file, a skill) are read by the model, and “there’s no guarantee that it’ll follow your instructions.” Deterministic ones (hooks, deny rules, tests, CI, branch protection) are enforced by the tooling, and they apply “every time, no matter what the model decided to do.”
the model decides
the tooling enforces
So when something has to always happen, or never happen, I try to move it out of the prompt and into something that runs:
- Tests, type checks and linters that the agent has to get green before it says it’s done. “Done” means the checks pass, not that the agent says it’s done.
- Hooks that run at fixed points in the agent’s loop, like formatting every file it edits or blocking edits to generated code. In the docs’ words, “certain actions always happen rather than relying on the LLM to choose to run them.”
- CI and branch protection as the last word. No matter what any agent or reviewer thinks, nothing merges without passing checks, and anything that isn’t set up to auto-merge needs a person to approve it.
- Scripts for checkable assumptions. If an assumption can be checked with a script, like whether the branch is up to date or whether a config value exists, a script beats asking the agent to remember to check.
Tests aren’t one thing, though. They come in a lot of strengths, and the more of them a PR can point to, the less I need to read the diff to trust it. Roughly from cheapest to strongest:
Lauren Tan’s talk “All Code Is Slop (Except Mine)” is a good tour of the strong end. Her team has agents drive the real app to verify their changes, uses property-based testing on the UI, and has used TLA+ model checking and Lean proofs on the parts that really can’t break. She’s also clear that formal verification is “not a silver bullet”. You don’t need every rung on every project. The point is to know the ladder exists and to climb it where the risk is.
The habit I’m trying to build: when a reviewer, human or model, flags the same kind of problem twice, ask whether it could be a check instead of a comment. A lint rule or a test catches it every time, for free, and nobody has to remember it.
Most of the time you still want the agent to use its judgment. The deterministic layer is for the short list of things where judgment isn’t the point.
Auto-merging
Right now I’m the last step on most PRs, but not all of them. For certain projects, and for docs, we already auto-merge.
Docs are the easy place to start. A change to a README or a doc comment is low risk, easy to revert, and the reviewer loops and checks above already catch most problems in it. Once those pass, there’s not much left for me to add by clicking merge. GitHub’s auto-merge and protected branch rules get you most of the way there: require the checks to pass, and have a small workflow turn on auto-merge for PRs whose changes are all docs.
Docs are also becoming less important in the first place. A lot of documentation exists so the next person can understand the code without reading all of it. Agents are getting better and better at reading the code and its context directly, so they need less of that written down, and a stale doc matters less when nobody is relying on it.
I think the future moves further in this direction. As agents understand code and context better, and as more of the “is this safe?” question gets answered by deterministic checks, more kinds of changes can merge on their own, and human review can focus on the changes where judgment actually matters.
Packaging what works
Once a workflow works more than once, I try to package it so I don’t have to explain it again. Agents have three pieces that help here:
- Skills are folders of instructions the agent loads when a task calls for them. They’re a good fit for tasks that repeat but aren’t deterministic enough to script, like “review this the way our team reviews” or “plan this migration”.
- MCP servers connect the agent to your other systems, like your issue tracker or your docs, so it can look things up instead of asking you.
- Plugins bundle skills, agents, hooks and MCP servers together so a whole team can install them at once.
The idea I like most here is team plugins: one package with the team’s domain knowledge, workflows, integrations, and planning, review and debugging conventions. A new teammate installs it and their agents start out knowing how the team works. Before writing your own skill or MCP server though, look around. There are a lot of good ones already, and Matt Pocock’s repo above is a good place to start.
One rule I try to follow: only work on improving the harness while other work is actively running. Tweaking skills and prompts is fun, and it’s easy to spend a whole afternoon on it while nothing ships. If agents are busy on real work, tuning the setup in the meantime is free. If they’re not, it’s usually procrastination.
What I want to try next
A few ideas I keep coming back to:
- A disagreement detector. Run the same task through several models and flag the places where they meaningfully disagree. The places where models agree are probably fine. The places where they disagree are exactly where a human should look. It’s the cross-model review idea turned into something automatic. There’s research pointing the same way: in multiagent debate, several model instances propose answers and argue over them for a few rounds, which improved reasoning and factual accuracy and cut down on hallucinations.
- Episodic memory. Store past decisions and the reasons for them, and when a new task looks like an old one, pull up the similar cases so the agent starts from what we decided last time instead of from scratch. The Reflexion paper is a good starting point here. Its agents write reflections on what went wrong and “maintain their own reflective text in an episodic memory buffer” to make better decisions next time.
- PRs you can review without reading the code. I keep tuning what goes into my agents’ PR summaries, adding some things and cutting others, with the goal of reaching a point where I don’t need to read the diff to trust a change. Most of that comes from the PR spelling out what “done” meant: the acceptance criteria, the tests that prove each one, and that they all passed. The rest is visuals. I built a Chrome extension that builds on GitHub’s new pull request overview page and lays out what changed and how it was checked, so I can judge a PR at a glance instead of scrolling through files.
This is a leadership problem too
Sometimes, the hardest part of this isn’t the tooling. It’s that everyone is figuring it out at the same time, and seniority doesn’t mean you already know the answers. I think leading in this environment means modeling curiosity rather than expertise. For senior engineers, that looks like:
- Learning new tools in public, where people can see it.
- Saying “I don’t understand this yet” out loud.
- Sharing your actual workflow, including the parts that failed.
- Making it safe for people to experiment and get it wrong.
- Giving people the time and resources to adapt, instead of expecting it to happen on top of their normal work.
There’s research behind the safety part. Amy Edmondson defined psychological safety in 1999 as “a shared belief held by members of a team that the team is safe for interpersonal risk taking.” When Google studied what made its teams effective in Project Aristotle, psychological safety came out first on its list of what mattered, ahead of dependability, structure and clarity, meaning, and impact. If people are afraid to look slow while they learn agents, they’ll just not learn them.
If you’re just starting
You don’t need any of the parallel stuff to get value. If you’ve only used a chat window, here’s the order I’d try things:
- Use a coding agent in a real repo, on a small task you could do yourself, so you can judge the result.
- Before your next bigger task, ask it to interview you about the plan before it writes any code.
- Have a different model review the change before you open the PR.
- Once that feels normal, run two agents at once on two separate pieces of work.
- When you catch yourself explaining the same thing twice, turn it into a skill, a standing instruction, or deterministic validation.
Anthropic’s advice in Building effective agents applies to people too: start with “the simplest solution possible” and only add complexity when you need it. The fan-out and the command centers came later for me. The grilling and the cross-model review were the two things that made the biggest difference, and you can start both this week.
Sources
- Claude Code overview, Anthropic
- Create custom subagents, Claude Code docs
- Agent skills, Claude Code docs
- Hooks reference and hooks guide, Claude Code docs
- Claude Code on the web, Claude Code docs
- Plugins, Claude Code docs
- Introduction to the Model Context Protocol
- Codex, OpenAI
- Codex plugin for Claude Code, OpenAI on GitHub
- Lauren Tan, “All Code Is Slop (Except Mine)”, AI Engineer CODE 2026 (video)
- Matt Pocock, skills (including
grillingandwayfinder), GitHub - Guide: Understand team effectiveness, Google re:Work
- Amy Edmondson, “Psychological Safety and Learning Behavior in Work Teams”, Administrative Science Quarterly (1999)
- Building effective agents, Anthropic (2024)
- How we built our multi-agent research system, Anthropic (2025)
- The TLA+ home page, Leslie Lamport
- Lean, the Lean theorem prover
- Best practices for Claude Code, Claude Code docs
- Run parallel sessions with worktrees, Claude Code docs
- git-worktree documentation, Git
- treehouse, a pool of reusable git worktrees for agents
- Panickssery, Bowman and Feng, “LLM Evaluators Recognize and Favor Their Own Generations” (2024)
- Du et al., “Improving Factuality and Reasoning in Language Models through Multiagent Debate” (2023)
- Shinn et al., “Reflexion: Language Agents with Verbal Reinforcement Learning” (2023)
- Automatically merging a pull request, GitHub Docs
- New pull request overview page in public preview, GitHub Changelog
- About protected branches, GitHub Docs