Qwen4-35B-A3B-DFly2 β€” Zero-KV Block-Diffusion Speculative Drafter (v2 Archived Β· Pivoted to DFlash-2)

Architecture Pivot Notice (2026-12-05): Active large-scale training has moved to dymoo/Qwen4-35B-A3B-DFlash2! While v2 (41.8M tokens, live below) delivered strong gains on reasoning (math_think 1.98 β†’ 3.74, +89%) and overall T=1.0 acceptance (+20.5%), our roofline and architecture analysis showed that QSA-only KV reuse leaves the drafter blind to 75% of Qwen4-35B-A3B (its 30 GatedDeltaNet layers, 20.5B Layer-1 PLE n-gram table, and 4-stream hyper-connections), capping headroom over Qwen4's native built-in MTP head on code and agent workloads. We have therefore pivoted our scaled training run to DFlash-2 (dymoo/Qwen4-35B-A3B-DFlash2) β€” featuring 5-layer HC-averaged multi-depth hidden fusion ([1, 10, 19, 28, 39], including post-PLE Layer 1) into a compact W = 2048 sliding KV ring (~20 MiB/session), grouped dynamic 2-tap causal convolutions to eliminate block suffix blur, a low-rank Markov candidate path selector (block_size = 8), and native z-lab/dflash / SGLang / vLLM compatibility. This v2 DFly2 checkpoint remains archived here for zero-KV DFly2 users.

A 1.07B-parameter zero-KV-cache block-diffusion speculative drafter (DFly2 / DFlash-2 style) for Qwen/Qwen4-35B-A3B (qwen4_moe), trained via online KL distillation with Attentive Hidden Correction (topk = 128) and cross-attention directly over 5 sparse QSA target KV layers ([3, 11, 19, 27, 35]).

  • Zero extra KV cache: Reuses the target model's existing QSA KV cache (preserves prefix caching and snapshot/rewind with 0 bytes of draft KV overhead).
  • Single-forward block drafting: Proposes gamma = 5 draft tokens (block_size = 6, max tau = 6.0) in one parallel pass (~5 ms overhead on AMD Strix Halo gfx1151).
  • Lossless verification: Exact greedy (T = 0.0) and rejection-sampling (T = 1.0, min(1, p/q) + residual) verification against target logits.
  • Active training series: We are continuing to scale on-policy rollouts and training tokens (v1 β†’ v2 β†’ v3) and pushing each verified checkpoint with updated live benchmarks to this repository.

Checkpoint Progression & Live Speculative Acceptance Benchmarks

Evaluated end-to-end with block_size = 6 (gamma = 5, hidden_correction_topk = 128, max_new_tokens = 128) on the held-out 8-prompt multi-domain suite (code_nothink, code_think, tool_json, math_think, chat_nothink, long_ctx 6.8K):

Checkpoint Training Data & Scale Overall T=0.0 Mean Ο„ ↑ Overall T=1.0 Mean Ο„ ↑ math_think (T=0 / T=1) tool_json (T=0 / T=1) code_think (T=0 / T=1) code_nothink (T=0 / T=1)
v1 (step 550) 9.0M off-policy tokens (INT4 teacher) 1.821 1.617 1.98 / 2.63 2.00 / 1.74 2.00 / 1.34 1.57 / 1.48
v2 (step 1000, current) 41.8M total (+32.8M @ 65% on-policy, native FP8 teacher) 2.115 (+16.1%) 1.949 (+20.5%) 3.74 / 3.43 2.47 / 1.94 2.05 / 1.98 1.55 / 1.56

v2 Per-Prompt Breakdown (Qwen/Qwen4-35B-A3B-FP8 Live Teacher, block_size = 6, gamma = 5)

Prompt Category Thinking Prompt Tokens T=0.0 Ο„ T=0.0 Slot Accept [1..5] T=1.0 Ο„ T=1.0 Slot Accept [1..5]
math_think Yes 53 3.74 82% / 65% / 50% / 41% / 35% 3.43 86% / 76% / 43% / 19% / 19%
tool_json (schema) No 92 2.70 74% / 64% / 30% / 2% / 0% 2.42 64% / 47% / 23% / 6% / 2%
tool_json (tool calls) No 87 2.23 65% / 32% / 16% / 7% / 4% 1.47 37% / 8% / 1% / 0% / 0%
code_think Yes 50 2.05 60% / 26% / 15% / 3% / 2% 1.98 53% / 22% / 12% / 8% / 3%
code_nothink (diff) No 56 1.67 46% / 12% / 8% / 1% / 0% 1.53 33% / 10% / 6% / 4% / 1%
long_ctx (6.8K code) No 6,784 1.64 46% / 13% / 4% / 1% / 0% 1.75 45% / 21% / 5% / 3% / 1%
chat_nothink No 65 1.46 37% / 9% / 0% / 0% / 0% 1.43 29% / 12% / 1% / 0% / 0%
code_nothink (LRU) No 61 1.44 33% / 6% / 3% / 1% / 1% 1.59 45% / 11% / 3% / 0% / 0%
Overall Mean β€” β€” 2.115 55% / 28% / 16% / 7% / 5% 1.949 49% / 26% / 12% / 5% / 3%

Honest diagnostic & what's coming in v3: v2 delivered huge gains on reasoning (math_think 1.98 β†’ 3.74, code_think T=1.0 1.34 β†’ 1.98) and structured JSON (2.00 β†’ 2.70), lifting overall T=1.0 acceptance by +20.5%. Non-thinking (code_nothink, chat_nothink, long_ctx) stayed flat because v2's 2,285 on-policy rollouts were heavily weighted toward thinking=True at seq_len=2048. v3 (training next) adds 5,000+ fresh 50/50 nothink + think on-policy rollouts at seq_len=4096 for +65M tokens (~108M total) to lift non-thinking and long-context acceptance alongside reasoning.

Artifact Inventory (v2)

File Format Size SHA-256
Qwen4-35B-A3B-DFly2-Q8_0.gguf GGUF Q8_0 (recommended runtime) 339.1 MB 4828147bd6316d65…
Qwen4-35B-A3B-DFly2-BF16.gguf GGUF BF16 (reference) 637.9 MB d15a97dbabe0f79c…
model.safetensors PyTorch BF16 weights 637.7 MB 9212efc0ff9146a3…
config.json DFly2 architecture config (block_size=6, target_kv_layers=[3,11,19,27,35], hidden_correction_topk=128) β€” β€”
golden_parity_q8_0.json Numerical parity fixture for runtime verification β€” β€”
eval_dfly2_v2_live.json Full per-prompt T=0.0 & T=1.0 evaluation trace β€” β€”

Compute & GPU-Hours Ledger

Checkpoint Hardware Stage GPU-Hours Cumulative GPU-Hours Notes
v1 (step 550) 1Γ— NVIDIA A100-SXM4-40GB 4.8 hrs 4.8 hrs 9.0M off-policy tokens (INT4 teacher) + export
v2 (step 1000, live) 1Γ— NVIDIA A100-SXM4-80GB 4.7 hrs 9.5 hrs 1,500 on-policy rollouts (0.83h) + 1,000 steps native FP8 teacher (3.62h, +32.8M tok) + live T=0/T=1 eval (0.25h)
DFlash-2 (successor) 1Γ— NVIDIA A100-SXM4-80GB In progress β€” Pivoted to dymoo/Qwen4-35B-A3B-DFlash2 (5-layer PLE+GDN+QSA fusion, 2-tap dynamic convs, Markov selector, block_size=8)

Architecture Summary

  • 5-layer Qwen4 DFly2 draft decoder (hidden_size = 2048, num_attention_heads = 16, num_key_value_heads = 2, head_dim = 256, intermediate_size = 6144, zero_centered_norm = true)
  • Cross-attention target KV layers: [3, 11, 19, 27, 35] (5 of 10 QSA sparse-attention layers)
  • Attentive Hidden Correction: hidden_correction_topk = 128 (zero-overhead embedding-projection refinement)
  • Tied input embedding & LM head: Reuses the target model's token_embd and output weights (not duplicated in the drafter GGUF).

Companion Releases (Full Collection)

Downloads last month
324
Safetensors
Model size
0.3B params
Tensor type
BF16
Β·
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for dymoo/Qwen4-35B-A3B-DFly2

Quantized
(733)
this model

Collection including dymoo/Qwen4-35B-A3B-DFly2