mirror of
https://github.com/openai/codex.git
synced 2026-11-23 23:10:47 +00:00
## Why Remote compaction v2 dropped the turn's final-answer schema, so its request could lose the cached prompt prefix shared with sampling even when both requests used the same cache key. ## What changed Carry the turn's JSON schema and sampling strictness into compaction requests, including the non-strict guardian verdict format. The Responses API still generates compaction summaries independently of that schema. ## Testing - Check that automatic compaction on Bedrock and GCP uses the same `text.format` and `prompt_cache_key` as sampling, with and without a schema. - Check that guardian reviews retain their verdict format across compaction and retries, and that an approval after compaction allows the command to run. GitOrigin-RevId: 2cb5df2539358e3d74f1dce51baac2806b6219eb