Back to Signal Feed
CodeTracked since May 19, 2026

Strip DeepSeek reasoning fields when tool calls are present

This PR fixes a DeepSeek-only compatibility regression by auto-detecting models routed to `deepseek-reasoner` and removing `reasoning_effort`/`reasoning` from requests whenever `tools` are included, which prevents reasoner endpoints from rejecting tool-call traffic.

deepseek-v4-flashdeepseek-reasonerapi.deepseek.comreasoning_effort

What Happened

  • This PR fixes a DeepSeek-only compatibility regression by auto-detecting models routed to `deepseek-reasoner` and removing `reasoning_effort`/`reasoning` from requests whenever `tools` are included, which prevents reasoner endpoints from rejecting tool-call traffic.
  • This PR fixes a DeepSeek-only compatibility regression by auto-detecting models routed to `deepseek-reasoner` and removing `reasoning_effort`/`reasoning` from requests whenever `tools` are included, which prevents reasoner endpoints from rejecting tool-call traffic.
  • 1 evidence item attached for review.

What is Different

Before

Scattered source updates, isolated context, and manual follow-up across multiple feeds.

Now

Adds a new `OpenAICompat` flag (`disableReasoningWhenToolsPresent`) and DeepSeek auto-detection (`*-flash`, `deepseek-r1`, `deepseek-reasoner` on `api.deepseek.com`) so build-time parameter assembly drops `reasoning_effort` and `reasoning` whenever `tools` are present, with tests covering detection and request-body behavior.

Why Track This

Why It Matters

Developers using DeepSeek tool-calling workflows (for example subagents) can avoid immediate 400 failures on tool invocations, so assistant runs no longer stop at the first step for affected Flash/reasoner models. The change is implemented via compat-mode detection in `openai-completions-compat` and parameter stripping in `buildParams`; in the next cycle, watch for new DeepSeek model naming/routing changes and verify custom compat overrides do not unintentionally remove reasoning from non-targeted models.

Impact

Developers using DeepSeek tool-calling workflows (for example subagents) can avoid immediate 400 failures on tool invocations, so assistant runs no longer stop at the first step for affected Flash/reasoner models. The change is implemented via compat-mode detection in `openai-completions-compat` and parameter stripping in `buildParams`; in the next cycle, watch for new DeepSeek model naming/routing changes and verify custom compat overrides do not unintentionally remove reasoning from non-targeted models.

What To Watch Next

  • Watch whether deepseek-v4-flash becomes a repeated pattern.
  • Track follow-up changes around Tool Calling.
  • Compare future signals against this evidence trail.
  • Re-check risk flags: deepseek_model_routing_pattern_changes, compat_flag_override_side_effects.
Open Topic TimelineOpen Technical EventOpen Original Sourcedeepseek_model_routing_pattern_changes / compat_flag_override_side_effects / incomplete_coverage_of_new_reasoner_aliases

Supporting Evidence