DeepSeek Thinking Mode Guide: Reasoning Effort and Routing

Answer in brief

For deepseek, use thinking for thinking mode, reasoning_effort for reasoning effort, stream for streaming, and max_tokens for the generated-output cap. The current official documentation lists model IDs; use only the IDs in the evidence table and recheck them before release. See the official documentation; verification date: 2026-08-20.

Key facts at a glance

Product / model Current ID or version Use case Evidence
deepseek Official source does not specify a selectable model ID Confirm the current product surface Official source

Failure modes and verification

Failure mode Verification action
Stale model or version reference Compare the model name and ID with the official source before release.
Unstructured or incomplete output Validate the response against the documented contract and a deterministic fixture.
Unverified factual claim Keep the claim qualified or remove the claim when the official source does not support it.

FAQ

How do thinking and reasoning_effort differ?

thinking.type selects thinking or non-thinking behavior. reasoning_effort requests the reasoning level used when thinking mode is active. See the Thinking Mode guide.

How should a client consume streaming thinking output?

Set stream to true, collect delta.reasoning_content separately from delta.content, and handle data: [DONE]. Use stream_options with include_usage when the final usage chunk is required. See the Chat Completions API.

What does max_tokens limit, and how is usage measured?

max_tokens limits generated completion tokens. Inspect usage, including prompt_tokens, completion_tokens, total_tokens, and, when returned, completion_tokens_details.reasoning_tokens. The exact numeric context limit is not specified in this entry. See Token & Token Usage.

What is the routing rule when no selectable model ID is published?

The current official documentation lists model IDs; use only the IDs in the evidence table and recheck them before release. Select the documented API surface and endpoint, do not invent a model value, and treat undocumented fallback or internal routing behavior as unspecified. Start with the official documentation.

What must be preserved across tool-call turns?

When a thinking-mode turn performs a tool call, preserve and return the generated reasoning_content in every subsequent request for that interaction, together with the relevant assistant message fields. See the Thinking Mode guide.

Sources and freshness

Extended guide

Direct answer

For the product deepseek, use thinking to switch thinking mode, reasoning_effort to request a reasoning level, stream to choose incremental delivery, and max_tokens to cap generated completion tokens. The current official documentation lists model IDs; use only the IDs in the evidence table and recheck them before release. Treat routing as a documented API-surface decision, such as an OpenAI-compatible or Anthropic-compatible endpoint, not as permission to invent a model name. The official DeepSeek documentation is the authority for the Thinking Mode guide, Chat Completions API, and Token & Token Usage guide. Verification date: 2026-08-20.

Control map

Concern Official control or field Operational meaning
Mode thinking.type = enabled or disabled Selects thinking or non-thinking behavior; the guide documents thinking as enabled by default.
Effort reasoning_effort Requests low, high, or max; the documented default is high.
Delivery stream With true, returns partial message deltas as data-only SSE and ends with data: [DONE].
Budget max_tokens Caps generated completion tokens; input plus generated tokens must fit the context length.
Accounting usage, completion_tokens_details.reasoning_tokens Reports prompt, completion, total, and reasoning-token fields when returned.
Routing base_url, request format, and response metadata The official source does not specify an internal routing algorithm, fallback policy, or selectable model ID for this product.

Numbered operating steps

  1. Choose the API surface. Use the OpenAI-compatible base URL https://api.deepseek.com, or use the Anthropic-compatible base URL https://api.deepseek.com/anthropic when that client format is required. Keep the message schema and parameter placement consistent with the selected format. Do not add a guessed model value; the current official documentation lists model IDs for this product.

  2. Set the mode explicitly when reproducibility matters. For OpenAI-format calls, send thinking with type set to enabled or disabled. When using the OpenAI SDK, the official guide places thinking inside extra_body; reasoning_effort remains a request parameter. Do not treat a higher effort as a larger max_tokens value: effort and output cap are separate controls.

  3. Choose delivery behavior. Set stream to true for incremental output. Accumulate delta.reasoning_content separately from delta.content, because thinking-mode reasoning and the final answer are distinct fields. If a complete response is easier to process, leave streaming disabled and read the final message fields. When stream_options includes include_usage, the API sends an additional usage chunk before data: [DONE]; its choices field is empty, while other streamed chunks can contain a null usage field.

  4. Set and inspect the budget. Use max_tokens as a ceiling for generated completion tokens. The API states that prompt tokens plus generated tokens are constrained by context length. After completion, inspect usage, including prompt_tokens, completion_tokens, total_tokens, and, when present, completion_tokens_details.reasoning_tokens. The token guide says actual counts depend on tokenization, so estimates are not usage records. The exact numeric context limit and default max_tokens value are not specified in this entry.

  5. Preserve conversation state. In ordinary thinking-mode turns without tool calls, prior reasoning_content does not need to be concatenated into the next context. If a thinking-mode turn performs a tool call, pass the generated reasoning_content back in every subsequent request for that interaction. Preserve content, reasoning_content, and tool_calls together. The official guide warns that omitting required reasoning state can cause the API to reject the request.

Streaming checklist

  • thinking.type and reasoning_effort match the intended behavior.
  • stream_options is used only with stream: true.
  • include_usage is enabled when the final streamed usage chunk is needed.
  • reasoning_content and content are handled separately.
  • finish_reason and usage are checked before declaring success.
  • Routing assumptions are limited to documented endpoints and returned metadata.
  • No invented model ID is stored in configuration.

For change control, record the verification date and recheck the official documentation before relying on any undocumented routing rule, context limit, default, or future model identifier.

Evidence refresh

The model and feature records below are rechecked against the linked official sources. If availability changes, update this table and the verification date together.

Product / model Current ID or version Use / caution Evidence
DeepSeek DeepSeek V4 Flash deepseek-v4-flash general-purpose chat and lower-latency workloads Official source
DeepSeek DeepSeek V4 Pro deepseek-v4-pro reasoning and higher-capability workloads Official source
DeepSeek DeepSeek V4 Flash Vision Experimental deepseek-v4-flash-vision-exp experimental image-input workloads Official source

Sources

Evidence and freshness

Last verified:

Primary sources

Verified model records

Explore More Tools