/specs · v2.4
Proof specification
“Reconciled” means three concrete things: every line traces to a signature, the pack is tamper-evident, and anyone can reproduce it from the same inputs. MerkleBooks prepares audit-ready workpapers — it is not a CPA firm and does not issue audit opinions.
1. Balance invariant
For every wallet, mint and period, the ledger must satisfy the equation below. A non-zero Δ blocks the close and creates a review item.
Δ = pre_balance + inflows − outflows − fees − post_balance require Δ == 0 // checked against on-chain post-token balances
2. Merkle seal
Each journal line is canonicalised (sorted keys, fixed decimals) and hashed with SHA-256. Lines are ordered by (slot, signature, index) and folded into a Merkle root printed on every export.
leaf = sha256(canonical_json(line)) node = sha256(left || right) root = 0x9f3c…a71e
3. Reproducibility header
| Field | Example | Purpose |
|---|---|---|
| ruleset_version | 2026.10.1 | Which accounting rules fired |
| decoder_versions | jup@6.4, dlmm@3.1 | Which parsers ran |
| slot_range | 298,104,220 – 312,891,402 | Exact chain window |
| merkle_root | 0x9f3c…a71e | Tamper evidence |
4. Verify it yourself
$ cargo install merkle-verify $ merkle-verify audit-pack-2026-Q3.json --rpc <your-rpc> ✓ 4,812 lines · root matches · Δ = 0 on 37 mints
The verifier is independent of our servers: it re-fetches signatures from your own RPC.