# Doctrina: Blockchain 5.0 for Artificial Intelligence
## 3 Blockchain and Smart Contracts  
Figure 2 illustrates the workflow and components involved in the Ethereum blockchain, focusing on block creation, validation, and the execution of smart contracts through the Ethereum Virtual Machine (EVM).  
On the left side, we see the Ethereum validators, which are responsible for the creation of new blocks. Each block consists of a header and data. The header includes various fields such as the hash of the previous block, difficulty level, a nonce (an arbitrary number used only once to ensure security), a timestamp, block number, gas limit, and an address. The data section contains a list of transactions, which can be normal transfers, contract deployments, or state changes.  
This figure also depicts the Merkle Tree, a data structure used in blockchains for efficiently summarizing and verifying the integrity of large sets of data, such as transactions. The Merkle Tree ensures that each block is securely linked to its transactions. The bottom part of the tree represents individual transactions, which are combined pairwise to form the next layer of hashes, culminating in the Merkle root hash that is stored in the block's header.  
The process continues with light nodes in the network that do not store the full blockchain but can verify transactions using the block headers, thus maintaining the network's integrity without requiring significant computational resources.  
Moving to the right side of this figure, we encounter EVM, which is a crucial component of the Ethereum network. It acts as a runtime environment for smart contracts, allowing them to be executed in a secure and isolated manner. EVM handles various types of transactions, such as normal transfers, deployment of new contracts (which is the creation of the contract on the blockchain), state-changing transactions (which alter the state of an existing contract), and smart contract bytecode (which is the compiled code of a contract that the EVM can execute).  
The interaction with smart contracts is illustrated through the representation of users who can create, transfer, and interact with smart contracts. When a user initiates a smart contract interaction, it generates a transaction that can be a state change or a contract creation.  
Finally, this figure demonstrates the validation and proposal of new blocks. After transactions are executed and their results are computed by the EVM, these results must be validated. If they are valid, a new block proposal is created. This proposal includes the new state of the blockchain after the transactions have been executed. Validators or miners then work to validate this new block, and once consensus is reached, the block is added to the blockchain. This process repeats with the creation of each new block, allowing the Ethereum blockchain to function and grow securely.  
Ethereum was selected as the prototyping platform for Doctrina due to its advanced smart contract capabilities, established runtime environment, and alignment with public, decentralized execution models. As a Turing-complete blockchain platform, Ethereum enables the implementation and testing of complex logic required for on-chain AI workflows. Its standardized execution model, deterministic transaction processing, and support for verifiable computation provide a rigorous and reliable environment for evaluating the feasibility of decentralized AI integration. Moreover, Ethereum's public infrastructure allows for realistic assessment of system performance, scalability constraints, and economic mechanisms such as gas fees, which are essential for maintaining network integrity in open blockchain environments. These characteristics make Ethereum a technically ap  
Figure 2: Ethereum architecture.  
propriate and representative platform for validating the foundational principles of the Doctrina architecture.