forked from openai/codex
## Why Replaying tool outputs under a different model can expand or shrink the history shown to the model if truncation uses the new model's budget. ## What changed Save the originating history truncation budget on function and custom tool outputs and reuse it during replay, preserving existing tool-specific overrides. Include the existing 20% serialization allowance once, before converting byte budgets to tokens. Rename the metadata field to `history_truncation_token_limit` while retaining `fallback_token_limit_override` as its serialized name for compatibility. ## Testing Add regression coverage for resume and fork with different model budgets, including custom tool outputs. Extend unit coverage for existing overrides and byte-budget conversion. GitOrigin-RevId: a62c8fd3e43198e2252b150fba72f022939c1070 |
History
|
|
|---|---|---|
| .. | ||
| absolute-path | ||
| approval-presets | ||
| audio | ||
| cache | ||
| cargo-bin | ||
| cli | ||
| elapsed | ||
| fuzzy-match | ||
| git-discovery | ||
| home-dir | ||
| image | ||
| json-to-toml | ||
| oss | ||
| output-truncation | ||
| path-uri | ||
| path-utils | ||
| plugins | ||
| pty | ||
| readiness | ||
| redacted-string | ||
| rustls-provider | ||
| sandbox-summary | ||
| sleep-inhibitor | ||
| stream-parser | ||
| string | ||
| template | ||