Skip to main content
Reasoning models “think” before they answer. Called through compatible mode, their output carries a few extras over regular models. This page covers three things: how to get the thinking, how to handle multi-turn, and how to make structured output reliable.
This page focuses on /v1/chat/completions compatible mode. For Claude’s native thinking blocks (the thinking field on /v1/messages), see the Claude Effort & Thinking Guide. For Gemini’s native thinking_level and thought_signature, see Gemini Native Calls.

Overview

In compatible mode, reasoning models fall into three groups by “does it emit thinking text”:
No matter the type, the answer is always in content. If you read only content, every reasoning model integrates just like a regular model; read reasoning_content only when you want to surface the thinking.

Thinking content: reasoning_content

Models that emit thinking text put the chain of thought in reasoning_content, parallel to content. Non-streamingmessage carries both:
Streaming — a run of delta.reasoning_content is pushed first; delta.content starts only once thinking is done. Be sure to render the two separately (collapse the thinking, stream the answer), or the UI will flash a wall of thoughts first:
The streamed “mutual exclusivity” of reasoning vs content differs across three models — tolerate all three:
  • grok-4.3: during thinking only the reasoning_content key is present; during the answer only content (the other key simply doesn’t appear).
  • qwen3.6-plus: both keys are present; the inactive one is null.
  • glm-5.1: during thinking content is "" (empty string) while reasoning_content has a value.
Uniform approach: read with a truthiness check (if reasoning: / if content:) to skip all three empty states — missing, null, and "".
Reasoning tokens can dwarf the answer. In testing, a trivial “1+1” question produced hundreds of reasoning_tokens on grok-4.3 against just a few answer tokens. Thinking is billed as output tokens, so evaluate whether to enable / display it for latency- and cost-sensitive use cases.

Thought signatures and multi-turn

A “thought signature” is a Gemini native concept: in native multimodal / function calling, the model returns an encrypted thought_signature that must be passed back across turns to preserve reasoning continuity (see Gemini Native Calls and Gemini Function Calling). In /v1/chat/completions compatible mode, reasoning models are stateless:
  • Multi-turn only requires putting the previous assistant turn’s content into the message history;
  • There is no need to pass back reasoning_content, and no signature field appears in the response;
  • In testing, gemini-3.1-flash-lite and grok-4.3 both kept multi-turn context correctly while only content was passed back.
If you need to preserve Gemini’s thought signatures across turns, or use Claude’s native thinking blocks in multi-turn, switch to the corresponding native endpoint rather than compatible mode.

Structured output

Use response_format to make the model emit JSON only. Two types:

Per-model support (tested)

json_schema support varies widely — this is the biggest pitfall in structured output:

Getting JSON reliably across models

Don’t assume json_schema works on every model. For cross-model reliability, combine:
  1. Prefer json_object — broader compatibility than json_schema;
  2. In the prompt, explicitly say “return JSON only” and include the word “json” (required by qwen, more reliable for others too);
  3. Parse defensively: strip ```json code fences, strip a <think>…</think> prefix, then json.loads, and degrade gracefully on failure.