Commit Graph
73 Commits
Author SHA1 Message Date
Pavlo RatushnyiandClaude Sonnet 5.5 c0190bdb6d feat(cuda-driver): sealed prefill_stage PTX (chunk-wide PLE decode, embedding broadcast, GR/GDN kernels with folded guards, element-parallel dequant)
New precise-recipe asset (extra-seal-plan group prefill-stage, nvcc 13.2.86), sealed with compile_assets.py/seal_pins.py, with its sm_86 companion.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-17 02:04:42 +02:00
Pavlo RatushnyiandClaude Opus 5.5 3e05437bf2 merge: claude/laptop-profile (RTX 3080 laptop: mapped experts instead of a 50 GB RAM copy, KAR read-only file source, resident RAM budget, regenerated sm_86 resolver image, paired bench harness, docs/laptop-profile.md)
Laptop numbers (indicative, 3 prompts x 2): Original decode 8.15 tok/s / TTFT 7.2 s (KAR PLE), port 2.70 tok/s / 28.4 s;
both bottlenecks (serial CPU expert preparation, prompt-path expert copies) are being fixed on claude/pool-zero-copy and
claude/prefill-throughput. model-format now denies (instead of forbids) unsafe code for one audited mmap owner.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 13:10:56 +02:00
Pavlo RatushnyiandClaude Opus 5.5 c9845eed52 fix(experts): split bank copies at page-locked boundaries; Original bench without the subcommand
With part of a file-mapped bank page-locked (`pin_resident`), an H2D copy that starts in registered pages and
runs into unregistered ones is refused by the driver (CUDA_ERROR_INVALID_VALUE, first seen on the laptop run).
`MappedExpertBank::copy_pieces` cuts a `cache_source` slice at every registered boundary and the four copy
sites (prompt copy ring, cache fill, swap fill, PCIe staging) issue one copy per piece; one piece when nothing
is locked, so the default path is unchanged. original_bench.sh: the `strata` binary takes the generate
options directly.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 12:49:53 +02:00
Pavlo RatushnyiandClaude Opus 5.5 e9995d8ec3 merge: claude/numerics (parity tooling: KAR PLE row parity test, opt-in residual/ladder/PLE traces, comparison scripts)
Result recorded in LeaseVibe: port vs Original deviation equals the Original's own deviation between its expert settings
(median max |dlogprob| 0.292 vs 0.287, top-1 differs 4/120 vs 3/120); KAR PLE rows bit-identical (1744/1744).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 11:57:37 +02:00
Pavlo RatushnyiandClaude Opus 5.5 84a6817a5a diag(numerics): ladder comparison tools, CPU-expert Original arm, logprob comparators
Results (3 prompts x 41 teacher-forced rows): port vs Original agree exactly
at the embedding and the first GDN half; relL2 of the residual then grows
smoothly with depth (1e-3 after layer 0 FFN, ~1e-2 by layers 8-13, 5-15e-2
by layers 28-44). The Original's own GPU-expert-cache vs CPU-expert arms show
the same profile and the same logprob spread (median 0.287 vs port 0.292).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 11:57:00 +02:00
Pavlo RatushnyiandClaude Opus 5.5 bbba0f231d bench(laptop): paired Original/port harness on fixed pre-tokenized prompts
* tokenizer example `chat_tokens`: one user turn per line, thinking off, to comma-separated IDs, so both
  engines get exactly the same token IDs (benchmarks/laptop/prompts.txt: 3 prompts, 78-88 tokens).
* leleka-runtime ignored test `original_serve_laptop_bench`: opens the Original serve stack with the
  low-RAM sources (mapped experts, read-only KAR file; resident/memfd still selectable), serves every prompt
  REPEAT times greedily and prints TTFT, prompt/decode phase times, prefill/decode tok/s, memory and the
  output IDs of the first pass.
* scripts/laptop: original_bench.sh drives the unmodified `strata generate --serve` (setup.py's IQ3_S
  arguments, conversation cache off, one GEN at a time, TTFT to the first T line); port_bench.sh runs the
  test; monitor.sh samples process RSS/anon/file/shmem/locked/pinned and GPU VRAM once a second.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 11:27:46 +02:00
Pavlo RatushnyiandClaude Opus 5.5 2262072206 merge: claude/kv-streaming into the bring-up branch
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 10:56:28 +02:00
Pavlo RatushnyiandClaude Opus 5.5 6917f7c704 chore(bring-up): register the KV GPU proofs in the qsa smoke group and regenerate the smoke table
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 10:54:29 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 b62a37abaa diag: opt-in port residual/ladder/PLE-row traces and offline Original-comparison scripts (build not yet verified on the server)
LELEKA_TRACE_RESIDUAL=<dir> dumps the final R of each verifier window,
LELEKA_TRACE_LADDER adds a per-hc_read R ladder (2 frames per layer),
LELEKA_TRACE_PLE prints the PLE row ids per window row. scripts/numerics
holds the patch scripts for a private copy of the Original (not applied to
engine/strata) and the comparison tools.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 10:45:58 +02:00
Pavlo RatushnyiandClaude Opus 5.5 93fbf3a8f6 merge: sm_86 companions (RTX 3080) into the bring-up branch
Brings claude/sm86-assets: per-architecture PTX companions under crates/cuda-driver/ptx-sm86 behind the sm86 feature (sm_120 stays
the byte-identical default), 127 companions incl. the newly sealed MMQ-group, mapped-expert-copy and scalar-MTP assets, the
double-NUL lookup fix, and scripts/gpu-bringup/regress_3080.sh (31 items pass on the 3080 in 344 s). Conflict in
desktop-core/Cargo.toml resolved by keeping both the Linux/dev dependencies and the sm86 feature.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 10:38:09 +02:00
Pavlo RatushnyiandClaude Opus 5.5 0103ee90aa feat(kv): per-owner resident KV window for the streamed QSA layers (kv_stream n_slots)
The resolver PTX baked 8192 resident pages (--kv-resident 32768). Port the
Original's KvStreamMap::n_slots: leleka_qsa_resolve and leleka_qsa_stream_reset
take n_slots (resealed with nvcc 13.2.86, sm_120, precise flags; digests in the
window asset, the window seal plan and the ptx_abi test). Every streamed owner
sizes its resident runs and resolver state from the process-wide window
(configure_kv_resident, default 32768 cells = the previous behaviour) and
launches with its own slot count; the verify window carries it in its KV
binding. leleka-context: resident_pages_for (layer.cpp kv_plan rule),
resident_runs, stream_map_bytes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 10:34:33 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 b625aa2fc8 regress_3080.sh: read commits from a Windows git worktree under WSL
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 10:14:07 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 6173c2d309 gpu-bringup: regress_3080.sh, one-command model-free regression of a commit on the sm_86 card
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 10:04:12 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 0ca493be04 test: run the scripted-engine HTTP smokes through the runtime stack (fake_runtime over real gRPC)
fake_runtime is a leleka.runtime.v1 server (the real RuntimeServer) whose engine is the same
engine.sh the smokes already use; fixture.runtime_stack() swaps strata-next's engine child for
it when STRATA_TEST_FAKE_RUNTIME is set, otherwise nothing changes. scripts/test-api-over-runtime.py
runs the ten smokes whose assertions do not depend on strata-next owning the engine process.

The HTTP layer clamps reasoning_tokens to the engine-reported output total, which a text-level
engine's re-tokenized pieces can otherwise exceed.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 03:00:55 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 c8a0f602fa sm86: document the companion set and the RTX 3080 smoke results, add offline tests
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 02:09:58 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 eb674cef0a sm86: drop cvta.to.shared on already-shared addresses in three hand-written PTX
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>
2026-10-16 01:59:52 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 6ca48b8648 test(smokes): align the Chat and Messages smokes with the accepted sampling and picture surface
smoke-chat-completions expected frequency_penalty 0.1 to be refused and
smoke-messages expected top_k 1 and a countable picture block to be refused;
cce4333 (sampling forwarding) and 81b9070 (vision) made those valid, so both
smokes failed against the current binary (they run in linux.yml). Use
out-of-range values for the refusal cases and expect a picture block to be
countable (one pad, nothing encoded) while generation without an encoder still
refuses it. Both pass against the current debug strata-next.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 01:59:26 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 1884e4ab5f cuda-driver: sm86 feature swaps the sm_86 companion in at module-load time
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>
2026-10-16 01:56:23 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 676457bf8f sm86: tool that derives sm_86 companions of the sealed sm_120 PTX
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>
2026-10-16 01:54:12 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 b8daf8fe9b gpu-bringup: accept PTX ISA 9.1/9.2 (CUDA 13.1/13.2)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 18:21:13 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 88482263e3 build: pin CUDA toolkit to 13.2.2 (nvcc 13.2.86) matching the host driver (CUDA 13.2); bootstrap reads release from the lock; group closed-kernel smokes
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 18:16:42 +02:00
Pavlo Ratushnyi 618a3fa253 Merge branch 'claude/port-rv-kernels' into claude/port-main
# Conflicts:
#	docs/cuda-seal-plan-additions-window.json
#	scripts/check-local.sh
2026-10-14 17:04:06 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 4a640498aa feat(serve): pin-gated PTX assets for native head, sampler and MTP session rope (replace Option::None constants); seal-plan entries and tests
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 17:03:42 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 ee335df9f4 chore(check-local): stub CUDA syntax pass is advisory off macOS
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 17:01:57 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 c280730262 docs(cuda): flag-policy audit of every ported .cu against CMake (unsealed assets without a plan entry, sealed precise builds of fast-math Originals, corrected window re-seal candidates); add literal_diff.py
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 17:00:26 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 90d3433da4 feat(gpu-bringup): mandatory fast-math reseal of six PTX, flag overrides, PTX ISA/driver precheck
Rust port / port-typecheck (push) Failing after 7s
Rust port / port-fast (push) Failing after 7s
Rust port / port-oracles (push) Failing after 9s
Rust port / port-linux-tests (push) Failing after 32s
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>
2026-10-14 17:00:26 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 2ab3a8ca48 test(cuda): run the stub pass through clang's CUDA frontend (host/device call legality, __shared__ rules, <<<>>>); fix qsa variants block_q4_0 packing, de-duplicate native_head_native.cu
- 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>
2026-10-14 16:56:45 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 9189e236e3 feat(gpu-bringup): remote_sync tests, toolkit tests, plan seal slots, doc runbook
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 16:54:39 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 55b16be9fd feat(gpu-bringup): smoke inventory + runner, remote sync, host sanity and env recording
smoke_inventory.py scans every real #[ignore] attribute, extracts the enabling
LELEKA_* flags and values, classifies tests (device / assets / mock) and assigns
them to dependency-ordered groups (smoke-groups.json). run_gpu_smokes.sh runs
them in order, stops a group at its first failure, skips dependents, continues
independent groups, treats a filter that matches nothing as a failure, records
nvidia-smi before/after, refuses a busy GPU and never starts a model run
without --allow-model-runs plus caller-supplied env. remote_sync.sh mirrors the
tree (no --delete, refuses to clobber unpulled sealed files) and builds the
three binaries and the test binaries on the host; host_sanity.sh is read-only;
record_env.sh captures hardware/software/model digests for the ledger.
Tested with stub cargo/nvidia-smi, shellcheck and a Linux container.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 16:54:39 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 671be9c786 feat(gpu-bringup): compile_assets/seal_pins toolkit for the Linux nvcc session
compile_assets.py reads docs/cuda-seal-plan*.json (assets and new_sources
formats), an extra plan for assets no plan covers, and the four rope PTX list
of docs/rope-and-memory-plan.md; verifies .cu pins, runs nvcc with the exact
flags (fast-math policy lint, rope flag variants), validates exports and ABI
parameter counts, and writes PTX + build-manifest.json outside the tree.
seal_pins.py installs the PTX in the encoding each consumer expects and patches
every pin form (PtxPin arrays/structs, AssetSpec.sha, Option tuple arrays,
plain len/sha consts, re-pins of regenerated rope PTX, ptx_abi test) with
exactly one replacement per field and a read-back check. fake-nvcc and a
unittest suite exercise the pipeline on macOS; no GPU, no generated PTX.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 16:54:39 +02:00
Pavlo Ratushnyi 94fb39ccba Merge branch 'claude/port-docs-ci' into claude/port-main 2026-10-14 16:53:32 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 58db6f44b2 test(context): accept any NaN for invalid-YaRN kernel args in the rope golden
rope_plan_golden compared kernel_args.corr_low/corr_high bit-for-bit, while the
corr_dims check right above already (correctly) treats NaN payload/sign as a libm
detail. For beta_slow=-1 the fixture, generated on arm64, holds 0x7fc00000, but
x86 SSE's default NaN is 0xffc00000, so the test failed on Linux x86_64. Compare
NaN-vs-NaN as equal for these two fields; all non-NaN bits stay exact.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 16:47:56 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 f334b66215 test(cuda-driver): teach the fake libcuda the eagerly-resolved cuMemsetD8_v2
Driver::load resolves cuMemsetD8_v2 (the `zero` entry point) up front, but the
synthetic mock_cuda.c (also #included by the q5/q6/projection-family mocks)
never defined it, so every isolated CPU ELF gate died in Driver::load with
MissingSymbol("cuMemsetD8_v2") before reaching its protocol assertions. Add a
load-only stub (same policy as the existing cuMemcpyDtoD_v2 stub) and an opt-in
`run.sh --mocks` mode that builds the fake libraries and runs the mock_driver,
q5_mock and q6_mock matrices in the Linux container.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 16:43:29 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 de21513033 test(linux): add docker x86_64 harness for the Linux-gated port crates
leleka-cuda-driver, leleka-runtime and leleka-native-cpu-expert are gated on
linux/x86_64 and had only ever been type-checked with `cargo check --target`.
scripts/linux-tests/run.sh builds a linux/amd64 image from the toolchain pinned
in rust-toolchain.toml (Rosetta/qemu on Apple Silicon), mounts the repo read-only
with a persistent cargo cache and target volume, runs one `cargo test
--no-fail-fast` shard per crate and prints a pass/fail/ignored/time summary.
No GPU is used: #[ignore]d tests stay ignored and libcuda.so.1 is absent.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 16:41:51 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 c0021c6d09 ci(check-local): fast path first, Linux type-check, port oracles; known fmt/Clippy debt reported instead of failing
Adds --fast/--port modes. The fast path runs fmt, Clippy and tests on the
host-buildable crates. fmt/Clippy debt in crates owned by other branches is
reported (STRICT_DEBT=1 makes it fatal). The script is now executable.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 16:40:42 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 fd7b2c7b8b test(cuda): unified CUDA stub headers and clang syntax/semantics pass over every ported .cu (asm and <<<>>> rewritten, operands kept type-checked)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 16:39:43 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 8832be7025 docs(offline): record the offline port status, divergences and open items; run the oracle diffs from check-local
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 16:07:14 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 2d00e78706 feat(reasoning-budget): port Service.reasoning_budget and the run-loop wrap-up with a Service.run differential
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 16:07:14 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 250fd3e65d feat(prompt): render the pinned chat template with minijinja instead of a hand-written Qwen format
minijinja =2.24.0 (+ minijinja-contrib pycompat for str methods), configured like serve/frontend.py ChatTemplate:
trim/lstrip blocks, no autoescape, raise_exception, Python tojson (json.dumps ensure_ascii=False) and str.strip trim.
All 10 chat_golden.json cases render byte for byte straight through the template (tool_calls, tool messages, no
generation prompt included). Ordered Json keeps object key order. scripts/offline/diff_chat_template.py: 12000
generated conversations vs jinja2 (identical renders, identical raise_exception messages); committed golden + test.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 15:53:16 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 18d712eed5 feat(context): reuse the port-rope leleka-context crate and port setup.py's RAM/VRAM sizing rules
crates/context is taken verbatim from claude/port-rope (rope scaling incl. setup_resolve_rope/derived_factor, memory
plan, context policy). New setup_policy module: ram_ctx, ctx_ram_need, resident_budget_gib, low_ram_*; a golden grid
from 'import setup' (resolve_rope/derived_factor too, which the branch had only transcribed) checked bit for bit.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 15:45:55 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 08dbe0abe0 feat(mtp-fetch): port tools/mtp_fetch.py (inventory/fetch/verify) with a local-mirror differential
Pinned 31-entry SHA-256 table, 206 + exact Content-Range, retry-once on wrong bytes, inventory re-read on a revision
change, verified.json stamps. model::http_client is now shared. Tests port test_mtp_fetch.py onto a real local HTTP
mirror; scripts/offline/diff_mtp_fetch.py runs the unmodified Python against the same mirror (10 scenarios).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 15:43:43 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 3485221865 feat(offline-tools): port embd_bf16_pack, ple_fp8_pack, draft_vocab, make_profile, mtp_rt
New crate leleka-offline-tools wired as 'strata-next tools ...'. Every output is byte-identical to the unmodified
Python tool (scripts/offline/diff_tools.py: packs incl. refusal cases, 14 draft-vocab subsets x out/stats, make_profile
at 512/256/8 experts with ranked bases and traces, mtp_rt at the real H/FF geometry). Committed tiny goldens +
integration tests; mtp_rt's multi-MB input is regenerated from a shared splitmix64 rule.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 15:40:02 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 f2ec56325c test(dequant): bit-exact parity of 23 block types vs pinned gguf-py and iq_fixture
scripts/offline/diff_dequant.py (live, 32 rows x 3 seeds through export-tensor-f32) and a committed golden
with an integration test over the production visitor.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 15:33:27 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 debfbd0941 test(tokenizer): committed oracle differential, per-codepoint pre-tokenizer check, batch CLI
- crates/tokenizer pre_tokenize + model pre-tokenize-batch/tokenize-batch/detokenize-batch (debug/differential)
- scripts/offline/diff_tokenizer.py: every Unicode scalar x 13 contexts vs Python regex (0 real mismatches;
  14k strings differ only where regex 2026.9.10 has Unicode 17 and regex-syntax/unicodedata 16), a synthetic
  GGUF with BPE-trained merges past the heap path, 5-file extraction compare, encode/decode fuzz
- golden crates/tokenizer/tests/fixtures/tokenizer_oracle.json + integration test
- stricter-by-design: duplicate merges, missing chat template, negative special ids

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 15:32:23 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 f3bff3842d feat(gguf): header-reader differential, full metadata dump and Python geometry parity
- model inspect-metadata dumps every key/value (bool arrays typed); metadata_entries in model-format
- block_geometry gains Q8_K, IQ1_S, F64, MXFP4, NVFP4; ggml bridge decodes Q8_K, IQ1_S, MXFP4, NVFP4
- general.alignment must be uint32 (the Python reader accepted any width, the Rust reader ignored the rest)
- scripts/offline/diff_gguf_header.py: random GGUF vs unmodified gguf_reader.py, plus stricter-by-design list
- committed golden + integration test (headers and the geometry table)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 15:25:20 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 0d073e08aa feat(native-pack): match iq_pack.py conversions, add --compat-bf16/--base/--experts-bin and the exhaustive differential
- ple_conv1d inexact F32->F16 is accepted and recorded exact=false, as the oracle does
- conversions.json now carries method/exact/max_abs_err/source_shards like iq_pack.py
- opt-in --compat-bf16 (dequantize + RNE to BF16/F16/F32), --base (index_from_base, extra.bin),
  --experts-bin (+ experts.bin.src.json); receipts list the optional files present
- scripts/offline/diff_native_pack.py: 2700+ cases against the unmodified tools/iq_pack.py
- unit tests: real golden expert tables, numpy/gguf-py F16/BF16 rounding vectors
- fix three pre-existing clippy lints in leleka-model-format

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 15:20:15 +02:00
Pavlo RatushnyiandClaude Sonnet 5.5 7f896a8bb8 import: Original-literal source-port snapshot (frozen 2026-10-12 06:36, uncompiled together, no GPU run)
Snapshot of target/stra169-direct-port-integration/source-port (without target/), now the tracked base for the full Strata Rust port.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 14:38:46 +02:00
Pavlo Ratushnyi bffa3160f2 feat(cuda): admit independently qualified QSA operator assets 2026-10-09 21:01:50 +02:00
Pavlo Ratushnyi 11f9de7170 [skip ci] Integrate qualified Q2_0 routed projection asset 2026-10-09 12:29:05 +02:00
Pavlo Ratushnyi 2c6ef76e22 feat(cuda): integrate projection family [skip ci] 2026-10-09 11:20:44 +02:00