Skip to content

model and model_reasoning_effort are not set by global policy #24032

@mangiucugna

Description

@mangiucugna

What version of the Codex App are you using (From “About Codex” dialog)?

Version 26.519.31651 (3017)

What subscription do you have?

Enterprise

What platform is your computer?

Darwin 25.5.0 arm64 arm

What issue are you seeing?

When setting global policies via https://chatgpt.com/codex/cloud/settings/policies the model and model_reasoning_effort fields are ignored by the app (both cli and desktop) while feature flags are correctly applied

What steps can reproduce the bug?

Step 1.
Set a global policy in https://chatgpt.com/codex/cloud/settings/policies as follows:

# requirements.toml

model = "gpt-5.4"
model_reasoning_effort = "medium"

[features]
fast_mode = false

Step 2.
Close the app(s)

Step 3.
Edit ~/.codex/config.toml and remove the model and model_reasoning_effort fields

Step 4.
Open the app and notice that fast_mode is not available anymore but the model is set based on the last model and reasoning effort used in the last thread

I have asked Codex to debug the problem and this was the summary:

The cloud policy is being applied, but model / model_reasoning_effort are losing to the session/collaboration-mode state. fast_mode can still work because it is a feature/service-tier flag; it does not need to rewrite the session’s pinned model.

Evidence in this thread:

cloud policy cache: model = "gpt-5.4", model_reasoning_effort = "medium", fast_mode = false
active turn context: collaboration_mode.settings.model = "gpt-5.5", reasoning_effort = "xhigh"
sqlite thread row: model = "gpt-5.5", reasoning_effort = "xhigh"

So the likely bug is narrower: cloud-managed policy can affect feature flags, but model/reasoning are captured into collaboration_mode and/or persisted through SQLite, then reused. That aligns with Codex source where session startup builds CollaborationMode from resolved model and model_reasoning_effort (source), and with an existing issue about SQLite-persisted reasoning overriding config (#17436).

Disabling sqlite may mask it, but it is not a clean fix. The cleaner bug report is: “cloud policy disables fast_mode, but model and model_reasoning_effort from the same policy are ignored because Desktop/local session state persists collaboration_mode model/reasoning.”

What is the expected behavior?

codex should set the defaults of the group policies set by the administrator

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    appIssues related to the Codex desktop appbugSomething isn't workingconfigIssues involving config.toml, config keys, config merging, or config updatessessionIssues involving session (thread) management, resuming, forking, naming, archiving

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions