Prompts under 64 rows hit the Original's literal RegionTooSmall fallback in the MMQ draft-KV recorder and then ran the scalar prefill on a
standalone owner whose scratch bank is not paired with the ring's main arena (validate_original_main -> InvalidQwenShape ->
InvalidDimension). The drafter now lends its stream to its own scalar owner (OriginalMtpDrafter/Actor::record_scalar_prefill).
Real model, RTX 5090: the 19-token and 56-token prompts of the smoke corpus now serve (16 resp. 10 tokens, the latter ending on <|im_end|>).
Structural evidence only; no numerical claim.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
- backend_original_serve_smoke.rs: LELEKA_SMOKE_PROMPTS (one text prompt per line) is tokenized with the verified tokenizer,
served greedily for LELEKA_SMOKE_MAX_NEW tokens (LELEKA_SMOKE_MIN_P sets spec_min_p) and printed as ids so the Original
(strata --tokens-file ...) can be run on the same ids.
- original_serve_native.rs: LELEKA_TRACE_LOGPROBS=<k> prints the top-k head logprobs of every row of each completed verify window
through OriginalVerifier::window_logprobs_topk (same format as the Original's STRATA_LOGPOS/STRATA_LOGPOS_TOPK).
First measurements against the Original (5 prompts, 64 greedy tokens, same settings): identical on 1 prompt, divergences on the
others after 4..28 tokens; per-row top-8 logprobs differ by a median of about 0.4 (max 2.3). Not parity; investigation continues.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Findings fixed on the way (all from running the ignored original_serve_smoke against the pinned IQ3_S shards, sealed KAR memfd,
pinned MTP pack and resident expert source; CUDA 13.2.86, sm_120, driver 595.99):
- mtp_original_prefill.rs: the batched draft-KV recorder asked the ring for separately owned DeviceBuffers 0..5, but the serve ring
is built from prepared spans of the shared region (ring.buffer(i) -> ContextPoisoned). The overlap checks now compare addresses
via ring.address(i), which handles both layouts.
- session_original_draft.rs: a published speculative draft leaves the MTP ring AHEAD of the committed target (e.g. snapshot 116 vs
target 114); validate() and rebind_restored() demanded equality and refused the next round. They now require snapshot >= target.
- original_serve_stack.rs/engine: the MTP drafter is sized at the verify width (mtp_load_t = max_t = 6) like generate.cpp, while the
chain stays capped at 3 drafts (c7b5a08 from claude/serve-preflight).
- smoke: loads the resident expert source, long (114-token) first prompt so the batched draft-KV path (>= 64 rows) is taken, short
prompt (scalar draft-KV path) last and reported instead of asserted: it still fails with InvalidDimension (open item).
Bring-up instrumentation (to gate or remove before merge): DBG/PROBE eprintln lines, TracePort (logs every OriginalServePort call),
PoisonCell (backtrace of the first context poisoning with LELEKA_TRACE_POISON=1), micro_driver_error tracing.
Structural/behavioural bring-up evidence only: no parity, quality or performance claim yet.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
generate.cpp rewrites o.spec to min(spec+2, 8) (generate.cpp:1535-1537) before mtp.load(..., o.spec, ...) (:2610), so the
drafter accepts every window the verifier runs (suffix drafts reach the verify width) while its chain stays capped by
set_max_drafts(S_mtp - 1). The Rust stack loaded it at settings.mtp_max_t (4): the first T=6 window made
OriginalMtpDrafter::draft_inner refuse (rows > max_t, mtp_original_full_drafter.rs, 2 us, InvalidQwenShape -> InvalidDimension).
OriginalServeSettings::mtp_load_t() (= max_t) now sizes the executor's scalar prefill, the shared layout and the actor.
max_drafts() stays 3.
The synthetic probe now runs the serve round shape (T=1 window+commit+draft, then T=6 with accepted_row 0..5, commit, draft
anchored at the previous speculative snapshot, max_drafts 3, coupled false): PROBE_MTP_MAX_T=4 reproduces the failure, the
default 6 passes for every accepted_row. Structural only; no numerical claim.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Verifier window T and MTP max_t default to the serve settings (6 and 4). PROBE_NO_RELEASE=1 reproduces the pre-fix failures.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The serve stack assembles a NEW verifier bank per request, but the MTP drafter bound itself to the first one: the direct-mode
round programs captured that bank's final-R span and retain its completed window (OriginalMtpDraftProgram::direct_window),
and the full-forward tail keeps the last staged window until the next stage. Two consequences, both reproduced by the
synthetic two-request probe: (1) OriginalVerifier::close fails with InvalidQwenShape after any request that drafted (the
bank Rc is still shared), so disassemble() reports Err and the stack is marked broken after the first request; (2) the
second request's first draft is refused by stage_round (11 us, InvalidQwenShape) because the new bank's R is another address.
OriginalMtpDrafter::release_verifier_bindings drains the draft stream, closes the cached round/step programs, drops the staged
window and forgets the direct mode; OriginalMtpActor and OriginalPromptExecutor::mtp_release_verifier expose it and
decode_phase calls it before disassemble. The next request re-captures its draft graphs (about 2 ms in the probe). The ring,
scalar prefix and weights are untouched. Structural fix: no numerical or performance claim.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
record_all over every ggml projection kind / expert format / shared-expert kind, then three windows (T=1,2,max_t) with a
zero-filled stand-in for the CPU expert pool, synchronous and asynchronous commit and the committed reads the serve host
makes. No model weights are read; the stand-in weights are uninitialised device memory of the exact sizes.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
OriginalVerifyQsaJournal::complete_commit required every mapped K/V journal to already stand at position+keep, but nothing
advances a journal for a verifier window: the window graph's mtp_original_append writes the resident pool and the host
copy on the GPU, and commit_mapped_prefixes (the only publisher) needs OriginalQsaMappedAppend receipts that only the prompt
path produces and is never called. Every first commit of the first decode round therefore failed with InvalidQwenShape and
poisoned the context. Found with the model-free synthetic verifier probe (replay + commit over zero weights).
complete_commit now checks that every journal stands at the window position and advances all of them together to
position+keep (publish_window_rows) before the index half is published. Structural fix only: the probe shows commit and
the following committed reads succeed over synthetic weights; no numerical or quality claim, not compared with the Original.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Ignored GPU probes in the print-per-step style of the existing bring-up probes; no model is read, nothing numerical is checked.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
bf16_f32_mmvf, gr_fixed and gr_batch_preview do mov.u64 R, shared_sym followed by
cvta.to.shared.u64 R, R. sm_120 tolerates it, sm_86 faults (CUDA error 700 in
full_matrix_transport_gpu dense-bf16-gdn-z on the RTX 3080 Laptop). The sm_86
companions omit the cvta; sealed sm_120 files are untouched; verified by the
smoke passing after the change.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Default build unchanged (arch_ptx::image is the identity without the feature,
sm_120 PTX and all pins untouched). With --features sm86 every cuModuleLoadData
site hands its sealed image to arch_ptx::image, which on a device with
8.6 <= cc < 12.0 looks the image up by the SHA-256 of the sealed sm_120 body in
the generated table and admits the companion only through sealed_ptx::pinned.
The four sm_120-only capability gates (MMQ resident, scalar/full/prefill MTP)
accept sm_86-class devices under the feature. leleka-runtime and
strata-desktop-core forward the feature. run_gpu_smokes.sh: SMOKE_SM86=1 adds
it to the test builds.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
121 companions of the 121 sealed sm_120 PTX (120 retargeted, 1 recompiled),
nvcc/ptxas 13.2.86 from deploy/cuda-toolkit.lock.json. Structural claims only:
ptxas -arch=sm_86 accepts each file, same .entry names and parameter counts as
the sealed original. Not wired into any build yet.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
scripts/gpu-bringup/sm86_assets.py: survey / infer / build / compare / check.
Default method is retarget (the sealed text with the .target line and two
documented sm_90+ rules edited, accepted only if ptxas -arch=sm_86 accepts it);
recompile from the .cu is the fallback and needs a recipe verified by a round
trip on sm_120. sm86-recipes.json is the round-trip evidence.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
- crates/cuda-driver/tests/original_{arena,executor}_probe.rs: ignored probes that create the expert-group arena and the
prompt-executor device objects without a model (seconds instead of a 15 minute model load).
- backend_original_serve_smoke.rs: load the resident expert source (the serve stack requires it) and print DBG progress.
- cache_original_prompt.rs and mmq_original_group.rs: DBG/PROBE eprintln tracing. Bring-up instrumentation; gate or remove
before merge.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
First real-model bring-up on the RTX 5090 (CUDA 13.2.86, sm_120) stopped at four build-time gaps:
- mmq_original_group_{swiglu,mul,fixup}.ptx and kernels/mapped_expert_copy.ptx were placeholders; compiled with
nvcc 13.2.86 (scripts/gpu-bringup/compile_assets.py + seal_pins.py for the MMQ group) and pinned.
- mtp_original_scalar_{norm,gr}.ptx were placeholders that make OriginalPromptExecutor::new fail closed; compiled with the
recipes of docs/cuda-seal-plan-additions.json against engine/strata headers, stored with a trailing NUL.
- ffi.rs mmq_shared() allowed only widths <= 64; added the eight sizes the same shared() formula gives for widths
80..128 (51520..61952), all below the 101376-byte opt-in limit of the device.
- native_prompt_device.rs PLE_SHA did not match the committed ple_prompt_device.ptx (CUDA 13.0.88 build); re-pinned to the file.
Structural/build evidence only: no numerical, quality or performance claim.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Pin matches the checked-in PTX (length + sha256), PTX is real sm_120 with every
named entry exported, and the pin guards still refuse one-byte-corrupted,
wrong-length, wrong-digest, zero-pin, embedded-NUL and unterminated synthetic
copies. Refusals that relied on 'unsealed' are re-expressed with corrupted-pin
copies. GPU load is verified separately by the host smokes; no numerical claim.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Adds the six audited assets (head_native, original_verify_qsa, router, gr_post,
gr_norm, ple_native_batch) as an atomic reseal group built with --use_fast_math,
re-pins their old digests (incl. ple PTX_BYTES) and window-plan hex, and a
generic --flag-override recorded in the manifest and re-applied by the sealer.
compile_assets --isa-inventory/--driver-check and run_gpu_smokes.sh refuse a
driver older than the highest PTX ISA in the tree (9.0 needs >= 580.65.06).
Runbook: mandatory reseal + golden comparison section, step d' (linux-tests).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
A virtual 8.6e9-element expert bank (group 96, section above 4 GiB) is never
allocated: archive bytes are a hash of the absolute offset, the planner and
kernel model decode first/middle/last-expert windows and the final partial
group, and every element is compared bit for bit with a per-element decode
written straight from the format definition. No defect found.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
- check-cu.py now defaults to clang -x cuda --cuda-host-only with real qualifiers; --plain keeps the C++-only pass.
- qsa_prompt_attention_variants.cu: block_q4_0 under pack(1) as in kv_q4.hpp (cu_pin refreshed).
- native_head_native.cu: orphan copy had __launch_bounds__ before extern "C" __global__ (never nvcc-built); now the sealed twin's text.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>