Archived
dflash2 coupled walk: Q at temperature 0.6 by default
Q's temperature (RADIANCE_DFLASH_Q_TEMP) only moves acceptance, never the output law. Held-out tokens per verify step at request temperature 1, x4, 32 rows of the eval set, Qwen3.8-27B MXFP4 with a DFlash2 drafter fine-tuned on our traffic, our serving flags: ordinary rule 3.52; coupled with Q at 1.0 3.71, 0.7 3.88, 0.5 3.85, 0.35 3.77. The walk's scores are flatter than the target's law, so a sharper Q puts its mass where the target's is; 0.6 is the default now. At 0.6, 3 interleaved rounds against the ordinary rule (64 held-out rows at x4, and three requests at x1 and x4, 1500 tokens, T 1): - tokens per step 3.53 -> 3.82 (+8.2 %), every round apart (3.50/3.49/3.61 vs 3.82/3.79/3.86); time-weighted decode +5.4 %; - decode per stream: 0.7k prompt x1 174.1 -> 181.7 (+4.4 %), x4 144.6 -> 153.8 (+6.4 %); 22k prompt x1 186.6 -> 191.0 (+2.3 %), x4 135.1 -> 146.2 (+8.2 %); 41k prompt x1 186.9 -> 196.8 (+5.3 %), x4 125.8 -> 135.0 (+7.3 %); aggregate at x4 +5.3..+5.5 %. Coupled at 0.6 against the ordinary rule, 5000-6000 samples of tokens 1-4 of two chat prompts: chi-square p 0.62..0.99. The walk's kernel issues each candidate's successor slice and unary score before the predecessor's codebook row (both are independent of it). This is the build measured above; it moved the pass time within noise (91.3 -> 90.8 us at M 16, steps 7), and tokens, ids, x and status still match the host oracle on all 40 random lattices (q by FP64 exp ulps, <= 4.3e-16). ctest (the environment-only tests excluded) 105/105. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
cb0abe9ac7
commit
ce79b12126
3 files changed
+26
-16
No files matched your search
@@ -424,8 +424,11 @@ static int declare_dflash2(RadBuilder* b, const RadModelMeta* meta, const RadBui
|
||||
/* --draft-coupling (RadBuildCtx::draft_coupling): the walk samples each draft from Q, its
|
||||
* scores' softmax over the best eight candidates, and the sampler couples the target's own draw
|
||||
* to it (abi/rad_spechub.h). The planes are named as the MTP head's, which is how the engine
|
||||
* finds them. RADIANCE_DFLASH_Q_TEMP sets Q's temperature (default 1); any value keeps the
|
||||
* output exact and moves only acceptance. */
|
||||
* finds them. RADIANCE_DFLASH_Q_TEMP sets Q's temperature; any value keeps the output exact
|
||||
* and moves only acceptance. The default, 0.6, is where held-out acceptance peaked on
|
||||
* Qwen3.8-27B MXFP4 + its DFlash2 drafter at request temperature 1 (tokens a step at x4, 32
|
||||
* rows: ordinary rule 3.52; Q at 1.0 3.71, 0.7 3.88, 0.5 3.85, 0.35 3.77): the walk's scores
|
||||
* are flatter than the target's law, and a sharper Q puts its mass where the target's is. */
|
||||
if (ctx->draft_coupling) {
|
||||
if (dc.steps() > RAD_MTP_COUPLE_MAX_ROUNDS || dc.sel_topk > RAD_DFLASH_COUPLE_MAX_K ||
|
||||
dc.sel_rank % RAD_DFLASH_EDGE_PARTS || dc.sel_rank > RAD_DFLASH_COUPLE_MAX_R) {
|
||||
@@ -435,6 +438,7 @@ static int declare_dflash2(RadBuilder* b, const RadModelMeta* meta, const RadBui
|
||||
RAD_DFLASH_COUPLE_MAX_R);
|
||||
return RAD_E_UNSUPPORTED;
|
||||
}
|
||||
dc.q_temp = 0.6;
|
||||
if (const char* e = std::getenv("RADIANCE_DFLASH_Q_TEMP")) {
|
||||
const double t = std::strtod(e, nullptr);
|
||||
if (!(t > 0.0) || t > 100.0) {
|
||||
|
||||
Reference in new issue
Block a user