wai-quantum 0.6.7: tensor networks that split controlled gates and fix projections #343
Merged
dcharlot
merged 3 commits from 2026-10-19 22:37:45 -04:00
wai/quantum-tn-split-0.6.7 into main 2026-10-19
wai-quantum 0.6.7: the changelog entry, and the version in every lockfile that pins it
All checks were successful
wai-quantum tensor-engine member / member · tensor engine, the kernel toolchain's simulator (linux) (pull_request) Successful in 8m4s
wai-quantum CPU vector units / member · vector unit, rvv 1024-bit (riscv64, emulated) (pull_request) Successful in 18s
wai-quantum CPU vector units / member · vector unit, sve 128-bit (aarch64, emulated) (pull_request) Successful in 36s
wai-quantum CPU vector units / member · vector unit, rvv 128-bit (riscv64, emulated) (pull_request) Successful in 13s
wai-quantum CPU vector units / member · vector unit, sve 2048-bit (aarch64, emulated) (pull_request) Successful in 10s
wai-quantum CPU vector units / member · vector unit, avx2 (x86_64 silicon) (pull_request) Successful in 13s
wai-quantum signal processor / processor and member · signal processor, emulated (pull_request) Successful in 13m54s
wai-quantum CPU vector units / member · vector unit, sve 512-bit (aarch64, emulated) (pull_request) Successful in 12s
wai-quantum WebGPU member / member · software Vulkan (linux) (pull_request) Successful in 2m12s
wai-quantum WebGPU member / shader checks · browser build · wasip2 inertness · MSRV (pull_request) Successful in 3m20s
wai-web wasm32 / wai-web wasm32 build · corpus, menu and writers (pull_request) Successful in 3m23s
WAI mbt2018_mean integer decode (regenerated vectors) / regenerate mbt2018_mean integer vectors → Rust decode, required (pull_request) Successful in 5m23s
wai-web reach builds / wai-web reach builds · the package of record, every output as recorded (pull_request) Successful in 2m45s
wai-web reach builds / wai-web reach builds · this tree's wai-web, every rung on its engine line (pull_request) Successful in 4m18s
WAI conformance / cargo-class corpora · macos (pull_request) Successful in 23m22s
WAI conformance / cross-arch byte-equality · macos (pull_request) Successful in 28s
WAI conformance / codec wrappers · fuzz smoke, text decode limits, C entry points, provenance, the semantic path (pull_request) Successful in 1m31s
WAI energy receipts / energy receipts · macos (pull_request) Successful in 10m57s
wai-pack / wai-pack · macos (pull_request) Successful in 1m57s
wai-quantum dataflow member / member · dataflow device absent (macos) (pull_request) Successful in 19s
wai-quantum FPGA member / member · FPGA datapath, simulated (macos) (pull_request) Successful in 1m34s
wai-quantum Metal member / member · Metal (macos) (pull_request) Successful in 36s
wai-quantum neural-processor member / member · neural processor (macos) (pull_request) Successful in 7m46s
wai-quantum OpenCL member / member · OpenCL GPU (macos) (pull_request) Successful in 1m4s
wai-quantum service / service · macos (pull_request) Successful in 53s
wai-quantum matrix-extension member / member · matrix extension absent (macos) (pull_request) Successful in 12s
wai-quantum portable tensor program / tensor program · Metal and the arm64 CPU (macos) (pull_request) Successful in 34s
wai-quantum CPU vector units / member · vector unit absent (macos) (pull_request) Successful in 24s
wai-quantum WebGPU member / member · Metal (macos) (pull_request) Successful in 6m29s
wai-quantum WebGPU member / member · browser WebGPU (macos) (pull_request) Successful in 3m25s
Co-Authored-By: Claude Opus 5.5 <[email protected]>
wai-quantum tn: Network::reduce fixes the indices a tensor allows one value of
Where a tensor is zero unless index i takes v, every tensor holding i keeps its entries at v and drops i, repeated until nothing changes; then simplify. Only zeros are read and entries selected. Projections run through diagonal gates and the deltas of split ones, so a CZ beside a projected output becomes scalars. Open indices are never fixed. simplify itself is unchanged, so networks that do not call reduce keep their bits. On the same 61-qubit CZ circuits (depth 8/12/16/20, 64 trials): log10 multiply-adds 5.35/8.25/11.22/14.26 split and reduced, against 6.58/9.23/ 12.09/15.16 split alone and 8.03/12.46/16.09/19.64 whole and simplified. tn_cost, the CLI's tn subcommand and the service's tensor_network method reduce their split networks. Tests: split networks reduced, and whole-gate networks reduced, give the state vector's amplitudes; open outputs too. Co-Authored-By: Claude Opus 5.5 <[email protected]>
wai-quantum tn: split controlled and diagonal gates at their block-diagonal qubits
Network::amplitude_split builds the same network as Network::amplitude but splits each gate on two or more qubits at every qubit it is block-diagonal on (a control, or a qubit it is diagonal on): G = Σ_a |a⟩⟨a| ⊗ G_a becomes the delta δ(out, in, k) on that qubit's wire and the blocks G_k, joined by a bond of dimension 2. Only zeros of the matrix are read, so the amplitudes are the same entries' sums. A cut through a CZ or CX then costs 2, not 4. On the 61-qubit CZ circuits of a published release, depth 8/12/16/20, the search (64 trials) finds log10 multiply-adds 6.58/9.23/12.09/15.16 on split networks against 8.03/12.46/16.09/19.64 on whole-gate ones. 1024 trials do not lower them further. tn_cost, the wai-quantum CLI's tn subcommand (--whole-gates for the old networks) and the service's tensor_network method build split networks. Tests: split networks give the state vector's amplitudes on circuits of CZ, CX both ways, a controlled random unitary, random diagonal gates, Toffoli, CCZ and random two-qubit unitaries, with outputs projected and open; CZ and CX split and a random unitary does not, CX at its control; on a 4 × 5 CZ grid of 12 layers the split network's tree costs less than an eighth of the whole-gate one's. Co-Authored-By: Claude Opus 5.5 <[email protected]>