Skip to main content

Crate cml

Crate cml 

Source
Expand description

cml — CML, the single-algorithm canonical append log over the spine.

CML (Canonical Merkle Log) is the single-algorithm append-only engine layered over the structural Merkle Spine. It owns one algorithm’s frontier carry (the base-k reduction schedule), the member-root fold, the append-only consistency::ConsistencyProof, inclusion and leaf proof generation, and the structural snapshot facet — the frontier peaks a spine::Seal freezes.

It is epoch-free and multi-algorithm-free (D7): the engine reads one algorithm’s view (AlgView) over a borrowed NodeReader substrate and never owns the store, so the polydigest combinator can drive N views over one shared data substrate without duplicating leaf data (D14). The activation timeline, the null-run-extents, the binding root, and coupling are the combinator’s facet, not CML’s.

The structural commitment a CML seal produces is the general spine::Seal (re-exported here); the epoch facet over it is polydigest::BoundSnapshot.

Re-exports§

pub use consistency::ConsistencyProof;
pub use consistency::reconstruct_consistency_roots;
pub use consistency::verify_consistency;
pub use engine::AlgView;
pub use engine::LogKind;
pub use engine::NodeReader;
pub use engine::carry;
pub use engine::compute_root;
pub use engine::consistency_proof;
pub use engine::frontier_peaks;
pub use engine::get_node_hash;
pub use engine::inclusion_proof;
pub use engine::leaf_proof;
pub use engine::peak_at;
pub use engine::reconstruct_subtree_root;
pub use engine::reconstruct_view;
pub use engine::root_for_at;
pub use engine::validate_epochs;
pub use error::Error;
pub use error::Result;
pub use schedule::reduction_count;

Modules§

consistency
Consistency proof structure and verification — the append-only evolution surface layered over the spine’s inclusion proof.
engine
The single-algorithm canonical-log engine over the spine.
error
CML engine error type.
mountain
The Merkle Mountain Range commitment topology — the append-only log’s own bagging of its perfect-subtree peaks, and the inclusion skeleton that pins a proof against it.
proof
schedule
Base-k carry reduction schedule algorithm.

Structs§

RunExtent
One committed canonicalization run-extent: a contiguous collapse of arity^height consecutive leaves into a single subtree, beginning at leaf index left.
Seal
The general structural commitment lattice: a sealed, resumable frontier.

Enums§

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).

Traits§

Hasher
Hash operations required by the Merkle Spine.

Functions§

evaluate
Recursively evaluate the root hash of a structured subtree.
frontier_for_size
Frontier decomposition of a log of n leaves at arity k.
nary_mr
Compute the Merkle root of an ordered sequence of child digests.
null_digest
Dynamically generate a null digest constant using the hasher.