open-standards/proof/conformance/v1/joulespec.toml
Transaction Science 78306391a1
All checks were successful
standards workspaces build + test / which workspaces this change touches (pull_request) Successful in 15s
standards workspaces build + test / pool-rs (pool/pool-rs, pool-rs, linux) (pull_request) Successful in 27s
standards workspaces build + test / arl-rs (arl/arl-rs, arl-rs, linux) (pull_request) Successful in 33s
standards workspaces build + test / joulehook-rs (joulehook/joulehook-rs, joulehook-rs, linux) (pull_request) Successful in 34s
standards workspaces build + test / jcp-rs (jcp-conformance, jcp/jcp-rs, -p jcp-energy --features nvml, jcp-rs, linux) (pull_request) Successful in 50s
standards workspaces build + test / jouledesk-rs (jouledesk/jouledesk-rs, jouledesk-rs, macos) (pull_request) Successful in 56s
standards workspaces build + test / sense-rs (sense/sense-rs, sense-rs, linux) (pull_request) Successful in 23s
standards workspaces build + test / proof-rs (proof/conformance/v1/joulespec.toml, proof-conformance, proof/proof-rs, proof-rs, linux, true) (pull_request) Successful in 1m3s
standards workspaces build + test / joule-ui-rs (joule-ui/joule-ui-rs, joule-ui-rs, linux) (pull_request) Successful in 1m49s
standards workspaces build + test / sandbox-rs (sandbox-conformance, sandbox/sandbox-rs, -p sandbox-tee --features amd-kds,intel-pcs, sandbox-rs, linux) (pull_request) Successful in 1m16s
standards workspaces build + test / joulespec-rs (true, joulespec/joulespec-rs, true, joulespec-rs, linux) (pull_request) Successful in 54s
standards workspaces build + test / eoc-rs (eoc/eoc-rs, -p eoc-meter --features cuda, eoc-rs, linux) (pull_request) Successful in 2m19s
standards workspaces build + test / smart-byte-rs (smart-byte/smart-byte-rs, smart-byte-rs, linux) (pull_request) Successful in 2m14s
repository checks / lockfiles, advisories, tests in CI, workflow hygiene, spec and section references, public text (pull_request) Successful in 3m44s
standards workspaces build + test / aac-rs (aac-conformance, aac/aac-rs, aac-rs, linux-arm64) (pull_request) Successful in 4m47s
standards workspaces build + test / jouleclaw-rs (-nodebug, jouleclaw/jouleclaw-rs, -p jouleclaw-energy --features rapl,nvml, jouleclaw-rs, linux-arm64, -C target-feature=+fp16) (pull_request) Successful in 5m15s
standards workspaces build + test / joulespec-proofs (joulespec/joulespec-rs, joulespec-proofs, true, macos) (pull_request) Successful in 5m54s
standards workspaces build + test / joulecontract-rs (joulecontract/joulecontract-rs, joulecontract-rs, linux-arm64, true) (pull_request) Successful in 1m12s
standards workspaces build + test / map-rs (map-conformance, map/map-rs, map-rs, linux-arm64) (pull_request) Successful in 1m16s
standards workspaces build + test / mesh-rs (mesh/mesh-rs, -p mesh-engine-gguf -p mesh-openai --features mesh-engine-gguf/gguf,mesh-openai/server, mesh-rs, linux-arm64) (pull_request) Successful in 1m17s
standards workspaces build + test / openpay (openpay, openpay, linux-arm64) (pull_request) Successful in 4m8s
standards workspaces build + test / joule-code-rs (joule-code/joule-code-rs, joule-code-rs, linux-arm64, true) (pull_request) Successful in 7m17s
standards workspaces build + test / macOS energy backends (pull_request) Successful in 11m48s
joulespec: applied to a standard that is not its own, which found a mis-aimed mutation
A producer that has only ever measured its own specification has demonstrated
a format, not a method. This points it at the proof standard.

`proof/conformance/v1/joulespec.toml` reads that standard's conformance items
from its own published §8 — a bulleted list with bold labels, declared as such
because the shape is a fact about the document — and maps each to a named
check in `proof-rs`, with a counter-artifact per mapping. Every item, C1
through C5 and the negative pack, reaches `E3`: the check is on record failing
against a declared edit, so its passing carries information. Attestation is
reported absent rather than `A0`, because no work was declared and no
implementer is therefore known.

The measurement lands in its own subdirectory rather than beside that
standard's vectors, which answer a different question and must not be confused
with it. Its energy comes from a wall clock, so it is a measurement and not a
vector: re-running changes the bytes, and its README says so.

## What producing it found

The first counter-artifact for C1 aimed at `Tier::LADDER`, assuming the router
iterated that constant. It does not — the constant is read only by the
monotonicity checks, and the router sorts the solvers it is handed. So
`trivial_closes_at_t0_no_waste` passed with the constant reordered, and the
harvester reported that the check could not see its subject.

The report was right and the manifest was wrong. That distinction is the whole
reason the producer reports what it observed rather than concluding: a check
that passes while something it should notice is broken is either a weak check
or a mutation that missed, and only an operator can say which. Re-aimed at
`Router::new`'s sort, the same check fails at once — so the check was strong
all along, and C1's evidence is real rather than assumed. A hypothesis that
z3's absence explained it was refuted first, with z3 on the path and the check
still passing.

## CI

`applied: <manifest>` is a separate step from the existing self-conformance
harvest, because that one builds the producer from the workspace under test,
which only works where the workspace under test *is* the producer's. This one
builds the producer from its own workspace and runs it against someone
else's. The build and the path lookup are separate commands: folded into one
substitution, a build failure yields an empty path and the step reports "no
such file" instead of the compiler error. No `--out`, since a receipt written
in CI would dirty the tree and its figures differ every run.

Co-Authored-By: Claude Opus 5 <[email protected]>
2026-11-02 04:27:13 -05:00

134 lines
5 KiB
TOML

# JouleSpec applied to the proof standard.
#
# The first time this producer has measured a specification other than its own.
# Clauses are read from `../../SPEC.md` section 8 rather than copied here, so
# this manifest cannot drift from that document: reword an item and its
# obligation address moves, and the witness bound to the old wording stops
# applying.
#
# The three declared things are human judgements the standard refuses to guess
# (JouleSpec SPEC 2.6, 2.5, 8): which check stands for which obligation, where
# each check's expectation comes from, and which inputs it depends on.
workspace = "../../proof-rs"
steward = "did:key:joulespec-applied-proof"
[spec]
document = "../../SPEC.md"
section = "8. Conformance"
# This document writes its conformance items as a bulleted list with bold
# labels, which is a fact about the document rather than about this producer.
shape = "bulleted-bold-label"
# C1..C5 and C-neg. A floor, so a parser that matched fewer fails rather than
# reporting success over a shorter list.
expect_at_least = 6
intent = "The cheapest-sufficient prover routes, accounts and seals as section 8 requires."
[artifact]
dirs = ["crates"]
extensions = ["rs"]
[energy]
watts = 30.0
provenance = "estimator"
# ---------------------------------------------------------------------------
# C1 -- cheapest-sufficient routing
#
# The first mutation written here was aimed at `Tier::LADDER`, on the
# assumption that the router iterated it. It does not: that constant is read
# only by the monotonicity checks, and the router sorts the solvers it was
# handed. So the check passed with the constant reordered, and the harvester
# reported -- correctly -- that the check could not see its subject. The
# report was right and the manifest was wrong, which is the distinction the
# operator has to make and the producer cannot.
#
# Aimed at the sort, the same check fails at once.
[[evidence]]
clause = "C1"
check = "tests::trivial_closes_at_t0_no_waste"
anchor = "specification"
footprint = [
"crates/proof-schema/src/lib.rs",
"crates/proof-cascade/src/lib.rs",
]
[evidence.counter]
file = "crates/proof-cascade/src/lib.rs"
find = " solvers.sort_by_key(|s| s.tier());"
replace = " solvers.sort_by_key(|s| std::cmp::Reverse(s.tier()));"
breaks = "orders the router's rungs dearest-first, so a goal no longer closes at the cheapest tier that can discharge it"
# ---------------------------------------------------------------------------
# C2 -- disclosed escalation
[[evidence]]
clause = "C2"
check = "tests::escalation_discloses_waste"
anchor = "specification"
footprint = ["crates/proof-cascade/src/lib.rs"]
[evidence.counter]
file = "crates/proof-cascade/src/lib.rs"
find = " wasted_uj = wasted_uj.saturating_add(uj);"
replace = " wasted_uj = wasted_uj.saturating_add(0);"
breaks = "stops counting a failed cheaper attempt's joules as escalation waste"
# ---------------------------------------------------------------------------
# C3 -- energy honesty
[[evidence]]
clause = "C3"
check = "tests::ladder_is_cheapest_first_and_monotone"
anchor = "specification"
footprint = ["crates/proof-schema/src/lib.rs"]
[evidence.counter]
file = "crates/proof-schema/src/lib.rs"
find = """ pub const LADDER: [Tier; 4] = [
Tier::Automation,
Tier::Smt,"""
replace = """ pub const LADDER: [Tier; 4] = [
Tier::Smt,
Tier::Automation,"""
breaks = "breaks the ladder's strict monotonicity by putting a dearer rung first"
# ---------------------------------------------------------------------------
# C4 -- the flywheel
[[evidence]]
clause = "C4"
check = "tests::cache_is_the_flywheel"
anchor = "specification"
footprint = ["crates/proof-cascade/src/lib.rs"]
[evidence.counter]
file = "crates/proof-cascade/src/lib.rs"
find = """ total_uj: 0,
wasted_uj: 0,"""
replace = """ total_uj: 1,
wasted_uj: 0,"""
breaks = "charges a joule for a proof served from cache, so re-proving is no longer free"
# ---------------------------------------------------------------------------
# C5 -- the receipt
[[evidence]]
clause = "C5"
check = "jcr1::tests::envelope_rejects_wrong_steward"
anchor = "specification"
footprint = ["crates/proof-receipt/src/jcr1.rs"]
[evidence.counter]
file = "crates/proof-receipt/src/jcr1.rs"
find = " if kid != expected_steward {"
replace = " if false {"
breaks = "stops comparing the envelope's key id against the expected steward, so a wrong steward verifies"
# ---------------------------------------------------------------------------
# C-neg -- the negative pack
[[evidence]]
clause = "C-neg"
check = "tests::unproved_goal_cannot_be_sealed"
anchor = "specification"
footprint = ["crates/proof-receipt/src/lib.rs"]
[evidence.counter]
file = "crates/proof-receipt/src/lib.rs"
find = """ if !r.proved {
return Err(ReceiptError::NotProved);
}"""
replace = """ if false {
return Err(ReceiptError::NotProved);
}"""
breaks = "lets a receipt be sealed for a goal nothing proved"