Skip to content

feat: route guardian review model selection through providers#22258

Merged
celia-oai merged 7 commits into
mainfrom
dev/cc/changes
May 13, 2026
Merged

feat: route guardian review model selection through providers#22258
celia-oai merged 7 commits into
mainfrom
dev/cc/changes

Conversation

@celia-oai
Copy link
Copy Markdown
Collaborator

@celia-oai celia-oai commented May 12, 2026

Why

Guardian review selection was hard-coded in core, which worked for the default OpenAI path but did not give provider implementations a way to choose backend-specific reviewer model IDs. That matters for Amazon Bedrock: guardian review should run through the Bedrock/Mantle provider using Bedrock's openai.gpt-5.4 model ID, instead of accidentally selecting a reviewer model that implies the OpenAI backend.

What Changed

  • Added provider-owned approval review model selection via ModelProvider::approval_review_model_selection.
  • Moved the existing default selection policy into the provider abstraction: prefer the requested reviewer model when it is available, otherwise fall back to the active turn model, preferring Low reasoning when supported.
  • Added an Amazon Bedrock override that pins guardian review to openai.gpt-5.4 with Low reasoning.

@celia-oai celia-oai changed the title tmp Route guardian review model selection through providers May 12, 2026
@celia-oai celia-oai marked this pull request as ready for review May 12, 2026 05:53
@celia-oai celia-oai requested a review from a team as a code owner May 12, 2026 05:54
@celia-oai celia-oai requested a review from pakrym-oai May 12, 2026 05:54
@celia-oai celia-oai changed the title Route guardian review model selection through providers feat: rout guardian review model selection through providers May 12, 2026
@celia-oai celia-oai changed the title feat: rout guardian review model selection through providers feat: route guardian review model selection through providers May 12, 2026
@celia-oai celia-oai requested a review from dylan-hurd-oai May 12, 2026 05:55
Comment thread codex-rs/model-provider/src/provider.rs Outdated
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: cedd67f3e7

ℹ️ 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/model-provider/src/amazon_bedrock/mod.rs Outdated
@celia-oai celia-oai requested a review from pakrym-oai May 12, 2026 18:21
@celia-oai
Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector
Copy link
Copy Markdown
Contributor

Codex Review: Didn't find any major issues. Already looking forward to the next diff.

ℹ️ 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".

@celia-oai celia-oai enabled auto-merge (squash) May 12, 2026 19:59
@celia-oai celia-oai merged commit e2eb7c3 into main May 13, 2026
27 checks passed
@celia-oai celia-oai deleted the dev/cc/changes branch May 13, 2026 01:55
@github-actions github-actions Bot locked and limited conversation to collaborators May 13, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants