By Sagar Shankaran, Founder of CallSphere
How Claude Code on desktop runs parallel agents: orchestrator loop, isolated subagent contexts, the tool bus, locks, and shared-state merge.
Key takeaways
Run a single agent on your laptop and the mental model is easy: one loop, one context window, one tool call at a time. The moment you redesign Claude Code on desktop to run several agents at once, that simplicity disappears. Now you have multiple loops competing for the same files, the same MCP servers, the same terminal, and the same human watching the screen. The architecture you build underneath decides whether that feels like a team of engineers or a pile-up at a four-way stop.
This post walks the full stack of a desktop Claude Code build designed for parallelism — from the top-level orchestrator down to how each subagent gets its own isolated context and how their results are stitched back together. The goal is a concrete picture an engineer can hold in their head, not a marketing diagram.
The reason to run agents in parallel on desktop is wall-clock time. A large refactor, a multi-file migration, or a research sweep across a codebase has independent chunks. A single agent processes them one after another; a fleet of subagents can attack them simultaneously, each in its own context, and report back. The desktop is a good home for this because it already has the file system, the credentials, and the long-lived processes the work depends on.
But parallelism is only worth it when the chunks are genuinely independent. If subagent B needs the output of subagent A, you have not parallelized — you have added coordination overhead to a sequential job. The architecture's first job is to make independence cheap to express and dependence impossible to fake.
At the top sits the orchestrator: a long-running Claude loop whose only job is to decompose work, spawn subagents, watch their results, and decide what happens next. It holds the plan and the high-level context, and it deliberately does not do the detailed work itself. Beneath it is a pool of subagents, each a fresh Claude loop with its own context window, its own system prompt, and a narrow task. At the bottom is the tool and permission bus — the single mediated path through which any agent touches the file system, the terminal, the network, or an MCP server.
Hear it before you finish reading
Talk to a live CallSphere AI voice agent in your browser — 60 seconds, no signup.
flowchart TD
U["User goal in desktop UI"] --> O["Orchestrator loop"]
O --> P{"Independent chunks?"}
P -->|No| S["Run sequentially in main context"]
P -->|Yes| F["Fan out subagents"]
F --> A1["Subagent: isolated context A"]
F --> A2["Subagent: isolated context B"]
A1 --> B["Tool & permission bus"]
A2 --> B
B --> R["Results & summaries back to orchestrator"]
R --> OThe arrows that matter most are the ones pointing back up. Subagents return summaries — a compact statement of what they did, what they changed, and what they learned — not their full message history. If the orchestrator inhaled every subagent's raw transcript, its context window would fill in minutes and you would lose the very oversight the orchestrator exists to provide.
The single most important architectural decision is that each subagent owns a separate context window. This is not just a token-budget trick. Isolation means subagent A cannot be confused by subagent B's intermediate reasoning, cannot accidentally act on B's half-finished file edits, and cannot inherit B's mistaken assumptions. Each agent reasons about a clean, scoped slice of the problem.
In practice the orchestrator passes each subagent three things: a task description, a read-only snapshot of the shared context it needs (relevant file paths, conventions, constraints), and a contract for what to return. The subagent does its work in private and emits a structured result. The desktop runtime never merges two subagents' contexts; it merges their outputs, which is a much smaller and safer surface.
Reasoning in parallel is safe because it touches nothing shared. The danger is in side effects. Two subagents editing the same file, two running npm install in the same directory, or two opening a write transaction against the same MCP-backed database will corrupt each other. The tool bus solves this with leases: before any mutating tool call executes, the bus acquires a lock on the resource — a file path, a directory, a named MCP connection — and releases it when the call returns.
A simple, effective rule is path-scoped locking for the file system and serialized access per terminal session. Read-only calls (reading a file, querying an MCP resource) can run fully concurrently; write calls queue behind a lease. The orchestrator can further reduce contention up front by assigning non-overlapping file scopes to each subagent, so the locks are rarely contended in the first place.
State in a parallel build splits cleanly into two kinds. Immutable shared context is everything every agent may read but none may write during the run — the plan, the coding conventions, the snapshot of the repo at fan-out time. Per-agent scratch is everything a single agent writes — its draft edits, its notes, its tool results. Keeping these separate eliminates a whole class of race conditions, because two agents never write the same cell.
Still reading? Stop comparing — try CallSphere live.
CallSphere ships complete AI voice agents per industry — 14 tools for healthcare, 10 agents for real estate, 4 specialists for salons. See how it actually handles a call before you book a demo.
The orchestrator reconciles scratch into shared state only at join points: when a subagent finishes, the orchestrator reviews its diff, resolves any conflicts (usually by re-running an affected agent rather than auto-merging), and folds the change into the canonical state. This is the desktop equivalent of a merge step in version control, and treating it that way — explicit, reviewable, conflict-aware — is what keeps a fleet of agents from quietly clobbering each other's work.
| Concern | Single agent | Parallel desktop build |
|---|---|---|
| Wall-clock on independent work | Slow, serial | Fast, concurrent |
| Context per task | One window, shared | Isolated per subagent |
| Race conditions | None | Real; need the tool bus |
| Token cost | Lower | Several times higher |
The orchestrator is a long-running Claude loop that decomposes a goal into independent tasks, spawns subagents to do them, and reconciles their results. It holds the plan and high-level context but deliberately does no detailed editing itself, so its context window stays clear for oversight.
Through context isolation and a tool bus. Each subagent has its own context window and writes only to its own scratch space, and all mutating tool calls pass through a bus that locks the targeted file or resource until the call completes.
Yes. Multi-agent runs typically consume several times more tokens than a single agent, because each subagent maintains its own context and re-reads shared material. Parallelism pays off only when wall-clock time matters and the work is genuinely independent.
Whenever later steps depend on earlier outputs. If subagent B needs A's result, parallel execution just adds coordination overhead. Reserve fan-out for chunks that share no dependencies and touch non-overlapping files.
CallSphere takes these same parallel-agent patterns and points them at conversations: multi-agent voice and chat assistants that answer every call, pull data through tools mid-conversation, and book real work around the clock. See it running at callsphere.ai.
Source & attribution: This is an independent, original explainer inspired by Anthropic's coverage on the Claude blog. Claude, Claude Code, Claude Cowork, Claude Opus, and the Model Context Protocol are products and trademarks of Anthropic. CallSphere is not affiliated with or endorsed by Anthropic.

Written by
Sagar Shankaran· Founder, CallSphere
LinkedInSagar Shankaran is the founder of CallSphere, where he builds production AI voice and chat agents deployed across healthcare, hospitality, real estate, and home services. He writes about agentic AI, LLM engineering, and shipping voice agents that handle real calls in production.
See how AI voice agents work for your industry. Live demo available -- no signup required.
A resin increase means re-costing hundreds of part numbers one at a time. Splitting the list four ways by contract rule moves the pass-through weeks earlier.
Anthropic's Claude Fable 5 and Mythos 5 explained: pricing, availability, frontier benchmarks, the dual-model safeguard architecture, and what they mean for AI agents.
Where Claude Code, MCP, and multi-agent systems are taking GTM engineering next, and how to prepare your team now for standing and multi-agent workflows.
Where Claude Cowork and the Claude agent ecosystem are heading next — standing agents, MCP, skills as a moat — and the concrete moves to prepare your team now.
The metrics, leading signals, and anti-metrics that prove Claude Cowork is working — acceptance rate, time-to-outcome, and why usage counts mislead.
Shipping an agentic GTM workflow is easy; proving it works is hard. The metrics, signals, and eval loops that show a Claude Code rebuild is paying off.
© 2026 CallSphere Inc. All rights reserved.
Made within San Francisco
Watch how CallSphere handles real customer calls, schedules appointments, and processes payments — live.
Try Live DemoBook a DemoCalculate Your ROI