Technical Architecture
Last updated
Last updated
Sharding Technology
Zippy's technological foundation is a hybrid sharding technology that combines network sharding and state sharding. Sharding refers to a horizontal scaling method in which tasks in the blockchain network are distributed to different nodes for processing. By splitting a block in chronological order into different chunks and assigning them to different shards for parallel processing and confirmation of a small portion of transactions, the performance of the entire network can be improved. After the entire storage area is divided, different shards only store different parts. Therefore, each node is only responsible for processing its own shard data.
Network Sharding: Divide the entire blockchain network into groups, each group called a shard. All shards process different transactions simultaneously to achieve parallel bookkeeping.
Transaction Activities Run on a Per-node Basis: Transactions are randomly allocated to different shards or groups, and some nodes are responsible for bookkeeping, such as allocation through transaction hash values or addresses, or random allocation through VRF.
State Sharding: Store the complete ledger information in each shard, and each shard maintains its own ledger information.
Zippy solves the problem of cross-shard data synchronization through a full-stack approach.
Beacon Chain and Execution Chain
The Beacon Chain is also a sharded chain responsible for transmitting instructions and coordinating the operation of the execution chain. It does not store data and is only responsible for managing random beacons and identity registration.
Random Beacon: generates random numbers and accepts stake pledges.
Sharded chains are responsible for storing and running the state information and transactions on different chains, belonging to the demand execution layer. They can process, verify transactions, and has many nodes to maintain and verify transactions, with data storage capabilities.
To ensure the security and consistency of the blockchain, the beacon chain contains the header of each block in the sharded chain, and the beacon chain also broadcasts its own header to other shards. Even if N sub-chains are running synchronously, the headers of each shard can be shared with each other, while ensuring decentralization.
Zippy achieves cross-shard communication and maintains consistency between shard transactions through the Kademlia routing protocol. Each shard interacts with its neighboring shards according to the distance determined by the shard number in the routing table. This allows for efficient information transmission and transaction verification.
To prevent text tampering, many blockchain structures require downloading the entire node information, which greatly reduces the verification speed. However, Zippy uses light node information, which combines partial hash values of each block in each epoch and downloads all hash values in the current epoch for verification. This provides a more efficient and secure verification process.
Parallel Ethereum Virtual Machine
The parallel confirmation mechanism using the Ethereum Virtual Machine (EVM) is a method to improve transaction confirmation speed on the Ethereum network. In the Ethereum network, each transaction needs to be verified and confirmed one-by-one by multiple nodes before it can be added to the blockchain, which usually requires a certain amount of time and resources.
To speed up this process, Zippy adopts the parallel execution engine using the Ethereum Virtual Machine (EVM) through optimistic execution. In terms of the execution engine, conflicts are pro-actively managed and transactions are processed, optimistically, in batches, and then verified after execution as indicated by Figure 4.
Specifically, when a node receives a transaction, it sends the transaction to other nodes for verification and confirmation. If multiple nodes verify the transaction simultaneously, these nodes can execute the transaction's smart contract code in parallel without waiting for confirmation from other nodes. This parallel confirmation mechanism can improve transaction processing speed and network throughput, thereby improving the performance and scalability of the entire network. Grouping the sender transactions in parallel also avoids transaction conflicts. In cases where there are dependencies, the parallel engine reads and writes all transactions, records them in a data structure, checks the dependencies, and records them. Once all dependencies are recorded, the information is attached to the block as metadata. Transactions are then rearranged for re-verification.
The Zippy Parallel EVM tackles key challenges to enable efficient parallel transaction processing by the following features:
Dispatcher: Responsible for distributing transactions across multiple threads for concurrent execution, thereby optimizing throughput.
Parallel Execution Engine: Utilizes parallel processing to execute transactions independently on dedicated threads, significantly reducing processing time.
Local StateDB: Each thread maintains its own dedicated "thread-local" StateDB, which efficiently records state access information during execution.
Conflict Detection & Re-execution: Ensures data integrity by identifying and managing transaction dependencies. In the event of conflicts, transactions are re-executed to guarantee accurate outcomes.
State Commit Mechanism: Once finalized, the results are seamlessly committed to the global StateDB, updating the overall state of the blockchain.
Consensus Mechanism——fBFT+PoS
Ethereum uses the traditional pBFT consensus mechanism with a complexity of O(N*N) (N is the total number of nodes). In pBFT, each validator needs to broadcast its vote to other validators, which is similar to a leader broadcasting messages to all nodes, and nodes will continuously broadcast to each other, resulting in the number of messages increasing almost quadratically with the number of nodes, greatly increasing the complexity of communication. When the number of nodes in the system reaches several hundred or thousands, the network will be very congested, and it will be difficult for the blockchain to scale. Under this mechanism, if the malicious attackers are less than 1/3, the network will not experience security issues.
Zippy uses the iterative and optimized fBFT consensus mechanism and BLS (Boneh-Lynn-Shacham) multi-signature scheme to address the scalability issues of the traditional pBFT consensus mechanism. The complexity of the fBFT mechanism and BLS multi-signature scheme is O(N) (where N is the total number of nodes), which is much more efficient than the O(N*N) complexity of the pBFT mechanism. In the fBFT mechanism, validators don't need to broadcast their votes to every member, they only need to send their vote to the leader through digital signatures. The leader then combines the received digital signatures into a multi-signature with a data size of O(1) and broadcasts it. This reduces the communication complexity from exponential expansion to linear expansion, especially when the number of nodes is large, resulting in significant improvements in scalability. Additionally, Zippy uses the BLS multi-signature algorithm to verify the signatures on the block header and beacon chain, avoiding the huge communication overhead of verifying nodes and broadcasting voting results. Finally, RaptorQ fountain codes are used to accelerate block propagation.
Under this mechanism, security may be slightly less than the traditional pBFT consensus mechanism. Before the use of sharding technology, all participants were in an aggregated state, and the proportion of malicious attackers was relatively small, which had little overall impact. After sharding, if all malicious attackers are concentrated in one shard, they will have an absolute dominant position, which can then destroy the shard.
Zippy introduces a PoS (Proof of Stake) mechanism and a reshuffling mechanism based on weighted sharding to ensure security.
Validators are randomly assigned to shards, and the maximum number of votes for each validator in each shard is set according to a proportional rule to prevent one person from dominating a shard. Specifically, in each epoch, validators receive voting power based on their token stakes, and this voting power is randomly assigned to different shards. To deal with a large number of malicious token holders, Zippy can randomly sort the voting power and evenly distribute it to different shards for voting. To obtain voting power, the minimum token stake required is the total staked amount divided by (number of shards*c), where c=600. Once more than 600 stakes are obtained, the high security of the shard can be ensured. Therefore, the more tokens there are, the larger the threshold required.
Zippy limits the amount of voting power a validator can obtain in each shard. If a validator's voting power in a shard exceeds the threshold, it will be reassigned to another shard. To prevent malicious attacks, the voting power in each shard is randomly reassigned to other shards at the end of each epoch. When a validator is assigned to a new shard, they only need to download the content of the new shard. Moreover, since the first block of each period contains additional hash pointers pointing to the first block of the previous period, it is only necessary to verify the hash of the first block of each period, reducing the cost and time required for signature verification. Through this method, new nodes can skip other blocks in a period when tracing the hash pointers, which speeds up the verification of the current state of the blockchain.
Stochastic Algorithm——VDF+VRF
Verifiable Delay Function (VDF) and Verifiable Random Function (VRF) are cryptographic concepts that can be used to generate random numbers or verify the results of some computation. In Zippy, VDF is used to delay the disclosure of random numbers to prevent attacks by the last discloser. Specifically, validators need to perform some difficult-to-reverse computations to obtain random numbers, ensuring that the generation process is not predictable or tampered with. VRF is used to select consensus verification groups, and it can randomly select verification groups by encrypting classification to prevent validators from colluding to cheat. By combining VDF and VRF technologies, Zippy ensures randomness and enhances the security of consensus.
Due to the presence of VDF, the leader cannot know the actual final random number before submitting pRnd to the blockchain. By using VDF to calculate Rnd and submitting pRnd in the previous block, the leader cannot manipulate the process or tamper with the result. If the leader does not submit pRnd and stops the protocol, fBFT has a timeout mechanism to switch leaders and restart the protocol. With the random algorithm determined, the nodes (each node with one validator) can be randomly assigned to each shard, and they will be periodically reassigned to ensure that the validators do not occupy the same node for a long time, thus ensuring security. In addition, the random process uses the DRG protocol, whose complexity is O(n), achieving linear speed and thus improving efficiency.
Smart Contracts and Development Framework
ZippyChain is fully Ethereum Virtual Machine (EVM) compatible. Any application developed for Ethereum can be redeployed on ZippyChain without any changes. The same bytecode from Ethereum can be redeployed on ZippyChain without modifications.When interacting with a smart contract on ZippyChain, the virtual machine pulls the bytecode and associated state from disk, then steps through individual opcodes to execute the function being called. For example, if two individuals were to deposit into a platform like Aave on Ethereum, the transactions would be ordered sequentially, one after the other. In contrast, on ZippyChain, these transactions would essentially be processed in parallel, and be potentially deposited into different shards.
The Ethereum Virtual Machine (EVM) is a crucial component of the Ethereum blockchain, functioning as its computation engine. It is responsible for managing the state of the blockchain and enabling the execution of smart contracts. The EVM operates within client software like Geth, which allows nodes to run on the network and maintain copies of transaction data. The EVM processes this data to update the distributed ledger, ensuring that all nodes reflect the same state of transactions and contracts.
Smart Contract Execution
The EVM executes smart contracts by interpreting bytecode, which is generated from high-level programming languages such as Solidity. When a smart contract is deployed, it is compiled into bytecode that the EVM can understand and execute. This execution involves interpreting Opcodes—low-level machine instructions that dictate how operations are performed.
Block Creation
In addition to executing transactions, the EVM plays a vital role in block creation. It sets standards for managing state transitions from one block to another, with states stored in a Merkle Patricia Trie. This structure ensures that the current state of the blockchain is accurately maintained across all nodes.
Gas Fee Management
The EVM operates under a gas fee mechanism, which limits the computational resources that can be used during transaction execution. Gas serves as a measure of computational power on Ethereum; each operation in a transaction consumes a certain amount of gas, and users must provide sufficient gas to execute their transactions successfully. For ZippyChain, the gas fee consists of the base fee, which is 5*10-9 ZPT.
Architecture of the EVM
The architecture of the EVM is based on a stack-based memory model, which includes several key components:
Memory: Temporary storage used during contract execution.
Storage: Persistent storage for contract data.
Stack: A last-in-first-out (LIFO) structure used for managing function calls and local variables.
The EVM is considered quasi-Turing complete, meaning it can perform computations given sufficient resources but is constrained by gas limits, preventing infinite loops or excessive resource consumption.
On-Chain Storage
ZippyChain 's on-chain storage solutions are designed to manage and store various types of data, primarily through the use of smart contracts. The architecture of ZippyChain incorporates Trie Data Structure that facilitates efficient and secure data management. Patricia Merkle Tries combine a radix trie with a Merkle tree. This structure allows for efficient storage and retrieval of data while ensuring integrity through cryptographic hashes. The main types of tries used are:
State Trie: Stores the current state of all accounts and their balances.
Storage Trie: Holds contract-specific data and state variables, effectively acting as a virtual filing cabinet for each smart contract.
Transaction Trie: Contains information about all transactions processed by the network
Types of On-Chain Storage
Smart Contract Storage: Data can be stored directly in smart contracts. This includes variables that maintain state information relevant to the contract's functionality. Each contract has a dedicated storage space where data is stored permanently on the blockchain.
Calldata: This is a special type of memory used to hold function arguments during execution. While it is not permanent storage, it is crucial for temporary data handling within transactions.
On-Chain Calldata Encoding: Media or other data can be encoded directly within Ethereum transaction calldata. While this method is cost-effective, it lacks programmability and may be subject to pruning in future network updates.
7.1 Limitations and Consideration
Cost: Storing data directly on-chain can be prohibitively expensive due to gas fees associated with transactions. For example, every new 32 bytes of storage can consume significant gas, making it impractical for large datasets.
Data Size Constraints: Each block has a maximum size limit, which restricts the amount of data that can be included in a single transaction. This limitation necessitates careful planning when designing smart contracts to ensure efficient use of space.
Immutability: Once data is stored on the blockchain, it becomes immutable, meaning it cannot be altered or deleted. This characteristic ensures data integrity but also poses challenges for updating information.
Given the constraints of on-chain storage, many developers opt for hybrid solutions that combine on-chain and off-chain storage methods:
Off-Chain Storage with References On-Chain: Large files or documents are often stored off-chain using decentralized file storage systems like IPFS or Arweave, while hashes or references to these files are stored on-chain. This approach balances cost-effectiveness with the benefits of immutability and decentralization
7.2 Zippy Layer 2 Storage Chain
ZippyChain is set to introduce the Zippy Layer 2 Storage Chain, a decentralized storage system designed to provide efficient, secure, and reliable data storage services for users and developers. This innovative platform supports the management of data and token assets compatible with Ethereum addresses, allowing users to utilize their Ethereum wallets for easy asset transfers to Zippy, benefiting from improved performance and lower costs.
The Zippy Storage Public Chain facilitates the interchangeability of data and token assets through smart contracts, enhancing liquidity by enabling users to trade these assets seamlessly. To ensure data security and reliability, Zippy employs a "storage provider" network consisting of nodes that store user data. Uploaded data is fragmented and distributed across these nodes, which are then reassembled upon user request.
Developers are provided with APIs that match the performance of existing Web2 cloud storage solutions, allowing them to use familiar programming languages and tools. This feature reduces learning curves and development challenges, enabling rapid application migration to the Zippy platform.
The architecture incorporates the GHOSTDAG consensus [8], which enhances transaction confirmation and block generation efficiency while maintaining high decentralization and security. This consensus mechanism supports scalability and throughput, achieving faster transaction confirmations with lower latency.
Additionally, ZippyChain promotes data ownership and market opportunities, particularly for artificial intelligence applications. Users can trade their data as assets, unlocking economic benefits while providing high-quality datasets for AI training. Overall, the Zippy Layer 2 Storage Chain aims to revolutionize decentralized storage by combining blockchain technology with user-friendly features that cater to both developers and end-users in the evolving digital landscape.
Zero Knowledge Proof and Zippy Layer 2 ZK EVM chain
Zero-Knowledge Proofs are cryptographic protocols that allow one party (the prover) to demonstrate to another party (the verifier) that a statement is true without revealing any information beyond the validity of the statement itself. This technology is particularly valuable in blockchain for several reasons:
Transaction Privacy: ZKPs enable users to conduct transactions without disclosing sensitive information such as transaction amounts or participant identities. For instance, privacy coins like Zcash utilize ZKPs to obscure transaction details, allowing users to transact securely while preserving anonymity.
Identity Verification: ZKPs can facilitate identity verification processes without requiring users to disclose personal information. This is especially beneficial in decentralized identity systems, where users can prove attributes (e.g., age or citizenship) without revealing their actual identities, even ZNS.
Scalability: By allowing off-chain computations and submitting only the proof to the blockchain, ZKPs can enhance scalability. Techniques like ZK-Rollups bundle multiple transactions into a single proof, significantly increasing throughput while maintaining privacy. ZippyChain will launch its own layer 2 blockchain with ZK EVM.
Security: The non-interactive nature of certain ZKP implementations, such as ZK-SNARKs, provides efficient verification processes that bolster security against data leaks and unauthorized access.
To scale the Mainnet further, ZippyChain will launch a zero-knowledge EVM layer 2 public chain with ZK Rollup, which is a blockchain network built on top of the main chain that uses zero-knowledge proof technology to protect user privacy and executes smart contracts using the Ethereum virtual machine. Therefore, Zippy has high scalability and privacy protection capabilities, while also maintaining compatibility with Ethereum smart contracts, making it easy for developers to migrate existing Ethereum applications to this public chain.
One of the core technologies is ZK Rollup, which uses zero-knowledge proof to achieve blockchain scalability. In ZK Rollup, transactions sent by users are collected by an off-chain aggregator. The aggregator packs these transactions into a batch and generates a zero-knowledge proof (ZKP) to prove that the batch of transactions is valid. Then, the aggregator publishes this proof and the metadata of the batch (such as the hash of the transactions) to the main chain. Since the main chain does not need to process each transaction and only needs to verify the ZKP, and the size of the zero-knowledge proof does not depend on the number of packed transactions, ZK Rollup can greatly improve the throughput (TPS) and processing capacity of the mainnet while maintaining network security and decentralization.
At the same time, ZK EVM can also protect data privacy and be beneficial to AI training as we can verify data without observation. ZK Rollup can move the verification and processing of transactions to the second layer chain, thereby protecting the privacy of transactions. This is particularly important for AI applications that involve sensitive data because it can ensure the confidentiality and integrity of data, thereby improving the quality and efficiency of AI training.
Fusion of AI Agents with Blockchain
AI agents are capable of executing tasks across various industries, including transportation, supply chain, and healthcare, etc. These agents are designed to perform economic work on behalf of users, enhancing efficiency and productivity within the digital economy.
ZippyChain provides a robust blockchain infrastructure that supports agent operations and user transactions. We will provide a platform to serve as a directory for registered agents, ensuring their discoverability and facilitating interactions. ZippyChain documents transactions securely, while ZPT tokens power the ecosystem by enabling transactions and interactions. The combination fosters a decentralized approach to automation, where AI agents can operate without central control. This not only increases efficiency but also democratizes access to advanced technologies for various participants in the digital economy. ZippyChain infrastructure supports high-performance applications by enabling AI agents to operate seamlessly across multiple blockchain protocols. This addresses scalability and reliability challenges in DApp development, allowing developers to integrate sophisticated AI functionalities effortlessly. Specifically, we tackle the following pain points for AI agents.
Creation and Deployment of AI Agents ZippyChain provides a user-friendly interface that allows individuals to create AI agents easily through a plug-and-play system. Users can stake tokens to deploy their agents, which are then integrated into the blockchain environment. Each agent is represented as an ERC-20 token, ensuring ownership and facilitating transactions within the ecosystem.
Tokenization and Co-Ownership ZippyChain supports the tokenization of AI agents, enabling users to share ownership and profits generated by these digital entities. This co-ownership model fosters a collaborative environment where multiple stakeholders can invest in and benefit from the success of AI agents.
Revenue Generation AI agents can generate revenue through various interactions—such as providing services LLM finetuner, gaming or entertainment—and this income is distributed among token holders.
ZippyChain utilizes smart contracts to ensure transparency and security in all interactions. The decentralized nature of blockchain allows for reliable record-keeping and trust among participants, which is crucial for managing digital assets effectively. By integrating AI agents with blockchain, ZippyChain enables more personalized and responsive applications. Users benefit from intelligent interactions that anticipate their needs based on previous engagements, making decentralized applications (dApps) more intuitive.
Decentralized & Collaborative AI on Blockchain
The centralization of artificial intelligence is a significant challenge resulting from the proprietary nature of large datasets, and outdated models that require re-training. Moreover, large language models such as ChatGPT require extensive computing power (e.g., over 10K GPU) to pre-train, which is too costly for many firms.
To address this issue, Zippy proposes a decentralized framework that uses AI, prediction markets, and crowd sourcing GPUs to collect vast amounts of data and create shared machine learning models. The framework enables participants to collaboratively build a dataset and use their own GPUs and smart contracts to host an updated model that can be publicly shared on Zippy. This framework is particularly useful for learning problems with similar inputs, such as personal assistants, games, and recommender systems, large language models (LLM).
The system consists of three configurable components: the incentive mechanism, data handler, and the machine learning model. Multiple contributors can collaboratively train the model using their own GPUs, which remains open for others to use. Participants add data to the system, which is validated and stored before updating the model. The smart contract of the system accepts "add data" actions from participants, with the incentive mechanism triggering payments or allowing other actions. The framework incentivizes contributors to submit honest data and penalizes bad data submissions, with financial profits being a possibility but not the primary goal.
The dataset is public and easily accessible through the blockchain's transaction history or emitted events. Compared to typical crowdsourcing platforms, which often struggle to filter out spam and bad data submissions, this framework provides a more reliable and cost-effective method of collecting large datasets. The parallel EVM under Zippy allows fast pre-training of large language models. The Zippy framework aims to create valuable shared resources for the benefit of all, while promoting continuous model improvement through collaboration and reducing dependency on proprietary data.
As shown in Figure 11, adding data consists of 3 steps. (1) The Incentive Mechanism validates the transactions, for instance, in some cases a “stake” or monetary deposit is required. (2) The DataHandler stores data and meta-data into the blockchain. This ensures that it is accessible for all future uses, not limited to this smart contract. (3) The machine learning model is updated according to predefined training algorithms. In addition to adding data, anyone can query the model for predictions, and the incentive mechanism may be triggered to provide users with crypto payments.
By exploiting open source LLMs such as Huggingface, LLaMa and Deepseek, we are on a journey of democratizing artificial intelligence through blockchain.
CrossChain Bridges
With the increasing prevalence of Layer 1 (L1) blockchains and Layer 2 (L2) scaling solutions, as well as the rise of decentralized applications (dApps) operating across multiple chains, the necessity for effective communication and asset movement between these chains has become crucial to network infrastructure. Various types of bridges have emerged to facilitate this connectivity.
Bridges serve to connect blockchain networks, enabling interoperability and communication between otherwise isolated ecosystems. Without these connections, significant innovation within a single blockchain can be stifled by its inability to engage with other ecosystems.
By providing a transportation route between blockchains, bridges allow for the transfer of tokens, messages, arbitrary data, and even smart contract calls from one chain to another.
Zippy aims to be the Layer 1 Trustless Bridge across all chains. Zippy will launch a trustless bridge to other mainstream blockchains such as Bitcoin, Ethereum, BSC, Tron, Avalanche, Solana, etc. It is a bridge with cross-chain light clients, relayers, and prover full nodes, all trustless, no additional trust assumptions beyond the two blockchains that the bridge is connected to:
A gas-efficient Zippy light client on Ethereum (can be connected to other chains) that only requires a checkpoint to verify any number of Zippy transaction proofs by the clients.
A constant-size Zippy light client proof that any user needs to send cross-chain (e.g., Ethereum) to claim their Zippy transaction.
Benefits of Bridges
Bridges unlock a multitude of use cases by enabling the exchange of data and asset movement between blockchain networks. Each blockchain possesses unique strengths and weaknesses concerning speed, throughput, and cost. Bridges enhance the overall crypto ecosystem by allowing blockchains to leverage each other's innovations.
For developers, bridges offer:
Cross-Chain Transfers: Facilitate the movement of data, information, and assets across different chains.
Expanded Protocol Features: Bridges enhance the design space for protocols. For instance, a yield farming protocol originally on Ethereum Mainnet can provide liquidity pools across all EVM-compatible chains.
Utilization of Diverse Blockchain Strengths: Developers can capitalize on lower fees from various L2 solutions by deploying their dApps on rollups and sidechains.
Collaboration Opportunities: Encourage developers from different blockchain ecosystems to collaborate on new products.
Attracting Diverse Communities: Draw users and communities from various ecosystems to engage with their dApps.