23 releases (7 stable)

new 2.0.0-alpha.5 Mar 24, 2025
2.0.0-alpha.4 Mar 18, 2025
1.3.1 Mar 21, 2025
1.1.0 Feb 26, 2025
0.82.0-alpha.0 Dec 26, 2024

#883 in Magic Beans

Download history 125/week @ 2024-12-22 37/week @ 2024-12-29 871/week @ 2025-01-05 471/week @ 2025-01-12 445/week @ 2025-01-19 206/week @ 2025-01-26 57/week @ 2025-02-02 344/week @ 2025-02-09 350/week @ 2025-02-16 414/week @ 2025-02-23 564/week @ 2025-03-02 318/week @ 2025-03-09 719/week @ 2025-03-16 438/week @ 2025-03-23

2,048 downloads per month
Used in 35 crates (17 directly)

MIT/Apache

5MB
108K SLoC

penumbra-tct

The tiered state commitment tree for Penumbra.


lib.rs:

The tiered commitment tree for Penumbra.

Eternity┃           ╱╲ ◀───────────── Anchor
    Tree┃          ╱││╲               = Global Tree Root
        ┃         * ** *           ╮
        ┃      *   *  *   *8 levels
        ┃   *     *    *     *     ╯
        ┃  ╱╲    ╱╲    ╱╲    ╱╲
        ┃ ╱││╲  ╱││╲  ╱││╲  ╱││╲ ◀─── Global Tree Leaf
                        ▲             = Epoch Root
                     ┌──┘
                     │
                     │
   Epoch┃           ╱╲ ◀───────────── Epoch Root
    Tree┃          ╱││╲
        ┃         * ** *           ╮
        ┃      *   *  *   *8 levels
        ┃   *     *    *     *     ╯
        ┃  ╱╲    ╱╲    ╱╲    ╱╲
        ┃ ╱││╲  ╱││╲  ╱││╲  ╱││╲ ◀─── Epoch Leaf
                 ▲                    = Block Root
                 └───┐
                     │
                     │
   Block┃           ╱╲ ◀───────────── Block Root
    Tree┃          ╱││╲
        ┃         * ** *           ╮
        ┃      *   *  *   *8 levels
        ┃   *     *    *     *     ╯
        ┃  ╱╲    ╱╲    ╱╲    ╱╲
        ┃ ╱││╲  ╱││╲  ╱││╲  ╱││╲ ◀─── Block Leaf
                                      = Note Commitment

Builders for individual epochs and blocks: useful when constructing a Tree in parallel, but unnecessary in a single thread. Build individual epochs to insert into Trees. Build individual blocks to insert into epoch::Builders or Trees.

Dependencies

~39MB
~714K SLoC