Parallel subagents cause extreme token amplification and repeated compaction
Summary
On 2026-07-14 between 20:39 and 21:00 (Asia/Shanghai), Codex consumed an unexpectedly large amount of tokens while working on a music_score task.
The task was to analyze how newly added artist-statistics fields should be connected to the data lake and application code.
Observed behavior
A parent session spawned two parallel review subagents:
- Parent: 019f5688-69ed-7663-98ab-605632b5687c
- 019f60a3-c2f2-7961-b739-5ed05eadc087 — standards_review
- 019f60a3-e3ba-7202-afde-e8d88c3d89dc — spec_review
The two subagents started within seconds of each other and showed nearly identical behavior:
- Approximately 340M cumulative tokens per subagent within about two minutes
- More than 2,200 token-count events per subagent
- 10 context compactions per subagent
- 486 patch-apply events per subagent
- Repeated context processing despite the task being a bounded review
The aggregate cumulative token count across active sessions reached approximately 1.4B.
Environment
- Codex Desktop on macOS
- Subagent CLI: 0.144.2
- Parent session CLI: 0.144.0-alpha.4
- OpenAI model provider
- Reported subagent context window: 353,400 tokens
Expected behavior
Parallel subagents should consume tokens roughly in proportion to the actual work performed. Context compaction and patch application should not enter a replay or retry loop.
Actual behavior
Two parallel subagents appear to have repeatedly reprocessed or replayed the same large context. Their event counts and token growth were almost identical, suggesting duplicated context processing or a compaction/retry loop.
Related issues
- #33171 — remote-compaction failure in long-running tasks and subagents
- #33024 — large-context tasks becoming silent at model response boundaries
- #9748 — concurrent subagents unexpectedly draining usage quota
- #16812 — compaction regression causing token usage amplification
Questions
- Is parent context duplicated when multiple review subagents are spawned?
- Why are thousands of token-count events emitted within minutes?
- Can repeated compaction or patch application enter a replay loop?
- Is this related to the mixed CLI versions 0.144.0-alpha.4 and 0.144.2?
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗