Skip to content

Support model overrides for auto-review#23767

Open
won-openai wants to merge 6 commits into
mainfrom
auto-review-model
Open

Support model overrides for auto-review#23767
won-openai wants to merge 6 commits into
mainfrom
auto-review-model

Conversation

@won-openai
Copy link
Copy Markdown
Collaborator

Why

Some parent models need Guardian auto-review to run on the active parent model instead of the provider-preferred review model, while older /models payloads still need to deserialize cleanly when they do not include the new catalog field.

What changed

  • Added optional ModelInfo::auto_review_model_override metadata with omitted-field compatibility.
  • Updated Guardian model selection so Some(true) uses the parent turn model while missing or false values keep the existing preferred-review-model path and parent fallback.
  • Added focused Guardian coverage for override true and missing/false behavior, and updated ModelInfo constructors in local catalogs and fixtures for the new optional field.

Validation

  • cargo test -p codex-protocol
  • cargo test -p codex-core guardian_review_uses_ --lib
  • just fmt
  • just fix -p codex-core
  • git diff --check origin/main

A full cargo test -p codex-core run compiled and progressed through the suite, then aborted with a stack overflow in thread_manager::tests::resume_and_fork_do_not_restore_thread_environments_from_rollout.

@won-openai won-openai requested a review from a team as a code owner May 20, 2026 22:15
@won-openai
Copy link
Copy Markdown
Collaborator Author

@codex review

Copy link
Copy Markdown
Contributor

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 58f0201cf8

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread codex-rs/core/src/guardian/tests.rs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant