wai-ops: int_synth decodes through the integer operator set, goldens unchanged (D2c, M1) #242
Loading…
Reference in a new issue
No description provided.
Delete branch "wai/d2c-decoders-on-ops"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
D2c, first decoder:
wai.neural.int_synthdecodes through the integer operator setwai-ops/1(integer-operators, Draft). Every committed golden is byte-identical. The decoder is lowered to itsint_synth/1graph and loaded with its certificate, and the interpreter runs it, with the fast kernels behind it held to it. The direct decode remains only as a test oracle.The seven gates, each in its own commit
c2cac5b2,2ae2a439). wai-rs depends on wai-ops behindneural_int(src/int_ops.rs). Every committed set lowers to its committed.whg1. Loading it gives the certificate's verdict:acc32for facade, gradient, bloom and the smallsynthset, andacc64for photo. The two falsification sets fail the profile they claim. New testtests/int_synth_ops.rs.25de4ab3).int_synth::ops::decode_from_specdecodes through the lowering. On every neural-conformance vector it gives the same bytes as the direct decode, and matches the SHA-256 sidecar, the BLAKE3 hash and photo's reference bytes. byte-exact-conformance gains the cross-architecture golden through the lowering.f3927f75). There are 27 fixtures, one for each refusal the direct decode makes. Each is refused both ways, and the sink's dispatch reportspayload_malformed. The graph's input range decodes at both ends and refuses one past each. Also: the registryopsmember (acc64,full,int_synth/1), SPEC §5 and §7 citations, and a CHANGELOG entry.89e00eaa).tests/int_ops_differential.rs, behind a test-onlylegacy_intfeature.wai-ops-differential.ymlruns an hour in each profile onlinux, seeded by the date.93bd919e). wai-ops gainsinterp::Kernelsandrun_with; wai-rs'sint_ops::Hostlends it the fast convolution and transposed convolution. The host declines under the reference policy, on uncovered geometry, past the operand bound, or where a value would leave i64. Each is checked against the interpreter per operator (random convolutions, requiring the fast kernel ran) and per decoder (every committed vector under the reference and four fast policies).a6c61f3c).decode_from_specdecodes through the lowering. The direct path iscfg(any(test, feature = "legacy_int")).layerslist, a layer without_ch0 and fields of 2^32 or more, which the lowering already refused but no text stated.int_synthset and payload and finds none affected.c08d66f1). The direct path's fast dispatch goes, along with its guardreference_output_side, the oldkernel_equivalencetests and theopsscaffolding. The plan's cap on a transposed convolution's uncropped output now does the deleted guard's job.Merges of main:
0cb391e0,791590cb,70aca892,6ca9d92e.135c9ad7set aside an earlier non-compiling draft so the gates could land in order. The draft's later pieces (M2–M6) stay in its commit, not in the tree.Falsifications (each shown red, then green after restore)
acc32bound (found by bisection withwai-verify bounds); load step 8 disabledpostout_pad.min(1))post, after the switchint_kernels_vectors, both byte-exact goldens, including the file-based one that stayed green under the same fault at gate 2int_kernels_geometry::padding_far_beyond_the_kernel, the differential's planned-breaks testChecks at the head (build host)
wai-verify vectors verifypasses.wai_ops_check.pyrewrites everything byte for byte.interp.rsis included by every harness.Not in this PR
🤖 Generated with Claude Code
1fa13396, with D2b #221, #227 and #228) into wai/d2c-decoders-on-ops 0cb391e06cRefusal parity (tests/int_synth_ops.rs): one fixture for each refusal the direct decode makes (a payload short or long, a side of 2^64 or 2^255, C*S*S past the word, an output that is not [3, H, W], an H of 0, a first in_ch that is not C, a set that is not JSON or has no layers, a malformed layer, a negative, fractional or non-boolean field, a weight or bias count off by one, a value past i32, layers that do not chain, an output side of 0). Each is refused by both decodes, and a sink's int_payload dispatch reports it as payload_malformed, the one code integer-payloads §13 gives. The lowered graph's input check [-128, 127] decodes at both ends and refuses one past each with field_range at input 0. The registry's ops member (integer-operators §11): codecs::OpsMember and capability_ops, Registration::ops, the export's ops member and its schema (built in its own function: the schema literal had reached json!'s recursion limit). wai.neural.int_synth gets {set wai-ops/1, profile acc64, subset full, lowering int_synth/1}; a unit test pins it as the only member, on a NeuralIntegerExact capability. registry/ regenerated by `wai registry export`. SPEC §5's row cites integer-payloads §13 and integer-operators §13.1; SPEC §7 says a NeuralIntegerExact capability that decodes through the operator set names it in its ops member. REGISTRY.md lists the member; CHANGELOG entry. int_ops::PROFILE is private: as a public constant, cbindgen wrote an opaque Profile typedef into include/wai.h. Co-Authored-By: Claude Opus 5.5 <[email protected]>bd3983c6, with #229-#232, #235, #142, #209, #210) into wai/d2c-decoders-on-ops 791590cb06c20f8473, with #237) into wai/d2c-decoders-on-ops 70aca892781ec8f447, with #233, #234, #236, #238, #239, #240) into wai/d2c-decoders-on-ops