Skip to content

Use current model for review#9179

Merged
pakrym-oai merged 2 commits intomainfrom
pakrym/use-main-model-for-review
Jan 14, 2026
Merged

Use current model for review#9179
pakrym-oai merged 2 commits intomainfrom
pakrym/use-main-model-for-review

Conversation

@pakrym-oai
Copy link
Collaborator

@pakrym-oai pakrym-oai commented Jan 14, 2026

Instead of having a hard-coded default review model, use the current model for running /review unless one is specified in the config.

Also inherit current reasoning effort

Use review_model from config only when present, otherwise fall back to the session/client model for review threads and sub‑agents. Fix otel manager model wiring and update tests to cover both custom and unset review_model cases.
@pakrym-oai pakrym-oai changed the title Use main model for review Use current model for review Jan 14, 2026

let mut config = self.config.as_ref().clone();
config.model = Some(self.config.review_model.clone());
if let Some(review_model) = &config.review_model {
Copy link
Collaborator

Choose a reason for hiding this comment

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

is there a difference between self.config and config?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

config = self.config.as_ref().clone(); ?

Copy link
Collaborator

Choose a reason for hiding this comment

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

yeah was just wondering why are we using self a line above it.


// Build per‑turn client with the requested model/family.
let mut per_turn_config = (*config).clone();
per_turn_config.model_reasoning_effort = Some(ReasoningEffortConfig::Low);
Copy link
Collaborator

Choose a reason for hiding this comment

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

unrelated change?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Related, I'd like to use the current reasoning effort as well.

@etraut-openai
Copy link
Collaborator

Please make sure that any behavior changes here are also reflected in the VSCE, which also implements a /review feature.

@pakrym-oai pakrym-oai merged commit 92472e7 into main Jan 14, 2026
32 checks passed
@pakrym-oai pakrym-oai deleted the pakrym/use-main-model-for-review branch January 14, 2026 16:59
@github-actions github-actions bot locked and limited conversation to collaborators Jan 14, 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.

3 participants