Decision Trace Format — Conformance Vectors
These vectors are normative for the Decision Trace Format 1.0. A conformant verifier must produce the stated result and exactly the stated set of (code, trace_id, seq) errors for every vector. Error detail text is not part of conformance.
Each directory contains:
| File | Purpose |
|---|---|
trace.jsonl — or parent.jsonl + child.jsonl for bundles |
The trace(s) to verify, in interchange form |
keys.json |
The key set the verifier is given |
expected.json |
The required result and error set |
To run them with the reference verifier:
rashnu trace verify --keys 03-tampered-content/keys.json 03-tampered-content/trace.jsonl
| Vector | Exercises | Expected |
|---|---|---|
| 01-valid-closed | A complete, closed trace | VALID |
| 02-valid-open | The same trace with no trace.closed |
VALID_OPEN |
| 03-tampered-content | One byte of content altered after signing | E_CONTENT_HASH |
| 04-tampered-header | A hashed envelope field altered after signing | E_RECORD_HASH |
| 05-removed-record | One record deleted from the middle | E_SEQ, E_PREV_HASH at the gap only |
| 06-reordered-records | Two adjacent records swapped | E_SEQ, E_PREV_HASH, E_TS_ORDER on the affected records |
| 07-unknown-key | Correctly signed by a key not in the key set | E_KEY_UNKNOWN |
| 08-wrong-key-signature | kid names one key, signature made with another |
E_SIG |
| 09-key-expired | A key in the set, used outside its validity window | E_KEY_EXPIRED |
| 10-redacted-valid | Content erased and the erasure recorded | VALID |
| 11-redacted-unrecorded | Content erased silently | E_UNRECORDED_REDACTION |
| 12-redaction-targets-genesis | A redaction.applied naming seq 0 |
E_REDACTION_TARGET |
| 13-record-after-close | A tool call appended after trace.closed |
E_AFTER_CLOSE |
| 14-missing-required-field | task.submitted without idempotency_key |
E_KIND_RULE |
| 15-delegation-valid | Parent and child correctly linked, child envelope within parent’s | VALID |
| 16-delegation-widened | Child holds a clearance the parent lacks | E_ENVELOPE_WIDENED |
| 17-delegation-broken-link | Child’s parent pointer lands on the wrong record | E_PARENT_LINK on both sides |
| 18-key-revoked-mid-trace | A key withdrawn part-way through the trace it was signing | E_KEY_REVOKED on the record signed after the revocation only |
| 19-empty-trace | A file holding no records at all | EMPTY — not VALID_OPEN, which would vouch for a fetch that failed |
The vectors are generated by the reference implementation (Rashnu) from pkg/trace/vectors_test.go with fixed, seeded keys so that they are byte-for-byte reproducible. The expected results are written by hand from the specification, not derived from the verifier; the test suite checks the verifier against them. Regenerate with make vectors.