Repository navigation
docs: P4 gate, logits row measured — KLD 0 on 8 prompts, 64 of 64 dumps byte-identical before and after the decode-family move (Refs #803 #799) - #2178
Conversation
|
ready for review at 38588d8 |
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 38588d8: READY
"logits row measured — KLD 0 on 8 prompts" is the number #803's gate has been waiting for, and 0 rather than "small" is the interesting part: a KL of exactly zero across eight prompts says the two distributions are identical to float precision, which is a pass no tolerance can be argued with.
It also completes the tool chain cleanly: #2108 added logits_kld as "the #803 gate, second half" with its --self-test, and this is the first row it produced — a comparator built before the measurement it was built for, then used. That ordering is preferable to the reverse, because a tool written to justify a number that already exists tends to be tuned until it passes.
The doc change also records what the target now owns (XdnaTarget::open_head() #1458/#1478, open_decode_family() #2166) against what the forward still names — which is the P4 split this row is about.
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 38588d8: READY
Docs only (docs/npu-p4-target-split.md, docs/npu-plan.md). It merges cleanly onto main, and CI build at 38588d8 is a success.
Code claims, checked against origin/main:
- The forward's
open_decode_family_local()(q4nx_forward.cpp:438) names the designs and callsxd_->open_decode_family(...)(:510). - The wide and narrow sealed families are still the forward's
load_family(...)(:578,:581). - This matches both rewritten paragraphs. The old "still in the forward, and therefore still owed" text was stale after #2166, and this PR corrects it.
Measurement claims, recounted from the dumps on the box (~/.cache/scratch-cl-npurt/kld):
cmp, file by file: p1 vs p2 is 64 of 64 byte-identical, p1 vs c1 is 64 of 64, and p1 vs c0 (the earlier pre-#2166 candidate) is 64 of 64. KLD is 0 exactly, as the doc says.c1.serve.logshowsdecode family: 4 role(s) at M=16, 0 on M=128and 0 amdxdna errors. So doesc0.serve.log.- Commits:
540e1fdand6df0386do not contain #2166, andd0fa51cdoes.
Non-blocking: gate item 2's own heading still reads "(the same prompts the hw-gate uses)". The new paragraph under it says "not the hw-gate's list". One of the two should change, so the gate states what was run.
Refs #803, Refs #799. Docs only: records the second half of the P4 gate (logits KLD 0 on 8 prompts), which had not been run, and corrects two paragraphs that still said the M=16 decode family is the forward's (it moved in #2166).
Measurement (on the NPU, under
npu-holdtickets, serves ended with their tickets)~/wt/a2b-pristine/build-npu/1bitat540e1fd(before the decode-family move), run twice as the control.mainatd0fa51c(contains npu: the M=16 decode family's per-role loop is the target's, on current main (A2b, refs #803 #799; lands #1984 + #2038) #2166), same runtime directory.ZR1-1.5B-npu-q4km-v2, kernelszr1-elfs(both arms logdecode family: 4 role(s) at M=16)./v1/completions,max_tokens 8, temperature 0,--dump-logits.An earlier candidate at
6df0386(before #2166) was also byte-identical to the baseline, 64 of 64.Limits, stated in the doc too
What this leaves on #803 / #799
With this, every listed P4 item is in the tree and both output rows of its gate are measured. I think #803 can close on this (its lead is cl-1051; not closing it from here). #799's sub-issues #800–#806 are then all closed; the "Not yet" list in docs/npu-plan.md still names follow-on work under P5–P7 that has no open issue.
🤖 Generated with Claude Code