Add a per-thread context-window profile selector
What variant of Codex are you using?
Codex Desktop and Codex CLI with a ChatGPT subscription.
What feature would you like to see?
Please add a per-thread context-window profile selector so each Codex session can choose its own context/usage tradeoff without changing the global configuration.
For example, when creating a thread—and later from that thread's settings—users could select:
- Efficient: smaller active context, earlier compaction, lower usage
- Default: OpenAI's recommended profile
- Extended: larger active context, later compaction, with a clear usage warning
The exact token counts may remain model- and plan-dependent. The important requirement is that the choice is scoped to one thread rather than applied globally.
Why per-thread scope matters
Different tasks have very different context requirements:
- A small coding fix benefits from an efficient profile.
- A long research, debugging, or architecture task may need the extended profile.
- Running several threads at once should not force every thread to use the most expensive context setting.
- Changing a global setting should not silently alter the context behavior of existing threads.
A global-only setting makes users choose between wasting usage on small tasks and losing continuity on long tasks.
Requested behavior
- Add a context profile control to the new-thread UI.
- Allow the profile to be changed from an existing thread's settings.
- Persist the selected profile in thread/session metadata.
- Show the effective token window and auto-compaction threshold before confirmation.
- Warn that a larger profile may consume subscription usage faster.
- Keep existing threads pinned to their selected profile unless the user changes it.
- Expose an equivalent CLI option, for example:
``bash``
codex --context-profile efficient
codex --context-profile default
codex --context-profile extended
- If a selected profile is unavailable for the current model or plan, explain why and fall back explicitly rather than silently.
Expected result
Users can optimize context and usage per task while preserving predictable behavior across concurrent and existing sessions.
Related issues
- #34619 requests restoration of GPT-5.6 Sol's 372k profile or an opt-in setting. This request is broader and specifically asks for a general, persistent per-thread selector across supported models and profiles.
- #32803 and #32806 discuss context-profile reductions and their impact.
1 Comment
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action