Account for output-token reservation in context compaction thresholds
Cluster 43547 · agent. Data as of
1 open item. Fix merged in #50781 on 22 Jun 2026. Check it covers your case.
The short answer
- Known?
- Yes. 5 related items grouped here, 1 issue already closed.
- Fix event
- A fix was merged to main in PR #50781. Check it covers your case. No release data is tracked.
- Tracker
- The maintainers' tracker marks this
resolved, deciding PR #50781. That is separate from the fix event. - Still open
- 0 issues and 1 PR.
Most members concern the compaction/compression trigger not factoring in reserved output tokens, with one issue noting a custom-provider default max_tokens of 65536 reducing usable input budget. One member differs slightly, addressing output-cap retry convergence to a workable max_tokens, which is related but a distinct change.
Open issues0
Open PRs1
- PR#89777fix(agent): converge output-cap retry to a workable max_tokens on first attempt
Fixes on record
-
#50781 fix(compress): reserve output tokens in the compaction threshold (#23767, #43547)
files:
agent/agent_init.py,agent/context_compressor.py,tests/agent/test_context_compressor.py
2 PRs closed without merging
From the close comments: merged via another change 1 · superseded by another PR 1
Closed issues · 1
- Closed#43547Context compaction trigger ignores the output-token reservation (custom-provider default max_tokens=65536 halves the usable input budget)
How this cluster was grouped
-
Link evidence (
structural links throughout): every member is connected by structural evidence: shared changed files, or a closing/superseded reference. -
Pairwise link density
0.40: the share of item pairs that carry a link, counting a structural link in full and a relevance-only link at 0.36.1.00means every pair is linked.
Pick up a Lab task
Check whether a fix covers the open issues here, with your own agent. Bring back evidence for maintainers.
Open the LabAt a glance
- Subsystem
- agent
- Merged PRs
- #50781
- Closed issues
- 1
- Attempts
- 2 PRs closed without merging
- Fix link checked
- 22 Jun 2026