Hive Canon · Provable Layer · Born Here

SMSH. The seal on the state the agent thought from.

SMSH stands for Sealed Message-State Hash. It's the cryptographic seal that ties every Tre’gent receipt to the exact reasoning state the agent was in when it acted. A receipt tells you what the agent did. SMSH tells you what the agent knew when it did it. You need both to actually audit an action. Either one by itself isn't enough.

Provable Layer · Hive Primitive SMSH LIVE SMSH-PQ LIVE SMSH-MAX LIVE URN reserved · v0.3.3

What it is

An LLM doesn't remember anything between calls. Whatever the agent was reasoning over in the moment, like instructions, retrieved context, earlier turns in the conversation, tool outputs, or policy rules, only existed inside that one inference window. The second the call finishes, all of that is gone. SMSH grabs a cryptographic fingerprint of that window before it disappears, and locks it to the receipt that records what the agent did next.

Without SMSH, a receipt can only say "the agent did X at time T." With SMSH, the receipt can also say "this action came from reasoning state smsh:…, and anyone holding the original data can check that hash matches, byte for byte." You can no longer pull the action apart from the reasoning that led to it.

What it binds

01

Prompt & instruction set

The system prompt, the user/principal instruction, and any tool-use directives present at execution time. Hashed in canonical order.

02

Retrieved context

RAG hits, vector lookups (SVU surface), prior turn history, tool outputs returned into the window. Bound by content hash.

03

Policy posture

The SHOD policy snapshot checked at the moment of the action. This covers the allowlist, daily cap, recipient cap, price window, trust tier, and anomaly state.

04

Identity & principal

The agent identity, the principal/HAHS handle, and the delegation chain in effect when the inference resolved.

How the hash gets built

SMSH always gives the same result for the same inputs. Any verifier who runs the same data through it gets the same hash. First the data gets put into one standard order, then it gets hashed.

# Canonical SMSH construction (v1) state := { "prompt": canonical(prompt_bundle), # sorted-key JSON "context": merkle_root(retrieved_items), # content-addressed "policy": canonical(shod_snapshot), # sorted-key JSON "identity": canonical(principal_record), # HAHS handle bound "tool_outputs": merkle_root(tool_returns), "ts": iso8601_utc(execution_time) } canonical_bytes := sorted_json(state, separators=(",", ":")) smsh := "smsh:" + base64url( SHA-256(canonical_bytes) )

Every Tre’gent receipt carries the SMSH value in a top-level smsh field. If you rebuild the hash from the published source data, it has to match that field byte for byte. If it doesn't match, the offline verifier rejects the receipt.

The four tiers

SMSH ships in four live tiers. Each one covers a different audit need, and each one plugs straight into the AFIR signing pipeline.

SMSH (canonical, LIVE)
Single-state seal, the default for production

This is one SHA-256 hash over the state record, put in standard order first. It's built into every Tre’gent receipt the Hive Lattice issues. You can check it offline against the published rule for standard order and the issuer's Ed25519 key.

HashSHA-256 over canonical-sorted JSON
Encodingbase64url, no padding
Receipt fieldsmsh (top-level)
StatusLIVE on the transaction harness
VerifierTre’gent offline verifier · verify_receipt.py
SMSH-Quorum
K-of-N threshold seal for chains of authority

Sometimes an action's authority traces back through several earlier steps. When that happens, SMSH-Quorum requires at least K out of N of those earlier SMSH values to carry valid signatures before it honors the new receipt. Tre’gent checks this rule as part of tracing an action's ancestry. It's used for delegated authority chains and for actions that need agreement from multiple agents.

PredicateK-of-N over ancestor SMSH signatures
DefaultK = 2, N = 3 (configurable per principal)
Receipt fieldsmsh_quorum (when invoked)
StatusLIVE, claim A on the Tre’gent page
SMSH-Δ
Records every change as it happens, so nobody can fake the history

State changes between turns all the time. A tool output revises a fact, a policy snapshot updates, a piece of context gets swapped out. SMSH-Δ locks each one of those changes to the SMSH that came right before it. That builds a chain of signed changes that nobody can quietly edit later without breaking the chain. The record of how the reasoning changed over time is backed by math, not just a story someone tells you.

Constructiondelta = canonical(diff(state_prev, state_next))
AnchorSHA-256(prev_smsh ‖ delta_bytes)
Receipt fieldsmsh_delta_chain (when invoked)
StatusLIVE, claim B on the Tre’gent page
SMSH-PQ
A sealed envelope built to survive quantum computers

For sensitive inspection files, ViewKey material, and evidence that only specific auditors should see, SMSH-PQ wraps the standard SMSH in a post-quantum sealed envelope, using ML-KEM-768 for key exchange. The original SMSH binding stays exactly as it was. The PQ layer just adds more protection on top. It's signed twice: once with ML-DSA-65 (NIST FIPS 204, the government's post-quantum signature standard) over the same digest, and once with Ed25519 so older systems can still check it. AFIR uses this on every receipt that holds regulated evidence with a long retention window.

EnvelopeML-KEM-768 (NIST FIPS 203) key encapsulation
Signature postureML-DSA-65 (NIST FIPS 204) primary, Ed25519 for legacy compatibility
Use caseLong-retention regulated evidence, sealed inspection payloads, AFIR receipts
StatusLIVE, see the Hive-PQ page
SMSH-MAX
The strongest option: everything chained together

This is the top tier. SMSH-MAX wraps the standard SMSH in SMSH-PQ signing, adds the SMSH-Δ change chain across the whole multi-turn conversation, and anchors the resulting Merkle root on-chain through Base and USDC. It's built for regulated setups where an auditor or regulator needs to rebuild the entire chain of reasoning, policy state, and signatures from one file they can check themselves, even years after the fact.

ConstructionSMSH-PQ envelope + SMSH-Δ chain + on-chain Merkle anchor
AnchorBase mainnet, USDC settlement layer
Signature postureML-DSA-65 primary, Ed25519 compat, full delta chain
Use caseFinancial settlement, FINRA WORM, EU AI Act high-risk, SR 11-7 model risk, multi-year retention
StatusLIVE, anchored on-chain via AFIR receipts

How it fits the receipt

A Tre’gent receipt is the signed record of one agent action. It names the actor, the action, the amount, the time, the counterparty, the policy checks it passed (SHOD), and the SMSH of the reasoning state that authorized it. Verification has to match exactly, byte for byte. The offline verifier (verify_receipt.py) puts the receipt back in standard order, rebuilds the SMSH from the published source data, and only then checks the Ed25519 signature. If anything in the receipt or the source data has shifted even slightly, verification fails.

# Verifying a receipt with SMSH binding (sketch) canon := sorted_json(receipt, separators=(",", ":")) sig_ok := ed25519_verify(issuer_pubkey, canon, receipt.sig) smsh_ok:= ( sha256(sorted_json(receipt.state_pre)) == receipt.smsh ) pass := sig_ok and smsh_ok

Why it matters

You can't rebuild an audit trail from logs after the fact. Logs can be edited. Pipelines change over time. Context windows don't stick around. By the time a regulator asks "why did the agent do this," the reasoning state behind that action is already gone. SMSH fixes that by hashing the state into the receipt before the action even finishes. The proof exists from the very first moment. It's not a story someone reconstructs later.

For regulated buyers in financial settlement, healthcare, legal, and government, this is the difference between "the agent did it" and "the agent did it under this exact policy, with this exact context, signed and checkable by anyone offline." That difference is what Hive sells.

Current status

All four tiers are LIVE. The URN is reserved at urn:hive:smsh:v1. SMSH is a Hive primitive registered in hivetrust.json under the provable layer. SMSH and SMSH-Δ are live on the transaction harness (step 08). SMSH-Quorum is live as claim A on the Tre’gent reasoning page. SMSH-PQ and SMSH-MAX are live on the Hive-PQ evidence profile and through AFIR receipts. SMSH-MAX anchors on Base mainnet through USDC. The rule for standard ordering and the source-data format at /.well-known/schemas/smsh-v1.json is at version 0.3.3. Hive wrote and maintains this spec.