Codex CLI /agents and worktrees: a review load your team can hold

By Rogier Muller09.29.26
Codex CLI /agents and worktrees: a review load your team can hold

This research library uses AI-assisted source research and drafting. Linked sources support product claims; analysis and proposed exercises are our interpretation. Unless an article documents a test and its results, do not read it as a hands-on review or an independently verified benchmark.

The Codex CLI /agents view and default worktrees make parallel agent work cheap to start. OpenAI announced the refreshed CLI at DevDay on 29 September 2026, with an /agents view to delegate and track multiple tasks and improved worktree workflows, for all plans. Starting five sessions takes a minute. Reviewing five diffs does not, and that cost lands on someone else.

This page is for engineering leads deciding how much parallelism a team can absorb. The tool facts come from the Codex CLI docs and the Codex changelog.

What do the Codex CLI /agents view and worktrees change?

Three capabilities matter to a team.

  • The agents view, called the agent command center in the release notes, lists sessions with status filters, token and usage estimates, and actions to hide, archive, or delete tasks.
  • Worktree sessions can be started from that view, and worktree support is on by default since release 0.156.0. Each worktree is a separate checkout that shares Git metadata, and a branch can be checked out in only one place at a time.
  • Subagents let one session spawn others. The /agent command switches between their threads, and approval requests from an inactive thread can appear while someone is looking at the main one.

The docs also state that subagent workflows consume more tokens than comparable single-agent runs. Parallel work spends usage faster as well as review time.

Why does parallel agent work move the bottleneck to review?

Worktrees solve file conflicts. They do not solve attention. Each session hands over a diff, a list of commands, and claims about tests, and a person still has to check them against the requirement.

Picture one engineer who starts four sessions before lunch. The reviewer inherits four context switches after lunch, each with its own branch and its own story about what was tested. None of that shows up in the agents view as a cost.

Our recommendation: treat reviewer capacity as the constraint and size parallelism to it, rather than to what the tool allows.

A team policy for parallel sessions

Decision Proposed default Reason
Open sessions per person A small number agreed by the team, often two or three Each session needs a reviewer who still has the context
Subagent fan-out A cap in the project's .codex/config.toml One prompt should not spawn more threads than anyone will read
Ownership One named person per session, with the session renamed via /rename The agents view shows many tasks; names show who answers for them
Output One branch and one pull request per worktree session Reviewers see one purpose per change
Exploration Custom agents with sandbox_mode = "read-only" Investigation can fan out while edits stay in one place
Check before human review /review against the base branch Obvious issues are fixed before a reviewer spends time
Cleanup Archive finished tasks and delete clean managed worktrees Stale sessions hide the ones that need attention

The two config files are short. The key names below come from the subagents guide, and the cap value is your team's choice:

# .codex/config.toml
[agents]
max_concurrent_threads_per_session = 3
# .codex/agents/pr-explorer.toml
name = "pr_explorer"
description = "Read-only codebase explorer for gathering evidence before changes are proposed."
sandbox_mode = "read-only"
developer_instructions = """
Stay in exploration mode.
Trace the real execution path, cite files and symbols, and avoid proposing fixes unless the parent agent asks for them.
"""

Every custom agent file must define name, description, and developer_instructions. Commit both to the repository so every engineer gets the same limits. Personal agents live in ~/.codex/agents/ and are outside that shared review.

Which approval points should the team agree?

Approvals from background threads come first. The CLI surfaces them in an overlay while you look at another thread, so the person approving has to read which thread is asking and what it wants to run.

Permission modes for unattended work come second. The CLI reference recommends --sandbox workspace-write for unattended local work that stays inside the workspace. It warns against --dangerously-bypass-approvals-and-sandbox unless you are inside a dedicated sandbox VM.

Voice needs a line in the policy too. It is useful to start and steer tasks, but approvals and diffs should be read on screen. Agree that nobody approves a command they only heard summarized.

Worktree deletion is the last point. The CLI asks for confirmation before it deletes clean managed worktrees. Anything with uncommitted work belongs to its session owner, who decides whether to keep it.

Rollout checklist

  1. Agree the open-session limit per engineer and name a reviewer for each repository.
  2. Commit .codex/config.toml with a concurrency cap and one read-only explorer agent.
  3. Add one line to AGENTS.md: every session ends with a summary of changed files, commands run, and test results.
  4. Run for one sprint with the limit, one branch per session, and a /review pass before every pull request.
  5. Look at the measures below, then raise or lower the limit and record why.

What should you measure?

Record three things per pull request: reviewer active time, rework after the first review, and whether the change matched the agreed task. Also count sessions started, sessions merged, and sessions abandoned each week. A rising abandoned count suggests people start more work than the team can review.

Use the definitions in our measurement guide, and hand reviewers the evidence listed in From AI-generated code to a reviewable change. The free methodology guide explains Delegate, Review, Own, and AI training for teams can practise this policy on your own repositories.

Set the session limit at your next team meeting and commit the config file the same day.

Further reading