Use GitAGI
GitAGI White Paper:A Peer-to-Peer Deep Learning Network
GitAGI White Paper:A Peer-to-Peer Deep Learning Network

GitAGI-3.jpg

Abstract

A peer-to-peer AI network should allow AI development to be directly initiated and utilized by individuals within the network, without the need for AI training or inference to be conducted through centralized clusters monopolized by a few. While distributed computing facilitates collaborative task execution on a large scale, the majority of computing capacity remains under the control of a small number of institutions. That would mean losing the advantage that AI, as an advanced productivity tool, should inherently possess in the field of innovation. Digital signatures provide ownership attribution for data and control over transmission. Any contributions to the AI network made by individuals can be integrated for use by others within the network. This will make it much easier for individuals to be incentivized for innovation, breaking the situation where only a few can benefit from innovative achievements.

We propose a peer-to-peer deep learning network called GitAGI, where individuals can participate in network maintenance or usage without permission. GitAGI employs parallel techniques to divide neural network computing tasks into Sub-DAGs and schedules different Sub-DAG to be computed simultaneously across multiple computing nodes. When a computing node is detected by the network as having exited while still having unfinished tasks, the task broker node will schedule other computing nodes from the network to continue executing this task. The network utilizes Proof of Work (PoW) distributed ledger to record task assignments. The PoW mechanism fairly produces tokens, attracting users to participate in the maintenance and development of the GitAGI network. Additionally, it adopts hybrid computing verification to validate the effectiveness of computational workload and prevent malicious behavior by nodes. With the assurance of data and model ownership, we aim to develop a decentralized, global, and individual sovereignty-oriented AGI computing infrastructure. Our goal is to build an AGI digital economic network accessible and participatory for everyone.

1 Introduction

In the era of Large-scale models intelligent emergence, the development of artificial intelligence requires extremely high computational resources.For the vast majority of developers, the cost of high-performance dedicated computing clusters is prohibitively expensive and difficult to obtain. Individual developers are constrained by the limited resources available within a single organization, making it impossible for them to participate in the development of advanced LM and contribute to the advancement of AI. Computational resources, AI models, data, and other resources are controlled by a very small number of institutions, leading to market monopolies. Ultimately, this will discourage fair competition, innovation incentives, and rapid development in the AI industry.

We propose a decentralized deep learning framework (DDL) to support deep learning networks that can run in the open-net environment. GitAGI builds a decentralized intelligent network using technologies such as blockchain, parallel computation graphs (Sub-DAGs), decentralized hash tables (DHT), mixed expert models (MoE), and proof of useful work (PoUW). By applying large-scale heterogeneous computational resources to decentralized AI infrastructure, unlock the enormous potential for individual participation in AI innovation, and pave the way for decentralized development in the AI industry.

2 Transaction and Task

GitAGI consists of two types of transactions: regular transactions and AI task transactions.

Regular transactions in GitAGI are consistent with the transaction mechanism in existing Proof of Work (PoW) consensus, ensuring the consistency and availability of ledger data. GitAGI supports the Ethereum Virtual Machine (EVM) and smart contracts. Additionally, in the future, it will open up to the WebAssembly (WASM) VM Dapp ecosystem.

The AI task transaction is a transaction type specially established by GitAGI to facilitate the execution of AI tasks (such as model training and inference). AI developers submit AI task transactions, which trigger the AI task processing workflow upon confirmation.
Miners who package the AI task transactions in blocks are responsible for creating a computing network comprising task broker nodes and computing nodes to carry out AI computations. After the AI task transactions are completed, the computation results will be recorded in the PoUW ledger.

The execution process of AI task transaction:

1) AI Task Decomposition: Task broker nodes organize temporary computing networks based on the computational power and network environment of each computing node, and generate task subgraphs (Sub-DAGs) for the selected computing nodes.

2) AI Task Computation: Computing nodes execute a series of computational processes, including forward propagation (FP), backward propagation (BP), and parameter updates (Update), based on the assigned Sub-DAG.

3) AI Task Verification: Employing a hybrid computation verification method to prevent cheating by computing nodes.

3 The Proof of Useful Work

The PoUW consensus algorithm integrates multi consensus mechanisms and network structures from classical blockchain, fully inheriting the fairness, transparency, and anonymity features of PoW. The efficient operation of DPoS network makes it more suitable as the execution environment for decentralized deep learning (DDL). This characteristic allows GitAGI to perform AI task computations while still retaining the advantages of decentralized architecture. Ultimately, this allows blockchain technology to be applied to the development of AI in a democratic and open manner, rather than solely serving as electronic currency.

Node Type:

Full NodeSyncing and verifying every block and transaction of GitAGI, executing smart contract code and state transitions to ensure consistency with other nodes in the network.
Light NodeNo need to sync all existing blocks, just download block headers and the required data.
Miner NodeParticipate in PoW ledger maintenance. Responsible for validating transactions, executing smart contracts, and confirming block creation.
Task Broker NodeCreate an AI task transaction DAG graph, decompose it into Sub-DAGs, and assign these Sub-DAGs to different computing nodes. After all computing nodes complete their tasks, synthesize the complete task result. Also, responsible for validating the computing node workload validity.
Computing NodePerform Sub-DAG computation.

4 Network

GitAGI uses PoW consensus + EVM as the underlying network for asset issuance, transactions, and smart contract execution.

Ledger Network

In the PoUW network, valid workload is defined as any computation or service that is valuable to the network. The proof mechanism is implemented through the following steps:

1) Task Generation:The dataset customized by AI developers, which includes AI parameters and reward details, will be used to construct AI task-type transactions. Miner nodes would confirm the transaction and mine the block.

2) Task Allocation: The network generates an DAG graph based on task-specific requirements and computing node capabilities. This graph is then decomposed into Sub-DAGs and distributed to seperate computing nodes.

3) Task Execution: Computing nodes execute the assigned Sub-DAG.

4) Proof of Work: Employing a hybrid computing verification method to prevent cheating on computing nodes.

5) Consensus Reached: The task broker node completes the validation of the validity proof of work, serving as the final step in the PoUW consensus.

The security of the PoUW network is established based on the node scale and the cost of malicious behavior in the POW consensus. The interactive collaboration between the ledger network and the computing network endow PoUW with the security advantages constructed by both POW and DPOS. The 51% hashing power security model in the POW consensus safeguards the sustainability of both the ledger network and the token economy.

Computational Network

The execution process of deep learning models is divided into forward propagation (FP) and backward propagation (BP). The FP and BP processes are described as directed acyclic graphs (DAG). When a task broker node receives a task published by an AI developer, it processes the task file, which includes neural network model files, data files, etc. Based on the neural network model file, the task broker node can define a DAG graph. Then, the task broker node splits the neural network DAG graph using parallel techniques, generating Sub-DAGs. When a computing node is detected by the network as having exited while still having unfinished tasks, the task broker node will schedule other computing nodes from the network to continue executing this task. The computing node retrieves the latest checkpoint from the GitFILE storage service and continues the unfinished task.

5 Reward

GitAGI adopts the PoUW (Proof of Useful Work) consensus mechanism to incentivize mining nodes to participate in network maintenance. All coins are generated by mining nodes through competing for the right to record transactions. These coins are then issued when new blocks are created. The total supply of GitAGI Coin is fixed at 84,000,000 coins. Initially, the block reward is set at 5 coins per block. Every 8,400,000 block height increase triggers a halving of the block reward. This model ensures a continuous issuance of coins through block rewards, which then enter circulation in the market.

Miners can earn two types of rewards based on their level of participation. Firstly, they receive mining rewards for maintaining the ledger. Furthermore, among the fees paid by AI developers for AI tasks, the mining node, the task broker node, and computing node receive 20:10:70 respectively.

AI model developers define their pricing plans through smart contracts. AI DApp developers, when using the models, are considered to have accepted the pricing plans and must pay fees to the AI model developers accordingly.

6 Decentralized Deep Learning Framework

Decentralized Deep Learning(DDL) is a permissionless decentralized development platform for deep learning, supporting the distributed collaboration of AI computing tasks in the open-net environment.

DDL transforms an open-source framework of deep learning into permissionless decentralized architectures, expanding their network infrastructure and adopting a running model based on an open-net, with open APIs and tool components, DDL assist developers in defining neural network models more conveniently and enables them to utilize decentralized devices for training and inference within the open-net environment.

To achieve the feasibility of AI training or inference computation in the open-net environment, GitAGI has innovated across four key elements: task partitioning, computation, communication, and fault tolerance. As follows:

1) AI tasks DAG are partitioned into Sub-DAGs in parallel based on both data and model dimensions.

2) Intelligent sub-DAG distribution is carried out according to the device performance and network environment connected to the decentralized deep learning network.

3) Using the mixture of experts (MoE) model, which has been restructured with a decentralized architecture. Compared to a Dense model with equivalent convergence performance, this approach reduces the computational power requirement by 90% for models of the same parameter scale.
0*v0y9YM72FRzR9Jbx.webp

4) Three model compression techniques are employed to compress the communication data volume. With no loss in model quality,communication efficiency is improved by 500%.

5) Distributed hash tables are employed to realize the elasticity and flexibility of the decentralized communication framework, allowing for dynamic permissionless joining and exiting of computing nodes.

DDL adopts a hybrid computing verification method to verify the validity of computational work on computing nodes. Considering the actual verification costs as well as the token economy, the practical approach will provide a dedicated ZKML algorithm library and observer node verification. This approach balances the high accuracy of ZKML in executing verification work with the efficiency and cost advantages of Optimistic ML.

7 AI Sovereignty

It’s clear the productivity boost represented by AI is reshaping the way society produces wealth. As a productivity tool, AI is unleashing the creative potential of ordinary individuals, driving large-scale collaboration and innovation in human society. Simultaneously, the explosion of digital productivity presents new institutional demands for the digital world’s equity system. People need a more robust encryption technology system to safeguard their personal digital rights.

In the era of Web3, AI is driving a paradigm shift in social wealth. The keys and ownership of data brought by the electronic encryption system will become the declaration of individual digital sovereignty in this era.

8 Summary

Because the high-quality datasets, large parameter models, and high-performance computing required for AI research are difficult for individuals to obtain, AI innovation has become almost entirely dependent on large research institutions, and is even being monopolized by a few organizations. Although the pace of AI innovation is already quite active, only a few people are able to participate. The barriers to participating in AI innovation limit the number of people who can directly benefit from dividends of AI.

In the future, we will need an AI system built on the principles of cryptography and decentralized architecture. The system allows anyone who wants to innovate AI to be able to directly participate in AI development without having to own a large amount of basic AI resources. Blockchain’s existing digital signature and smart contract frameworks offer the potential for achieving individual sovereignty over AI.

We propose a deep learning network designed to operate in an internet environment. The ledger network and AI computing network collaborate with each other, providing a highly scalable solution due to its simple structure. It also ensures fairness and efficiency, aligning with the expected principles of individual sovereignty in AI. All types of nodes can freely join or leave the network at any time, enabling the accomplishment of large-scale deep learning tasks at the level of the public open-net.