Reasoning vs Non-reasoning
On this page
Updated November 3, 2026 based on the xAI API reference and Reasoning guide:
max_completion_tokenscaps only the visible response, not reasoning;logprobsis ignored from Grok 4.20 onward; adjustable reasoning applies to grok-4.5, 4.6, and 4.7. Sources: Chat Completions · Reasoning.
Two Fundamentally Different Approaches
The Grok lineup offers two approaches to reasoning: grok-4.20 generation comes in two distinct variants—reasoning and non-reasoning—while grok-4.5, grok-4.6, and grok-4.7 unify them into adjustable reasoning via an effort parameter, which cannot be disabled. This choice isn’t cosmetic—it fundamentally changes the model’s behavior, capabilities, cost, and API constraints. Choosing the right variant for each task is a key skill.
How Reasoning Works
When you use a reasoning variant, the model engages in an internal thought process before producing its response. It breaks down the problem, explores different approaches, verifies its logic, and builds its response step by step.
At xAI, this reasoning is “encrypted” for Grok 4 models and higher: you cannot read the intermediate steps in plain text. However, you can:
- Retrieve the encrypted content via
include=["reasoning.encrypted_content"]to reinject it into subsequent requests - Check the reasoning token count in
usage.completion_tokens_details.reasoning_tokens
Reasoning consumes additional tokens, billed at the output rate. A reasoning request therefore costs more than an identical non-reasoning request; the gap depends on the task and effort, so measure it on your data.
Parameters Forbidden in Reasoning Mode
This is a common pitfall during migration. Reasoning variants do not support certain parameters that are common in non-reasoning mode:
| Parameter | Non-Reasoning | Reasoning |
|---|---|---|
| presencePenalty | Supported | Forbidden (error) |
| frequencyPenalty | Supported | Forbidden (error) |
| stop | Supported | Forbidden (error) |
| logprobs | Ignored from Grok 4.20 onward | Ignored |
| max_completion_tokens | Supported | Supported (visible response only) |
If you pass presencePenalty, frequencyPenalty, or stop to a reasoning variant, the API returns an error. Make sure to remove these parameters from your requests when switching to reasoning.
When to Use Reasoning
Reasoning adds clear value for certain task categories:
- Mathematics and formal logic — solving equations, proofs, optimization
- Complex code analysis — debugging with interdependencies, security audits
- Multi-step questions — problems that require building reasoning in multiple phases
- Nuanced decisions — evaluating pros and cons, in-depth comparative analysis
- Quantitative expertise — statistics, financial modeling, data analysis
When to Use Non-Reasoning
Non-reasoning is preferable when the task does not require deep reflection:
- Writing and summarization — the model doesn’t need to “think” to write
- Classification and tagging — quick content categorization
- Information extraction — structuring data from raw text
- Translation — the model knows how to translate without explicit reasoning
- Simple conversation — chatbots, FAQs, first-level support
- Content generation — emails, descriptions, marketing copy
Routing Strategy
In production, the optimal strategy is to dynamically route requests to the right variant:
- Analyze the request — does it involve calculation, analysis, or simple processing?
- Default routing to non-reasoning — it’s faster and cheaper
- Switch to reasoning when the request involves multi-step reasoning
- Monitor results — adjust routing criteria based on observed quality
This approach lets you benefit from reasoning power when needed, without paying the surcharge when it’s superfluous.
The Special Case of max_completion_tokens
According to the xAI API reference, max_completion_tokens applies only to the visible response: reasoning tokens and function calls do not count toward it, and the default value is 128,000 tokens. Set this cap based on the expected response length, and adjust reasoning via effort (reasoning_effort) on grok-4.5, 4.6, and 4.7.
Key Takeaways
- Reasoning variants add an internal thought phase before responding
- Reasoning is encrypted (not visible in plain text); however, grok-4.7 exposes a summary, viewable via streaming
presencePenalty,frequencyPenalty, andstopare forbidden in reasoning mode- Reasoning costs 2 to 5 times more than non-reasoning
- Use reasoning for math, logic, and multi-step problems
- Use non-reasoning for writing, classification, and extraction