mirror of
https://github.com/kvcache-ai/ktransformers.git
synced 2026-11-05 01:07:28 +00:00
[GH-ISSUE #2118] Support DSpark speculative decoding for DeepSeek-V4-Flash-0731 in sglang-kt #1282
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
kvcache-ai/ktransformers#1282
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 @edwardyehuang on GitHub (Aug 2, 2026).
Original GitHub issue: https://github.com/kvcache-ai/ktransformers/issues/2118
Reminder
Description
Summary
DeepSeek-V4-Flash-0731 (official release, 2026-07-31) ships a new DSpark speculative decoding module instead of the NextN-style MTP head used in DeepSeek-V4-Flash-Preview.
sglang-kt==0.6.4only supportsEAGLE/NEXTNspeculative algorithms and cannot load the new draft head, forcing users to disable speculative decoding entirely (~2x decode speed loss).Request: port DSPARK support to sglang-kt (upstream SGLang supports it since v0.5.16).
Background
Per the official release notes, DeepSeek-V4-Flash-0731 "has the same model structure as DeepSeek-V4-Flash-DSpark, i.e. it comes with a speculative decoding module attached."
The checkpoint layout changed:
model.enorm/hnorm/e_proj/h_proj(+weight_scale_inv)mtp.0,mtp.1,mtp.2(4,705mtp.*keys inmodel.safetensors.index.json), each containing attention + 256 routed experts + 1 shared expert, plusmtp.2.confidence_head.projandmtp.2.markov_head.markov_w1/w2New
config.jsonfields:@trilog-inc commented on GitHub (Aug 3, 2026):
Hi,
I managed to get Codex and 5.6 Sol to migrate the DSpark implementation from mainline. You can find the sglang update here https://github.com/trilog-inc/sglang/tree/codex/dspark-amx and the ktransformers update here https://github.com/trilog-inc/ktransformers/tree/codex/dspark-amx-native.
I also added the feature to select a different GPU for the draft model. In my case an RTX 4090 which frees up ~15G of VRAM on the RTX 6000.
It works on my system ( Xeon with AMX and a RTX 6000 pro ). Still doing tests but prefill is about 960t/s and decode from 25-35t/s.
EDIT: Averaging 45-60t/s with frequency expert placement via distribution recording.