Consensus Mechanism
IBVM employs a hybrid consensus mechanism combining elements of Proof-of-Stake for the sequencer selection and anchoring to Bitcoin's Proof-of-Work for security.
Sequencer Selection
Sequencers are selected through a weighted random process based on stake:
Sequencer candidates stake BTC in a special contract
Selection probability is proportional to stake amount
A verifiable random function (VRF) determines selection: $P(select_i) = \frac{Stake_i}{\sum_{j=1}^{n} Stake_j}$
Selected sequencers have exclusive rights to produce blocks for a set period
Sequencer Responsibilities
Each selected sequencer:
Collects transactions from the mempool
Orders transactions based on gas price
Executes transactions and updates the state
Generates batch commitment and ZK proof
Publishes commitment to Bitcoin blockchain
Fault Detection and Slashing
To maintain honest behavior:
Sequencers' stakes are locked in a slashing contract
Invalid state transitions can be challenged during the challenge period
If a fraud proof is successful, the sequencer loses part of their stake: $Slash_{amount} = min(Stake_i, S_{base} + S_{proportional} \times TxValue)$ Where:
$S_{base}$ is the base slashing amount
$S_{proportional}$ is the proportional factor
$TxValue$ is the economic value of affected transactions
Chain Reorganization Handling
In case of Bitcoin chain reorganizations:
Monitor the Bitcoin chain for reorganizations
If a reorganization affects IBVM commitments:
Revert to the last valid state
Reapply subsequent valid batches
Update the IBVM state accordingly
The mathematical condition for reorganization: $Height(Block_{commitment}) > Height(Block_{fork})$
Last updated