Skip to content

registry: the dense qwen3.5 family is served on the NPU route, so Qwen3.8-27B-NPU2's packs are not a census gap (Fixes #587) - #1278

Merged
bong-water-water-bong merged 2 commits into
mainfrom
1bit/tissues-587
Nov 6, 2026
Merged

bong-water-water-bong merged 2 commits into
mainfrom
1bit/tissues-587

Conversation

@bong-water-water-bong

@bong-water-water-bong bong-water-water-bong commented Nov 6, 2026 •

Copy link
Copy Markdown
Collaborator

Fixes #587 — the item that was still open at the host level: registering the model on the NPU
route
. The device row the issue asks for already exists in this repository; what did not exist is
a registry that admits the family is served, so the census counted this issue's own model as an
unserved gap.

Root cause. tools/registry_build.py's NPU_ARCHS lists Qwen3_5MoeForCausalLM (the
qwen3_5_moe type, "Qwen3.6-35B-A3B") and never the dense qwen3.5 class, so
registry/architectures.json mapped the whole dense qwen35 family hrx-only — while
FastFlowLM/Qwen3.8-27B-NPU2 (Qwen3_5ForConditionalGeneration, model_type qwen3_5) is the
container this repository has measured NPU rows for since 2026-10-27. The route does not refuse it
at load, so the registry column was describing a refusal that does not happen.

Measured effect (host-side, no device). tools/census_watch.py --full, before vs after this
branch, on the live FastFlowLM org:

origin/main this branch
Q4NX packs "for a family the NPU route does not serve" 38 (incl. qwen35 (12 packs)) 26 (no qwen35 line)
FastFlowLM/Qwen3.8-27B-NPU2 line registry Qwen3_5ForConditionalGeneration -> qwen35 (no route) … -> qwen35 npu route: qwen3_5
registry/architectures.json counts.npu 7 9

The measured proof for "served", from this repo, not asserted here: int8 Q4NX on the NPU route
decodes at 63.1 s/token and takes 145.7 s to a first token
(bench/npu-leaderboard/27b-*.json, 2026-10-27), a 5-token prefill chunk is 58.14 s, and the
ternary sealed-ELF rung on the same container is 1.72 s/token with 3/3 text-identical
output (engine#697, closed 2026-11-01 by #728, merged 46353fe9). Today's fresh end-to-end run is
not in this PR and the body does not pretend otherwise: the first attempt was a 9-minute
npu-hold ticket (§ rule 1), it took the token after 172 s and then blocked 245 s on
/tmp/1bit-npu-device.lock, which an orphaned host-GEMM serve (pid 2231177,
~/wt/issue1035-npubuild, :18095, alive since 11:28, no /dev/accel fd) holds exclusively
outside the FIFO. Two other lanes are blocked on the same process; it is escalated, not worked
around.

Scope. NPU_ARCHS gains the family's two text-LM classes (Qwen3_5ForCausalLM,
Qwen3_5ForConditionalGeneration → qwen3_5) and deliberately not Qwen3_5Model, the bare vision
wrapper: the vision tower is a separate vision_weight.q4nx this route does not load.
registry/architectures.json regenerated against the pinned llama.cpp (--check clean).
docs/npu.md's qwen35 row goes from "not served: no NPU kernel set" to the measured answer, with
what a stock install still lacks named (a kernel set for the geometry — none ships here), and the
fast-lane sentence gains qwen3_5. docs/registry.md's npu row stops pretending the column is
just qwen3.

Tests. tests/census_watch_test.py failed 5 checks after the change, and rightly: its NPU-gap
fixtures used D3-Mini (qwen3_5_text → qwen35) as the HRX-only example. D3-Mini now asserts the
new truth (npu, npu_model_type=qwen3_5, not npu_gap), and the guard's firing path keeps a
real example — a FastFlowLM/Gemma3-12B-NPU2 listing (gemma3 is HRX-only in the live registry
and FLM ships those packs) driven through sweep_org + report_flm, plus a new check that a moved
NPU-served pack does not alert. npu_flm_families drops qwen35 and gains three explicit checks
including "the bare vision wrapper is not claimed". All pass, as do registry_gaps_test.py,
npu_leaderboard_test.py, check_pins_test.py, bump_workflow_report_test.py,
registry_build.py --check and copyright.py --check.

Measured on the device as well (second commit a3139ade). After the device lock cleared, one
npu-hold ticket produced three leaderboard records for this container on the sealed single-ELF
ternary rung: decode 0.2902 s/token (3.45 tok/s) as the slope between completion lengths
((n5−n1)/4 = 0.2884, (n9−n1)/8 = 0.2920, agreeing within 1.3 %, 3 repeats each), prefill
19.55 tok/s
as the marginal cost of a prompt token (51.1 ms/token over 24 extra tokens), and
22.811 s to a first token cold with the container load inside it. Same container, whole
progression: 63.1 s/token int8 → 1.72 s/token per-role PB16i (engine#697) → 0.2902 s/token here.
Caveats are in the records: no prefix cache was shared (flm_prefix_cache said so per request), the
model answers in reasoning_content so token counts are what is measured, and prefill is the per-op
path answering one prompt at a time (not 32-token-chunk throughput).

What this PR still does not claim: the hybrid-prefill probe (item 3) keeps its recorded answer
("recommended against", #587 comment 2026-10-27) — and the 19.55 tok/s prefill row above is the
number that keeps it true, since HRX prefill on the same box is ~287 tok/s. No KLD-vs-BF16 or
GSM8K n=40 rows are added: both need a reference pass and ~2 h of decode at 0.29 s/token, which is a
separate ticket. They are listed on the issue with the exact commands so the close does not lose
them.

… FastFlowLM packs are not a gap (Fixes #587)

`tools/registry_build.py`'s NPU_ARCHS listed only the MoE qwen3.5 class
(`Qwen3_5MoeForCausalLM`, "Qwen3.6-35B-A3B"), never the dense one, so
`registry/architectures.json` mapped the whole dense qwen35 family `hrx`-only. The daily
census-watch answered from that file, so it reported `qwen35 (12 packs)` under "Q4NX (NPU) packs
for a family the NPU route does not serve" - including `FastFlowLM/Qwen3.8-27B-NPU2`, the model
this issue is about, which this repository has measured NPU rows for since 2026-10-27.

The route does not refuse that container at load: it decodes it at 63.1 s/token and takes 145.7 s
to a first token (`bench/npu-leaderboard/27b-*.json`), a 5-token prefill chunk is 58.14 s, and the
ternary sealed-ELF rung on the same container is 1.72 s/token at 3/3 text-identical output
(engine#697, closed by #728). What a stock install lacks is a kernel set for the geometry, not the
model type - which is why the docs row now says that instead of "not served".

NPU_ARCHS gains the two text LM classes of the family (`Qwen3_5ForCausalLM`,
`Qwen3_5ForConditionalGeneration` -> qwen3_5) and deliberately not `Qwen3_5Model`, the bare
vision wrapper: the vision tower is a separate `vision_weight.q4nx` this route does not load.
Regenerated with the pinned llama.cpp: npu 7 -> 9, `--check` clean.

Measured effect on the census, `census_watch.py --full` before vs after: 38 -> 26 Q4NX packs under
"a family the NPU route does not serve" and no `qwen35` line at all; `FastFlowLM/Qwen3.8-27B-NPU2`
now prints `registry Qwen3_5ForConditionalGeneration -> qwen35  npu route: qwen3_5`.

tests/census_watch_test.py failed 5 checks after this and was right to: its NPU-gap fixtures used
D3-Mini (`qwen3_5_text` -> qwen35) as the HRX-only example. D3-Mini now asserts the new truth, and
the guard's firing path keeps a real example (a `FastFlowLM/Gemma3-12B-NPU2` listing; gemma3 is
HRX-only in the live registry and FLM ships those packs) through `sweep_org` + `report_flm`, plus a
new check that a moved NPU-served pack does not alert. docs/npu.md's qwen35 row and the fast-lane
sentence carry the answer with the numbers and the engine#697 provenance.
@bong-water-water-bong

Copy link
Copy Markdown
Collaborator Author

#1278 ready for review at 9040fc9 (5 files: tools/registry_build.py, registry/architectures.json, tests/census_watch_test.py, docs/npu.md, docs/registry.md; Fixes #587). Host-only: no device, no kernel, no ELF.

@bong-water-water-bong bong-water-water-bong left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

VERDICT: READY at 03ef6d7f — the registry regenerates byte-identically from the tool at this head, and I reproduced the census before/after against the live Hub: 38 → 26 packs, with exactly the 12 qwen35 packs leaving the list and FastFlowLM/Qwen3.8-27B-NPU2 moving to served.

Generated artifact. python3 tools/registry_build.py (needs third_party/llama.cpp checked out; I initialized it at the pinned 32559003a) → wrote … architectures.json: hrx 298, npu 9, architectures 298, mapped 298, byte-identical to the file in the PR (git status clean). So the committed JSON is the generator's output, not a hand edit.

The route claim, main vs this head (registry/architectures.json, architectures map):

HF class origin/main this head
Qwen3_5ForConditionalGeneration {"gguf":"qwen35","backends":["hrx"]} {"gguf":"qwen35","backends":["hrx","npu"],"npu_model_type":"qwen3_5"}
Qwen3_5ForCausalLM {"gguf":"qwen35","backends":["hrx"]} same, npu + qwen3_5
Qwen3_5MoeForCausalLM hrx, npu (qwen3_5_moe) unchanged

and Qwen3_5Model (the bare vision wrapper) is still unclaimed, which is what the NPU_ARCHS comment says it should be.

The census, run twice on this box against the live org (tools/census_watch.py --full, swapping only registry/architectures.json between the two runs):

origin/main registry :  -> 38 Q4NX (NPU) pack(s) for a family the NPU route does not serve: … qwen35 (12 pack(s)) …
this head   registry :  -> 26 Q4NX (NPU) pack(s) for a family the NPU route does not serve: dflash 1, gemma-embedding 1,
                           gemma3 7, gemma4 4, gpt-oss 2, hunyuan-dense 1, hy_v3 1, lfm2 6, phi3 1, qwen2vl 1, qwen35moe 1

38 − 26 = 12, the qwen35 line is gone, and FastFlowLM/Qwen3.8-27B-NPU2 prints with a + instead of !! … npu route: no. The residual qwen35moe (1 pack) is a different gguf family (qwen35moe, served for the text arch) and is honestly still counted.

The measured rows the new doc text cites are the records in the tree, to the digit: 27b-npudx-20261027 decode 63.1 s/token, 27b-first-token-after-transpose-20261027 145.7 s, 27b-prefill-batched-20261027 prefill 58.14 s; and the ternary rung's provenance checks out too — engine#697 CLOSED 2026-11-01T02:50:16Z, engine#728 MERGED 2026-11-01T09:51:49Z.

tests/census_watch_test.py → all checks passed (it grew the arms for the token fallback and the 401 path, and they are the reason the census above could run unattended). Docs are in the same PR as the behaviour (docs/npu.md family table, docs/registry.md's npu row now pointing at NPU_ARCHS as the source of the list). Fixes #587, which is still OPEN, is the right close: the route is what was missing at the host level, and the pack the issue names is now served and counted served.

One caveat I want on the record rather than in a nit: the census is live-Hub data read tonight, so 38/26 are this evening's org, not constants; the delta (the 12 qwen35 packs) is the part the PR changes and it is what I reproduced.

@bong-water-water-bong
bong-water-water-bong merged commit 918f731 into main Nov 6, 2026
8 of 9 checks passed
@bong-water-water-bong
bong-water-water-bong deleted the 1bit/tissues-587 branch November 6, 2026 19:38
@bong-water-water-bong

Copy link
Copy Markdown
Collaborator Author

Measured on the device after all — second commit a3139ade on this branch. The blocker cleared (the orphaned host-GEMM serve released /tmp/1bit-npu-device.lock at 16:28:30), and my attempts then failed twice on my invocation, not on the model: --kernels must be the kernels-m16 subdirectory (18 _t2s2-tagged ELFs incl. the sealed one), and the binary the keeper serves this rung with is ~/wt/serve-bin/t2s2-20261104/1bit, not the older 11-02 one. Reading the keeper's own launch line fixed both.

Three leaderboard records, one npu-hold ticket, greedy, one 13-token prompt, --kernels …/kernels-m16, port 18099, clean exit, 0 amdxdna errors in the window:

metric value how it was taken
decode 0.2902 s/token (3.45 tok/s) slope between completion lengths so prefill and per-request cost cancel — (n5−n1)/4 = 0.2884 and (n9−n1)/8 = 0.2920, agreeing within 1.3 %, 3 repeats each: n=1 0.9537 ± 0.0038 s, n=5 2.1073 ± 0.0150 s, n=9 3.2900 ± 0.0105 s
prefill 19.55 tok/s marginal cost of a prompt token, two prompt lengths: 51.1 ms/token over 24 extra tokens (t37 2.1810 ± 0.0344 s vs t13 0.9537 ± 0.0038 s)
first token 22.811 s cold /health answers ~4 s after launch before the container loads, so the load is inside the first request; the same prompt warm is 0.9537 s

The same container now has the full progression on the leaderboard: 63.1 s/token + 145.7 s first
token
on the int8 rung (2026-10-27) → 1.72 s/token on the per-role PB16i set (engine#697) →
0.2902 s/token here. That is what makes the qwen35 row's "served" claim in this PR a measurement
rather than a citation, and it is why docs/npu.md's row and the regenerated
docs/npu-leaderboard.md (22 records valid) carry it.

Caveats written into the records rather than left implicit: the route reported flm_prefix_cache: no slot shares a prefix on every request, so no prefix cache is inside these numbers; the model answers
in reasoning_content (content is empty at these budgets), so the token counts are what is measured;
prefill here is the per-op path answering one prompt at a time, so it must not be read as 32-token
chunk throughput — which is also why the hybrid answer stays "recommended against" (HRX prefill on
the same box is ~287 tok/s). Per-request JSON and the driver are kept at
~/evidence/tmoe-npu/587-27b-row-20261106/.

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.

NPU: Qwen3.8-27B-NPU2 (FastFlowLM Q4NX, 17.1 GB) on the NPU route and as the hybrid prefill side

1 participant