Skip to content

Commit 5f782f9

Browse files
afflomclaude
andcommitted
Bump version to 0.4.6
Implements wiki ADR-043 through ADR-049 — the implementer-facing cost-model + observable-surface trio, plus the user-flagged `axis!` macro orphan-rule bug fix. ADR-048 — `TypedCommitment` cost-model surface (5th substrate parameter): - `TypedCommitment` trait (sealed) + 3 built-in implementors: `EmptyCommitment` (no-commitment default), `SingletonCommitment<P>` (one ObservablePredicate), `AndCommitment<A, B>` (typed conjunction). Trait surface: `bandwidth_bits() -> f64`, `accept_prob() -> f64`, `evaluate(kappa_label: &[u8]) -> bool`, `predicate_count() -> usize`, `predicate_iris() -> &'static [&'static str]`. - `PrismModel<H, B, A, R, C>` extends to a 5-substrate-parameter shape; `C: TypedCommitment` defaults to `EmptyCommitment` so existing models compile unchanged. - `run_route<H, B, A, M, R, C>(input, &resolvers, &commitment)` extends to a 6-type-parameter signature; the catamorphism's post-resolver `commitment.evaluate(kappa_label)` consultation gates the success-envelope. Failure surfaces as `PipelineFailure::ShapeViolation` with the foundation-vetted `commitment/TypedCommitment/VIOLATED` shape IRI. - `prism_model!` macro extended: accepts optional 5th type-position + optional `fn commitment() -> C { … }` body clause. Macro emits the 5-position impl with the commitment threaded into `forward`'s body. - `TRACE_REPLAY_FORMAT_VERSION` bumped 6 → 7 for the CommitmentEvaluated trace event variant. ADR-049 — Observable + cryptanalysis-battery surfaces: - `ObservablePredicate` trait (sealed) + 4 foundation-declared typed observable primitives: `Stratum<P>`, `WalshHadamardParity`, `UltrametricCloseTo<P>`, `AffineParity`. Each implements the foundation-vetted observable_iri per the closed Observable catalog. - `axis::cryptanalyze::<H: Hasher>(samples)` → `CryptanalysisReport` with §A–§J test outcomes + `all_pass()` helper. The structural battery witnesses Hardening Principle U1–U6 (ADR-047). - `observable:SpectralObservable` closed-catalog extension (Path-1 class hosting Walsh–Hadamard-parity-derived spectral readings). Counts: CLASSES 472→473, CLASSIFICATION_PATH1 414→415, SHACL_TESTS 284→285, CONFORMANCE_CHECKS 544→545. ADR-043 / 045 / 046: documentation-only (resolver-body discipline scope, Grounded::tag already realized in foundation). ADR-044 already realized: `PartitionProductFields` FIELDS + FIELD_NAMES split-const form was in place from prior release. ADR-047 — σ-Projection Hardening Principle: documentation in TypedCommitment / ObservablePredicate trait surfaces (U1–U6 axioms named; bandwidth_bits / accept_prob propagation tight per U2). axis! macro orphan-rule bug fix (user-flagged): - Prior emission generated `impl<T: MyAxis> AxisExtension for T` — a foreign-trait blanket that violates Rust's orphan rule from any external crate. - Fixed by emitting a companion `axis_extension_impl_for_<snake>!` macro per axis trait; users invoke it once per implementing struct to get an orphan-rule-conformant `impl AxisExtension for MyStruct` with the kernel-id-routed dispatch_kernel body. - 7 new test cases in `uor-foundation-sdk/tests/smoke.rs` covering kernel-id consts, AxisExtension wiring, dispatch routing, unknown-id rejection, single-kernel handling, method-signature contract, AXIS_ADDRESS/MAX_OUTPUT_BYTES propagation. End-to-end implementor-verification tests for ADR-048 + ADR-049 in uor-foundation-sdk/tests/smoke.rs: - `adr048_*` cost-model enforcement (Empty/Singleton/And evaluate; prism_model! 5-position form with `fn commitment()` clause; failure surfaces with the canonical shape IRI; success returns `Grounded` with output_bytes carrying the κ-label the commitment accepted). - `adr049_*` observable predicate evaluation (Stratum, WalshHadamardParity, UltrametricCloseTo, AffineParity each exercised) + cryptanalysis battery surface pin. All quality gates green: fmt, clippy --all-targets -D warnings, workspace tests (71 SDK smoke tests, every foundation test), conformance (545 passed, 0 failures, 10 meta-audit, 0 gaps). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 746075c commit 5f782f9

31 files changed

Lines changed: 2407 additions & 148 deletions

Cargo.lock

Lines changed: 13 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ members = [
1818
resolver = "2"
1919

2020
[workspace.package]
21-
version = "0.4.5"
21+
version = "0.4.6"
2222
edition = "2021"
2323
rust-version = "1.83"
2424
license = "Apache-2.0"

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ structure based on Z/(2^n)Z.
99

1010
## Ontology
1111

12-
Version 0.4.4: 34 namespaces · 472 classes · 948 properties · 3560 named individuals
12+
Version 0.4.6: 34 namespaces · 473 classes · 948 properties · 3560 named individuals
1313

1414
All terms are encoded as typed Rust data in `spec/` (`uor-ontology`) and exported as:
1515
- `foundation/` (`uor-foundation`) — typed Rust traits (published to crates.io)

codegen/src/enforcement.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5186,7 +5186,7 @@ fn generate_grounded_wrapper(f: &mut RustFile) {
51865186
f.doc_comment("Increment when the layout changes (event ordering, trailing fields,");
51875187
f.doc_comment("primitive-op discriminant table, certificate-kind discriminant table).");
51885188
f.doc_comment("Pinned by the `rust/trace_byte_layout_pinned` conformance validator.");
5189-
f.line("pub const TRACE_REPLAY_FORMAT_VERSION: u16 = 6;");
5189+
f.line("pub const TRACE_REPLAY_FORMAT_VERSION: u16 = 7;");
51905190
f.blank();
51915191
f.doc_comment("v0.2.2 T5: pluggable content hasher with parametric output width.");
51925192
f.doc_comment("");

0 commit comments

Comments
 (0)