Repository navigation
Conversation
Author
|
Failing check appears to be coming from upstream. Let me know if you want to enable this functionality and/or need any changes. Cheers! |
Owner
|
Thank you @swbiggart for this and for the careful receipt! The owner will decide on this one. |
Open
7 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem and change
Native DeepSeek rejects
tool_choice: "required"and named function choices because its tool-call opener spans text and a DSML token, while the server expects a single vocabulary token. Native CUDA also does not advertise or wire call-gate enforcement.Recognize the split opener and enable a request-local call gate for the native CUDA DeepSeek family. Add first tool-call prefix and offered-function-name enforcement across serial, speculative, and concurrent generation. Named choices use the narrowed tool list; thinking stays unconstrained until it closes.
autoandnonedo not install a gate.The gate enforces the first call's opening and offered function name. The gate does not enforce valid argument JSON, argument-schema conformance, later calls, or completion when a token limit, stop condition, or cancellation ends generation. No transport optimization or SGLang changes are included.
Base and implementation
Based directly on
deepseek-v41-zig-tp4atb8b115e7ed6c86d81b7575caa6f3d4ade52b323c. Benchmarked source:253c38ca4a30fca8e0fe242d5599844e84cc187c; the receipt amendment changes no code.The gate checks tokens before subsequent forwarding or drafting, cuts speculative output at the first invalid token, and tracks only committed tokens. Provenance and Apache-2.0 attribution are recorded in
ATTRIBUTION.md.Validation and performance
132 lane, 375 server, five JSON and 170 engine API tests pass; Linux ARM64
compile passes all seven steps. Astra reviewed the implementation. Golden: 309/319 equal, ten known differences, zero unexpected.
The full macOS suite remains blocked by inherited
SO.BUSY_POLL; lean findingsremain 1,615, unchanged from base.
Matched upstream/patched/upstream/patched benchmark on four GB10s, using the
same checkpoint, runtime and four-stream ring workloads:
No meaningful performance reduction was observed. All 96 measured burst replies
and 36 token/text qualification replies match. All 18 tool-choice feature cases
pass. A separate matched active-call workload passes all 84 calls, with
required/named throughput within 0.33% of auto and identical output tokens.
See the validation receipt
for commands, build provenance, per-load data and measurement scope.