Repository navigation
qwen38: keep the unset MTP draft off under --parallel above 1 - #695
Conversation
A drafted load runs a round of sampled or id-banning requests a slot at a time, where a plain load runs the round as one pass. With the unset draft rule picking the checkpoint folder's MTP layer, a --parallel 4 server of Qwen3.8-Flash-Next-FP4-Local on a GB10 decoded four sampled 4096-id requests at 28.3 tok/s over their all-active window against 61.6 on the plain load, and four greedy ones at 56.5 against 64.2. Unset, the rule now drafts on a one-slot load and leaves the draft off on more, its load draft=off record naming the slots. The rule is the same for a GGUF draft file and a checkpoint folder's MTP layer, since both step their rounds the same way. BLOOMERY_DRAFT=mtp still drafts on any slot count, and a folder without the layer keeps its own rule. gate_qwen38_serve's server of the seat's defaults at --parallel 2 now sets BLOOMERY_DRAFT=mtp, keeping the drafted residency, rounds and width chooser it checks, and the draft share clause holds the unset draft off on two slots of the GGUF split.
There was a problem hiding this comment.
Verdict: CLEAN: The slot rule preserves explicit draft settings, earlier off reasons, and named refusals.
Non-blocking
⚠ Validate the final scope: crates/gpu-gates/src/bin/shared/serve_seats/qwen38.rs:1365 applies the rule to GGUF and folders. The body says GGUF is unchanged and names a helper and test absent from this head.
Update the description and FAIL-first output. Attach just gate-gpu-qwen38-serve output and a same-lease GGUF greedy/sampled A/B on the contributor's card, with both commit hashes, model and commands.
For a lone greedy request on a multi-slot server, disabling MTP replaces a pass of up to four verify rows with one target row per step. The supplied folder measurements do not establish that tradeoff for GGUF.
Checked
Duplicates: 6 new items checked (2 functions, 3 closures, 1 enum variant); no duplicate owner found. Dryer reported 0 pairs; gpu-gates was checked manually with Grep.
Complexity: draft_slot_share 36 → 41 adds a refusal case and shares setup/polling; Draft38Off::fmt 17 → 18 adds one harmless match arm.
Silent failure: 2 record-read fallbacks followed; malformed or absent records produce an error or a failed gate clause.
Tests: static mutation review only. At qwen38.rs:948, replacing slots > 1 with false, changing it to >= 1, or dropping the explicit-word guard fails the new unit assertions. Dropping the call at line 1365 fails the new GGUF refusal clause. Reverting the gate's explicit mtp setting fails its real-tier chooser assertion.
Gates: no tolerance moved. The changed residency-server setup has a dated PIN and replacement coverage for the unset two-slot rule.
Adversarial paths: zero slots are refused; explicit MTP still checks the context window; existing folder/media restrictions and MTP-only lever refusals remain.
Escape catalog: no C1–C4 pattern matched.
Notes
Dryer did not scan gpu-gates; its changed code was checked manually.
No tests ran during this review. The body reports a host rule gate, without a complete GPU gate run and both tested commit hashes; GPU evidence is incomplete.
Card check: needs-gpu. This pull request changes crates/gpu-gates/src/bin/bloomery_serve_qwen38.rs, crates/gpu-gates/src/bin/gate_qwen38_serve.rs, crates/gpu-gates/src/bin/shared/serve_seats/qwen38.rs and carries no gate run on a card (CONTRIBUTING's evidence list); a maintainer adds gpu-verified after one.
🔨 Shingler, bloomery's review bot: approves a clean pull request and requests changes on a must-fix (how it works)
|
The review is done and the contribution check passed, so I'm merging this. |
BLOOMERY_DRAFT를 설정하지 않았을 때 MTP draft(GGUF draft 파일과 체크포인트 폴더의 MTP layer 모두)를 slot이 한 개인 서버에서만 기본으로 켜서,--parallel 4서버의 동시 요청 네 건 처리량이 떨어지지 않게 합니다.Part of #565.
What and why
With
BLOOMERY_DRAFTunset, the default rule turns the MTP draft on at any--parallelvalue, whether the draft is a GGUF file or the MTP layer of an FP4-Local checkpoint folder. A drafted load steps a round of sampled or id-banning requests one slot at a time. On a--parallel 4server with four such requests, decode throughput falls to the speed of one request.This PR turns the unset default on only for a one-slot server. With
--parallel2 or more andBLOOMERY_DRAFTunset, the draft stays off whatever its source, and theload draft=offline names the slot count.BLOOMERY_DRAFT=mtpstill drafts at every slot count, andBLOOMERY_DRAFT=offstill disables the draft. A folder without an MTP layer keeps its own rule indraft_off_for.draft_for_slotsincrates/gpu-gates/src/bin/shared/serve_seats/qwen38.rsowns the slot decision, andrun()calls it once after the folder rule.Draft38Off::Slotsincrates/levers/src/lib.rscarries the slot count into the load line.docs/serving.md, the lever registry entry forBLOOMERY_DRAFTand the seat's module documentation state the rule as it now works.The cost is on servers with
--parallel2 or more: they no longer get the C@2 greedy gain, which was 45.86 to 67.66 tok/s (+47.52%). That default can be revisited now that the batch-aware draft width in #690 has merged.Release notes: Fixed: a Qwen3.8 server with
--parallelabove 1 no longer turns its MTP draft on by default, which slowed sampled and id-banning requests.Code shape
draft_for_slotsis the one owner of the slot decision, andrun()calls it for every draft source.load draft=offline, and no refusal is added.PIN(2026-10-23)comment.gate_qwen38_servehas a server that runs--parallel 2with no draft word and used to check the drafted residency, the width chooser and the drafted rounds on it. That server now setsBLOOMERY_DRAFT=mtp, so it keeps the same drafting checks, and a newdraft_unset_is_off_on_two_slotsclause under the draft share clause holds the unset two-slot answer: a--parallel 2server with the draft unset andBLOOMERY_MTP_WIDTH=fixedmust stop before its plan record with the refusal naming the two slots. No band or tolerance moved.cargo fmtis clean on what I touched.Duplication found or removed (
path:line), or "none": none.What I ran
The rule gate on this head, run on an NVIDIA GeForce RTX 5090 (driver 595.99.02):
an_unset_draft_drafts_on_one_slot_onlypins the first boundary at two slots and also holds a setmtp, a setoffand an earlier reason. It fails first when the slot condition indraft_for_slotsmoves fromslots > 1toslots > 2:gate_qwen38_serveneeds a 3090 and the reference build set, which I do not have, so I compiled the changed clauses with the workspace check (cargo check --workspace --all-targetswith the GPU features) and did not run them. Their behavior is unverified here.Throughput
On an NVIDIA GB10:
The checkpoint is
nvidia/Qwen3.8-Flash-Next-FP4-Localatb9ce18a6887e18c089fdea8509a33e63429a3300, served directly from its folder withBLOOMERY_DRAFTunset. A request sends 4096 prompt ids and generates 128 ids with no RAM cache. Greedy groups use temperature 0 and sampled groups use temperature 0.8 with seed 7. The--parallel 4servers use--ctx-size 16896. The metric is decode tok/s over the window in which all requests are generating."Before #682" is the build before #682 added the folder default, "Main" is main with it, and "This PR" is this head.
--parallel 1, decode tok/s--parallel 4, decode tok/sC@4 sampled decode throughput changed by +1.49% against the build before #682 and rose from 28.34 to 62.52 tok/s against main.
On main, C@4 sampled decode fell by 54.00% against the build before #682, and C@4 greedy fell by 12.04%.
For the
--parallel 1row, the first two columns are the values from a--parallel 4server. A one-slot server drafts as before, and its C@1 decode is 52.56 tok/s.The greedy ids of the one-slot server with the draft on equal those of the four-slot server with it off.
Each value is a single observation without a confidence interval. Main and the build before #682 were measured in one session and this PR in another. The throughput runs used the folder server of an earlier head of this branch, whose folder rule is the one on this head. Differences between sessions are about 1.7%, so the -1.62%, -1.53% and +1.49% rows are within that.
What I ran into
This does not block the PR. I did not time a GGUF split server at
--parallel2 or more. The rule applies to it because the same step path runs its rounds, and the serve gate clauses above are the only check of it, which I could not run.Hardware
One NVIDIA DGX Spark (GB10), driver 595.84, CUDA 13.3, for the throughput runs. One NVIDIA GeForce RTX 5090, driver 595.99.02, for the rule gate.
AI help
AI 코딩 에이전트가 코드를 작성한 후 설명을 썼고, 테스트를 마쳤습니다. diff 리뷰와 PR 초안 리뷰는 제가 직접 했습니다.