Chapter 34: Further Reading

Blockchain Fundamentals for Prediction Markets


Foundational Blockchain and Ethereum

  1. Buterin, V. (2014). Ethereum Whitepaper: A Next-Generation Smart Contract and Decentralized Application Platform. The founding document of Ethereum. Vitalik Buterin lays out the case for a Turing-complete blockchain and describes the account model, transaction structure, and smart contract paradigm that underpin every on-chain prediction market. Essential reading for understanding why Ethereum was designed the way it was, not just how it works. Available at ethereum.org/whitepaper.

  2. Wood, G. (2014). Ethereum: A Secure Decentralised Generalised Transaction Ledger (Yellow Paper). The formal specification of the Ethereum protocol. Covers the EVM in rigorous mathematical detail, including opcode definitions, gas costs, state transition functions, and the Modified Merkle Patricia Trie. Dense but invaluable if you need to understand exactly how contract execution works at the bytecode level. Available at ethereum.github.io/yellowpaper.

  3. Antonopoulos, A. M. & Wood, G. (2018). Mastering Ethereum. O'Reilly Media. The most comprehensive technical guide to Ethereum development. Covers accounts, transactions, the EVM, Solidity, security patterns, tokens (ERC-20, ERC-721), and development tools. The chapters on security vulnerabilities and best practices are particularly relevant for prediction market developers. Available free at github.com/ethereumbook.

  4. Nakamoto, S. (2008). Bitcoin: A Peer-to-Peer Electronic Cash System. The paper that started it all. While Bitcoin does not support complex smart contracts, understanding its proof-of-work consensus, UTXO model, and cryptographic primitives provides essential context for Ethereum's design decisions. A 9-page read that remains remarkably clear. Available at bitcoin.org/bitcoin.pdf.

Smart Contract Development

  1. OpenZeppelin. Contracts Documentation and Library. The industry-standard library of audited, reusable smart contract components. Their ERC-20, ERC-721, ERC-1155, access control, and security utility contracts are used by virtually every production DeFi protocol, including prediction markets. The documentation includes detailed explanations of design patterns and security considerations. Available at docs.openzeppelin.com/contracts.

  2. Ethereum Foundation. Solidity Documentation. The official reference for the Solidity programming language. Covers syntax, type system, inheritance, error handling, assembly, and the ABI specification. The "Security Considerations" section catalogs known vulnerability patterns (reentrancy, overflow, tx.origin misuse) with examples. Available at docs.soliditylang.org.

Python and web3.py

  1. web3.py Documentation. The official documentation for Python's Ethereum interaction library. Covers provider setup, contract interaction, event filtering, transaction signing, middleware, and ENS integration. The examples section provides working code for common operations. The migration guides for major version changes are helpful when updating existing code. Available at web3py.readthedocs.io.

  2. Brownie Documentation (eth-brownie). A Python-based development and testing framework for Ethereum smart contracts. While Foundry (Rust-based) has gained popularity for pure Solidity development, Brownie remains valuable for Python developers who want to test contract interactions in a familiar environment. Its integration with pytest and web3.py makes it particularly suitable for building and testing prediction market strategies. Available at eth-brownie.readthedocs.io.

Layer 2 and Scaling

  1. L2BEAT. Layer 2 Risk Analysis Dashboard. An independent research project that tracks every Layer 2 network, categorizes them by type (optimistic rollup, ZK-rollup, validium, etc.), assesses their security properties, and monitors TVL. The risk framework evaluates each L2 on state validation, data availability, upgradeability, and sequencer centralization. Essential for choosing which L2 to deploy or trade prediction markets on. Available at l2beat.com.

  2. Thibault, L. T., Sarry, T., & Kannan, A. (2022). Blockchain Scaling: A Survey of Approaches and Their Performance. IEEE Access. An academic survey of scaling solutions including state channels, sidechains, plasma, optimistic rollups, and ZK-rollups. Provides formal definitions, performance benchmarks, and security comparisons. Useful for understanding the theoretical foundations behind the L2 solutions that prediction markets rely on.

Security and MEV

  1. Daian, P., Goldfeder, S., Kell, T., et al. (2020). Flash Boys 2.0: Frontrunning in Decentralized Exchanges, Miner Extractable Value, and Consensus Instability. IEEE S&P 2020. The seminal paper on MEV (Miner/Maximal Extractable Value). Demonstrates how transaction ordering manipulation enables front-running, back-running, and sandwich attacks on DEX trades. Directly applicable to prediction market trading, where visible mempool transactions can be exploited by MEV searchers. The paper's analysis of the "dark forest" of on-chain trading has shaped the entire field.

  2. Trail of Bits. Building Secure Smart Contracts (repository and guides). A collection of best practices, vulnerability patterns, and analysis tools from one of the leading smart contract security firms. Includes guides on common pitfalls, the Slither static analysis tool, and Echidna property-based testing framework. Particularly relevant sections cover reentrancy prevention, access control, and safe math operations. Available at github.com/crytic/building-secure-contracts.

Prediction Market Protocols

  1. Peterson, J., Krug, J., Zoltu, M., Williams, A. K., & Alexander, S. (2019). Augur: A Decentralized Oracle and Prediction Market Platform. The technical whitepaper for Augur, the first major decentralized prediction market. Describes the market creation process, the LMSR-based AMM, the REP-based oracle and dispute resolution system, and the fork mechanism. While Augur's architecture has evolved, the paper remains an excellent study of on-chain prediction market design principles. Available on arXiv: 1501.01042.

  2. Gnosis. Conditional Token Framework Documentation. The technical documentation for the CTF, the token standard that underlies Polymarket and other modern prediction markets. Covers condition preparation, position splitting/merging, collection IDs, and the ERC-1155 token mechanics. Understanding the CTF is essential for anyone interacting programmatically with Polymarket. Available at docs.gnosis.io/conditionaltokens.

Cryptographic Foundations

  1. Menezes, A. J., van Oorschot, P. C., & Vanstone, S. A. (1996). Handbook of Applied Cryptography. CRC Press. A comprehensive reference for the cryptographic primitives used in blockchain systems: hash functions (SHA-256, Keccak), digital signatures (ECDSA), elliptic curve cryptography (secp256k1), and Merkle trees. While much of the book covers topics beyond blockchain, the chapters on hash functions and public-key cryptography provide the mathematical foundations for understanding how blockchain security actually works. Available free at cacr.uwaterloo.ca/hac.