RAGLedger

Specification · v0.4 (draft for comment)

An open format for AI answer receipts.

Evidence should not depend on one vendor. The receipt spec defines what a receipt holds, how it is hashed, signed and chained, and how anyone can verify it.

RAGLedger receiptspec 0.4 · sample
Receipt
rcpt_01JD8X2
Issued
2026-11-19 09:14 UTC
Assistant
Cover Helper · UK
Customer
C-48213

Question

Does my travel policy cover skiing?

Answer

Yes. Travel Plus covers on-piste skiing for up to 17 days per trip. Off-piste only with a guide.

Source
DOC-TRV v3 · ch-112 · 0.91
Source
DOC-TRV v3 · ch-118 · 0.84
Model
gpt-4.1 · Azure UK South
Prompt
cover-helper/v19
Policy
pack v14 · 6/6 pass
prev
e0d222…e3aa
hash
d1324a…8b08
sig
Ed25519 · nvm-uk-2026-09

#0001Fields

What every receipt holds.

FieldTypeMeaning
receipt_idstringUnique ID, prefixed rcpt_
spec_versionstringReceipt spec version
issued_atRFC 3339When the answer was given
assistantobjectAssistant ID, version and region
session_id / turnstring / intConversation and turn
customer_refstringYour pseudonymous customer reference
questionobjectText (optionally redacted) and SHA-256
answerobjectText as given and SHA-256
retrieval[]arraydoc_id, doc_version, chunk_id, score, chunk_sha256
modelobjectProvider, name, version and parameters
promptobjectTemplate ID, version and SHA-256
policyobjectRule pack version and results
approverobject, optionalRole, ID and time of human approval
retentionobjectPolicy, delete-after date, legal hold
prev_hash / hashhexChain link and this receipt's SHA-256
signatureobjectEd25519 signature and key ID
anchorobjectMerkle root, batch and anchored time

#0002Sample

One receipt, in full.

Fictional sample. Hashes shortened for display.

{
  "receipt_id": "rcpt_01JD8X2",
  "spec_version": "0.4",
  "issued_at": "2026-11-19T09:14:22Z",
  "assistant": { "id": "cover-helper", "version": "19", "region": "uk" },
  "customer_ref": "C-48213",
  "question": { "text": "Does my travel policy cover skiing?", "sha256": "…" },
  "answer": { "text": "Yes. Your Travel Plus policy covers…", "sha256": "d1324a…8b08" },
  "retrieval": [
    { "doc_id": "DOC-TRV", "doc_version": "v3", "chunk_id": "ch-112", "score": 0.91, "chunk_sha256": "…" }
  ],
  "model": { "provider": "azure-openai", "name": "gpt-4.1", "params": { "temperature": 0.1 } },
  "prompt": { "template_id": "cover-helper", "version": "19", "sha256": "…" },
  "policy": { "pack": "northvale/v14", "results": [{ "rule": "R1", "result": "pass" }] },
  "retention": { "policy": "uk-6y", "delete_after": "2032-11-19", "hold": null },
  "prev_hash": "e0d222…e3aa",
  "hash": "d1324a…8b08",
  "signature": { "alg": "Ed25519", "key_id": "nvm-uk-2026-09", "value": "…" },
  "anchor": { "merkle_root": "7c1e…a90b", "batch": "2026-11-19" }
}

#0003Integrity

How a receipt proves itself.

01

Canonical hash

SHA-256 over the canonical JSON of the receipt, excluding the signature.

02

Signature

Ed25519 with a tenant key ID. Retired keys stay published for verification.

03

Chain

prev_hash links each receipt to the one before in the same ledger.

04

Anchor

A daily Merkle root over the batch, published so inclusion can be proved.

#0004Status

Draft for comment.

Version 0.4 is a working draft. We are collecting comments from design partners in banking, insurance and the public sector before a 1.0 release.

Licence, governance and the path to 1.0 are being finalised with design partners. Ask for the draft.

Next entry

See a recall run on an assistant like yours.

We connect a sample assistant, withdraw a document and show every affected answer, with the receipts and the evidence pack.