Downloads · 30 days
97
10% of all-time downloads
Hikari07jp/DSpark-Gemma-4-31B-draft
DSpark-Gemma-4-31B-draft is a text generation model from Hikari07jp. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as apache-2.0.
A retrained + extended DFlash draft model for google/gemma-4-31B-it, built on top of z-lab/gemma-4-31B-it-DFlash (Apache-2.0).
Downloads · 30 days
97
10% of all-time downloads
All-time downloads
944
Public
Parameters
1.7B
6.4 GB on disk
Likes
4
Public
Click a slice to open those files.
.safetensors6.4 GB · 100%
From the Hugging Face model README
A retrained + extended DFlash draft model for google/gemma-4-31B-it, built on top of z-lab/gemma-4-31B-it-DFlash (Apache-2.0).
Two variants are included:
| variant | path | what it is | works with |
|---|---|---|---|
| DSpark (semi-AR markov) | repo root | retrained backbone + rank-256 semi-AR markov head, probabilistic drafting | vLLM 0.24.0 + our patch |
| backbone-only | backbone-only/ | retrained backbone, drop-in z-lab replacement | stock vLLM + PR #41703 (same as z-lab head) |
Setup: target = nvidia/Gemma-4-31B-IT-NVFP4
(official NVFP4), RTX PRO 6000 Blackwell (96 GB), vLLM 0.24.0 + PR#41703, K=15,
--kv-cache-dtype bfloat16, draft attention_backend=flash_attn. Throughput from vLLM
/metrics counters (not SSE chunk counting), ABBA alternation, warm-up rounds discarded,
paired per-round statistics. Prompts are train-disjoint (24 per domain).
| domain | DSpark tok/s | z-lab tok/s | diff |
|---|---|---|---|
| math | 217.4 | 207.1 | +5.0% |
| code | 197.6 | 185.9 | +6.3% |
| chat | 91.8 | 88.5 | +3.7% |
| toolcall | 181.5 | 191.3 | −5.1% |
| aggregate | 151.6 | 144.7 | +4.7% (CI excludes 0) |
Aggregate +0.7% — below our measured greedy noise floor (~1.5%), so we report this as a tie. Both heads reach ~4.06x over non-speculative decoding (171.7 vs 42.3 tok/s).
backbone-only/: the markov bias hurts structured JSON
(−5.1% vs z-lab on toolcall) while backbone-only is +6.6% over z-lab on toolcall.backbone-only/ (drop-in).Speculative decoding is lossless by construction; we additionally verified end-to-end: gsm8k (n=150) and structured tool-call JSON (n=24) accuracy identical to non-speculative baseline (McNemar exact p=1.0, Δ=0.00pp), and NVFP4 target quality matches BF16 on the same battery.
uv pip install -U --torch-backend=auto \
"vllm @ git+https://github.com/vllm-project/vllm.git@refs/pull/41703/head"
vllm serve nvidia/Gemma-4-31B-IT-NVFP4 \
--kv-cache-dtype bfloat16 \
--speculative-config '{"method":"dflash","model":"Hikari07jp/DSpark-Gemma-4-31B-draft/backbone-only","num_speculative_tokens":15,"attention_backend":"flash_attn"}'
Requires the DSpark patch on top of vLLM 0.24.0 — see
hikarioyama/dspark-gemma4-31b for the
patch and instructions. Then add "draft_sample_method":"probabilistic" to the
speculative config and serve the repo root as the draft model.
Note: --kv-cache-dtype bfloat16 is required (FP8 KV is incompatible with the flash_attn
draft path for this hybrid-SWA model), and FlashInfer rejects gemma-4's hybrid SWA — the
config above is the known-good combination.