Repository navigation
Preserve Bolt target arithmetic across speculative verification boundaries - #2916
Conversation
Segment native R8 verification at the pinned H128 Flash split-K key-tile boundary and merge only generator-owned recurrent, logits, auxiliary and prediction snapshots. Preserve ordinary decoding, fixed buffer addresses, rollback behavior and actual target-pass accounting. Add complete live ordinary/k7 token and finite-state comparisons, identical-candidate replay and reset-reuse coverage. The preserved 30-case suite passes twice (60 comparisons and 27,326 boundaries); LCB145 matches all 512 tokens twice. Independent HuggingFace fidelity remains unqualified. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: rui-ren <ruiren1225@gmail.com> (cherry picked from commit 4ef79a1a24a66c1e32085325a7980f8f658be5f6) Signed-off-by: rui-ren <ruiren1225@gmail.com>
The conventional split package stores embedding copies in distinct data files and regions, unlike the native shared blob. Check the registry's file identity, numeric range, dtype, shape and device scope, asserting sharing for equal keys and distinct entries otherwise. Retain all reset, rejection, public-boundary and numerical checks; no inference or package changes. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: rui-ren <ruiren1225@gmail.com>
GenAI uses its own fs::path wrapper, which does not implicitly convert to std::filesystem::path. Pass resolved path strings to the file-identity check. The complete native test translation unit passes the original compiler's syntax check. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: rui-ren <ruiren1225@gmail.com>
Accept a separate ordinary-only R1 graph while retaining eight recurrent slots and the existing R8 attention geometry. Keep the normal package and speculative verification unchanged. Add live committed-state and token comparison against R8, including graph capture and reset. This is an experimental path pending runtime qualification and throughput measurement. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: rui-ren <ruiren1225@gmail.com>
Use an opt-in dynamic-row target graph, persistent query-row indices, and one-row tensor views over existing buffers. Capture both row geometries in the same session, retaining the original R8 attention geometry and R8 prefill to avoid the static-R1 TTFT regression. Preserve target-forward counters and keep the normal R8 package unchanged. Extend live-state capture/reset comparison across the 128-key boundary and preserve exact sequences and state-comparison receipts. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: rui-ren <ruiren1225@gmail.com>
Allocate the eight-row backing tensor in NemotronBoltState, not while validating model metadata. Keep the symbolic session contract intact for the captured one-row view. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: rui-ren <ruiren1225@gmail.com>
Convert a flat packed R8 package into dynamic R8-prefill/R1-decode geometry while retaining packed initializer bytes and external ranges. Hardlink large payloads inside the new package instead of disabling path validation or duplicating weights. Document the required Mamba readout correction and ordinary-only scope. The converter reproduces the exact graph and config used by the live-state qualification and real30 candidate; C++ sources are unchanged from d73a6e6. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: rui-ren <ruiren1225@gmail.com>
Qualified opt-in ordinary decode: about 27% fasterUpdated the actual stack33967 tip The ordinary decoder was computing eight target rows while committing only the first. R1 also exposed a real Mamba inconsistency: its readout reduced two partials while R8 Unprofiled frozen real30, six H100s, two reversed same-GPU passes, 240 complete measured
Ordinary TTFT medians: short 357.35→359.00ms, medium 826.97→831.29ms, Separate same-GPU synthetic-2048 CUDA profiles, 64 captured target passes: Correctness: all240 exact same-mode sequences and complete counters match; Scope: hybrid is ordinary-only. Both speculative arms use the original R8 package. Reproduce the exact tested graph/config with: python examples/python/nemotron-bolt-hybrid.py --input <packed-r8> --output <fresh-same-filesystem-hybrid>Requires onnx-ir/numpy/ml-dtypes and both updated runtimes. External-data validation Pins:
Full commands, per-case exact tokens/counters, raw kernel traces, provider maps, |
Dependency and scope
Draft correctness follow-up to #2890, based on its exact head
f1a3c6c79532bc2db8b809ce99d1357a453bd722through the existing upstream mirrorrui-ren/bolt-stack-20261104/06-drafter-graph-replay.The original #2867 -> #2868 -> #2890 branches and PRs are unchanged.
This is not the separate-prefill change in closed #2891.
Published source is the already-qualified commit
c0fd01914265d5157d6da1376c38b4df521a76c5: four files, including documentationand regression tests. No source was changed or rebased for publication.
This is a fork-based dependent PR; no native stack registration is claimed.
Issue
The pinned native H128 Flash attention route partitions split-K work using the
padded endpoint of each fixed-R8 call. A speculative block crossing a 128-key
arithmetic boundary can therefore use different BF16 attention arithmetic from
target-only row-zero decoding, despite identical queries and valid-prefix KV.
Small numerical differences can change predictions and break ordinary/k7 token
identity. Changing acceptance logic alone does not address the source.
Change
the native fixed-R8 graph.
prediction IDs and auxiliary rows on device before acceptance. Do not copy
ordinary/reference state or change attention kernels, weight precision,
padding policy or cache ownership.
acceptance/round accounting.
independently advancing ordinary/k7 live-state/reset regressions.
file identity, dtype, shape and device keys, including GenAI path strings.
Those follow-up changes affect tests, not inference.
Validation and provenance
build receipt before publication.
NemotronBolt.VerificationKeepsQueryEndpointsInOneKeyTile: 1 passed,zero skips. Git whitespace checks passed.
of the native/private ORT package and [CUDA] Consolidate source-exact BF16 decoding into existing contrib operators onnxruntime#33940's equivalent
public package. Two reversed-order passes over the frozen 30 real prompts
checked 240 complete measured generations. Every complete generated
sequence matched the frozen quantized ordinary-control sequence, and complete
speculative counter dictionaries matched across compared runs.
tensor/state comparisons per variant, and the full 512-token LCB145
ordinary/k7 probe. The public ORT package required no additional GenAI change.
5859c053086adc11578bbfb618dfeb84d01447f570fea4bd99a9fe5acbd865b0.eb33580c8eca54cfe37f5da62539a31a2dcb5f677175aefdb55ff480d29d3469.76d4aa528bc00aa0264c44415551a1df4f63147679ea853569f0f97cb0906cbd.The throughput difference in the ORT comparison is not a speedup caused by
this GenAI fix: both arms used this same source and binaries. Segmentation can
require an extra real target pass; correctness and truthful counters take
precedence over historical non-lossless k7 timings.
Limits
This is qualification of the pinned Bolt/H128 route and frozen quantized
control, not a generic attention-backend guarantee, new independent HuggingFace
accuracy qualification, full benchmark-suite accuracy rerun or main-branch CI
acceptance. The build was incremental with recorded inputs, not a fresh full
build from main. The new GPU fixtures require explicit model/token fixtures;
the publication-time one-test CPU run is not presented as executing them.
Keep this PR draft pending normal review and CI.