src/bin/generate_agent_vectors.rsThis document defines the authoritative set of 20 conformance test vectors for the H33 Agent Governance Attestation Model v1.0. Each vector specifies a deterministic input-output contract that any independent verifier implementation MUST satisfy to claim conformance with the agent governance specification.
Conformance vectors are the mechanism by which H33 enforces verifier equivalence: if two independent implementations consume the same vector and produce the same output, they are functionally equivalent for that operation. This property is the foundation of replay-grade attestation — the ability to reconstruct agent governance state from the chain alone, without contacting the originating infrastructure.
The vectors are generated deterministically by src/bin/generate_agent_vectors.rs in the scif-backend repository. They are machine-readable JSON files that serve as the immutable conformance corpus for the agent governance layer.
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119.
To generate the canonical vector set from source:
# From the scif-backend repository root
cargo run --bin generate_agent_vectors --releaseThis produces 20 JSON files (AGT-TV-001.json through AGT-TV-020.json) in the output directory. Each file is a self-contained test vector.
An independent verifier implementation MUST follow this process for each vector:
input object and feed it to the corresponding operation in your implementation.expected_output object.expected_output MUST match exactly. Partial matches constitute a conformance failure.An implementation SHALL be considered conformant if and only if all 20 vectors produce byte-identical expected outputs. An implementation that passes 19 of 20 vectors is non-conformant.
Determinism requirement: Running the same vector 1,000 times MUST produce the same output 1,000 times. Any non-determinism in hash computation, chain traversal, or replay extraction disqualifies the implementation.
| ID | Category | Name | Result |
|---|---|---|---|
AGT-TV-001 |
Identity | Valid Agent Receipt — canonical name generation from agent fields | PASS |
AGT-TV-002 |
Identity | Valid Agent Session — ML-DSA keypair generation and scope binding | PASS |
AGT-TV-003 |
Session | Valid DAG (3 Nodes) — SessionStart, ToolCall, SessionEnd chain | PASS |
AGT-TV-004 |
Session | Valid DAG (10 Nodes) — mixed node types with Merkle root | PASS |
AGT-TV-005 |
DAG Ops | Tampered Receipt — payload modified after hash computation | FAIL |
AGT-TV-006 |
DAG Ops | Broken Chain — non-existent predecessor reference | FAIL |
AGT-TV-007 |
DAG Ops | Forged Hash — manually replaced node_id vs computed SHA3-256 | FAIL |
AGT-TV-008 |
Tool & Memory | Missing Predecessor — orphan node with non-zero, non-existent predecessor | FAIL |
AGT-TV-009 |
Tool & Memory | Replay Determinism — two identical DAGs produce identical frames | PASS |
AGT-TV-010 |
Policy | Replay at Timestamp — 5-point time-slice with monotonic node counts | PASS |
AGT-TV-011 |
Replay | Scope Violation — forbidden tool and data class rejection | FAIL |
AGT-TV-012 |
Replay | Expired Session — post-expiration action rejection | FAIL |
AGT-TV-013 |
Replay | Delegation Chain — 3-level scope narrowing with budget tracking | PASS |
AGT-TV-014 |
Integrity | Exposure Attestation — PII non-exposure proof via FHE path | PASS |
AGT-TV-015 |
Integrity | Tool Envelope — MCP tool attestation with provenance score | PASS |
AGT-TV-016 |
Key Mgmt | Memory Checkpoint — SHA3-256 state capture with predecessor link | PASS |
AGT-TV-017 |
Governance | Approval Flow — request/grant DAG linkage with human supervisor | PASS |
AGT-TV-018 |
Governance | Root Hash Computation — deterministic Merkle roots across DAG sizes | PASS |
AGT-TV-019 |
Governance | Subgraph Extraction — multi-session DAG partitioning with independent roots | PASS |
AGT-TV-020 |
Governance | Cross-Session Reject — session isolation violation detection | FAIL |
Of the 20 vectors: 13 are PASS vectors (valid inputs that MUST be accepted) and 7 are FAIL vectors (invalid inputs that MUST be rejected with the specified failure reason).
Identity vectors verify that agent registration and session initialization produce deterministic, verifiable artifacts. An implementation MUST generate identical canonical names and bind cryptographic key material correctly.
ToolCallMetadataOnlytool_call.web_search — "Web search for policy data"INTACTtrue, Chain valid: true, Replay deterministic: truenode_id. Verify predecessor chain terminates at zero hash.h33.session.6311.20260518.001Activeweb_search, calculator], forbidden data classes [pii]UStrue, Chain valid: true, Replay deterministic: trueh33.session.{agent_id_prefix_4}.{YYYYMMDD}.{seq}. Confirm scope constraints are well-formed and session expiration is in the future relative to started_at.Session vectors verify correct DAG construction across multi-node sessions. An implementation MUST produce identical Merkle roots for identical inputs, maintain correct predecessor linkage, and close sessions with H33-74 commitments.
SessionStart (t=0) → ToolCall (t=1s) → SessionEnd (t=2s)node_id as predecessor_hashsession_id and agent_idINTACTtrueH33_AGENT_V1_MERKLE domain separator. Compare against expected root hash. Verify predecessor chain: node[2].predecessor = node[1].node_id, node[1].predecessor = node[0].node_id, node[0].predecessor = zero hash.INTACTtrueDAG operations vectors verify that an implementation correctly detects tampered data, broken chains, and forged hashes. These are negative vectors: the implementation MUST reject the input and report the specific failure mode.
node_id no longer matches the computed hash. The action_type field was changed to TAMPERED.action_type post-attestation.0x9b3e...89350xf036...9ed2 (mismatch)payload.action_typeCORRUPTEDfalse, Chain valid: false, Replay deterministic: falseHash mismatch: declared node_id does not match recomputed SHA3-256. Payload was modified after attestation.node_id. Implementation MUST reject the node and report CORRUPTED integrity status.predecessor_hash points to a node ID not present in the DAG.0xddeb...92bb (non-existent)BROKEN_CHAINtrue (node hash is correct), Chain valid: falseInvalidPredecessor: node references predecessor which does not exist in the DAG. DAG insertion rejected.predecessor_hash resolves to an existing node (or zero hash for genesis). Reject insertion and report BROKEN_CHAIN.node_id that does not match the computed SHA3-256. Unlike a tampered receipt (AGT-TV-005), the payload is untouched — only the declared hash was forged.0x9805...59af0x9860...9069HASH_MISMATCHfalse, Chain valid: falseHashMismatch: declared node_id != computed hash. DAG insertion rejected.node_id. Report HASH_MISMATCH and reject.Tool and memory vectors verify correct handling of orphan nodes, tool envelope attestation, memory checkpoint chaining, and replay determinism. These vectors exercise the data provenance layer of the agent governance model.
predecessor_hash references a node that does not exist in the DAG and is not the zero hash genesis marker. This is an orphan node that MUST be rejected on insertion.ToolCall with action tool_call.orphan0x6c7f...a5b0MISSING_PREDECESSORtrue, Chain valid: falseInvalidPredecessor: predecessor not found in DAG and is not zero hash. Insert rejected.MISSING_PREDECESSOR and BROKEN_CHAIN.1716000002500 (between node 2 and 3)truetruePolicy vectors verify deterministic time-slice replay across DAG states. An implementation MUST produce monotonically increasing node counts as replay timestamps advance, and each frame hash MUST be unique.
| Timestamp | Node Count | Frame Hash (prefix) |
|---|---|---|
1715999999999 | 0 | 0x0000...0000 (empty) |
1716000000500 | 1 | 0x3dd5...c51e |
1716000004500 | 5 | 0xeb3f...e908 |
1716000007500 | 8 | 0x65d4...eeb5 |
1716000099999 | 10 | 0x43ba...f516 |
timestamp <= replay_timestamp. Compute the frame hash. Node counts MUST be monotonically non-decreasing. All non-empty frame hashes MUST be unique.Replay vectors verify scope enforcement, session expiration, and delegation chain integrity. These vectors exercise the governance boundary layer that constrains agent actions.
file_write and data class pii. Both access attempts MUST be denied.web_search, calculatorpii, phifile_write (not in allowed list)pii (in forbidden list)false, Data class permitted: falseScope violation: tool 'file_write' not in allowed_tools; data class 'pii' in forbidden_data_classes. Both access attempts denied.Expired and expires_at < current_time.Expired1715996400000 (1 hour before check time)1716000000000falseSession expired: expires_at < current time. Session status is Expired. Actions rejected.expires_at timestamp and the status field. Either condition alone is sufficient for rejection. Both MUST be checked.web_search, calculator, file_read], budget 3, forbidden [phi]web_search, calculator], budget 2calculator], budget 1Integrity vectors verify exposure attestation and tool envelope correctness. These vectors exercise the data classification and provenance scoring subsystems.
piiNotExposedtrue, Chain valid: trueevidence_hash is a valid SHA3-256 digest. Confirm the exposure_status is a recognized enum value. Implementation MUST treat NotExposed as a cryptographic claim that can be independently verified against the evidence artifact.h33.tool.anthropic.claude-code.bash.v11.0.0mcp-server-001Successtruerequest_hash and response_hash are valid SHA3-256 digests, (b) response_timestamp > request_timestamp, (c) latency = response_timestamp - request_timestamp in microseconds, (d) provenance score is in range [0.0, 1.0]. Tool name MUST follow the canonical dotted format.Key management vectors verify memory checkpoint chaining and state capture. An implementation MUST maintain predecessor-linked checkpoint chains and produce correct SHA3-256 digests of memory, context window, and retrieved document state.
null (first in chain)memory_hash, context_window_hash, retrieved_docs_hashtruepredecessor_checkpoint is non-null, verify it references a valid prior checkpoint. Memory size MUST be a positive integer. Implementation SHOULD verify that checkpoint IDs form a monotonically ordered chain.Governance vectors verify approval flows, Merkle root computation, subgraph extraction, and cross-session isolation. These vectors exercise the highest-level governance operations that bind agent actions to organizational policy.
ApprovalRequest for $50,000 transfer to external_accountApprovalGrant by human supervisor, 30 seconds laternode_idagent_id values (requesting agent vs. approving supervisor)INTACTtruepredecessor_hash equals request node's node_id, (b) grant timestamp > request timestamp, (c) both nodes share the same session_id, (d) approval expiration is after grant time. The requesting agent and approving agent MUST have different agent_id values (separation of duties).H33_AGENT_V1_MERKLE domain separator and confirms that different DAG sizes produce different roots.| DAG Size | Root Hash |
|---|---|
| 1 | 0x2343ed3589cc94380cd86e2ac63da7c44ac21878444fea29c6887a5b79024134 |
| 3 | 0x559205332d00d75ddc992daf53b6e0a67bc869f9ce2b81ecc23a1397aa6a6cf1 |
| 5 | 0x7b7b8a965a06be79f3eae6cc78d94865c3cd9f858473f17b304cfd3f35a50859 |
| 10 | 0xb6f8e34e381a32ec574f618f0b53a47c75fae9202026f27fd9897ea00046f3ff |
H33_AGENT_V1_MERKLE domain separator. Roots MUST match exactly. All four roots MUST be distinct. Run the 10-node computation twice and verify byte-identical output.| Session | Nodes | Subgraph Root (prefix) |
|---|---|---|
| 1 | 5 | 0x04a5...3da6 |
| 2 | 3 | 0x6234...43ca |
| 3 | 7 | 0x53f9...cf4d |
session_id. Each subgraph MUST contain exactly the specified number of nodes. Compute independent Merkle roots per session. Full DAG root MUST differ from all subgraph roots. Sum of subgraph node counts MUST equal full DAG node count.0xfad1...ad440xd578...8313SESSION_ISOLATION_VIOLATEDtrue, Chain valid: falseCross-session predecessor: node in session B references predecessor from session A. Session isolation violated. An independent verifier implementation must reject this node.predecessor.session_id == node.session_id. Any mismatch MUST trigger SESSION_ISOLATION_VIOLATED. This check is REQUIRED even though the raw DAG insertion succeeds.Every vector file conforms to the following JSON schema. Implementations SHOULD validate vector files against this schema before processing.
{
"vector_id": "AGT-TV-NNN", // Unique identifier
"name": "Human-readable name", // Short description
"description": "...", // Full description
"category": "valid" | "invalid", // Expected outcome class
"input": { ... }, // Operation-specific input
"expected_output": {
"verification_status": "VERIFIED" | "FAILED",
"dag_integrity": "INTACT" | "CORRUPTED" | "BROKEN_CHAIN" | ...,
"hash_valid": true | false,
"chain_valid": true | false,
"replay_deterministic": true | false,
"expected_root_hash": "0x..." | null
},
"failure_reason": "..." | null, // null for valid vectors
"version": "1.0.0", // Spec version
"generated_at": "2026-05-18T00:00:00Z" // Generation timestamp
}Immutability guarantee: Once a vector is published at a given version, its input and expected_output fields SHALL NOT change. A change to any vector constitutes a new version of the conformance suite.
| Status | Meaning | Vectors |
|---|---|---|
INTACT | All hash chains valid, Merkle root matches, no tampering detected | 001, 003, 004, 017, 018, 019 |
CORRUPTED | Payload modified after hash computation; declared hash does not match recomputed hash | 005 |
BROKEN_CHAIN | Predecessor reference points to a non-existent node (chain link missing) | 006 |
HASH_MISMATCH | Node ID was forged; declared ID differs from computed SHA3-256 | 007 |
MISSING_PREDECESSOR | Predecessor hash is non-zero but references no existing node | 008 |
SESSION_ISOLATION_VIOLATED | Cross-session predecessor detected; node references predecessor from different session | 020 |
N/A | Vector does not test DAG integrity (session, scope, or exposure tests) | 002, 009, 010, 011, 012, 013, 014, 015, 016 |
An implementation MAY claim partial conformance by specifying which categories it supports. The categories and their required vectors are:
| Level | Categories | Vectors | Minimum |
|---|---|---|---|
| Core | Identity + Session + DAG Operations | 001–007 | 7/7 |
| Extended | Core + Tool/Memory + Policy + Replay | 001–013 | 13/13 |
| Full | All categories | 001–020 | 20/20 |
Implementations claiming any conformance level MUST pass all vectors in the specified set without exception.
| Reference | Title | URL |
|---|---|---|
| [Agent Spec] | AI Agent Governance Attestation Model v1.0 | h33.ai/specifications/agent-governance/ |
| [H33-Chaos] | H33-Chaos Adversarial Validation Suite | h33.ai/h33-chaos/ |
| [@h33/agent] | H33 Agent TypeScript SDK | h33.ai/sdk/h33-agent-ts/ |
| [GitHub] | H33 Post-Quantum GitHub Organization | github.com/H33ai-postquantum |
| [RFC 2119] | Key words for use in RFCs to Indicate Requirement Levels | rfc-editor.org/rfc/rfc2119 |
| [SHA3-256] | NIST FIPS 202: SHA-3 Standard | csrc.nist.gov |