docs: make benchmark validation reproducible
Browse filesREADME-only: explicit train split, exact seven-case validation matrix pinned to immutable fixture/verifier commits, and fail-closed scope/limitations. No fixture or license changes.
README.md
CHANGED
|
@@ -20,7 +20,9 @@ task_categories:
|
|
| 20 |
- other
|
| 21 |
configs:
|
| 22 |
- config_name: default
|
| 23 |
-
data_files:
|
|
|
|
|
|
|
| 24 |
---
|
| 25 |
|
| 26 |
<div align="center">
|
|
@@ -37,18 +39,23 @@ configs:
|
|
| 37 |
|
| 38 |
A small **benchmark corpus of governance decision receipts** for the open
|
| 39 |
[`governed-receipt-spec`](https://github.com/szl-holdings/governed-receipt-spec).
|
| 40 |
-
|
| 41 |
-
offline verifier**
|
| 42 |
-
|
| 43 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 44 |
|
| 45 |
Built and maintained by [SZL Holdings](https://a-11-oy.com). Apache-2.0.
|
| 46 |
|
| 47 |
-
> **
|
| 48 |
-
>
|
| 49 |
-
>
|
| 50 |
-
>
|
| 51 |
-
>
|
| 52 |
> `null` / `UNAVAILABLE`.
|
| 53 |
|
| 54 |
---
|
|
@@ -58,12 +65,14 @@ Built and maintained by [SZL Holdings](https://a-11-oy.com). Apache-2.0.
|
|
| 58 |
A **governed inference receipt** is the small, replayable, hash-chained record a
|
| 59 |
governed AI runtime emits for one governed action (e.g. an inference): what it
|
| 60 |
**decided**, the **Λ** governance-floor status, whether **energy** was actually
|
| 61 |
-
measured, and a
|
|
|
|
| 62 |
|
| 63 |
A receipt is explicitly **NOT** a zero-knowledge proof and **NOT** a proof of
|
| 64 |
-
computation
|
| 65 |
-
|
| 66 |
-
|
|
|
|
| 67 |
|
| 68 |
---
|
| 69 |
|
|
@@ -71,24 +80,64 @@ computation — it is a signed, tamper-evident audit record of a governance
|
|
| 71 |
|
| 72 |
```
|
| 73 |
bench.jsonl # one row per case: file, category, expected_result, source, note
|
| 74 |
-
valid/ #
|
| 75 |
a11oy-khipu-chain.json # 5-receipt signed hash chain (seq 0->4)
|
| 76 |
a11oy-khipu-genesis.json # single signed genesis receipt (seq 0, prev = 64 zeros)
|
| 77 |
lake-inference-receipt.json # decision=allow + measured-or-null energy in the clear
|
| 78 |
readiness-audit-receipt.json# unsigned envelope, content bound by payloadSha256
|
| 79 |
daily-activity-receipt.json # HMAC-stub daily activity receipt
|
| 80 |
-
invalid/ #
|
| 81 |
tampered-payload.json # a payload byte flipped -> DSSE PAE content-hash mismatch
|
| 82 |
broken-chain.json # prev rewritten -> hash-chain link breaks
|
| 83 |
```
|
| 84 |
|
| 85 |
`bench.jsonl` is the machine-readable manifest (the dataset viewer renders it):
|
| 86 |
each row carries `file`, `category` (`valid`/`invalid`), `expected_result`
|
| 87 |
-
(`PASS`/`FAIL`), the `source_dataset`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 88 |
|
| 89 |
---
|
| 90 |
|
| 91 |
-
##
|
| 92 |
|
| 93 |
| File | Source dataset | Shows |
|
| 94 |
| --- | --- | --- |
|
|
@@ -98,13 +147,15 @@ each row carries `file`, `category` (`valid`/`invalid`), `expected_result`
|
|
| 98 |
| `valid/readiness-audit-receipt.json` | [`SZLHOLDINGS/readiness-runs`](https://huggingface.co/datasets/SZLHOLDINGS/readiness-runs) | unsigned envelope with `payloadSha256` |
|
| 99 |
| `valid/daily-activity-receipt.json` | `SZLHOLDINGS/szl-evidence` | HMAC-stub daily activity receipt |
|
| 100 |
|
| 101 |
-
The two `invalid/` files are byte-level
|
| 102 |
-
included purely to exercise
|
| 103 |
-
|
|
|
|
|
|
|
| 104 |
|
| 105 |
---
|
| 106 |
|
| 107 |
-
##
|
| 108 |
|
| 109 |
The verifier is Python 3 standard library only — no third-party packages, no
|
| 110 |
network.
|
|
@@ -115,8 +166,9 @@ git clone https://huggingface.co/datasets/SZLHOLDINGS/governed-receipts-bench
|
|
| 115 |
# 2. get the spec + verifier
|
| 116 |
git clone https://github.com/szl-holdings/governed-receipt-spec
|
| 117 |
cd governed-receipt-spec
|
|
|
|
| 118 |
|
| 119 |
-
# 3. the
|
| 120 |
python verify.py ../governed-receipts-bench/valid/*.json # -> OVERALL: PASS
|
| 121 |
|
| 122 |
# 4. ... and the tampered ones FAIL
|
|
@@ -127,11 +179,30 @@ python verify.py ../governed-receipts-bench/invalid/broken-chain.json # ->
|
|
| 127 |
Or paste any receipt into the live verifier Space:
|
| 128 |
**[`SZLHOLDINGS/governed-receipt-verifier`](https://huggingface.co/spaces/SZLHOLDINGS/governed-receipt-verifier)**.
|
| 129 |
|
| 130 |
-
|
| 131 |
-
the JSON Schema
|
| 132 |
-
|
| 133 |
-
|
| 134 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 135 |
|
| 136 |
---
|
| 137 |
|
|
|
|
| 20 |
- other
|
| 21 |
configs:
|
| 22 |
- config_name: default
|
| 23 |
+
data_files:
|
| 24 |
+
- split: train
|
| 25 |
+
path: bench.jsonl
|
| 26 |
---
|
| 27 |
|
| 28 |
<div align="center">
|
|
|
|
| 39 |
|
| 40 |
A small **benchmark corpus of governance decision receipts** for the open
|
| 41 |
[`governed-receipt-spec`](https://github.com/szl-holdings/governed-receipt-spec).
|
| 42 |
+
`bench.jsonl` declares one expected outcome for each case under the spec's
|
| 43 |
+
**dependency-free offline verifier**. With the fixture bytes at dataset commit
|
| 44 |
+
[`2887f9a`](https://huggingface.co/datasets/SZLHOLDINGS/governed-receipts-bench/commit/2887f9af1137bef789edf2e9eaad9177a1d6d27e)
|
| 45 |
+
and verifier commit
|
| 46 |
+
[`007106b`](https://github.com/szl-holdings/governed-receipt-spec/commit/007106bcb0212138345e19eb5efba8bb69327d57),
|
| 47 |
+
the five `valid/` rows return **PASS** and the two `invalid/` rows return
|
| 48 |
+
**FAIL**. These are conformance labels for the checks that verifier performs,
|
| 49 |
+
not proof that every recorded statement is true or that signer identity was
|
| 50 |
+
cryptographically established.
|
| 51 |
|
| 52 |
Built and maintained by [SZL Holdings](https://a-11-oy.com). Apache-2.0.
|
| 53 |
|
| 54 |
+
> **Fixture provenance.** The manifest identifies the public datasets from which
|
| 55 |
+
> the `valid/` files are declared to originate. This benchmark checks the bytes
|
| 56 |
+
> supplied here; it does not independently prove those provenance statements or
|
| 57 |
+
> the real-world truth of payload claims. The `invalid/` files are explicitly
|
| 58 |
+
> labeled mutations. Where energy was not measured, the fixture records
|
| 59 |
> `null` / `UNAVAILABLE`.
|
| 60 |
|
| 61 |
---
|
|
|
|
| 65 |
A **governed inference receipt** is the small, replayable, hash-chained record a
|
| 66 |
governed AI runtime emits for one governed action (e.g. an inference): what it
|
| 67 |
**decided**, the **Λ** governance-floor status, whether **energy** was actually
|
| 68 |
+
measured, and a **DSSE-style** envelope that lets anyone re-check supported structural,
|
| 69 |
+
hash, schema, and chain relations offline.
|
| 70 |
|
| 71 |
A receipt is explicitly **NOT** a zero-knowledge proof and **NOT** a proof of
|
| 72 |
+
computation. It is an audit-record format for a governance decision and any
|
| 73 |
+
byte-binding or chain relations that are actually present and checked. Some
|
| 74 |
+
fixtures here are unsigned or lack a checked content-hash field, so their trust
|
| 75 |
+
strength is limited to the checks recorded below. See the spec for the full framing.
|
| 76 |
|
| 77 |
---
|
| 78 |
|
|
|
|
| 80 |
|
| 81 |
```
|
| 82 |
bench.jsonl # one row per case: file, category, expected_result, source, note
|
| 83 |
+
valid/ # manifest expectation: PASS under the pinned verifier
|
| 84 |
a11oy-khipu-chain.json # 5-receipt signed hash chain (seq 0->4)
|
| 85 |
a11oy-khipu-genesis.json # single signed genesis receipt (seq 0, prev = 64 zeros)
|
| 86 |
lake-inference-receipt.json # decision=allow + measured-or-null energy in the clear
|
| 87 |
readiness-audit-receipt.json# unsigned envelope, content bound by payloadSha256
|
| 88 |
daily-activity-receipt.json # HMAC-stub daily activity receipt
|
| 89 |
+
invalid/ # labeled mutations; manifest expectation: FAIL
|
| 90 |
tampered-payload.json # a payload byte flipped -> DSSE PAE content-hash mismatch
|
| 91 |
broken-chain.json # prev rewritten -> hash-chain link breaks
|
| 92 |
```
|
| 93 |
|
| 94 |
`bench.jsonl` is the machine-readable manifest (the dataset viewer renders it):
|
| 95 |
each row carries `file`, `category` (`valid`/`invalid`), `expected_result`
|
| 96 |
+
(`PASS`/`FAIL`), the manifest-declared `source_dataset`, `n_receipts`, and a
|
| 97 |
+
`note`. The manifest has **7 unique paths**, **5 PASS** labels, **2 FAIL** labels,
|
| 98 |
+
and **19 receipt objects** across the referenced files.
|
| 99 |
+
|
| 100 |
+
## Load the manifest directly
|
| 101 |
+
|
| 102 |
+
The `default` configuration has one explicit `train` split and needs no custom
|
| 103 |
+
dataset loading code:
|
| 104 |
+
|
| 105 |
+
```python
|
| 106 |
+
from collections import Counter
|
| 107 |
+
from datasets import load_dataset
|
| 108 |
+
|
| 109 |
+
bench = load_dataset(
|
| 110 |
+
"SZLHOLDINGS/governed-receipts-bench",
|
| 111 |
+
name="default",
|
| 112 |
+
split="train",
|
| 113 |
+
)
|
| 114 |
+
assert len(bench) == 7
|
| 115 |
+
assert Counter(bench["expected_result"]) == {"PASS": 5, "FAIL": 2}
|
| 116 |
+
```
|
| 117 |
+
|
| 118 |
+
Loading the manifest does not itself verify the referenced fixture files. Run
|
| 119 |
+
the pinned verifier below for that step.
|
| 120 |
+
|
| 121 |
+
## Exact case matrix
|
| 122 |
+
|
| 123 |
+
The following results were reproduced against the pinned dataset and verifier
|
| 124 |
+
commits linked above. The manifest and verifier do **not** expose stable,
|
| 125 |
+
machine-readable failure codes, so none are invented here; the last column
|
| 126 |
+
records the verifier's supported check or prose failure reason.
|
| 127 |
+
|
| 128 |
+
| File | Objects | Expected | Reproduced | Supported result / reason |
|
| 129 |
+
| --- | ---: | ---: | ---: | --- |
|
| 130 |
+
| `valid/a11oy-khipu-chain.json` | 5 | PASS | PASS | 5 PAE hashes and 5 schema checks pass; chain intact across 5 receipts |
|
| 131 |
+
| `valid/a11oy-khipu-genesis.json` | 1 | PASS | PASS | PAE hash and schema pass; one-receipt genesis chain intact |
|
| 132 |
+
| `valid/lake-inference-receipt.json` | 1 | PASS | PASS | PAE hash and schema pass; one-receipt chain intact |
|
| 133 |
+
| `valid/readiness-audit-receipt.json` | 1 | PASS | PASS | `payloadSha256` passes; envelope is unsigned with 0 signatures; schema skipped; chain not applicable |
|
| 134 |
+
| `valid/daily-activity-receipt.json` | 1 | PASS | PASS | Structural envelope check only; unsigned with 1 signature entry; no content-hash field; schema skipped; chain not applicable |
|
| 135 |
+
| `invalid/tampered-payload.json` | 5 | FAIL | FAIL | Receipt 2 payload is invalid JSON and its recomputed PAE SHA-256 mismatches `_pae_sha256`; chain then also fails |
|
| 136 |
+
| `invalid/broken-chain.json` | 5 | FAIL | FAIL | Receipt at `seq=3` has `prev=deadbeef...`, which does not equal the `seq=2` digest |
|
| 137 |
|
| 138 |
---
|
| 139 |
|
| 140 |
+
## Manifest-declared provenance of the `valid/` fixtures
|
| 141 |
|
| 142 |
| File | Source dataset | Shows |
|
| 143 |
| --- | --- | --- |
|
|
|
|
| 147 |
| `valid/readiness-audit-receipt.json` | [`SZLHOLDINGS/readiness-runs`](https://huggingface.co/datasets/SZLHOLDINGS/readiness-runs) | unsigned envelope with `payloadSha256` |
|
| 148 |
| `valid/daily-activity-receipt.json` | `SZLHOLDINGS/szl-evidence` | HMAC-stub daily activity receipt |
|
| 149 |
|
| 150 |
+
The two `invalid/` files are byte-level mutations of
|
| 151 |
+
`a11oy-khipu-chain.json`, included purely to exercise two failure paths. The
|
| 152 |
+
`tampered-payload` file differs by one byte. The `broken-chain` file rewrites the
|
| 153 |
+
`seq=3` `prev` value and recomputes the PAE-bound identifiers, leaving the chain
|
| 154 |
+
relation invalid.
|
| 155 |
|
| 156 |
---
|
| 157 |
|
| 158 |
+
## Verify with the standard-library reference verifier
|
| 159 |
|
| 160 |
The verifier is Python 3 standard library only — no third-party packages, no
|
| 161 |
network.
|
|
|
|
| 166 |
# 2. get the spec + verifier
|
| 167 |
git clone https://github.com/szl-holdings/governed-receipt-spec
|
| 168 |
cd governed-receipt-spec
|
| 169 |
+
git checkout 007106bcb0212138345e19eb5efba8bb69327d57
|
| 170 |
|
| 171 |
+
# 3. the manifest-labeled valid fixtures PASS ...
|
| 172 |
python verify.py ../governed-receipts-bench/valid/*.json # -> OVERALL: PASS
|
| 173 |
|
| 174 |
# 4. ... and the tampered ones FAIL
|
|
|
|
| 179 |
Or paste any receipt into the live verifier Space:
|
| 180 |
**[`SZLHOLDINGS/governed-receipt-verifier`](https://huggingface.co/spaces/SZLHOLDINGS/governed-receipt-verifier)**.
|
| 181 |
|
| 182 |
+
At the pinned verifier commit, inference decision objects are checked against
|
| 183 |
+
the JSON Schema; non-inference objects are skipped. The verifier recomputes a
|
| 184 |
+
content hash only when `_pae_sha256` or `payloadSha256` is present, checks
|
| 185 |
+
`prev`/`digest` and contiguous `seq` relations for chainable records, and checks
|
| 186 |
+
envelope structure. It does **not** cryptographically verify signature bytes,
|
| 187 |
+
public-key ownership, or signer identity, and it does not re-derive the runtime's
|
| 188 |
+
internal `digest`.
|
| 189 |
+
|
| 190 |
+
## Fail-closed interpretation and limitations
|
| 191 |
+
|
| 192 |
+
- Treat **PASS** as success only for checks the verifier actually ran. `SKIP` or
|
| 193 |
+
`n/a` is not evidence that the omitted property holds.
|
| 194 |
+
- Treat malformed input, an unknown schema/payload type/algorithm/key, a missing
|
| 195 |
+
required verifier resource, or a verifier exception as **FAIL** or
|
| 196 |
+
**UNAVAILABLE**; never as PASS. Integrations may need stricter policy than the
|
| 197 |
+
reference verifier.
|
| 198 |
+
- A structurally present signature entry is not a cryptographically verified
|
| 199 |
+
signature. In particular, the daily-activity fixture has no independently
|
| 200 |
+
checked content hash at this verifier revision.
|
| 201 |
+
- A receipt can bind bytes without proving that payload claims are factually
|
| 202 |
+
correct, that computation occurred, or that a decision was safe.
|
| 203 |
+
- The two negative fixtures cover only a PAE/payload mutation and a broken chain
|
| 204 |
+
link. They are not an exhaustive adversarial suite, a security certification,
|
| 205 |
+
or a comparison of verifier implementations.
|
| 206 |
|
| 207 |
---
|
| 208 |
|