Dariusfar commited on
Commit
6706a52
·
verified ·
1 Parent(s): 57443b8

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +44 -1
README.md CHANGED
@@ -45,9 +45,52 @@ Pair with **GLM-4.7-Flash** in a DFlash-capable inference stack (e.g. a speculat
45
  serving engine). It requires the target model plus a DFlash runtime and does not generate text
46
  on its own.
47
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
48
  ## Training
49
 
50
- Trained on NERSC Perlmutter; exported from training checkpoint `step_2916`.
 
 
51
 
52
  ## License
53
 
 
45
  serving engine). It requires the target model plus a DFlash runtime and does not generate text
46
  on its own.
47
 
48
+ ## Method note: decoupling draft width from verification depth
49
+
50
+ A DFlash-style drafter normally uses a **single width `k`** for both the draft pass *and* the
51
+ number of proposals the target verifies. In this work those two knobs are **decoupled** into
52
+ independent, fixed-shape controls:
53
+
54
+ - **`draft_width`** — the non-causal DFlash draft-query width. Because mask rows attend to one
55
+ another, a *wider* draft pass shifts the **acceptance** profile at early positions.
56
+ - **`verify_k`** — how many of those proposals are actually sent to the target for verification.
57
+ On a **fine-grained MoE target** like GLM-4.7-Flash, each verified token is expensive, so this
58
+ is the real cost driver.
59
+
60
+ The technique runs the proposer at a **wide** `draft_width`, keeps only the first `verify_k`
61
+ proposals, and verifies just that prefix — discarding the tail *before it ever enters the
62
+ target's KV / sequence state*. Draft and verify graphs stay fixed-shape (CUDA-graph
63
+ capturable), and target output semantics are preserved (the DeepSpec `prediction_shifted` row
64
+ contract), so the accelerated path is numerically faithful to the target.
65
+
66
+ **Why it helps.** A wide draft raises the number of committed tokens at early positions
67
+ (≈3.1 committed through position 4 at width-8, vs ≈2.1 at width-4), while a short verify avoids
68
+ paying MoE verification cost on the low-probability tail. The two optima are genuinely
69
+ different, so tying them together leaves throughput on the table.
70
+
71
+ ### Results
72
+
73
+ The sweet spot was **wide draft (8) / short verify (3)**. On a fixed same-node benchmark it
74
+ delivered **~1.16× throughput vs. an MTP-1 baseline** and **~+3% over the matched coupled
75
+ setting** (mean accepted length 2.50 vs 2.40) at **flat p95 latency**. The gain is strongly
76
+ **workload-dependent** (≈0.97×–1.54× across code / reasoning / numerical-optimization prompts),
77
+ which motivates **workload-aware / request-level routing** rather than one static configuration.
78
+
79
+ ![Draft-width × verify-depth matrix — accepted length and throughput across the swept grid](rd181_matrix_heatmaps.png)
80
+
81
+ *Draft-width × verify-depth matrix: acceptance and throughput across the swept configurations.
82
+ Wide-draft / short-verify (e.g. 8/3) sits at the throughput optimum.*
83
+
84
+ ![Per-domain throughput vs. baselines](speedbench_full_domain_throughput.png)
85
+
86
+ *Full-domain throughput vs. baselines (MTP-1 and coupled DFlash). Note the strong per-workload
87
+ variation — the motivation for request-level routing.*
88
+
89
  ## Training
90
 
91
+ Trained on NERSC Perlmutter (4×A100-40GB); exported from training checkpoint `step_2916`.
92
+ Draft config: block 16, 8-layer draft (hidden 2048), auxiliary hidden states from target
93
+ layers [1, 12, 23, 33, 44].
94
 
95
  ## License
96