Web3 is a term used to describe a version of the Internet that empowers users to co-manage public Internet infrastructure by rewarding them with native network tokens. Blockchain networks operate at the backbone, acting as a publicly verifiable and collectively maintained digital notary and accounting machine. AI tools can be used to make decentralized applications more intelligible and usable on the front end, and they can also be used in the design of blockchain protocols and their applications.
~
The term "Web3" is not completely new and has evolved over the past decades, encompassing various visions for the Internet's future. Similar terms, like "Web 3.0," were used before the emergence of Bitcoin to describe a more intelligent web. Web 3.0 was first used to refer to the “Semantic Web,” a version of the World Wide Web designed to make vast amounts of data more intelligible through the attribution of metadata. The manual nature of this process was not scalable and led to the realization that machine learning and artificial intelligence could play a more effective role in achieving this vision. However, the term never gained mainstream adoption. In 2014, Ethereum co-founder Gavin Wood coined a variation of the term—“Web3”—to describe a decentralized Internet infrastructure powered by blockchain networks and other decentralized protocols. Both Web 3.0 and Web3 share the goal of creating a more intelligent and user-centric web, but they differ in their approaches. Blockchain networks and other Web3 protocols reinvent how the back end is managed. AI applications can make the front end of applications smarter and more user-friendly.
However, in popular discourse, the term "Web3" has become somewhat interchangeable with "crypto" or "blockchain," which both reflect a narrower understanding of its broader vision. “Crypto” is often used to refer solely to cryptocurrencies, reducing Web3 to a single application: tokens that act as digital currencies or digital assets. Similarly, “blockchain” focuses solely on the technological infrastructure, overlooking other essential components of decentralized Internet infrastructure. Such a reductionist view risks confining Web3 to its technological components and financial applications, ignoring a wide array of non-financial tokens and the fact that crypto networks are socioeconomic systems, governed and used by people. To add to the confusion, AI is described as an isolated innovation—something completely different—as if there were two types of web that have nothing to do with each other: an AI-powered web and a blockchain/crypto-powered web.
In the context of this book, I therefore like to unite both concepts and show how blockchain infrastructure and AI applications work in tandem with each other to power Web3 applications. However, the main focus of this book will be the game-changing aspects of purpose-driven tokens that steer Web3 networks. While AI is not the focus of this book, the increasing role of AI agents both at the edges of Web3 networks and at the center of their protocols will be outlined in the use case chapters of this book, where applicable.
History of the Web
Before the emergence of the Internet, data exchange between computers was cumbersome. Electronic data exchange required manual transfer via some kind of hardware device—such as a floppy disk—upon which files were saved to be physically transferred to another computer. The Internet Protocol was a game-changer because it enabled seamless data transmission between computers over telecommunication networks, slashing the time and cost of data exchange and making it a breeding ground for many social and economic applications. However, the Internet we use today is still predominantly built on the idea of the stand-alone computer because the computer preceded the Internet, and this historic order of events also shaped the logic of how data was exchanged over the Internet.
Despite 35 years of mass Internet adoption, data today is mostly centrally stored and managed on stand-alone computers. Each time we interact over the Internet, copies of our data are created (in the form of emails, files, money), and these copies are sent to the server of a service provider. Every time that happens, we lose control over what happens to that copy of our data. As a result, system administrators are needed to manage identities, passwords, and security. Value settlement requires intermediary services. This raises issues of trust and introduces inefficiencies across the supply chain of goods, services, and assets.
Web1: The first wide-area computer-to-computer network—ARPANET—emerged in 1969. It was the predecessor of the current Internet, which was initially developed for military use. Though it was later adopted by universities, it remained a fringe phenomenon until the rise of the personal computer in the 1980s and the emergence of easy-to-create graphical interfaces in the 1990s powered by Hypertext Transfer Protocol (HTTP) and Hypertext Markup Language (HTML). These revolutionary protocols allowed anyone to create a website with a few lines of code and navigate the web by clicking on links instead of using command-line interfaces. What eventually became known as the World Wide Web (WWW) was predominantly read-only, with data hosted on centralized servers. Navigation of web pages relied on Internet browsers and search engines, both of which dominated early innovation of Internet applications.
Web2 can be described as a front-end revolution once Internet infrastructure and its applications became more sophisticated and widely adopted, and the smartphone era amplified usability. The term “Web2” was coined in the early 2000s as more Internet applications started to facilitate read-write interactions instead of read-only interactions, creating globally used social and economic networks. However, the operators of most of these Web2 platforms that emerged also got to dictate all network rules while unilaterally controlling their users' data. This was the result of the predominantly private ownership structures of the operators as well as the client-server nature of the web.
Web3 protocols can empower a more collaboratively managed and user centric web. They combine the Internet's networking capabilities with the computational functions of computers, incentivizing human participation. Anyone can become a node operator, contributing to governance, maintenance, and operations—without the need for a central coordinator. Cryptographic building blocks and token-based incentives are foundational components of a new type of Internet infrastructure that intends to shift control from centralized entities to individual users, emphasizing data ownership, privacy, and peer-to-peer interactions. Network rules are computationally encoded and enforced by all participants, who collectively manage the state of who is allowed to do what and when in the network. Participation is open to everyone. Access rights, property rights, management rights, information rights, or voting rights are represented by tokens that are collectively managed—which is why some refer to it as the “Internet of Agreements.” However, decentralized applications are not only fueled by their token-based economic systems but also increasingly leverage AI agents in the design and operations of these systems to make interactions more intelligible and usable.
While research and development of P2P computing are as old as the Internet itself, they only existed at the fringes of Internet mass adoption. Since the emergence of Bitcoin and subsequent blockchain networks, decentralized computing has experienced a renaissance. Blockchain networks have come to provide a native governance layer for the Internet and are the backbone of Web3 infrastructure networks.
Blockchain Concept in a Nutshell
The Bitcoin white paper proposed a mechanism to create peer-to-peer money without banks, resolving the double-spending problem over the internet in the absence of central coordinators. The idea was to combine cryptographic methods with economic incentives in a unique way so that anonymous internet participants could collectively mint new Bitcoins, maintain the ledger, and verify Bitcoin transactions. What started as a playground for a handful of cypherpunks and crypto-anarchists eventually gained mainstream adoption. The Bitcoin network became the first collectively maintained public payment network over the internet and spurred a renaissance in P2P networks and alternative currencies. Over the years, Bitcoin’s blockchain architecture was modified numerous times so it could serve a wide range of purposes. Today, blockchain networks are used as a general public infrastructure to issue and manage any type of token with a variety of properties. The wide range of rights that can be attached to a token is collectively verified by all participating network nodes. This subchapter outlines the most important concepts and terminologies of blockchain networks. Details of these concepts will be discussed throughout the book.
Public & permissionless network: Bitcoin is more than just a cryptocurrency. It is, first and foremost, a publicly maintained payment network with a unique data structure, economic system, and network currency (Bitcoin). Anyone can become an operator of network services (i.e., verify transactions and write new transactions to the ledger). Anyone can consume network services (i.e., send Bitcoins over the network). The same applies to other public and permissionless blockchain networks.
New type of decentralized institution: While the purpose of Bitcoin was to create P2P electronic cash, the way to achieve this purpose was to create an open payment network that is collectively maintained—inadvertently creating an infrastructure for a new type of coordination tool over the internet. All actions are collectively managed by autonomous network nodes, executed, and rewarded according to the rules defined in the network's protocol.
The blockchain protocol defines the rules for how network nodes interact with each other and how they are rewarded for their contributions. All network rules are computationally encoded, verified, and executed. The protocol represents the computational constitution of the network, defining (i) how to reference and securely identify network participants; (ii) under which conditions sending tokens from A to B is valid; (iii) the rewards participants receive for validating transactions and managing the ledger; and (iv) under which conditions participants can decide on rule changes. Bitcoin's codebase was the first blockchain protocol. Many variations of the Bitcoin codebase have been developed over the years.
Network nodes: The term node refers to all the computers in a blockchain network that autonomously execute protocol functions. Depending on the type of blockchain network, nodes can have different roles and fulfill different functions, such as validating transactions, storing data, participating in consensus processes, or ordering transactions. Nodes can be operated by individuals and institutions willing to invest in the necessary hardware to perform network services. Operators are usually incentivized with network tokens. While economic motivations dominate participation, nodes can also be operated for personal or political reasons.
Monetary & fiscal policy: The protocol defines how many network tokens (Bitcoin, Ether, etc.) can be minted over time, how this minting function is distributed in the absence of a central coordinator, and under which conditions network participants are rewarded with tokens. The protocol could also define how network taxes are collected for specific services and under which conditions the collected funds are redistributed. Network taxes (aka network fees) can be more or less loosely defined in the protocol. The more loosely they are defined, the more they become subject to market mechanisms.
Blocks: In the case of Bitcoin, transactions are recorded on average every 10 minutes in data batches, also referred to as “blocks.” Blocks include the details of each Bitcoin transaction, including the cryptographic signatures of the senders and computer nodes involved, as well as a reference to the previous block. Each block has a unique digital fingerprint (“hash,”) which is hard to manipulate and makes unilateral changes easy to detect. The process of verifying transactions and creating blocks is a collaborative effort among all participating network nodes.
Chain of blocks: Each block of transactions references the hash of the previous block, creating a chain of hashed blocks that guarantees the historical integrity of all transactions in each block, all the way back to the first block (“genesis block”). This ensures that if transaction data in one block is altered, the hash value of that block and all later blocks will change. This way, every computer in the network can check if transaction data in a block has been tampered with.
Tamper proof: The hash of each block protects against manipulation because any attempt to alter data on the ledger would require altering all subsequent blocks across all nodes in the network simultaneously—a feat made prohibitively expensive since all other nodes would have to agree.
The ledger (aka “blockchain”) refers to this chain of transaction blocks, which is collectively verified by all nodes in the network and grows every 10 minutes. All entries on the ledger are read-only. The ledger is not a traditional computer file but an alternative data structure—a growing list of chronologically linked data blocks. It serves as a publicly verifiable timestamp of who owns what, who did what, and when.
Spreadsheet in the cloud: Similar to “Google Sheets,” where everyone can access and edit a file centrally stored on Google’s servers, all nodes in the network collaboratively manage the ledger of a blockchain network. However, the ledger is not centrally stored. Instead, each independent node operator keeps an identical copy at all times (except during temporary updates when a new block is created).
Unlike traditional banking, where institutions validate financial transactions on a series of private ledgers, the Bitcoin network maintains a single ledger that is collectively managed. Each node in the network holds an identical copy of the ledger, acting as a digital notary and public accounting machine. Everyone can verify the truthfulness of any transaction, while no single user can unilaterally control the ledger.
Unlike distributed databases that are controlled by a single institution, the Bitcoin network distributes control across multiple independent entities that are unknown to each other, without a central administrator. Blockchain networks are particularly useful for inter-organizational setups where no party wants to entrust another with the management of assets, access rights, management rights, voting rights, or information rights.
Not a digital file: The term “coin” or “token” is simply a metaphor. A token does not represent a digital file that is sent from one device to another. Instead, the ownership status of a coin/token is documented in the collectively maintained ledger. The status is dynamic. The chain of ownership is referenced to the blockchain address of past and current token holders. The password (private key) that corresponds to a token holder's address can be used to generate a unique digital signature, proving ownership to all others in the network and effectively granting access to one's tokens.
Token, not coin: Blockchain tokens can represent some form of currency, but they don't have to. Even though most early blockchain tokens represented some form of currency, blockchain tokens can be used to issue any form of right, not only property rights, but also access rights, usage rights, management rights or information rights.
The Byzantine Generals Problem: For decades, the greatest challenge in the design of anonymous P2P was the question of how to deal with malicious network nodes in the absence of personal identification and coordinators securing the system. How could a distributed network of anonymous participants reach consensus about which data is correct or incorrect, or which process is true or false? Assuming that participants could be malicious (aka “byzantine”), any consensus mechanism would need to be designed in a way that it could withstand any inside or outside mistakes, misbehaviors or malicious attacks. In computer science, this was referred to as the “Byzantine Generals Problem.”
Distributed consensus: Before the emergence of Bitcoin, it was believed to be impossible to achieve fault-tolerant and attack-resistant “consensus” among untrusted nodes in a P2P network without a centralized coordinator. Bitcoin’s “Proof-of-Work,” was a solution to this problem. By combining cryptographic functions with economic difficulty functions in a unique way, Bitcoin’s consensus mechanism Proof-of-Work made it prohibitively expensive to cheat the system. The term “consensus “ or “consensus mechanism” refers to a type of voting process in a computer network, over which transactions or processes are correct. Bitcoin inspired many other projects to develop alternative consensus mechanisms.
Cryptoeconomics: Bitcoin’s Proof-of-Work sparked a growing field of studies, which in hindsight people started referring to as “Cryptoeconomics.” Cryptographic tools are used to secure the token transactions, provide full accountability for all participants, and maintain the privacy of each individual actor. Privacy, however, is only maintained at a pseudo-anonymous level. Economic mechanisms are applied to make sure that future transactions will be conducted in a truthful manner, assuming that all network actors could potentially be corrupt(ed). Reverse game theory is applied to reward participants with a native network token for keeping the network safe such that it is economically infeasible to cheat the system.
Security: In centralized systems, trying to manipulate data on a server resembles breaking into a house, where security is provided by a digital fence and an alarm system (firewall etc.). In contrast, blockchain networks are designed in a way that one would need to break into multiple houses around the globe simultaneously, which each have their own digital fence and alarm system. While this is theoretically possible, a resilient consensus mechanism is designed in a way to make this prohibitively expensive.
Accounts & passwords: Blockchain networks use decentralized Public Key Infrastructure for creating accounts and passwords without the need for central administrators.
Blockchain wallets is a key piece of software that runs on a device of the user (computer, mobile phone or dedicated hardware) and communicates with all other nodes in the blockchain network. Contrary to what the name might suggest, the wallet does not store one's coins/tokens. Instead it stores one's blockchain address (equivalent to a bank account number), private key (password), and a public key (necessary to authenticate the identity of a user) and allows one to create unique digital signatures. The word “keychain” or “signature creator” would be more appropriate than wallet, as a wallet acts as a secure key storage and communication tool for sending digital signatures to all other nodes in a blockchain network.
Block explorer: Due to the public and permissionless nature of blockchain networks, transaction data can be audited by anyone using specialized tools, such as open block explorers. They facilitate data analysis and work like a search engine for blockchain transactions and related metadata.
The Concept of “State”
An important aspect of blockchain networks is the concept of “state.” The Internet we use today is “stateless.” It doesn’t have a native mechanism to transfer what computer science refers to as “state.” State in this context refers to information or the status of “Who is who?”; “Who owns what?”; and “Who has the right to do what?” in a network. If you can’t hold state on the Internet, you cannot transfer digital rights—such as property rights, access rights, voting rights, or management rights—without centralized institutions acting as clearing entities.
The Internet today is governed by stateless protocols, such as TCP/IP, SMTP, and HTTP. These protocols regulate data transmission but not data storage, which can be centralized or decentralized. Centralized data storage has become the mainstream standard, primarily due to its simplicity and scalability. While these protocols revolutionized information transfer, they require trusted intermediaries to manage and broker actions between users. For example, session cookies were introduced to preserve state locally, enabling functionalities like browsing history, favorite sites, and auto-complete. However, these cookies—and the state they preserve—are controlled by individual service providers such as Google, Amazon, social networks, or banks, reinforcing centralization and unique points of failure.
Bitcoin’s consensus mechanism, Proof-of-Work, was revolutionary because it introduced a mechanism to natively manage state on the Internet, whereby all network nodes collectively maintain and verify the state of network tokens. The ledger acts as a single source of truth, recording all transactions and interactions to verify past, current, and future token transactions. The Bitcoin protocol was a game-changer because it paved the way for a more stateful Web. The ability to transfer money, other digital values, or digital rights easily and peer-to-peer is essential for efficient social and economic coordination.
The Concept of “Finality”
The concept of state is closely tied to the concept of “transaction finality,” which ensures that a transaction is valid and cannot be revoked without cause. In any economic transaction—online or offline—all parties involved seek assurance of finality: buyers want to be able to rely on the quality of goods or services received, while merchants or service providers want to ensure the payment is legitimate and finalized. When money is exchanged—whether in person, electronically, or otherwise—the recipient must always be able to trust that the transaction cannot be reversed arbitrarily.
Cash systems, check based systems & pre-electronic credit card processing: Cash payments provide immediate finality, as the recipient can instantly verify authenticity if they have the means to detect counterfeits. In contrast, cheque-based systems are less secure in terms of finality because cheques can bounce if there are insufficient funds. Double spending is also a risk, as the recipient of a cheque has no way to verify whether the issuer actually has sufficient funds until they go to the bank to cash it. Early credit card processing was paper-based and also lacked immediate finality, as payments were delayed until merchants could send in the paper slip to the credit card company and verify the transaction. Credit card companies vouched for the counterparty risk, which is why they needed to charge high processing fees to merchants to cover losses from clients who could not pay.
Electronic payment systems pre-blockchain: Modern electronic payment systems, such as credit cards or PayPal, give users the illusion of immediate finality. However, behind the scenes, financial intermediaries like banks and payment providers have complex backend processes in place to prevent double spending and ensure payment security. The process of updating privately managed ledgers delays settlement for merchants, even when funds are deducted from buyers immediately.
Blockchain based payments: Blockchain networks introduced a new form of finality by ensuring that transaction blocks, once committed to the ledger, cannot be revoked. The type of finality provided by a blockchain infrastructure depends on the consensus mechanism used; it can be probabilistic or deterministic.
“Probabilistic finality” is typically provided by Proof-of-Work systems, such as the Bitcoin network. Transactions included in a block are initially considered final with low certainty. As additional blocks are added to the ledger, the probability of reversal decreases exponentially. Older transactions become increasingly expensive to alter and, therefore, more secure, making it prudent to wait for multiple confirmations for high-value transactions.
“Deterministic finality” (also known as absolute finality) is provided by alternative consensus mechanisms that emerged over time, such as Proof-of-Stake (PoS) or Byzantine-Fault-Tolerant (BFT) systems. Deterministic finality ensures that once a transaction is added to the ledger, it is permanently finalized. There is no probability of reversal, as validators agree on the ledger’s state in a way that is immediately immutable. Unlike Proof-of-Work, additional confirmations do not enhance finality. While deterministic systems offer stronger initial security guarantees, they are much more complex and require greater network coordination. They also tend to be more centralized, as the number of validators is typically limited.
Protocol Forks & Network Splits
In software engineering, a “fork” is the process of copying and modifying open-source software without needing permission from the original developers. In blockchain networks, forks manifest in several distinct forms.
External forks occur when developers adopt a blockchain’s codebase to launch a completely new network with different values and priorities, along with a new community of participants. Examples of forks of the Bitcoin codebase include “Zcash” or “Litecoin.” Zcash was created with the purpose to provide a more privacy-preserving blockchain network than Bitcoin. Litecoin was created with the purpose to provide a more scalable network.
Internal forks (technical): This type of fork typically results from a protocol change aimed at improving network functionalities without the intention of creating a radically different network. Technical protocol updates are common in blockchain networks, particularly in the early years. They usually do not create much controversy, as they are part of the R&D process. In these cases, developers discuss proposed changes publicly, and once there is broad consensus, the new rules are implemented. Node operators must download the new protocol and install it on their computers—effectively voting for the upgrade. Node operators who upgrade to the new rules effectively vote for the change, while those who do not agree continue running the old protocol, potentially causing a network split. A protocol upgrade is considered successful when most nodes accept the new rules. The shorter chain with the nodes operating under the old rules eventually dies due to lack of support.
Internal forks (political) result from highly contested protocol changes. When the community is divided by strong political narratives, the network can split into two: one branch follows the new protocol, while the other retains the old version, even if it is the minority chain. Each network maintains the history of transactions up to the point of the fork, and token holders in the original network receive an equivalent amount in the new one. Anyone who owned tokens in the old network will also own an equivalent amount of tokens in the new minority network, which they can then sell or hold. However, this requires at least one exchange to list the token of the minority network; otherwise, there is no market for the new token, and as a result, the network fades into oblivion. Examples of highly politicized blockchain forks include the events that led to the emergence of “Bitcoin Cash” or “Ethereum Classic.”
Internal forks (economic): Sometimes, network splits can also result from deliberate secession for short-term economic gain, rather than philosophical protocol discussions. If the narrative convinces enough people, the network splits into two. If the new token is listed on an exchange, the narrative is further hyped before the market collapses or the narrators have sold off all their tokens in a rug pull. “Bitcoin Gold,” “Bitcoin Diamond,” and “Bitcoin Platinum” are examples of such events. Both political and economic forks are black swan events that can create unexpected market dynamics and influence the value of one’s tokens, depending on which network gains more traction in the long run.
Temporal splits of the network occur accidentally due to network latencies. In the Bitcoin network, for example, when two nodes solve a block simultaneously, they create two alternative versions of the ledger, resulting in two parallel blockchain networks. The Bitcoin protocol has a provision to resolve these temporal splits so that only one branch of the network survives: It always recognizes the version of the ledger managed by the network of nodes with the most computing power spent as valid; the other nodes eventually adapt.