Repository navigation
Description
Problem
A thread that delegates a task is woken with the task's result when the task ends, and the instructions tell it not to poll. In practice orchestrating threads still check on their children repeatedly while they wait. Every check is a model request that re-reads the orchestrator's whole context, so the cost grows with the size of the orchestrator's conversation, which is usually the largest one in the family.
Measurements
One environment, 15 days of ordinary use (Nov 6 to Nov 20 PT), counting task_status, t3_thread_read, t3_thread_wait and t3_thread_list calls made by a thread that had delegated tasks:
| Orchestrator model | Checks per delegated task | Longest run of checks in one thread |
|---|---|---|
| GPT-6.1 Sol | 8.0 | 909 |
| GPT-6.2 Sol | 2.4 | 272 |
| Opus 5.5 | 1.5 | 110 |
| All | 4.28 (8,730 checks for 2,041 tasks) |
Limits of these numbers:
- They include legitimate reads, such as reading a child once after its result arrives. The per-task averages are an upper bound on waste; the long runs are not explained by legitimate reads.
- Only about 50 checks happened while the child had a resumable Action run open, so the polling is not specific to Action waits. It also happens while children wait on pull requests.
- A Codex agent polling its own background command is not recorded as a timeline item, so self-polling is not in this count.
Questions to settle
- What do orchestrators want to know when they check? Whether the child is alive, how far it is, or whether it is stuck. The answer decides whether the fix is guidance, a tool, or both.
- One call for all children. A single MCP call returning the state of every task and thread the caller owns (running, waiting on what, since when, last activity) would replace N reads with one small result. It may also make polling cheaper to do and so more frequent.
- Answer in the tool result.
task_statusandt3_thread_readon a running owned child could say that the caller will be woken when it ends, at the moment the agent is deciding whether to check again. - Stuck children. Nothing reports a child that has stopped making progress, which is the legitimate reason to check. A server-side signal for that would remove the reason.
- Fire-and-forget versus bottleneck children. An orchestrator that can do other work should not block on a child; one whose next step needs the result should end its turn. Guidance does not distinguish the two today.
Scope
This is separate from the Codex background-wait work in https://redirect.github.com/lastobelus/lastCode/pull/791 and does not gate it. Evidence gathered there (polling counts per model in the eval) should be added here.
Activity