Codex worktrees run agents in parallel: one Sume queue

Codex CLI 0.162.0 adds managed worktree tools. Parallel agents in worktrees still share one Sume workspace: plan concurrency, queue and 429 queue_full apply.

4 min readSume
All posts

Codex CLI 0.162.0 (Oct 8) adds managed Git worktree tools, so several agents can work in separate checkouts at once. Sume does not see worktrees. All of them share the workspace behind one API key, one processing-concurrency limit and one queue, so five parallel agents on a Pro plan share four render slots.

What does Sume limit?

Generation concurrency is plan-only, and top-ups do not raise it. Queue capacity defaults to the larger of 3 and five times concurrency.

Sume plan limits, from the generation admission docs
PlanProcessing concurrencyQueue capacityAccepted jobs
Free156
Pro42024
Startup84048
Scale20100120

What happens when agents pile up?

Extra valid jobs wait as queued. When the queue is full, a paid submit fails with 429 queue_full. Wait for jobs to finish or cancel queued ones, then retry with the same idempotency key. 402 insufficient_credits is separate: the wallet is short.

How to run parallel Codex agents safely

Treat the Sume workspace as shared state:

  • Give each worktree agent its own idempotency_key namespace, such as the task id.
  • Call generation_admission_preview before a burst and read queue_capacity_remaining.
  • Use wave_size_hint only to size a submission wave. The docs say it is not a concurrency limit.
  • Use one jobs_wait call with up to 20 ids rather than many single waits.

What about the cost?

Each agent still needs its own max_spend_usd. The docs describe no shared cap across sessions, so divide your budget across the agents yourself. See Generation admission.

Sources

Related posts

More in Agents

All Agents posts

Written by Sume