Repository navigation
Recover a provider switch when the destination has insufficient context allowance #17068
RoySalisbury
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Problem or use case
A long-running coordinator was asked to switch from Claude to Codex to reduce pressure on the current provider's token allowance. The requested handoff stopped with:
Three consecutive destination runs failed before the agent could do any work or request recovery. The user had to intervene and return to the source provider; the coordinator subsequently created fresh Codex threads from concise handoff files for several worker lanes.
This can affect each worker switched in place as well as the coordinator, leaving an unattended workflow dependent on manual intervention.
Observed evidence
0.0.46-nightly.20261006.2735, Linux x64.claudeAgent,claude-opus-5-5; destination:codex,gpt-6.1-sol.199405used tokens with a258400maximum.The current handoff documentation already describes this refusal and advises compaction or a larger-context model. I am requesting a recovery workflow, rather than treating the documented refusal itself as a defect.
The inspected upstream handoff budget calculation reserves a quarter of the window, or at least 16000 tokens, in addition to existing context and the current request. With the recorded destination usage, that calculation leaves no handoff allowance even before the current request. This explains the refusal; the inspected upstream commit has not been verified as the installed build's commit.
Requested behavior
Provide a bounded, server-owned way to recover when an explicitly requested provider handoff is rejected for insufficient context allowance. Recovery cannot depend solely on the destination agent responding, because its turn has already failed.
A smallest useful version could:
A first version can expose one clear recovery action and a structured outcome when recovery is unavailable; fully automatic fallback across arbitrary providers is not required.
Related work
I searched existing issues, Ideas discussions, and the documented handoff workflow. The related proposals cover parts of this need; I did not find a complete proposal for recovery from this specific refusal.
All reactions