Skip to content

🐛 fix: omit DeepSeek reasoning effort when disabled#14194

Merged
tjx666 merged 1 commit into
canaryfrom
fix/deepseek-disable-thinking
Apr 26, 2026
Merged

🐛 fix: omit DeepSeek reasoning effort when disabled#14194
tjx666 merged 1 commit into
canaryfrom
fix/deepseek-disable-thinking

Conversation

@tjx666

@tjx666 tjx666 commented Apr 26, 2026

Copy link
Copy Markdown
Member

💻 Change Type

  • ✨ feat
  • 🐛 fix
  • ♻️ refactor
  • 💄 style
  • 👷 build
  • ⚡️ perf
  • ✅ test
  • 📝 docs
  • 🔨 chore

🔗 Related Issue

Fixes #14173

🔀 Description of Change

  • Remove reasoning_effort from DeepSeek chat payloads when thinking.type is explicitly disabled.
  • Keep reasoning_effort unchanged when DeepSeek thinking is enabled.
  • Add regression coverage for both payload shapes.

🧪 How to Test

  • Tested locally
  • Added/updated tests
  • No tests needed
cd packages/model-runtime && bunx vitest run --silent=passed-only src/providers/deepseek/index.test.ts

📸 Screenshots / Videos

N/A

📝 Additional Information

This is a provider-level payload compatibility fix. DeepSeek rejects requests that combine disabled thinking with reasoning_effort.

@vercel

vercel Bot commented Apr 26, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
lobehub Ready Ready Preview, Comment Apr 26, 2026 5:20am

Request Review

@dosubot dosubot Bot added size:XS This PR changes 0-9 lines, ignoring generated files. provider:deepseek labels Apr 26, 2026

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We've reviewed this pull request using the Sourcery rules engine

@codecov

codecov Bot commented Apr 26, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 67.85%. Comparing base (196c0a7) to head (f00243c).
⚠️ Report is 1 commits behind head on canary.

Additional details and impacted files
@@            Coverage Diff             @@
##           canary   #14194      +/-   ##
==========================================
- Coverage   67.85%   67.85%   -0.01%     
==========================================
  Files        2227     2227              
  Lines      191364   191366       +2     
  Branches    23747    19158    -4589     
==========================================
- Hits       129847   129845       -2     
- Misses      61388    61392       +4     
  Partials      129      129              
Flag Coverage Δ
app 61.09% <ø> (-0.01%) ⬇️
database 92.22% <ø> (ø)
packages/agent-runtime 79.82% <ø> (ø)
packages/context-engine 83.25% <ø> (ø)
packages/conversation-flow 92.40% <ø> (ø)
packages/file-loaders 87.02% <ø> (ø)
packages/memory-user-memory 74.74% <ø> (ø)
packages/model-bank 99.89% <ø> (ø)
packages/model-runtime 84.28% <100.00%> (+<0.01%) ⬆️
packages/prompts 70.14% <ø> (ø)
packages/python-interpreter 92.90% <ø> (ø)
packages/ssrf-safe-fetch 0.00% <ø> (ø)
packages/utils 88.41% <ø> (ø)
packages/web-crawler 88.66% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
Store 67.21% <ø> (ø)
Services 53.36% <ø> (ø)
Server 67.60% <ø> (-0.01%) ⬇️
Libs 53.30% <ø> (ø)
Utils 80.04% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@tjx666 tjx666 merged commit 8b22e55 into canary Apr 26, 2026
48 checks passed
@tjx666 tjx666 deleted the fix/deepseek-disable-thinking branch April 26, 2026 05:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

provider:deepseek size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

DeepSeek Cannot Disable Thinking

1 participant