mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[GH-ISSUE #7401] [Feature]: Native DeepSeek provider #4123
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#4123
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @ylli-selmani on GitHub (Oct 10, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/7401
Originally assigned to: @ylli-selmani on GitHub.
What problem does this solve?
DeepSeek has no built-in connection type. The usual workaround — a Custom (OAI-Compatible)
connection — works, but the natural-looking setup fails quietly and confusingly:
Setting the connection's Provider to OpenAI and pointing the Base URL at
https://api.deepseek.com/v1does not produce an OpenAI-shaped request.
shouldSuppressUnknownModelParameters("openai", "deepseek-v4-pro")returns true, because
openaihas a built-in catalog and DeepSeek's models are not in it, so the panel hidesTemperature, Top P, Top K, penalties, Reasoning Effort and Verbosity, and the sent body is left with
little more than
max_tokens. A user who did this and lost the Reasoning Effort control reported it as aregression and considered downgrading to an older release.
deepseekalso falls through to the generic path everywhere a provider id is matched, so its real requestrules are not modelled: DeepSeek accepts
reasoning_effort(none/low/high/max) plus a separatethinking: {type: enabled|disabled}switch, returns thinking underreasoning_content, and rejects orignores several fields the generic OpenAI rules would send.
Finally, the shipped catalog is stale.
DEEPSEEK_MODELS(packages/shared/src/constants/model-lists.ts)lists
deepseek-chat,deepseek-coderanddeepseek-reasoner— all retired on 2026-07-24 — plus the legacydeepseek-v4-flash, and it is missingdeepseek-flash, the current model name.Proposed solution
Add
deepseekas a first-class provider, in the same shape aszai,arliand the otherOpenAI-compatible built-ins:
deepseekin theAPIProviderunion, the shared connection schema, and the Drizzleenum; a
PROVIDERS.deepseekentry with default base URLhttps://api.deepseek.com/v1, so it appears inthe provider picker next to the other services.
MODEL_LISTS.deepseek, refreshed to what the API actually serves —deepseek-flashand
deepseek-v4-pro— dropping the retired ids. Host inference forapi.deepseek.com.deepseekthroughOpenAIProviderwith its own provider kind, mirroring thedocumented contract so the parameter panel and the sent body agree:
none/low/high/max), Temperature, Top P,Assistant Prefill, Assistant Reasoning Prefill, Thinking Tags, Custom Parameters
verbosity, notop_k/min_p, and marks both penalties deprecated with "will not take effect"thinking: {type}, reasoning read back fromreasoning_contentdeepseekinOPENAI_COMPATIBLEandKNOWN_PROVIDERS, aNEVER_SENTentry, and the reasoning-model rule, so the gating above is what the panel actually applies.
Scope is the text/chat provider only. DeepSeek image generation is deliberately out of scope.
Alternatives considered
it is an undocumented workaround for a service with a public, documented API, and it leaves the mis-pairing
trap in place for the next person who reasonably picks "OpenAI" for an OpenAI-compatible endpoint.
rejects fields it does not know, so relaxing it would reintroduce real 400s for genuine OpenAI users.
silently do nothing — the exact class of misleading control that #6776 set out to remove.
Additional context
Reasoning Model.
scripts/regressions/generation-parameter-relevance.regression.ts) is the naturalplace to pin the new rows; it already probes each provider's real request body and compares it against what
the panel shows.
docs/connections/providers-reference.mdneeds a DeepSeek section (and thedocs-i18nbranch mirrored).Template check
🤖 Drafted with Claude (Anthropic) for @ylli-selmani.