Claude Code source reveals at least 4 sub-agent isolation schemes—from the lightest coroutines to the heaviest independent processes. Anthropic is embedding software engineering process management thinking into AI coding tools. What we should care about here is: when AI starts genuinely working in parallel, "who changed which file" and "whose process is blocking whom" are no longer theoretical questions, but production incidents happening every minute.

What this is

Claude Code's sub-agents (Sub-agent, i.e., subordinate AI task units dispatched by the main AI) are not a single concept. Source code teardown shows it combines different forms across at least four dimensions:

Operation modes fall into three types: sync (the main AI waits for the subtask to finish before continuing), async (the subtask runs in the background and notifies upon completion), and background (the main AI doesn't even need to wait for a notification). Simply put, these are three management styles: "watching you work," "tell me when you're done," and "do it yourself, I don't care."

Isolation levels are divided into four tiers—and this is the key point:

Level 1: Pure coroutines, zero isolation. The subtask and the main AI are in the same process and the same memory space, relying only on context isolation to prevent "cross-reading." The advantage is speed; the disadvantage is that one infinite loop freezes everything.

Level 2: git worktree isolation (worktree, Git's multiple working directory mechanism allowing the same repository to have multiple independent directories simultaneously). Sub-agents modify files in independent directories without conflict, but still share the same process. This is the most cost-effective scheme.

Level 3: Teammate mode, true multi-processing. Each teammate runs in an independent tmux pane with process-level isolation; if one crashes, it doesn't affect the others.

Level 4: Fork subagent (experimental), inherits the parent's complete conversation context, reducing costs through prompt cache (caching prompts to reduce token overhead from redundant computation).

Our judgment: The core logic of this tiered design is not "the more isolation, the better," but "choose on demand." Read-only exploration is fine with coroutines, modifying code calls for worktree, and only long-running tasks require independent processes. This is engineering thinking, not technical showboating.

Industry view

Supporters believe this is a crucial step for AI coding tools evolving from "assistants" to "teams." Currently, most AI coding tools are still single-threaded dialogues—you ask a question, it answers. But real development scenarios require parallelism: running tests while modifying code while checking documentation. Without isolation mechanisms, multi-tasking in parallel means stepping on each other's toes.

But opposing voices are equally clear. An enterprise AI platform architect pointed out to us: The observability (Observability, i.e., the ability to monitor internal system states) of multi-agent systems deteriorates exponentially with the number of agents—"if one agent makes an error, you can reproduce it; if five agents interact and error, you can't even understand the logs." Furthermore, these mechanisms are still iterating rapidly; the source code contains numerous feature gates and experimental flags, making production environment stability doubtful.

Another overlooked risk is cost. With each additional layer of isolation, token consumption and compute resources go up. For enterprises, the math of "letting AI work in parallel" might not necessarily add up.

Impact on regular people

For enterprise IT: AI coding tools are acquiring "team collaboration" capabilities, but your code review processes and permission management might not have kept up. If an AI can simultaneously spawn three subtasks to modify three files, who reviews them?

For individual careers: Understanding "multi-agent collaboration" is becoming a soft skill in the AI era, much like understanding microservices architecture a decade ago. You don't need to write code, but you need to know why AI sometimes "fights with itself."

For the consumer market: Short-term impact is limited; this isolation mechanism currently only works in coding scenarios. But the design philosophy of tiered isolation—light isolation for light tasks, heavy isolation for heavy tasks—will very likely generalize to other AI application scenarios in the future.