license: other
license_name: qwen-community-1.0
license_link: https://huggingface.co/Qwen/Qwen3.8-Flash-Next/blob/main/LICENSE
base_model:
- shadowpa0327/Qwen3.8-Flash-Next-DSpark
- catplusplus/Qwen3.8-Flash-Next-uncensored-NVFP4-mixed
library_name: sglang
tags: - speculative-decoding
- dspark
- draft-model
- mxfp8
- qat
- lora
- sglang
- qwen3.8
- coding-agent
Qwen3.8-Flash-Next-uncensored-DSpark-MXFP8
An on-policy fine-tuned and selective W8A8 MXFP8 QAT DSpark speculative-decoding draft model tailored for catplusplus/Qwen3.8-Flash-Next-uncensored-NVFP4-mixed (Qwen3.8-Flash-Next-Spectrum-MXFP8), built on top of shadowpa0327/Qwen3.8-Flash-Next-DSpark.
- Architecture: 5-layer DSpark draft model (
664.6Mparams), reading multi-tap hidden states from target layers[1, 12, 23, 34, 45]and sharing the target model's embedding andlm_head. - Selective OCP
MXFP8Precision (modelopt_mixed): All 15 MLP linear projections (layers.{0..4}.mlp.{gate_up_proj,down_proj}) are quantized to OCPMXFP8([1, 32]E8M0 block scaling), while the multi-tap projector (fc), attention (self_attn), norms, and Markov/confidence heads remain in pristine BF16. - Footprint:
967.3 MBon disk (-361.9 MBvs. the1,329 MBBF16 checkpoint) with zero quantization degradation thanks to true W8A8 straight-through-estimator QAT.
What We Did
On-Policy Corpus & Multi-Tap Trajectory Capture (
2.09Mtokens)- Harvested
766on-policy sequences (2,092,058tokens) generated directly bycatplusplus/Qwen3.8-Flash-Next-uncensored-NVFP4-mixed:- Real
16K–73KOpenCode coding-agent sessions (alternating<think>reasoning, summaries, and JSON tool calls; held-out38K–73Ksession strictly excluded from training) - Fresh
temp=0.6EN/JP assistant & tool-calling chats and multi-language coding/research rollouts - Short-context anchor rollouts to preserve
0–8Kthroughput
- Real
- Captured exact target multi-tap hidden states from SGLang using per-token FP8 E4M3 storage with chunked-prefill stitching across long contexts.
- Harvested
Stage 1 — Long-Context On-Policy LoRA (BF16, 8 epochs)
- Fine-tuned with
LoRA r=64, alpha=128, unfrozenq_norm/k_norm, and gentle0.25×LR on the multi-tap projectorfc, using batched multi-anchor training across0–64K+contexts so the generalist 2.9B-token base is preserved while adapting to our quantized target and long-context tool-calling cadence. - Held-out validation simulated acceptance length (
block-size 5):- Short (
<8K):2.52 → 4.84(loss3.9757 → 1.7690) - Long (
≥8K):2.69 → 2.99(loss4.0451 → 3.0695)
- Short (
- Fine-tuned with
Stage 2 — Selective Quantization Sweep & True W8A8
MXFP8QAT (2 epochs)- Swept BF16 vs.
MXFP8-MLP(-361.9 MB) vs.MXFP8-MLPFC(-393.6 MB) vs.MXFP8-AllLinear(-488.9 MB) atblock-size 5and7. Quantizingfcorself_attncost1.1–1.3 tok/s, andblock-size 7lost~4 tok/son unified LPDDR5X; 15-MLP-onlyMXFP8atblock-size 5was the clear winner. - Ran 2 epochs of true W8A8
MXFP8STE QAT (simulating both weight and dynamic per-32-block activation quantization on the 15 MLPs) before snapping weights to OCPMXFP8. - Held-out validation after snapping: Short
4.86, Long3.01— zero quantization loss, slightly outperforming the BF16 checkpoint.
- Swept BF16 vs.
Verified Live Results
Benchmarked end-to-end on a single NVIDIA Thor (sm_110, 128 GB unified LPDDR5X) serving catplusplus/Qwen3.8-Flash-Next-uncensored-NVFP4-mixed via SGLang (--speculative-algorithm DSPARK --speculative-dspark-block-size 5, warm PLE NVMe cache):
| Benchmark Suite | Baseline | DSpark V2 QAT-MXFP8-MLP | Improvement | Notable Per-Task Results |
|---|---|---|---|---|
Short 5-Prompt (temp=0.0) |
37.71 tok/s (Stock BF16 DSpark) |
41.55 tok/s |
+10.2% |
code_lru 54.70 (+13.6%), opencode_edit 52.89 (+5.2%), tool_call_json 42.67 (+8.3%), chat_explain 41.45 (+8.0%) |
Short 5-Prompt (temp=0.6) |
31.85 tok/s (Stock BF16 DSpark) |
33.09 tok/s |
+3.9% |
jp_translation 29.10 (+14.4%), tool_call_json 36.69 (+13.3%) |
EN/JP Assistant & Tool Chats (temp=0.6, streaming decode) |
19.98 tok/s (Pre-V2 baseline) |
24.40 tok/s |
+22.1% |
quick_en 23.28 (+31.0%), tool_search 27.56 (+24.9%), quick_jp 23.49 (+19.9%), deep 24.77 (+17.9%) |
Held-Out OpenCode (38K–73K ctx, thinking ON, temp=0.6) |
23.81 tok/s (Pre-V2 baseline) |
26.84 tok/s |
+12.7% |
38K: 20.48 → 26.87 tok/s (+31.2%), 73K: 26.67 tok/s (peak 29.43 tok/s) |
Serving with SGLang
python3 -m sglang.launch_server \
--model-path catplusplus/Qwen3.8-Flash-Next-uncensored-NVFP4-mixed \
--served-model-name Nikola \
--host 0.0.0.0 \
--port 9000 \
--mem-fraction-static 0.915 \
--context-length 262144 \
--cuda-graph-max-bs-prefill 2048 \
--trust-remote-code \
--tool-call-parser qwen3_coder \
--reasoning-parser qwen3 \
--ple-offload-embedding \
--ple-offload-backend file \
--speculative-algorithm DSPARK \
--speculative-draft-model-path catplusplus/Qwen3.8-Flash-Next-uncensored-DSpark-MXFP8 \
--speculative-dspark-block-size 5 \
--disable-flashinfer-autotune \
--moe-runner-backend flashinfer_cutlass
Note: Requires an SGLang build with
qwen4_expauxiliary multi-tap hidden-state capture enabled (andmodelopt_mixedMXFP8 support for the DSpark MLP layers).
Acknowledgments & Thanks
- Huge thanks to
shadowpa0327for the initial 2.9B-tokenOpen-SWE-Tracestraining and release ofshadowpa0327/Qwen3.8-Flash-Next-DSpark! That rock-solid generalist foundation made it possible to specialize and QAT-quantize the predictor for our quantized model and long-context workloads on a single home workstation in just a couple of hours. - Thanks to the SpecForge / SGLang team for the DSpark architecture and serving runtime, and the Qwen Team for
Qwen3.8-Flash-Next.