p/elysium

Batches

batchstatetradessolnet flowfeefirst slotlast slotsequencer rootverifier rootelysium txsettled

Tree

Every batch the sequencer has sealed, with both roots, its certificate on Elysium and its settlement. A batch is open until the trade that fills it. A certificate is final when two certificates stand behind it. A challenged batch freezes everything behind it until both indexers agree.

Leaves of the latest sealed batch

indexslotwalletsidesoltokenspriority feeleaf
A leaf is the hash of signature, slot, wallet, side, lamports, tokens and priority fee. The root is the binary tree over the leaves in slot order, the last leaf repeated on odd levels.

Disputes

batchattemptsequencer rootverifier rootcleared
A dispute is written when the two roots differ. It clears only when both indexers re run and agree.

Sealing arithmetic

tradessolseals

Why a certificate and not the trades

Posting every trade to the parent chain is what makes most rollups expensive. Elysium posts a certificate and keeps the data with a committee, so the parent cost of a batch is the size of a root and a few integers. p/elysium keeps the leaves in its own register and posts the same shape. Anyone with the leaves can rebuild the root and check it against the contract on Elysium. Anyone without them cannot, which is why there are two indexers and a challenged state.