Subagents are agents the main agent hands a task to. Each answer says how to start one, what it can see and change, and how you keep track of it.
Starting one
| Question | Codex CLIchecked at 0.162.1 | Claude Codechecked at 2.1.299 | Cursor Agentchecked at 2026.10.12-d47ca18 | OpenCodechecked at 2.0.28 | pichecked at 1.2.0 |
|---|---|---|---|---|---|
| Is there one, and how does it start | Yes, and they are on by default ( Set | Yes. Claude delegates on its own when a task matches a subagent's Add a phrase like "use proactively" to a description to encourage automatic delegation. Source | Yes. The agent launches subagents on its own through its Task tool when a task is complex, guided by each subagent's Subagents have been available in the CLI (interactive and headless | Yes. The primary agent launches one with the | Not supported pi deliberately ships without subagents: its README says to build them yourself or install a package. The repo includes an example Third-party packages in the pi package gallery (https://pi.dev/packages) add subagents too, for example |
| Built-in subagents | Three built-in agent types ship: |
Explore and Plan skip your CLAUDE.md files and git status, and can't be resumed. Turn off Explore and Plan with | Two built-ins are documented: Explore, which searches and analyzes the codebase using a faster model so it can run many searches in parallel, and Browser, which drives a browser through MCP tools and filters noisy DOM snapshots and screenshots down to what matters. The agent uses them automatically. In the CLI you can set Explore's model to default, inherit, a specific model, or disabled from Hook payloads also report general Task subagent types such as |
| Not supported pi has no built-in subagent types. The example extension comes with four sample agent files you can install: |
| Define your own | Add one standalone TOML file per agent under Malformed files are skipped with a startup warning rather than failing the session. Source | Write a Markdown file with YAML frontmatter ( Both folders are scanned recursively, and the nested A plugin agent is addressed by its scoped name, such as | Create a Markdown file with YAML frontmatter followed by the prompt. Project subagents go in Plugins installed with In CLI 2026.10.12, project subagents load from | Add a Markdown file to New custom agents default to | Not supported Core pi has no agent definition format. With the example extension, an agent is a Markdown file with YAML frontmatter in Agent files are re-read on every call, so you can edit them mid-session. Source |
| What a definition can set | Partly Besides There is no per-agent tool allowlist or memory setting; tools can only be removed through the | Frontmatter can set Plugin agents ignore Claude Code silently ignores a misspelled field; | Partly Documented frontmatter fields are CLI 2026.10.12 also accepts Cursor may substitute another model if a team admin blocks the configured one, your plan lacks it, or a legacy plan needs Max Mode. Source |
V1 fields | Not supported In the example extension, a definition sets only |
While it runs
| Question | Codex CLIchecked at 0.162.1 | Claude Codechecked at 2.1.299 | Cursor Agentchecked at 2026.10.12-d47ca18 | OpenCodechecked at 2.0.28 | pichecked at 1.2.0 |
|---|---|---|---|---|---|
| What it sees, and what comes back | By default a subagent starts fresh, with only the task message the main agent writes plus the usual project instructions and skills. If the main agent sets 0.162.0 removed partial-history forks: a fork now copies either all of the history or none of it. Source | A subagent doesn't see your conversation. It starts with its own system prompt, the task message Claude writes, your CLAUDE.md files, a git status snapshot and any skills listed in Explore, Plan and agents with Your output style and auto memory don't reach a non-fork subagent. Source | A subagent starts with a clean context and does not see your conversation history; the parent must put everything it needs into the task prompt. It inherits the parent's tools, including MCP tools, and in the CLI also your credentials, rules and approval policy. Only its final message comes back to the parent, or an error status if it fails, along with an agent ID you can use to resume it with its context intact. Source | A new child session starts with fresh context, containing only the prompt the main agent writes plus a line saying it is a subagent. When it finishes, the text of its last reply returns to the main agent inside | Not supported In the example extension, each subagent is a separate |
| Several at once | Yes. Several subagents can run at once, capped by The docs recommend running read-heavy work in parallel and warn that parallel edits can conflict. Source | Yes. Claude can run several subagents at once, for example when you ask it to research modules in parallel. By default a session allows 20 at a time, and the next spawn fails with Every result comes back into the main context, so many detailed reports can use a lot of it. Source | Yes. The agent sends several Task tool calls in one message and they run at the same time; you can prompt for it, for example "Review the API changes and update the documentation in parallel". No concurrency cap is documented, but each subagent uses its own tokens, so five parallel subagents cost roughly five times as much. Parallel subagents share your checkout by default and can overwrite each other's edits unless you ask for isolation. Source | Yes. The main agent can issue several | Not supported Core pi cannot run subagents at all. The example extension's parallel mode ( |
| Keep working while it runs | Partly
Separate background chats (desktop Worktree mode, | Yes. In interactive sessions subagents run in the background by default while you keep talking, and you can press Background subagents get a smaller set of built-in tools than foreground ones. With | Yes. A background subagent returns control immediately and keeps working while you continue; set | Yes, without any flag. | Not supported No. The example Gallery packages such as |
| Your checkout or its own copy | Not supported Subagents work directly in the parent session's checkout; they get no worktree or copy of their own, so there is nothing to merge. Their edits land immediately, and parallel writers can collide. The built-in | By default a subagent works directly in your checkout, starting in the main conversation's working directory. With A worktree subagent can't edit files in your main checkout or point git at it. Kept worktrees are swept after | Partly By default, subagents edit the parent's checkout directly, so parallel subagents can overwrite each other. If you ask for isolation ("... each in its own environment"), each subagent gets its own branch, either in a Git worktree on the same machine or in a cloud VM with a fresh clone, and its changes stay on that branch until the parent merges them. In the CLI you can also isolate the whole session with In CLI 2026.10.12, per-subagent isolation sits behind a feature flag that is off by default, so it may not be available in every CLI session. Source | Subagents run in the parent session's directory and edit your checkout directly; there is no automatic per-subagent worktree or sandbox, so there is nothing to merge. Worktrees exist as separate session tools ( | Not supported There is no isolation. The example extension runs each subagent process directly in the parent's working directory, or in a per-task |
| Its permissions | Subagents inherit the parent turn's current sandbox and approval settings, including changes made with A definition can only narrow capabilities, e.g. | A subagent inherits your permission rules and permission mode. A definition can set Permission prompts from background subagents appear in your main session, labeled with the subagent's name. Press Esc to deny one tool call without stopping the subagent. Use | Partly Subagents run under the parent session's approval policy, sandbox setting and Run Everything ( | Launching a subagent is gated by the parent's | Not supported pi has no approval prompts or sandbox. Tools run with your OS user's permissions, and subagent processes are no different. A definition can only narrow the tool list ( For real containment, run all of pi inside a container or sandbox (see docs/containerization.md), or add the example |
| Subagents of subagents | Partly Nesting is controlled by
| Yes. Subagents can spawn their own subagents, up to three layers below the main conversation by default. At the limit the A fork can't spawn another fork, and agent-team teammates can't spawn teammates. Source | Partly Yes, one level deep. Since Cursor 2.5, the main agent and its direct subagents can launch subagents, but a subagent started by another subagent cannot launch any more. Nested launches also need Task tool access in the current mode, and hooks or tool policies can block them. Source | Only one level by default: The V1 top-level | Not supported The example extension has no depth limit or recursion guard. Each subagent is a full |
Watching and handing off
| Question | Codex CLIchecked at 0.162.1 | Claude Codechecked at 2.1.299 | Cursor Agentchecked at 2026.10.12-d47ca18 | OpenCodechecked at 2.0.28 | pichecked at 1.2.0 |
|---|---|---|---|---|---|
| Watch, steer or stop one | In the CLI, type
| Running subagents appear in a panel below the prompt. Use Subagent transcripts are saved to
| In the interactive CLI, each running subagent appears as a live row showing its status, streamed activity and token count, and running subagents also appear in the jobs list. Press There is no documented way to message a running subagent directly; steering with Enter goes to the main agent's active turn. ACP clients that advertise the | In the terminal client, | Not supported With the example extension, the tool row streams each subagent's live status, recent tool calls and token/cost usage.
|
| Hand work to a cloud agent | Partly Subagents always run locally; the main agent cannot spawn a cloud subagent. You can hand work to Codex Cloud yourself with
| Yes, as a separate cloud session rather than a subagent. The CLI can't push an existing terminal session to the cloud; the Desktop app can, from its Open in menu. Requires a claude.ai account; cloud sessions aren't available through Bedrock, Google Cloud or Foundry.
| Yes. In the CLI, start any message with Cloud subagents use your team's MCP configuration at cursor.com/agents, not your local servers.
| Not supported No. Subagents run as local child sessions on the same OpenCode server; there is no built-in cloud or remote handoff for delegated work. Source | Not supported pi has no cloud or remote agent handoff. The closest options are running the whole |