Expand description
eml — the Epoch Merkle Log: a general-purpose append-only log.
The EML library — the polydigest combinator over the cml single-
algorithm engine — instantiated at arity k = 2, no prefix (the caller’s
Hasher is used directly, with no domain-separation wrapper). It is the
behavioral successor of the frozen pre-campaign baseline: its root and
inclusion proofs are byte-identical to that baseline (the peak-bag is the
same canonical fold), while the consistency proof is upgraded to the MMR
prefix-form for durable witnesses. Conformance is anchored by the Lean corpus
and the durability property tests, not a byte-equality oracle.
The full EML surface is re-exported, so a consumer reaches the library
through eml::*. The instantiation’s only opinion is the arity: the
config preset and new/from_storage constructors fix k = 2,
while the re-exported NaryMerkleLog still accepts any TreeConfig for
callers that need a different arity.
Modules§
- binding_
proof - Cross-algorithm binding proof — a first-class, named proof API.
- error
- The EML library’s error surface, reached through
eml::error::*. The driver’s storage-parameterisedpolydigest::LogErroris the publicError; this module preserves theeml::error::Errorpath the historical surface exposed. - evolution
- The epoch-coupled append-only evolution surface.
- filling
fill— the operator-level filling operation over a sealedcrate::Sealed.- hasher
- The
Hasherseam — the multihash interface of the kernel. - mr
- Merkle root and evaluation over the n-ary subtree, with canonicalization.
- mutable
polydigest(cmt)— the polydigest combinator over the Canonical Mutable Tree.- proof
- The full proof surface a consumer reaches through
polydigest::proof::*(and soeml::proof::*): the CML engine’s append-only consistency + inclusion/ leaf proofs, plus the combinator’s binding/coupling/audit proofs and the epoch-coupled evolution checks. The originals live incmland the combinator modules; this module re-exports them, never a parallel copy. - root
- The polydigest combinator’s root construction and coupling verification.
- seal
- Freezing the combinator’s append-only log into the one commitment currency
crate::Sealed. - snapshot
BoundSnapshot— the epoch facet over the general structuralSeal.- snapshot_
proof - Snapshot proof — the aggregate proof over a sealed
Sealed. - storage
- Storage abstraction for leaf and node persistence.
- subtree
- Subtree descriptor for structured appends.
- topology
- Shared k-ary structural primitives — the perfect-subtree decomposition and the generic grouping fold.
- tree
- The combinator driver: the multi-algorithm append-only log over one shared data substrate.
Structs§
- Audit
Payload - The raw payload of an audit verification checkpoint.
- Binding
Proof - A cross-algorithm binding proof.
- Bound
Snapshot - The epoch facet over a structural
Seal: the seal paired with the committed epoch timeline, from which the binding root is derived. - Claimed
Leaf - One claimed leaf in a snapshot proof: a
spine::LeafProofpaired with the algorithm whose member root it verifies against. - CmtConfig
- Configuration for a
Cmt. - Consistency
Proof - Consistency proof: proves tree at
old_sizeis a prefix of tree atnew_size. - Coupling
Proof - A coupling proof that opens a binding root to its children: the raw
algorithm roots together with the committed epoch timeline. This is the
metadata-opening segment of inclusion/inactivity proofs: once authenticated
against the binding root,
alg_epochsis the trusted source foractive(X, p). - Epoch
Tree - The polydigest combinator over a
Cmt— the Epoch Merkle Tree (polydigest(cmt)). - Filled
Tree - A complete (gapless), readable single-algorithm tree produced by
fill, verified against theSealed’s committed binding root. - Inclusion
Proof - Inclusion proof: path from a leaf to the root.
- Leaf
Proof - A self-contained leaf proof: a leaf hash bound to its position, ready to verify against a trusted root and the structure’s skeleton.
- Memory
Storage - In-memory leaf and node storage backed by collections.
- Meta
- Opaque, application-defined byte payload attached to a Merkle commitment.
- Nary
Merkle Log - An n-ary Merkle Append-Only Log — the polydigest combinator’s driver over one shared data substrate.
- NullRun
- One null collapse run of a single algorithm: the algorithm projects to the
null constant across the aligned k-ary block
[left, left + k^height). - Proof
Step - A single level in a Merkle proof path.
- RunExtent
- One committed canonicalization run-extent: a contiguous collapse of
arity^heightconsecutive leaves into a single subtree, beginning at leaf indexleft. - Seal
- The general structural commitment lattice: a sealed, resumable frontier.
- Sealed
- The combinator’s frozen multi-algorithm snapshot: a structural
Sealbound to a committed epoch timeline, deriving the binding root. - Skeleton
Step - One step of an inclusion skeleton, ordered leaf → root.
- Snapshot
Proof - An aggregate proof over a sealed
Sealed. - Tree
Config - Configuration for the n-ary Merkle tree.
- Trusted
Binding Root - A trusted per-algorithm binding root presented to a binding proof.
- Verifier
Config - Configuration options for proof verification (local node policy).
Enums§
- CmtError
- A CMT construction or mutation error.
- Error
- The combinator driver’s error, parameterised by the storage backend’s error type.
- Fill
Error - Why a
fillrequest was rejected. - Fill
Kind - Which readable materialization
fillproduces. - LogError
- The combinator driver’s error, parameterised by the storage backend’s error type.
- LogKind
- Whether log-level appends are flat leaf appends or subtree appends.
- Subtree
- Describes a subtree to be appended as a single logical unit. Leaves are the atomic data items (czds). Nodes define intermediate n-ary nodes (transactions, commits).
Constants§
- LOG_
ARITY - The log arity: binary (
k = 2).
Traits§
- Hasher
- Hash operations required by the Merkle Spine.
- Storage
- Backend for persisting and retrieving raw leaf payloads and sealed internal node hashes.
Functions§
- all_
null_ runs - All algorithms’ null collapse runs at
(tree_size, arity), derived from the committed epoch intervals:(alg_id, runs)for every registered algorithm, sorted by algorithm ID, omitting algorithms with no null run (fully active over[0, tree_size)). This is the activation committed in every binding root; the redundancy physically binds the trees. - bag_
peaks - Bag a frontier’s peaks into the single member root under
hasher. - combined_
root - The combined root: the canonicalization fold (
spine::nary_mr) over the per-algorithm member roots as children, under one algorithm’s own hashH. - committed_
active_ algs - Derive the active algorithm set at
tree_sizefrom a committed timeline: the algorithms whose epochs cover the final positiontree_size - 1. Returned sorted by algorithm ID (inherited from the timeline ordering). - committed_
active_ at - Read the authenticated activity of
alg_idat positionindexfrom a committed epoch timeline. ReturnsNoneif the algorithm has no committed timeline. - config
- The EML configuration: arity
k = 2, no prefix. - constant_
time_ eq - Timing-safe comparison of two byte slices.
- count_
leaves - Count the total number of leaves in a structured subtree.
- evaluate
- Recursively evaluate the root hash of a structured subtree.
- fill
- Rebuild a complete (gapless) single-algorithm tree from a sealed
Sealedand the real historical leaf data, verifying the rebuilt binding root against the committed one — the trustless verification path. - from_
storage - Reconstruct an existing log from
storageat the EML arity (k = 2). - frontier_
for_ size - Frontier decomposition of a log of
nleaves at arityk. - mountain_
skeleton - Compute the MMR inclusion skeleton for a leaf
indexin a tree oftree_sizeleaves at arityk. - nary_mr
- Compute the Merkle root of an ordered sequence of child digests.
- new
- Create a new, empty log over
storage, hashing withhasherunder algorithm 0. - null_
digest - Dynamically generate a null digest constant using the hasher.
- null_
runs_ are_ trivial - Whether the committed activation is trivial: no algorithm has any null
run over
[0, tree_size)(every registered algorithm is fully active). A trivial activation carries no information beyond the member roots, so the binding-root fold omits its coverage child — absence of the child is the trivial encoding. - null_
runs_ for_ alg - Decompose algorithm
eps’s inactive positions in[0, tree_size)into the canonical null collapse runs: the maximal alignedk-ary blocks the tree folds to null, greatest-block-first within each contiguous inactive span (the same greedy decompositionspine::frontier_for_sizeapplies to the whole tree, here applied to each inactive gap). - rebalanced_
bag - Bag a frontier’s peaks into the CMT member root under
hasher— the rebalanced fold, grouping the rightmostk(the mutable peer of the append-only log’s backward-bag). Mirrorsbuild’s grouping so the folded member root equals the livecrate::Cmt::rootover the same peaks. An empty peak set is the empty-tree root. - rebalanced_
skeleton - The CMT’s concrete inclusion skeleton for
indexin a tree ofsizeleaves at arityk— the rebalanced topology the spine verifier pins a proof against. - reconstruct_
consistency_ roots - Reconstruct the old and new raw roots from a consistency proof.
- reconstruct_
inclusion_ root - Reconstruct the raw root from an inclusion proof path and its trusted skeleton.
- reduction_
count - Number of k-ary merges after appending an item at 0-based index
n. - serialize_
null_ runs - Canonical serialization of all algorithms’ null runs — the preimage of the binding root’s coverage child; the committed activation form.
- validate_
committed_ epochs - Validate the structural well-formedness of a committed epoch timeline at
tree_size: entries strictly sorted by algorithm ID; at least one epoch per algorithm; intervals ordered and non-overlapping (start <= end,start >= prior end); only the final interval may be open (end == u64::MAX); closed ends and open starts do not exceedtree_size. - verify_
consistency - Verify a consistency proof.
- verify_
consistency_ with_ coupling - Helper wrapper demonstrating consistency verification with decoupled coupling proofs.
- verify_
epoch_ evolution - Verify that a committed epoch timeline at
new_sizeis an append-only evolution of one previously committed atold_size— the temporal analog of a consistency proof. - verify_
inactivity_ with_ coupling - Verify an inactivity claim for a leaf at
indexusing a coupling proof. - verify_
inclusion - Verify an inclusion proof against a consumer-supplied skeleton.
- verify_
inclusion_ path_ structure - Validate that the trailing steps of an inclusion proof path match the
consumer-supplied
skeleton. - verify_
inclusion_ with_ coupling - Helper wrapper demonstrating inclusion verification with decoupled coupling proofs.
- within_
subtree_ path - Generate the inclusion proof path for a leaf index within a structured subtree.
Type Aliases§
- Algorithm
Metas - Reconstructed metadata for registered algorithms: a list of
(alg_id, epochs)pairs. - CmtResult
- A specialized
Resultfor the mutable tree. - Epochs
- Epoch metadata for a registered algorithm: a sequence of half-open
[start, end)intervals. - LogResult
- A specialized
Resultalias for the combinator driver. - Result
- A specialized
Resultalias for the combinator driver.