Bitcoin Interoperability: hVM vs. Existing Solutions

Hemi’s architecture is half-Bitcoin, half-Ethereum. But it doesn’t take half-measures with interoperability.

TL;DR:

  • Existing Bitcoin interoperability solutions typically don’t provide access to Bitcoin’s complete state — and often introduce additional trust models or points of failure through relayers.
  • Hemi approaches interoperability differently: The Hemi Virtual Machine (hVM) has a full, indexed Bitcoin node inside its EVM which provides smart contracts direct access to Bitcoin’s complete state in a completely trustless, relayer-free manner.
  • In the future, hVM will also provide direct access to indexed metaprotocol data like Ordinals, Runes, and BRC-20s.

Bitcoin and Ethereum each have growing ecosystems of decentralized applications and blockchain-based assets. With Hemi, the world’s two biggest blockchains can work together. 

For these two blockchains to be interoperable, they must be able to communicate. Existing approaches to Bitcoin interoperability have pushed the networks forward but remain limited to the most basic Bitcoin transactions and data:

  • Bitcoin Header Relay: third-party bots relay Bitcoin headers to an Ethereum smart contract that tracks lightweight Bitcoin consensus, forming a TL;DR history of the Bitcoin blockchain — on Ethereum. Smart contracts can then validate Bitcoin transactions with accompanying Merkle proofs to determine a specific transaction exists on the canonical Bitcoin chain. Bitcoin state that is the result of processing these transactions (like the UTXO table and spend script balances) cannot be verified, and the Bitcoin transactions of interest to a dApp must be passed in by external relayers.
  • ZK Tx Inclusion: uses zero-knowledge proofs to prove that a Bitcoin transaction has taken place to dApps. Again, however, it can only prove inclusion of specific transactions and too relies on external relayers.
  • Sequencer Query Relay: involves sequencers of a particular network performing queries for Bitcoin data requested by transactions in the blocks they process. Sequencers must be trusted to return complete data, as they do not provide a cryptographic proof that queries against indexed data represent Bitcoin’s latest and full state.

By contrast, Hemi uses a novel approach to Bitcoin interoperability: hVM.

The Ethereum Virtual Machine (EVM), collectively maintained by all the computers running nodes on an Ethereum-based network, manages the execution of smart contracts. To create hVM, we wrapped an EVM around a Bitcoin node.

With hVM, dApps don’t have to look outside the chain to answer questions about Bitcoin state – they have direct, efficient, and secure access to a full Bitcoin node running inside the EVM!

To accomplish this, Hemi uses a new “dual-chain L2 derivation” mechanism. Just like how Ethereum-based block derivation communicates relevant events and the current state of Ethereum to Hemi, our Bitcoin-based block derivation does the same on the Bitcoin side.

When a new Bitcoin block is created, the Hemi protocol picks it up as part of its derivation process by inserting a transaction into a Hemi block which communicates the new Bitcoin block’s header. The hVM uses this data to update a protocol-level view of Bitcoin consensus that’s synchronized across all Hemi nodes. Each time this consensus view is updated, each hVM node fetches the full corresponding Bitcoin block from Bitcoin’s P2P network and instructs the embedded Bitcoin full node to process this block.

The end result of this system is a “Processed Bitcoin View” (PBV) which is deterministically maintained as part of Hemi’s state transition function. All Hemi nodes on the same tip will have an identical PBV, and thus guarantee that the queries that Hemi smart contracts make against the embedded Bitcoin full node return the same results.

Because the state of the embedded Bitcoin full node is deterministic and based on running the entire Bitcoin protocol inside Hemi, there is no need for third-parties to relay data or be trusted to perform queries correctly, and every aspect of Bitcoin’s state can be directly and securely introspected without any cryptographic proofs.

By providing smart contracts with direct access to Bitcoin’s state at the EVM level, Hemi empowers developers to build Bitcoin-based decentralized applications and infrastructure more simply, securely, and efficiently than with existing Bitcoin interoperability solutions.

In the future, hVM will be updated to allow smart contracts to subscribe to automatic callbacks on future Bitcoin events (also without requiring relayers), and to include metaprotocols to allow direct querying of other views of Bitcoin’s state that aren’t part of the core protocol, like Ordinals, Runes, and BRC-20s.

To learn more about Hemi’s unique approach to interoperability, read the whitepaper and the relevant documentation or stop by the team’s Discord

Share