Source: BeWater Community
On June 14th, the AO Foundation officially launched the token economics of the decentralized supercomputer AO. On the evening of June 12th, prior to the release of the token economics by AO and the DA solution by NEAR, we invited the founders of Arweave and AO, Sam Williams, and the co-founder of NEAR Protocol, Illia Polosukhin, to engage in a deep discussion on the integration of AI and blockchain. Sam elaborated on the underlying architecture of AO, which is based on an Actor-oriented paradigm and a decentralized Erlang model, aiming to create a decentralized computing network that is infinitely scalable and supports heterogeneous process interactions. Sam also envisioned the potential applications of AO in the DeFi space, suggesting that by introducing trusted AI strategies, AO could achieve true “agent finance.” Illia shared the latest developments in scalability and AI integration by NEAR Protocol, including the introduction of chain abstraction and chain signature functions, as well as ongoing developments in peer-to-peer payments and AI inference routers. Additionally, both guests shared their perspectives on the priorities and research focus in their respective ecosystems, as well as innovative projects they are optimistic about. Thanks to @BlockBeatsAsia and @0xLogicrw for promptly compiling and translating the content into Chinese for the community.
Illia and Sam’s Involvement in AI and Cryptocurrency
Lulu: First, let’s start with a simple introduction of yourselves and how you got involved in the fields of AI and blockchain.
Illia: My background is in machine learning and artificial intelligence. Before entering the crypto space, I worked in this field for about 10 years. I am best known for the paper “Attention is All You Need,” which introduced the Transformer model widely used in various modern machine learning, AI, and deep learning technologies. Prior to that, I was involved in many projects, including TensorFlow, an open-source machine learning framework released by Google in 2014-2015. I also worked on question-answering systems, machine translation, and applied some research results in Google.com and other Google products.
Later, Alex and I co-founded NEAR.ai, initially an AI company focused on teaching machines to program. We believed that in the future, people would be able to communicate with computers in natural language, and computers would automatically program themselves. In 2017, this sounded like science fiction, but we conducted extensive research. We obtained more training data through crowdsourcing, with students from China, Eastern Europe, and other areas completing tasks for us, such as writing code and code comments. However, we faced challenges in paying them, as PayPal could not transfer funds to Chinese users.
Some suggested using Bitcoin, but transaction fees were high at the time. So, we delved deeper into research. With a background in scalability from Google, where everything had to be done at scale, my co-founder Alex created a sharded database company serving Fortune 500 companies. At the time, the state of blockchain technology was strange, with almost everything running on a single machine, limited by the capacity of a single server.
Therefore, we decided to build a new protocol, which became NEAR Protocol. It is a sharded Layer 1 protocol focusing on scalability, usability, and developer friendliness. We launched the mainnet in 2020 and have been growing the ecosystem since. In 2022, Alex joined OpenAI, and in 2023, he founded an AI company focusing on base models. Recently, we announced his return to lead the NEAR.ai team, continuing the work of teaching machines to program that we started in 2017.
Lulu: This is a very fascinating story. I didn’t know NEAR initially started as an AI company and is now refocusing on AI. Now, let’s hear from Sam about yourself and your project.
Sam: We started in this field about seven years ago when I had been following Bitcoin for a long time. We came across an exciting yet unexplored idea: you could store data on a network that would be replicated globally, without a single centralized point of failure. This inspired us to create an immutable archive that would be replicated in multiple locations, making it impossible for any single organization or even government to censor this content.
Our mission became to scale Bitcoin, or rather to achieve Bitcoin-style on-chain data storage at any scale, so we could create a knowledge repository for humanity, storing all history to form an immutable, trustless historical log where we would never forget how we got to this crucial background today.
We started this work seven years ago, and the mainnet has been live for over six years now. Along the way, we realized that permanent on-chain storage could provide functionalities far beyond our initial imagination. Initially, our idea was to store newspaper articles. But shortly after the mainnet launch, we realized that if you could store all this content around the world, you were essentially planting a seed for a permanent decentralized network. Furthermore, around 2020, we realized that with a deterministic virtual machine and a permanently ordered log interacting with programs, you could basically create a smart contract system.
We first attempted this system in 2020, calling it SmartWeave. We borrowed the concept of lazy evaluation from computer science, which is mainly promoted by the programming language Haskell. We knew this concept had been used in production environments for a long time, but it hadn’t been truly applied in the blockchain space. Typically, in the blockchain space, people execute smart contracts when writing messages. However, we believed that blockchain is essentially a data structure that only grows, with certain rules to include new information, without needing to execute code simultaneously with data writing itself. With an arbitrarily scalable data log, this was a natural way of thinking for us, although rare at the time. The only other team was the one now called Celestia (then called LazyLedger).
This led to a Cambrian explosion of computational systems on Arweave. There were about three or four major projects, some of which developed their own unique communities, feature sets, and security trade-offs. In this process, we realized that not only did we need to leverage data availability at the base layer to store these logs, but we also needed a mechanism to delegate data availability guarantees. Specifically, you could submit data to a packing node or other entities representing you (now called scheduling units), which would upload the data to the Arweave network and provide you with an economic incentive guarantee to ensure the data was written to the network. Once this mechanism was in place, you had a system that could scale computation horizontally. Essentially, you had a set of processes that could be seen as Rollups on Ethereum, sharing the same dataset and able to communicate with each other.
The name AO (Actor-Oriented) comes from a paradigm in computer science. We built a system that combines all these components, with a native messaging system, data availability providers, and a decentralized computing network. Therefore, the lazy evaluation component becomes a distributed collection, where anyone can start a node to resolve contract states. By combining these elements, you get a decentralized supercomputer. Its core is an arbitrarily scalable message log that records all messages involved in computation. I find this particularly interesting because you can perform parallel computations, and the scalability or utilization of my processes will not affect the scalability or utilization of your processes, meaning you can conduct computations of any depth, such as running large-scale AI workloads within the network. Currently, our ecosystem is strongly promoting this concept, exploring what happens when market intelligence is introduced into the base layer’s smart contract system. This way, you essentially have intelligent agents working for you, which are trusted and verifiable, just like the underlying smart contracts.
The Underlying Concepts and Technical Architecture of AO
Lulu: As we know, NEAR Protocol and Arweave are now driving the intersection of AI and cryptocurrency. I would like to delve deeper into this. Since Sam has touched on some of the underlying concepts and architectures of AO, I may start with AO first and then move on to AI. The concepts you described make me feel like those agents are autonomously running, coordinating, and allowing AI agents or applications to work on top of AO. Can you elaborate on the parallel execution or independent autonomous agents within the infrastructure of AO? Is the metaphor of building a decentralized Erlang accurate?
Sam: Before I begin, I want to mention that I built an operating system based on Erlang during my PhD. We called it running bare metal. The exciting thing about Erlang is that it is a simple yet expressive environment where every piece of computation expects to run in parallel, rather than a shared state model, which has become the norm in the crypto space.
The beauty of this lies in its elegant mapping to the real world. Just like how we are having this conversation now, we are actually independent actors, performing calculations in our own minds, then listening, thinking, and conversing. The agent or actor-oriented architecture of Erlang is indeed remarkable. Following my talk at the AO Summit was one of the founders of Erlang, who described how they came up with this architecture around 1989. At that time, they didn’t even realize the term “Actor-oriented.” But it’s such a wonderful concept that many people came up with the same idea because it makes sense.
For me, if you want to build a truly scalable system, you have to make them pass messages instead of sharing state. That is, when they share states, like in Ethereum, Solana, and almost all other blockchains.Like all other blockchains, NEAR is an exception in reality. NEAR has shards, so they do not share global state, but have local states.
When building AO, the goal is to combine these concepts. We want processes that can execute in parallel, perform arbitrary scale computations, while separating the interaction of these processes from their execution environment, ultimately forming a decentralized version of Erlang. For those less familiar with distributed technology, the simplest way to understand it is to imagine it as a decentralized supercomputer. With AO, you can launch a terminal within the system. As a developer, the most natural way to use it is to start your own local processes and then interact with them, just like you would with a local command-line interface. As we move towards consumer adoption, people are building UI and all the things you would expect. Essentially, it allows you to run personal computations in this decentralized computing device cloud and interact using a unified message format. When designing this part, we referred to the TCP/IP protocol that runs the Internet, trying to create a TCP/IP protocol that can be considered as the computation itself.
The data protocol of AO does not enforce the use of any specific type of virtual machine. You can use any virtual machine you want, as we have implemented WASM32 and 64-bit versions. Others in the ecosystem have implemented EVM. If you have this shared messaging layer (we use Arweave), then you can have all these highly heterogeneous processes interact in a shared environment, like the Internet of computations. Once this infrastructure is in place, the next natural step is to explore what can be done with intelligent, verifiable, trusted computations. Obvious applications are AI or smart contracts, letting agents make intelligent decisions in the market, possibly antagonizing each other, or representing humans against humans. When we look at the global financial system, around 83% of Nasdaq trades are executed by robots. This is how the world operates.
In the past, we could not bring the intelligent part on-chain and make it trustworthy. But in the Arweave ecosystem, there is another parallel workflow we call RAIL, the Responsible AI Ledger. It is essentially a way to create records of different model inputs and outputs and store these records publicly and transparently so that you can query and ask, “Hey, did this data I see come from an AI model?” If we can generalize this, we think it can solve a fundamental problem we see today. For example, someone sends you a news article from a website you don’t trust, with a picture or video of a politician doing something silly. Is it true? RAIL provides a ledger that many competing companies can use in a transparent and neutral way to store their generated output records, just like they use the internet. And they can do this at a very low cost.
Illia’s views on blockchain scalability
Lulu: I am curious about Illia’s views on the scalability of the AO method or model. You have been involved in the work of the Transformer model, which aims to address the bottleneck of sequential processing. I would like to ask, what is NEAR’s scalability approach? In a previous AMA chat, you mentioned that you are exploring a direction where multiple small models make up a system, which could be one of the solutions.
Illia: Scalability in blockchain can be applied in many different ways, and we can continue along the lines of Sam’s topic. What we see now is that if you use a single large language model (LLM), it has some limitations in inference. You need to prompt it in a specific way for it to run for a while. Over time, the model will continue to improve and become more general. But in any case, you are somehow training these models (think of them as primitive intelligence) to perform specific functions and tasks and to reason better in specific contexts.
If you want them to perform more general tasks and processes, you need multiple models running in different contexts, performing different aspects of tasks. To give a very specific example, we are now developing an end-to-end process. You can say, “Hey, I want to build this application.” The end result is a fully built application, including the right, formally verified smart contracts and thoroughly tested user experience. In real life, there usually isn’t one person building all these things, and the same idea applies here. You actually want AI to play different roles, performing different functions at different times, right?
First, you need an AI agent acting as a product manager, actually collecting requirements, figuring out what you want, what trade-offs there are, what the user stories and experiences are. Then there might be an AI designer responsible for translating these designs into the front end. Then there might be an architect responsible for the backend and middleware architecture. Next is an AI developer writing code and ensuring that smart contracts and all front-end work are formally verified. Lastly, there might be an AI tester ensuring everything runs smoothly, testing through browsers. This forms a set of AI agents, which may use the same model but are fine-tuned for specific functions. They play different roles independently, interacting with prompts, structures, tools, and observed environments to build a complete process.
This is what Sam mentioned, having many different agents asynchronously performing their tasks, observing the environment and figuring out what needs to be done. So you do need a framework, you need a system to continually improve them. From the user’s perspective, you send a request and interact with different agents, but they work together as a single system. At a lower level, they may actually pay each other for exchanging information, or different agents from different owners interact with each other to actually accomplish something. This is a new version of the API, more intelligent, more natural language-driven. All of this requires a lot of framework structure as well as payment and settlement systems.
There is a new way of interpreting called AI commerce, where all these agents interact with each other to complete tasks. This is the system we are all moving towards. When considering the scalability of this system, several issues need to be addressed. As I mentioned, NEAR is designed to support billions of users, including humans, AI agents, and even cats, as long as they can transact. Each NEAR account or smart contract runs in parallel, allowing for continued scaling and transactions. At a lower level, you may not want to send a transaction every time you call an AI agent or an API, no matter how cheap NEAR is, it is not reasonable. Therefore, we are developing a peer-to-peer protocol that allows agent nodes, clients (including humans or AI) to connect with each other and pay fees for API calls, data retrieval, etc., and have cryptographic economic rules to ensure they respond or else lose part of the stake.
This is a new system that goes beyond NEAR’s scalability, providing micro-payments. We call it yoctoNEAR, equivalent to 10^-24 of NEAR. This way, you can actually exchange messages at the network level with payment capabilities, so all operations and interactions can now be settled through this payment system. This solves a fundamental problem in blockchain, where we do not have a payment system with bandwidth and latency and there are actually many free-riders. This is a very interesting aspect of scalability, not limited to blockchain scalability but applicable to a world that may have billions of agents in the future. In this world, even on your device, multiple agents may run simultaneously in the background, performing various tasks.
Application of AO in the DeFi scenario: Agent Finance
Lulu: This use case is very interesting. I believe there is typically a need for high-frequency payments and complex strategies for AI payments, which have not yet been implemented due to performance limitations. So I am looking forward to seeing how these needs will be met with better scalability options. In our hackathon, Sam and the team mentioned that AO is also exploring using new AI infrastructure to support DeFi use cases. Sam, could you elaborate on how your infrastructure is being applied in the new DeFi scenario?
Sam: We call it Agent Finance. This refers to the two aspects we see in the market. DeFi has done very well in the first phase, decentralizing various economic primitives and bringing them on-chain, allowing users to use them without trusting any intermediaries. But when we think about the market, we think about the digital fluctuations and the intelligence driving these decisions. When you can bring this intelligence itself on-chain, you get a trustless financial tool, like a hedge fund.
A simple example is if we were to build a meme coin trading hedge fund. Our strategy is to buy Trump coins when Trump is mentioned, and Biden coins when Biden is mentioned. In AO, you can use oracle services like 0rbit to get the entire content of web pages, such as the Wall Street Journal or the New York Times, and then input it into your agent, which processes this data and analyzes how many times Trump is mentioned. You can also do sentiment analysis to understand market trends. Then, your agent will buy and sell these assets based on this information.
Interestingly, we can make the agents themselves execute without trust. This way, you have a hedge fund that can execute strategies, you can invest funds in it without trusting a fund manager. This is another aspect of finance that the DeFi world has not really touched on, making wise decisions and then taking action. If this system achieves it, it needs to solve several issues. As I mentioned, NEAR is designed to support billions of users, including humans, AI agents, and even cats, as long as they can transact. Each NEAR account or smart contract runs in parallel, allowing for continued scaling and transactions. At a lower level, you may not want to send a transaction every time you call an AI agent or an API, no matter how cheap NEAR is, it is not reasonable. Therefore, we are developing a peer-to-peer protocol that allows agent nodes, clients (including humans or AI) to connect with each other and pay fees for API calls, data retrieval, etc., and have cryptographic economic rules to ensure they respond or else lose part of the stake.
This is a new system that goes beyond NEAR’s scalability, providing micro-payments. We call it yoctoNEAR, equivalent to 10^-24 of NEAR. This way, you can actually exchange messages at the network level with payment capabilities, so all operations and interactions can now be settled through this payment system. This solves a fundamental problem in blockchain, where we do not have a payment system with bandwidth and latency and there are actually many free-riders. This is a very interesting aspect of scalability, not limited to blockchain scalability but applicable to a world that may have billions of agents in the future. In this world, even on your device, multiple agents may run simultaneously in the background, performing various tasks.To make these decision-making processes more trustworthy, the entire system can be unified to create an economy that appears genuinely decentralized, rather than just a settlement layer involving various economic games.
We see this as a tremendous opportunity, with some individuals in the ecosystem already beginning to construct these components. Our team has developed a trustless investment portfolio manager that will buy and sell assets according to the proportions you desire. For example, if you want 50% in Arweave tokens and 50% in stablecoins, it will automatically execute trades when the prices fluctuate. Behind this is an intriguing concept in AO known as cron messages. This means processes can awaken autonomously and decide to take actions in the environment. You can set your hedge fund smart contract to wake up every five seconds or five minutes, fetch data from the network, process it, and act in the environment. This makes it fully autonomous as it can interact with the environment, making it, in a sense, “alive.”
Executing smart contracts on Ethereum requires external triggers, leading to the construction of a significant amount of infrastructure to address this issue, although not smoothly. In AO, these functionalities are built-in. Consequently, you will see agents continuously competing in markets on-chain. This will drive network usage to increase significantly in unprecedented ways in the crypto space.
NEAR.ai’s overall strategy and development focus
Lulu: NEAR.ai is advancing some promising use cases. Can you tell us more about other aspects or the overall strategy and key focuses?
Illia: Indeed, there are many things happening at every level with various products and projects that can be integrated. This all begins with the NEAR blockchain itself. Many projects require a scalable blockchain, some form of identity verification, payments, and coordination. NEAR’s smart contracts are written in Rust and JavaScript, making them very convenient for many use cases. An interesting development is NEAR’s recent protocol upgrade introducing the yield/resume precompilation. These precompilations allow smart contracts to pause execution, waiting for external events to occur, whether it’s another smart contract or AI inference, and then resume execution. This is particularly useful for smart contracts needing input from LLM (like ChatGPT) or verifiable inferences.
We have also introduced chain abstraction and chain signing features, unique functionalities NEAR introduced over the past six months. Any NEAR account can transact on other chains. This is useful for building agents, AI inference, or other infrastructures since you can now conduct cross-chain transactions via NEAR without worrying about transaction fees, tokens, RPC, and other infrastructure. All of this is handled for you through the chain signing infrastructure. Even regular users can utilize this feature. There is a HOT Wallet built on NEAR on Telegram, recently launching Base integration on the mainnet, with approximately 140,000 users using this Telegram wallet with Base.
Furthermore, we plan to develop a peer-to-peer network that will enable agents, AI inference nodes, and other storage nodes to participate in more provable communication protocols. This is crucial as the current network stack is very limited with no native payment functionalities. Although we often refer to blockchain as “Internet money,” we have yet to solve the problem of sending money along with data packets at the network layer. We are addressing this issue, which is very useful for all AI use cases and broader Web3 applications.
Additionally, we are developing what is known as an AI inference router, essentially a place where all use cases, middleware, decentralized inference, on-chain, and off-chain data providers can be integrated. This router can act as a framework, truly interconnecting all the projects being built in the NEAR ecosystem, and then offering all these to NEAR’s user base. NEAR has over 15 million monthly active users across different models and applications.
Some applications are exploring how to deploy models on user devices, known as edge computing. This approach involves storing data locally and operating using relevant protocols and SDKs. From a privacy perspective, this has significant potential. In the future, many applications will run on user devices, generating or precomputing user experiences using only local models to avoid data leaks. As developers, we have a lot of ongoing research aimed at enabling anyone to easily build and deploy applications on Web3 and undergo formal verification on the backend. This will become a crucial topic in the future as OLLM models become increasingly powerful in discovering vulnerabilities in code repositories.
In conclusion, this is a complete technical stack, from the foundational blockchain infrastructure to Web3 chain abstraction, to peer-to-peer connections, ideal for connecting off-chain and on-chain participants. Next come AI inference router hubs and local data storage applications, particularly useful for scenarios requiring access to private data without leaking it externally. Finally, developers will integrate all research findings with the goal of constructing AI-built applications in the future. In the medium to long term, this will be a crucial development direction.
AO’s priorities and research focuses
Lulu: I’d like to ask Sam about AO’s current priorities and research focuses.
Sam: One idea that particularly interests me is utilizing the extended capabilities provided by AO to establish a deterministic subset of CUDA, an abstract GPU driver. Typically, GPU computations are non-deterministic, making them unsafe for use in calculations like on AO, at least not safely usable, so no one would trust these processes. If we can address this issue, which is theoretically possible, it would only require dealing with device-level uncertainty issues. There have been some interesting research efforts, but it needs to be handled in a way that can guarantee 100% accuracy, crucial for smart contract execution. We already have a plugin system supporting this feature as an internal driver in AO. The framework is in place; we just need to figure out how to precisely implement it. While there are many technical details, the basic idea is to make job loading in the GPU environment predictable enough for such computations.
Another aspect that intrigues me is whether we can leverage the capabilities of this on-chain AI to enable decentralized or at least open and distributed model training, especially fine-tuning models. The basic concept is if you can set a clear evaluation criterion for a task, you can train models against this criterion. Can we create a system where people can invest tokens to incentivize miners to compete in building better models? While this may not attract a highly diverse set of miners, it is not essential since it enables model training in an open manner. When miners upload models, they can add general data license tags, specifying that anyone can use these models, but if used for commercial purposes, specific royalties must be paid. These royalties can be distributed to contributors through tokens. By combining all these elements, we can create an incentive mechanism for training open-source models.
I also believe the previously mentioned RAIL plan is crucial. We have engaged in discussions with some major AI providers or inference providers about the possibility of supporting this plan, and they have shown strong interest. If we can get them to actually implement and write this data onto the network, users will be able to right-click on any image on the internet to query whether the image was generated using Stable Diffusion or DALL·E. These are fascinating areas we are currently exploring.
Illia and Sam’s favorite projects
Lulu: Please nominate one recent AI or crypto project that you each like, it can be any project.
Illia: I’ll take a different approach. We hold AI Office Hours every week, inviting some projects, with recent guests being Masa and Compute Labs. Both projects are fantastic, but I’ll use Compute Labs as an example. Compute Labs essentially transforms actual computing resources (such as GPUs and other hardware) into a real asset for economic participation, enabling users to profit from these devices. The crypto computing market is currently booming, seemingly a natural place for cryptocurrencies to promote markets. However, these markets lack moats and network effects, leading to fierce competition and profit compression. Thus, the computing market is just a supplement to other business models. Compute Labs offers a very crypto-native business model, capital formation, and asset decarbonization. It creates opportunities for people to participate that typically require building data centers. While the computing market is just one part, the primary goal is to provide access to computing resources. This model also aligns with the broader decentralized AI ecosystem, offering opportunities for a wider range of investors to participate in innovation by providing underlying computing resources.
Sam: There are many great projects in the AO ecosystem, and I don’t want to favor any one, but I believe Autonomous Finance is building the foundational infrastructure that makes “agent finance” possible. This is very cool, and they are truly pioneering in this area. I also want to appreciate the broader open-source AI community, especially the approach of Meta in open-sourcing the Lama model, which has spurred many others to open-source their models. If this trend did not exist, and OpenAI turned into ClosedAI after GPT-2, we might have been left in the dark, especially in the crypto space, as we would not have access to these models. People would only be able to rent these closed-source models from one or two major providers. Currently, this situation has not occurred, which is excellent. Ironically, but still giving credit to the king of Web2, Meta.