mirror of
https://github.com/getcompanion-ai/co-mono.git
synced 2026-04-19 22:01:38 +00:00
fix(ai): enable xhigh for anthropic opus 4.6
This commit is contained in:
parent
9494fa8d3f
commit
ee53b53689
4 changed files with 43 additions and 2 deletions
|
|
@ -47,10 +47,21 @@ export function calculateCost<TApi extends Api>(model: Model<TApi>, usage: Usage
|
|||
|
||||
/**
|
||||
* Check if a model supports xhigh thinking level.
|
||||
* Currently only certain OpenAI Codex models support this.
|
||||
*
|
||||
* Supported today:
|
||||
* - GPT-5.2 / GPT-5.3 model families
|
||||
* - Anthropic Messages API Opus 4.6 models (xhigh maps to adaptive effort "max")
|
||||
*/
|
||||
export function supportsXhigh<TApi extends Api>(model: Model<TApi>): boolean {
|
||||
return model.id.includes("gpt-5.2") || model.id.includes("gpt-5.3");
|
||||
if (model.id.includes("gpt-5.2") || model.id.includes("gpt-5.3")) {
|
||||
return true;
|
||||
}
|
||||
|
||||
if (model.api === "anthropic-messages") {
|
||||
return model.id.includes("opus-4-6") || model.id.includes("opus-4.6");
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue