Skip to content

feat(opencode): Add none effort level to deepseek-v4 models - #31795

Open
martinmr wants to merge 7 commits into
anomalyco:devfrom
martinmr:dev
Open

feat(opencode): Add none effort level to deepseek-v4 models#31795
martinmr wants to merge 7 commits into
anomalyco:devfrom
martinmr:dev

Conversation

@martinmr

Copy link
Copy Markdown

Issue for this PR

Closes #24610

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Adds a none variant to deepseek v4 models that enables non-thinking mode. These models tend to overthink a lot, so this feature is a quality of life improvement.

How did you verify your code works?

Ran it locally, verified that none option is there, and that it does not produce any thinking traces.

Screenshots / recordings

N/A

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@martinmr

Copy link
Copy Markdown
Author

No idea what the other changes are here. My changes were only to transform.ts. I am not sure how to resolve the conflicts so I'll let a maintainer do it.

@rekram1-node
rekram1-node force-pushed the dev branch 3 times, most recently from 3776548 to 0226034 Compare June 11, 2026 21:36
@LuisPeregrina

Copy link
Copy Markdown

Can any maintainer add dumb commit? Seems github had a hiccup and didn't continue with CI

@martinmr

martinmr commented Jul 7, 2026

Copy link
Copy Markdown
Author

Can any maintainer add dumb commit? Seems github had a hiccup and didn't continue with CI

It’s not a hiccup. Maintainers have to approve CI runs.

@tanishqvec

Copy link
Copy Markdown

Your payload is the right one for api.deepseek.com, but I don't think variants() is reached for these models: provider.ts:1310 does ProviderTransform.reasoningVariants(model, base) ?? ProviderTransform.variants(base), and because models.dev declares reasoning_options for deepseek-v4-*, reasoningVariants returns low/high/max and short-circuits the fallback. Worth checking against your build in case I've misread it.

Your model.providerID === "deepseek" guard was the right instinct — I counted ~63 models across ~30 providers that would match on the model id alone, and zen turns out to need a different payload again (it ignores thinking and accepts reasoning_effort: "none").

I opened #46181, which moves this into reasoningVariants and keeps your provider scoping. Happy to close mine if you'd prefer to move yours instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE]:Deepseek-V4 need a "disable thinking" button

4 participants