Skip to content

Reasoning

Reasoning models think before they answer. You can ask for more or less of that thinking with a reasoning effort, read the reasoning the model chooses to show, and see how many tokens it spent. Reasoning tokens are output tokens: you pay for them.

Dialect Field
Chat Completions reasoning_effort
Responses reasoning.effort

Accepted values are none, minimal, low, medium and high. Any other value returns 400 invalid_request with param set to the field. If you send nothing, Belarel sets no effort and the model uses its provider’s default.

Terminal window
curl https://api.belarel.com/v1/chat/completions \
-H "Authorization: Bearer $BELAREL_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model": "openai/gpt-5", "reasoning_effort": "low",
"messages": [{"role": "user", "content": "Is 221 a prime number?"}]}'

Belarel never drops the setting silently, and never refuses the call because of it itself — though a model’s provider may refuse a value the model does not support. What the model receives depends on the model, and the reasoning_effort decision in belarel.policy.decisions tells you which case you are in:

Model What the model receives Decision
OpenAI models (openai/…) Your value, as is. The provider may refuse a value a given model does not support — some models refuse none or minimal. The call then fails with the provider’s error, not a warn. allow, with the value as detail
deepseek/deepseek-v4.1-flash, as served by Belarel Your value, as is. The model does not reason by default, so none changes nothing; minimal to high make it reason. allow, with the value as detail
ornith/ornith-1.5-397b, as served by Belarel Your value, as is. Belarel measured that none turns its reasoning off. allow, with the value as detail
z-ai/glm-5.3-flash, as served by Belarel low only — see below. allow for low; warn for every other value
Other models Belarel serves the same way as the three above Your value, as is. The model may refuse or ignore a value it does not support. allow, with the value as detail
Any other model from a vendor other than OpenAI Nothing: the model runs at its default. warn, not applied: …

Belarel measured how this model reasons at each value. Only low really reduces its reasoning. It has no none mode: sent as is, none makes it return an empty answer. minimal and medium change nothing, and high makes it reason less than its default. So Belarel sends:

  • low → low.
  • none → low, with a warn decision.
  • minimal, medium, high → no effort: the model reasons at its default, which is the deepest it offers, with a warn decision.
"policy": {
"decisions": [
{ "rule": "org_api_catalog", "verdict": "allow", "detail": "residency any" },
{ "rule": "reasoning_effort", "verdict": "warn", "detail": "\"none\" is not supported by this model — \"low\" applied" }
]
}

On a model whose vendor takes no effort setting, the warn reads not applied: vendor "anthropic" takes no effort setting, for example. In the sandbox, you get the same decision a live call would get.

Many models keep their reasoning private unless asked. Belarel asks OpenAI and Google models for a reasoning summary. Other models return reasoning only if their provider streams it by default. What you receive depends on the model.

Dialect Non-streamed Streamed
Chat Completions choices[0].message.reasoning_content (absent when there is none) delta.reasoning_content chunks
Responses a reasoning output item, with its text in summary[].text (type: "summary_text") response.reasoning_summary_text.delta events

On the Responses API, reasoning.summary is accepted, but it does not change what you receive: you cannot pick the summary’s level. include: ["reasoning.encrypted_content"] is accepted too, and has no effect.

You do not need to send reasoning back in the conversation. On the Responses API, reasoning items you include in input are accepted and skipped.

Reasoning tokens are counted inside the output tokens, and the details field tells you how many there were:

Dialect Output tokens Of which reasoning
Chat Completions usage.completion_tokens usage.completion_tokens_details.reasoning_tokens
Responses usage.output_tokens usage.output_tokens_details.reasoning_tokens

Reasoning tokens are billed as output: at the model’s output rate, unless the model has a separate reasoning rate. You pay for them even when the model shows no reasoning text. See Cost & usage.

A high effort can spend many tokens before the first word of the answer. Leave room in max_tokens (or max_output_tokens): the budget covers reasoning and answer together.

If the budget runs out, the answer is cut short and the response says so: finish_reason is length on Chat Completions, and on Responses status is incomplete with incomplete_details.reason: "max_output_tokens". A reasoning model can spend the whole budget thinking and return little or no text.

Every call has a time limit of a little under 300 seconds. A non-streamed answer sends nothing until it is complete, so a long reasoning can reach that limit, or a proxy’s shorter idle timeout, before the first byte, and end in 504 request_timeout. With stream: true, reasoning and text reach you as they are generated, and Belarel sends a keep-alive comment every 15 seconds so the connection stays open. Use streaming for reasoning models with medium or high effort. See Streaming.