Effort is a hint about how much reasoning the model should spend. Providers
interpret it differently and some ignore it entirely.
Reference#
type Effort string
| Constant | Value |
|---|---|
EffortLow | low |
EffortMedium | medium |
EffortHigh | high |
EffortMax | max |
They are listed in increasing order. Set one on
Thinking.Effort.
Caveats
- It is a hint. Adapters map it onto whatever the provider offers and ignore it where there is no equivalent.
- Anthropic ignores it entirely — its adaptive thinking config has no effort or budget field.
- OpenAI does not define
max. skyl sends it literally, so expect a 400. - Gemini maps each level onto a concrete token budget: 1024, 8192, 16384, 24576.
- skyl does not validate the value, so an unknown effort string reaches the provider.
Usage#
Setting a level
req.Thinking = &skyl.Thinking{Enabled: true, Effort: skyl.EffortMedium}req.Thinking = &skyl.Thinking{Enabled: true, Effort: skyl.EffortMedium}Avoiding the undefined max on OpenAI
effort := skyl.EffortMax
if provider == "openai" || provider == "openai-compatible" {
effort = skyl.EffortHigh // "max" is not a value OpenAI defines
}
req.Thinking = &skyl.Thinking{Enabled: true, Effort: effort}effort := skyl.EffortMax
if provider == "openai" || provider == "openai-compatible" {
effort = skyl.EffortHigh // "max" is not a value OpenAI defines
}
req.Thinking = &skyl.Thinking{Enabled: true, Effort: effort}Troubleshooting#
A 400 mentioning reasoning_effort
You sent EffortMax to OpenAI. It is not one of their defined values; use
EffortHigh.
Changing the effort changed nothing
On Anthropic it is dropped. Reach the budget with
ProviderOptions: {"thinking.budget_tokens": N}, which works only there.