feat: accept xhigh effort for Anthropic (#24439)

This commit is contained in:
Danielle Maywood
2026-04-16 17:25:34 +01:00
committed by GitHub
parent 1092093e98
commit 15d8e4ff9f
8 changed files with 29 additions and 10 deletions
@@ -663,6 +663,7 @@ func ReasoningEffortFromChat(provider string, value *string) *string {
string(fantasyanthropic.EffortLow),
string(fantasyanthropic.EffortMedium),
string(fantasyanthropic.EffortHigh),
string(fantasyanthropic.EffortXHigh),
string(fantasyanthropic.EffortMax),
)
case fantasyopenrouter.Name:
@@ -208,6 +208,12 @@ func TestReasoningEffortFromChat(t *testing.T) {
input: ptr.Ref("max"),
want: ptr.Ref(string(fantasyanthropic.EffortMax)),
},
{
name: "AnthropicXHighEffort",
provider: "anthropic",
input: ptr.Ref("xhigh"),
want: ptr.Ref(string(fantasyanthropic.EffortXHigh)),
},
{
name: "OpenRouterEffort",
provider: "openrouter",