Programming on Bitcoin: A Survey of Layer 1 and Layer 2 Technologies in Bitcoin Ecosystem

Guofu Liao, Taotao Wang, Qing Yang, Yihan Xia, Long Shi, Xiang Zhao, Xiaoxiao Wu, Shengli Zhang, Anthony Chan, Richard YuenarXiv 2024 · OpenReview

TL;DR

This paper surveys the evolving landscape of Bitcoin's programming capabilities, focusing on Layer 1 enhancements like Taproot and emerging Layer 2 solutions. It highlights how these advancements are enabling new applications, from NFTs to complex smart contracts, and analyzes their impact on Bitcoin's performance and ecosystem.

What Problem Does This Paper Address?

Bitcoin, while a robust and secure digital currency, has historically been limited in its programming capabilities and transaction throughput due to its UTXO model and non-Turing-complete scripting language. This has restricted its use beyond simple peer-to-peer payments, hindering the development of complex decentralized applications. The paper addresses this by surveying the technical innovations, particularly the Taproot upgrade and subsequent Layer 1 and Layer 2 protocols, that are significantly expanding Bitcoin's programmability and scalability.

Methods

The paper employs a multi-faceted approach:

  • Technical Deep Dives: It thoroughly explains the technical intricacies of the Taproot upgrade, including the Schnorr signature algorithm and the Pay-to-Taproot (P2TR) transaction type.
  • Protocol Analysis: It analyzes various Layer 1 protocols (Ordinals, Atomicals, BRC-20, ARC-20) that leverage Taproot for functionalities like NFTs and fungible tokens. It also categorizes and examines Bitcoin Layer 2 solutions (BitVM, Babylon, BEVM, STACKS, RGB++, Lightning Network) by drawing parallels with Ethereum's Layer 2.
  • Data Analysis: The authors collect and analyze real-world Bitcoin blockchain data to measure the impact of these protocols on metrics like average block size, P2TR transaction prevalence, and miner fees.

Datasets

The paper utilizes publicly available Bitcoin blockchain transaction data from January 3, 2017, to August 21, 2024. This dataset was analyzed to track changes in average block size, the adoption of P2TR transactions, and fluctuations in miner fees. No new datasets were introduced.

Key Insights and Ideas

  • Taproot as a Catalyst: The Taproot upgrade was a pivotal moment, unlocking significant improvements in Bitcoin's privacy and programming potential, paving the way for a new wave of innovation.
  • Layer 1 Innovation for NFTs and Tokens: Protocols like Ordinals and Atomicals are effectively bringing NFTs and fungible tokens (BRC-20, ARC-20) to Bitcoin's Layer 1 by creatively utilizing Taproot's features, enriching the ecosystem beyond simple payments.
  • Layer 2 Solutions Mimicking Ethereum: Bitcoin is developing its own suite of Layer 2 solutions (Rollups, Sidechains, State Channels) that mirror Ethereum's approach to scalability and smart contract execution, aiming to broaden Bitcoin's utility.
  • Data Confirms Positive Impact: The analysis of blockchain data provides empirical evidence that these new protocols are indeed increasing block capacity and driving miner revenue, validating their beneficial impact on the Bitcoin mainnet.

Key Results

  • Increased Block Capacity: The "Segregated Witness" and "Taproot proposal" upgrades have led to an overall upward trend in average daily block size, indicating improved data structure efficiency and scalability.
  • P2TR Transaction Growth: The emergence of protocols like Ordinals and Atomicals has significantly boosted the adoption of P2TR transactions, which now constitute a substantial portion (20-50%) of all Bitcoin transactions.
  • Miner Fee Impact: Protocols like BRC-20, ARC-20, and Runes have attracted significant user activity, leading to increased transaction fees, which serve as a substantial income source for miners.
  • Ecosystem Enrichment: The survey demonstrates a clear trend of Bitcoin's ecosystem expanding beyond its original use case, embracing complex applications like NFTs and fungible tokens.

Limitations and Future Work

  • Centralization Concerns: Some protocols, like BRC-20, rely on centralized off-chain indexers, which conflicts with Bitcoin's decentralized ethos. Resolving this conflict is crucial for long-term development.
  • Scalability and Congestion: While innovations are improving scalability, increased transaction complexity from new protocols could still lead to network congestion. Future research should focus on optimizing solutions to handle higher transaction volumes without compromising speed.
  • Interoperability: Exploring interoperability between Bitcoin and other blockchain platforms could unlock new cross-chain applications.
  • Privacy Enhancements: Developing more efficient privacy-preserving mechanisms remains important as Bitcoin's capabilities expand.
  • Further Research: The paper suggests that future work should continue to analyze the impact of these evolving protocols and explore new avenues for decentralized finance and applications on Bitcoin.

Summary updated

Abstract

This paper surveys innovative protocols that enhance the programming functionality of the Bitcoin blockchain, a key part of the "Bitcoin Ecosystem." Bitcoin utilizes the Unspent Transaction Output (UTXO) model and a stack-based script language for efficient peer-to-peer payments, but it faces limitations in programming capability and throughput. The 2021 Taproot upgrade introduced the Schnorr signature algorithm and P2TR transaction type, significantly improving Bitcoin's privacy and programming capabilities. This upgrade has led to the development of protocols like Ordinals, Atomicals, and BitVM, which enhance Bitcoin's programming functionality and enrich its ecosystem. We explore the technical aspects of the Taproot upgrade and examine Bitcoin Layer 1 protocols that leverage Taproot's features to program non-fungible tokens (NFTs) into transactions, including Ordinals and Atomicals, along with the fungible token standards BRC-20 and ARC-20. Additionally, we categorize certain Bitcoin ecosystem protocols as Layer 2 solutions similar to Ethereum's, analyzing their impact on Bitcoin's performance. By analyzing data from the Bitcoin blockchain, we gather metrics on block capacity, miner fees, and the growth of Taproot transactions. Our findings confirm the positive effects of these protocols on Bitcoin's mainnet, bridging gaps in the literature regarding Bitcoin's programming capabilities and ecosystem protocols and providing valuable insights for practitioners and researchers.
BibTeX
@misc{liao2024programming,
  author = {Guofu Liao and Taotao Wang and Qing Yang and Yihan Xia and Long Shi and Xiang Zhao and Xiaoxiao Wu and Shengli Zhang and Anthony Chan and Richard Yuen},
  title = {{Programming on Bitcoin: A Survey of Layer 1 and Layer 2 Technologies in Bitcoin Ecosystem}},
  year = {2024},
  eprint = {2409.19622},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2409.19622},
}
Figure