Skip to content

docs(dflash): plan for gpt-oss-120b DFlash speculative decoding support - #131

Merged
drunkcoding merged 2 commits into
mainfrom
docs/dflash-gpt-oss-plan
Aug 14, 2026
Merged

docs(dflash): plan for gpt-oss-120b DFlash speculative decoding support#131
drunkcoding merged 2 commits into
mainfrom
docs/dflash-gpt-oss-plan

Conversation

@drunkcoding

Copy link
Copy Markdown
Contributor

What

Adds a phased, de-risked design doc (RFC) for supporting DFlash speculative decoding on openai/gpt-oss-120b in MoE-Infinity, using the z-lab/gpt-oss-120b-DFlash 0.8B block-diffusion drafter (arXiv 2602.06036).

Doc: docs/plans/gpt-oss-dflash-support.md (doc-only PR — no code changes).

Why

gpt-oss-120b is already a supported target, but MoE-Infinity has no speculative-decoding scaffolding today. DFlash is a lightweight, distribution-lossless way to speed up decode. This RFC captures the verified integration contract and a staged, low-risk path before any code lands.

Approach (summary)

  • Phase 0 — validate the SGLang reference, fully resident (go/no-go gate): confirm greedy losslessness vs plain gpt-oss-120b + record acceptance length and decode tok/s. If the resident-mode win isn't clearly positive, stop.
  • Then build natively into the synchronous engine/generation_loop.py path first — structurally the closest fit (HF past_key_values rollback), greedy first.
  • Resident-only for v1. A 9-token verify block would thrash the current next-layer/top-2 expert prefetcher, so expert-offload + spec-decode is explicitly deferred. Async continuous-batching serving is a later phase.

Contents

  • Verified DFlash runtime contract (drafter dims, block_size=10 → 9 draft tokens, mask_token_id=200000, target layers [1,9,17,25,33], target-hidden-state KV injection, accept rule).
  • MoE-Infinity integration anchors (file:line) for both decode paths.
  • Risk table (SGLang-on-Blackwell build, hidden-state extraction, KV rollback, offload amplification, losslessness).
  • Executable per-phase QA gates (pytest invocations + pass criteria), including a golden greedy-parity test.

Status

RFC for review. Phase 0 reference validation is being run separately; results will inform the go/no-go on native integration.

drunkcoding added 2 commits July 28, 2026 21:51
Phased, de-risked RFC to add DFlash block-diffusion speculative decoding for openai/gpt-oss-120b using the z-lab/gpt-oss-120b-DFlash 0.8B drafter (arXiv 2602.06036).

Phase 0 validates the SGLang reference (fully resident) as a go/no-go gate; native integration targets the synchronous generate path first; resident-only for v1 (expert-offload + async serving deferred). Includes the verified DFlash runtime contract, MoE-Infinity integration anchors, a risk table, and executable per-phase QA gates.
…y gate

Phase 0 (SGLang reference on SM120 Blackwell) is complete: GO. Adds section 0.1 with the validated results (DFlash worker init, acceptance length 3.66, single-stream 1.18-1.32x speedup, concurrency-8 0.65x regression) and two findings that refine the plan: (1) TP=4 is infeasible on SM120 for gpt-oss MXFP4 in current sglang main (all MoE backends fail; ran TP=2+Marlin); (2) strict token-identity is unattainable on this MXFP4 stack due to FP near-tie argmax flips (baseline is not self-identical) -- so the QA-3.1 parity gate now uses a same-process token agreement-rate metric instead of string identity. Also resolves open questions Q1/Q4 and updates the Definition of Done.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant