mirror of
https://github.com/getcompanion-ai/co-mono.git
synced 2026-04-19 14:01:15 +00:00
fix: clean up Codex thinking level handling
- Remove per-thinking-level model variants (gpt-5.2-codex-high, etc.) - Remove thinkingLevels from Model type - Provider clamps reasoning effort internally - Omit reasoning field when thinking is off fixes #472
This commit is contained in:
parent
02b72b49d5
commit
0b9e3ada0c
11 changed files with 45 additions and 148 deletions
|
|
@ -1007,16 +1007,10 @@ export class AgentSession {
|
|||
|
||||
/**
|
||||
* Get available thinking levels for current model.
|
||||
* The provider will clamp to what the specific model supports internally.
|
||||
*/
|
||||
getAvailableThinkingLevels(): ThinkingLevel[] {
|
||||
if (!this.supportsThinking()) return ["off"];
|
||||
|
||||
const modelLevels = this.model?.thinkingLevels;
|
||||
if (modelLevels && modelLevels.length > 0) {
|
||||
const withOff: ThinkingLevel[] = ["off", ...modelLevels];
|
||||
return THINKING_LEVELS_WITH_XHIGH.filter((level) => withOff.includes(level));
|
||||
}
|
||||
|
||||
return this.supportsXhighThinking() ? THINKING_LEVELS_WITH_XHIGH : THINKING_LEVELS;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue