Use AIUnderstand AIBuild with AI
Build with AI·Model deep dive·· 4 min read

Speed Up Qwen3.8-27B with the DSpine Draft Model in SGLang

DSpine-b16 is a five-layer draft model for speculative decoding of Qwen3.8-27B. See the card's numbers and the exact SGLang command it gives.

The code in this post comes from the model's docs and hasn't been run in our CI yet. If something breaks, let us know.

tencent/Qwen3.8-27B-DSpine-b16 is not a chat model. It is a draft model for speculative decoding: you serve it next to Qwen3.8-27B, and it proposes tokens that the main model then verifies. The card says DSpine “generates draft tokens in parallel”, with each layer passing predicted predecessor features to adjacent positions so that causal dependencies are carried through network depth.

What’s notable is the comparison the card makes against the official DFlash2 draft model for the same target. On every benchmark it lists, DSpine has a longer acceptance length and higher throughput.

Key specs

  • Draft model for Qwen3.8-27B (the card lists it as the base_model)
  • Five layers
  • Block size 16
  • 8,192-token sliding window
  • License: Apache 2.0
  • Runtime: SGLang (the card’s evaluation used SGLang 0.5.22 with BF16 and FlashAttention 3)

What the card measured

The card reports acceptance length for DSpine versus DFlash2, which uses a draft block size of 8. DSpine used 16. Some of the general-benchmark results at temperature 0:

Task DFlash2 DSpine
GSM8K 5.69 7.20
MATH-500 5.49 6.49
HumanEval 4.87 5.71
MBPP 5.04 6.14
MT-Bench 4.11 4.48

For agent workloads, the card reports end-to-end throughput in tokens per second, with the speedup over autoregressive (AR) decoding in parentheses. At low reasoning:

Benchmark AR DFlash2 DSpine
WorkBuddy Code 253.35 590.27 (2.33×) 686.23 (2.71×)
WorkBuddy Web 247.40 639.74 (2.59×) 773.19 (3.13×)
WorkBuddy Office 210.03 664.77 (3.17×) 805.53 (3.84×)
SWE-bench Pro 241.86 657.71 (2.72×) 713.41 (2.95×)
τ²-bench 301.39 891.37 (2.96×) 964.30 (3.20×)

The card also gives xhigh reasoning results, where DSpine’s speedups range from 2.87× to 3.55× across the same five benchmarks.

Read these with the card’s setup in mind: concurrency 8 for the runtime, dynamic verification referencing DSpark, ReplaySSM enabled, and agent trajectories replayed from CodeBuddy sandboxes (20 conversations per subset). The card doesn’t say how results would change with other settings.

Install

The card installs DSpine from its GitHub repository:

Terminal window
git clone https://github.com/Tencent/DSpine.git
cd DSpine
pip install -e .

The card doesn’t show how to download the draft checkpoint. Its command uses a local path, /path/to/Qwen3.8-27B-DSpine-b16, so you need to place the model files there yourself.

Run it

The card’s serving command, unchanged except for the path you must fill in:

Terminal window
sglang serve \
--model-path Qwen/Qwen3.8-27B \
--speculative-algorithm DSPINE \
--speculative-draft-model-path /path/to/Qwen3.8-27B-DSpine-b16 \
--speculative-num-draft-tokens 16 \
--dtype bfloat16 \
--attention-backend fa3 \
--speculative-draft-attention-backend fa3 \
--linear-attn-backend triton \
--enable-linear-replayssm-spec \
--mamba-ssm-dtype float32 \
--mamba-radix-cache-strategy extra_buffer \
--max-mamba-cache-size 64 \
--mem-fraction-static 0.80 \
--context-length 131072 \
--max-running-requests 8 \
--cuda-graph-max-bs-decode 8 \
--min-free-slots-delay 1 \
--sampling-backend flashinfer \
--reasoning-parser qwen3 \
--tool-call-parser qwen3_coder \
--trust-remote-code

A few flags are worth understanding before you change anything:

  • --speculative-algorithm DSPINE selects the DSpine method, and --speculative-num-draft-tokens 16 matches the block size of this checkpoint.
  • --enable-linear-replayssm-spec turns on ReplaySSM, which the card lists as enabled for its evaluation.
  • --max-running-requests 8 and --cuda-graph-max-bs-decode 8 match the concurrency of 8 used in the card’s tests.
  • --reasoning-parser qwen3 and --tool-call-parser qwen3_coder set up reasoning and tool-call parsing for the target model.

The card doesn’t include client code. How you send requests to the running server is up to you, and it isn’t covered by the card.

Gotchas

  • It’s a draft model, not a standalone model. The card gives it only as a companion to Qwen3.8-27B. The checkpoint is built for that target, so the card gives no basis for using it with a different one.
  • The sampling settings behind the numbers. The card’s temperature-sampling results use temperature=1.0, top_p=0.95, top_k=20. General-benchmark runs used xhigh reasoning and at most 4,096 new tokens.
  • Acceptance length is not wall-clock speed. The throughput table is the one that reports tokens per second, and only for the agent benchmarks listed.
  • Hardware isn’t specified. The card doesn’t say which GPUs it used or what the memory requirements are. Check the DSpine GitHub repository and the Qwen3.8-27B card before you plan capacity.
  • Window limit. The draft model has an 8,192-token sliding window, while the serving command sets --context-length 131072 for the whole server. The card doesn’t discuss how these two interact.
  • Untested here. The commands above are copied from the card and have not been run for this post.

When to pick it

Pick DSpine-b16 if you already serve Qwen3.8-27B with SGLang and care about generation speed, especially for agent-style workloads like the ones in the card’s tables. It’s licensed under Apache 2.0, and the card shows higher acceptance length and throughput than DFlash2 in its own tests.

Skip it if you use a different runtime, a different target model, or if you need a model you can chat with directly. The card only documents SGLang. Treat the speedup figures as results from the card’s own setup, and measure on your own traffic before relying on them.

Related