# cross-binding conformance Test vectors + multi-language verifiers for the two JouleClaw cross-standards binding schemas: - **`cross-binding/1`** (`cross-binding-vectors.json`) — the per-request binding across JouleClaw + Sandbox + Joule-Code, five invariants (trace-id equality, joule agreement, worst- counter provenance, trusted stewards, sandbox grants ⊆ cascade authorisation). - **`streaming-trace-binding/1`** (`streaming-trace-binding-vectors.json`) — the multi-window streaming generalisation, seven invariants (sandbox/binding trace-id, per-window stream-id consistency, window-id monotonicity, joule-sum within tolerance, worst-counter provenance across windows + sandbox, session_op_id accounted by a window seal, trusted stewards). ## Canonical encoding Both schemas seal under the same JCR-1-shaped canonical encoding: - JSON with object keys recursively sorted (alphabetical). - UTF-8. - No whitespace. - No float coercion (all numbers are integers). `content_hash` is BLAKE3 hex of the canonical bytes. ## Implementations Three byte-equal implementations are intended (Rust + Python + Go, following the JCR-1 v1 pattern): | | Rust | Python | Go | |---|---|---|---| | `cross-binding/1` | ✓ (`jouleclaw-cross-binding`) | ✓ (`verify_cross_binding.py`) | ✓ (`go/verify_cross_binding/main.go`) | | `streaming-trace-binding/1` | ✓ (`jouleclaw-cross-binding::streaming`) | ✓ (`verify_streaming_trace_binding.py`) | ✓ (`go/verify_streaming_trace_binding/main.go`) | Three byte-equal implementations across Rust + Python + Go, the JCR-1 v1 three-impl pattern. A standard is conformant if a fourth implementation in any language reproduces these PASS results. ## Running ``` # Rust (via cargo test, runs as part of the workspace) cargo test -p jouleclaw-cross-binding # Python (blake3 from pypi required) pip install blake3 python3 verify_cross_binding.py python3 verify_streaming_trace_binding.py # Go (lukechampine.com/blake3 from the go module, resolved on first run) cd go && go mod tidy ( cd verify_cross_binding && go run main.go ) ( cd verify_streaming_trace_binding && go run main.go ) ``` Either implementation MUST reproduce PASS on every vector. A conformant alternate impl in any language MUST reproduce these PASS results.