Diagram as text
- Each entry has two hashes:
prev_hash(the hash of the entry before it) and its ownhash. - Changing or removing any entry breaks every hash after it.
- An anchor is a signed statement of a stream's head: stream, sequence, head hash and time, signed with an Ed25519 key.
- Anchors are exported to a Git repository (the
ledger-anchorsbranch), so a verifier can compare the database with history kept elsewhere.
The ledger
Section titled “The ledger”Every action, model call, cost, policy decision, gate result, eval, approval and decision is an entry in an append-only ledger. Entries are never edited or deleted.
Each entry has a sequence number, an actor, a type (such as run.started, model.called,
budget.reserved, gate.completed, approval.decided, run.ended), a payload, an optional cost and
two hashes: prev_hash and its own hash (SHA-256 over a canonical form). Changing or removing any
entry breaks every hash after it.
- Hashes, not content. The ledger holds hashes and metadata (model, tokens, cost, verdict). The built-in paths never write prompts or outputs to it; free text in a custom worker’s payload is not scanned. Content, when it is kept, lives in the content store.
- One transaction. A state change and its ledger entry are written together, so the ledger cannot miss a change or record one that did not happen.
- People are opaque ids. A person appears as
human:<id>; emails and dotted names are refused (other names are not blocked).
Verifying
Section titled “Verifying”nuramesh ledger verify --team my-teamThis re-checks every stream’s hash chain against the database’s own head. It finds accidental damage
and edits inside the chain. It cannot, by itself, notice that the newest events or a whole stream were
deleted. For that you keep a head hash somewhere else (--expected-head) or use anchors.
Anchors
Section titled “Anchors”An anchor is a signed statement of a stream’s head: stream, sequence, head hash and time, signed
with an Ed25519 key. Anchors are exported to a Git repository (the ledger-anchors branch), so a
verifier can compare the database with history kept elsewhere.
- The word “verified” in a run report (
(verified)) andverify-ledger’sokmean the hash chains check out. They say nothing about anchors. - In the API,
okmeans nothing wrong was found.verifiedis true only when the chain is intact and signed anchors check out. A stream with no anchors isokbut notverified. - Events newer than the last anchor are reported as unanchored, not hidden.
- Anchors protect against editing the database. They do not protect against someone who controls both the host and the signing key. The security baseline lists this limit.
How to set it up: Anchor to Git.
Related pages
Section titled “Related pages”- Anchor the ledger to Git.
- Auditor guide.
- Content store and retention: where content lives, since the ledger holds hashes.
Was this page helpful?