The Internet of Agents

BeginnerMar 20, 2024
This article delves into the intersection of cryptocurrency and artificial intelligence, also known as "Crypto x AI" or "Crypto + AI". The author suggests that integrating artificial intelligence agents into blockchain infrastructure could lead to the emergence of an internet of agents. The piece further discusses strategies to attain this, emphasizing on immediate use cases and applications. The author offers a functional definition for artificial intelligence agents, highlighting that these agents can vary in type. The cost of security for artificial intelligence and blockchain intersection is also explored, with the aim to reduce it. The article suggests new application areas such as content curation and artificial intelligence prediction markets. Ultimately, the emergence of an artificial intelligence agent economy could revolutionize the way artificial intelligence interacts, providing a more potent infrastructure across various sectors.
The Internet of Agents

In recent months the theme of Crypto x AI (intersection of crypto and AI) or Crypto + AI (crypto infrastructure augmented with AI) has been top of mind. Many people in the blockchain community are excited about it, some are skeptical or not-yet-convinced, and some are building. Live projects at the intersection of blockchain and AI have had a revamp and many new projects are popping up.

For the past year I have been doing research in this area, in particular on AI agents running on blockchain infrastructure. We have a research group together with some colleagues at the Ethereum Foundation, Flashbots, and DeepMind among others. We are continuing to push the applied research boundaries to understand and test what type of AI agents applications are the best fit for blockchains and what new infrastructure we need to support them.

In this post, I will make the case that the integration of blockchain infrastructure and AI agents is desirable and that it will give rise to an Internet of Agents:

An upgrade to the current paradigm of interconnectivity, augmented with incentives and modern cryptography, that will allow us to reap the benefits of an economy driven by AI agents with unprecedented levels of security, efficiency, and collaborative potential.

I will then discuss the path to get there. I will focus on short-term use cases and applications, some of which are already being designed and developed. I will discuss their limits and potential improvements, as well as the research needed across AI and blockchain to unlock new use cases in the medium-term.

Blockchains as the Backend for the Internet of Agents

Let me start by saying that the style of this argument will be speculative yet practical. Blockchain and AI are the two technologies that have been progressing at the most rapid pace in the past ten years. Both have far reaching effects on the fabric of the internet and human society more broadly. Thus, to paint a meaningful vision of how these technologies will evolve and interact requires some speculation. However, even though scaling laws clearly point in a direction of rapid improvement, I will stay away for long-term speculation about AGI. (Despite the recent hype, I believe that autonomous self-improving AGIs are relatively far in the future and it is not yet clear what form they will take.)

I will focus on the short-to-medium term future in which AI takes the form of human assistants and agents. In this form, AIs are tools that service humans by facilitating the execution of human activities or by carrying out new activities in service of humans.

Figure 1. Left: a concept timeline of AI evolution with increasing performance. Right: block diagram of activities for humans and different forms of AI.

Assistants have been around for several decades in various forms, while recent advances in LLMs suggest that the new generation of AI agents will be much more capable and rapidly improving than before. Here is a working definition of what I mean by AI agent:

A computer program that interacts with the world. It perceives its environment via sensors (input data), processes the data autonomously (prediction and planning) and takes actions in order to achieve goals (acting).

Agents can be subject to constraints and can also learn from the environment. Today, agents are usually specialized to a particular type of input and a particular type of action. For example, chatbots such as ChatGPT take as input a text prompt, may use some tools to produce answers, and respond with a text output. A trading bot on the other hand, takes as input past market states, predicts future market states and optimal actions, and executes a trade. Agents can be of different types (e.g., chatbot is an LLM while traderbot is a small RL agent) and they may also compose to execute a task. In the future, we may discover a general architecture that can be trained to handle most of the use-cases.

Blockchains Possess Unique and Desirable Features

Public blockchains have a unique set of features that makes them very good infrastructure for the communication and interaction of AI agents. Later we argue that they make up for the best infrastructure for supporting agentic AI, but first, here are the features at a high level.

Decentralization: well-designed blockchain protocols are decentralized. Moreover, decentralization is part of the ethos of the communities that initially built them and upgraded them. It is built into the protocols and safe-guarded with governance.

Incentives: well-designed blockchains have sound incentive mechanisms that drive economic security via the native asset (for example, ETH in the case of Ethereum). Moreover, programmable smart contracts enable applications that can (1) leverage/use the native asset, (2) issue new digital assets with desired properties, and (3) define their own native asset and incentive mechanisms for their participants.

Openness and Composability: blockchains platforms are open access for users as well as application developers. Moreover, applications that are based on smart contracts deployed on blockchains inherit the same properties of openness and frictionless composability.

Cryptographic guarantees: blockchains leverage modern cryptography to deliver unique levels of security, auditability, and programmable privacy. As a result, they are trust-minimized much safer than legacy systems. Note that blockchain hacks come from smart contract bugs, which are inevitable in the early stages of the technology. As the stack matures it becomes more robust and secure, while traditional systems that rely on human trust do not have this property.

We can contrast these with the legacy internet, which only has decentralization. Base layer protocols such as TCP/IP or SMTP are open, but virtually all applications that have been built on top are proprietary. This gives the internet poor composability, a property that we argue is key when designing protocols for agents interaction. Moreover, the internet completely lacks incentives and modern cryptography at the protocol level.

Next, we present the ideal model for an economy where humans and agents cooperate and show that it requires the entire suite of features that blockchain protocols offer.

Figure 2. Conceptual drawing of the legacy internet (left) and of the internet of agents (right) according to ChatGPT.

Benefits of Blockchains for AI Agents

Fast-forward a few years. Imagine we are at the point where AI agents can execute a large array of human activities and that they have sufficient decision-making and planning capabilities. They can also execute tasks autonomously, possibly collaborating with other agents. Agents are widely deployed in society and undertake activities that have potentially high value to humans, both societal and financial.

Here are a few properties/desiderata that we would like this agentic AI systems and their interaction with humans to have, and how blockchains enable them.

Agent system desiderata

  • Alignment: some aspects of agent alignment, such as value learning, interpretability, and steerability depend on the AI design and training processes which would not utilize blockchain directly for the most part. However, the openness and composability of blockchain applications can offer unique opportunities in making agent activity legible, automatically monitored, and attributable, which are key for incentive distribution and the alignment of agentic systems.
  • Safety: blockchains are designed to be reliable and secure with minimal trust assumptions, in adversarial environments, where a lot of value is at stake. Agents interacting via smart contract applications inherit these strong properties. Moreover, advances in modern cryptography such as zero-knowledge proofs super power smart contract applications. For example, applications can require proofs of sensitive computations while the agent weights and inputs can remain private. Credible smart contracts are also the ideal tool to constrain the action-space of agents and set default and conditional permissions.
  • Discovery: the openness of the environment across applications allows for much richer routing of requests conditional on the application state and also on the past performance of agents, which can be fully observed. It is straightforward to envision agents credibly accumulating reputation based on their action history, which can then be used programmatically for ranking and discovery of the best agents for a given task.
  • Efficiency: blockchain infrastructure enhances the autonomy of agents by allowing them to execute consequential decisions, including payments, without direct human intervention and at low cost.

Human desiderata

  • Control and Programmable Privacy: blockchains enable humans to own and maintain control of their agents directly, without intermediaries. Individual data can be private and access can be conditionally gated using cryptography gadgets, from completely private computation (TEE/FHE) to programmable sharing of selected properties via zk-proofs.
  • Ownership and Fairness: people can set-up protocols to collectively own and govern agents. Rewards from agents work can be programmately distributed literally to the tiniest fraction of a cent. Fairness can be measured and improved via both protocol upgrades and democratic governance. The blockchain infrastructure paired with modern identity solutions being developed can also support and automate ambitious distribution programs, such as Universal Basic Income (or UBI) which is an important longer-term application.

Short aside on the AI Supply Chain

It is important to note that, beyond communication and interoperability, blockchain infrastructure can benefit the entire supply chain of model production (data gathering, data curation, training, fine-tuning). There are a number of applications being developed, including several data collection protocols and compute marketplaces. They are an important part of the decentralized AI stack but we will not discuss them here.

Figure 3. AI supply chain (white) and Internet of Agents (green).

Global Regulation and Governance

Blockchains offer versatile protocols where a wide range of rules and checks can be credibly enforced. This is, in my opinion, a unique opportunity for global regulation of AI markets and applications, which can be easily audited and checked for compliance. Transparency across protocols can also make it very easy to identify deviations in real-time and deploy corrective fixes, which is not possible in legacy systems.

Risks and Costs of Blockchain Infrastructure

Openness is not always desirable when training AI agents that make sensitive and impactful decisions. For example, deploying an open weight model that makes insurance underwriting decisions could expose model vulnerabilities and increase the likelihood of exploits/attacks.

One way around it could be to leverage modern cryptography to keep the agents private but their actions public. However, black box adversarial machine learning attacks are still possible, and in general cryptographic schemes for secure but verifiable machine learning computations are costly to implement which adds overhead to the already costly training process. This is one of most important areas of research at the intersection of AI safety and blockchains. We need to make it technically and economically viable in practice. One recent innovation is optimistic proofs for ML computations that I discuss below.

Another risk that has been discussed is that LLM-based oracles decrease the bar to deploy that can correctly assign incentives to physical, potentially harmful, actions in the real world. This is still not possible today, but more research should be focused on how to enable positive use cases and how to detect and prevent harmful behavior.

Blockchain-based Systems Can Grow to Meet the Demand

One question that is often on the mind of people that are not familiar with the current state of blockchain systems is whether they are ready to accommodate the load that would come with an increase in user activity.

This has been the focus of blockchain R&D for at least the past five years and today we are at at turning point where many solutions are coming online and increasing scalability by orders of magnitude. For example, Ethereum with its Layer 2 blockchains, that inherit full economic security, and scalable data availability solutions will soon be able to process tens of thousand transactions per second (TPS). New chains are coming online that leverage parallelization to process hundred thousands transaction per second. Shared sequencing solutions and secure bridges are going to allow applications deployed in different domains to interoperate securely and efficiently. Advances in zero-knowledge proof aggregation will make transactions even cheaper, as well as enable new type of off-chain compute and hybrid systems that are able to make security trade-offs even more efficient.

With all this infrastructure innovations coming to fruition in the next few years, there is no doubt that a mature blockchain ecosystem will be able to support very high throughput, from tens of thousands TPS today to millions of TPS at a small fraction of a cent per transaction.

The Road to the Internet of Agents

The figure above is a treasure map representing the three main steps on the path towards the Internet of Agents.

Let us go over them one by one.

Augmenting Current Decentralized Applications

The first step is to augment current blockchain applications with AI. AI is already at play in decentralized finance (DeFi), which is the app category that has most adoption to date. This takes the form of specialized models that constantly monitor the state of the market to take a specific action. For example: trading bots, liquidation bots, routing bots, statistical arbitrage bots and more in general bots executing strategies that aim at extracting profit (also known as MEV) from the flow of user transactions.

With the blockchain economy growing on top of the current DeFi foundations, it is natural to start from here and discuss opportunities for leveraging AI.

DeFi Augmentation

Blockchain protocols are currently automated but the interface with them is very manual, sometimes clunky, and often inefficient. AI has the potential to become the new interface that connects humans to onchain markets, with the mediation of smart agents. There are concrete opportunities to augment current protocols in at least three areas.

  • User intent matching: users interact with an AI agent to communicate, sometimes construct/refine, their intent and the AI matches it to a sequence of onchain actions that the user delegates to it. The intent takes the form of a goal and a number of guardrails and the action can be a single transaction or a structured plan executed over longer time-scale. One simple intent example is

    • “I want X units of token Y at price not higher than $Z”, or
    • “I want to invest $Z per month over the next six months in Ethereum Layer 2 projects”, or
    • “I want to restake my $ETH with EigenLayer and delegate it to AVSs, with an APR of at least X% and a risk factor of at most Y%”.
  • While the first one requires only a couple of transactions, the other examples require the formulation of a plan, execution of the plan with multiple transactions over the planning horizon, multiple price feeds, predictive models of risk and returns, and also contextual information. \

  • Action planning and routing: the infrastructure for sending transactions on the Ethereum blockchain is getting more mature and complex. There are now different routes optimizing for different desiderata: security, speed, price-efficiency, privacy. There is even a protocol aimed at making it easier to deploy new routes. Similar to what DEX aggregators do today with individual swaps, more advanced routing algorithms can be devised that also take into account the broader transaction supply chain context and for a variety of applications. Especially when planning a longer term strategy on behalf of a user, or of a Layer 2 application that buys services from the Layer 1 protocol, the action space is quite large and it is expanding as new mechanisms are deployed. For example, the optimal plan for a user portfolio optimization may be to partially redeploy their funds on a cheaper Layer 2 and execute their investment there. \

  • Shared funds and asset pools: the creation and management of funds where many people pool resources, agree on goals, and then delegate execution to AI agents. This requires aspects of both intent matching and action planning, and also mechanisms for shared ownership that the blockchain can uniquely offer. For example, a modern version of a digital art collector agent will need all these capabilities and also leverage the much richer context that is available to latest generation of LLMs, both for synthetizing community preferences and identify assets that match them. \

In all these cases, we have a principal human or community that outsources high valued onchain actions to some agents that run offchain. There is therefore a big need of inference guarantees. This can be achieved in two ways:

AI Services to Protocols

A related category is augmenting protocol infrastructure, as opposed to retail applications, with autonomous agents. Here most applications are similar to agent-based products that are being built for traditional business services, but these agents can leverage the openness, liveness, and data abundance of blockchains.

Examples are agents as security auditors/testers for smart contracts, analytics agents, and automated treasury and risk management services. Various flavors of this type of services have been offered by Web3-focused companies, but advances in agent autonomy and proof-of-inference now offer the opportunity to decentralize and remove trust from key services to protocol operations.

A new area of application is that of content curation. With decentralized social media like Farcaster and Lens on the rise, new opportunities for agent automated/intermediated curation arise. However, these require creating new mechanisms to orchestrate agent collaboration that we now describe.

Creating New Mechanisms for Agents Services

We can use the blockchain super power of creating credible commitment devices to implement new applications and new market mechanisms that leverage directly agent users. This is where we will start observing the power of coordinating many agents, to provide new services. We have discussed at length the topic in our recent paper, here I want to focus on a few concrete applications.

AI Prediction Markets

The most exciting and concrete application in the near-term is AI prediction markets. DeFi has unlocked the ability to trade long-tail assets on the blockchain, such as small protocols utility tokens, which are not tradeable in traditional markets because it is too costly to operate the infrastructure to support them. AI prediction markets have the potential to do the same thing with hyper-long-tail assets. The outcome of the smallest events that people care about could be tokenized and traded. For these markets to work they need:

  • Efficient price discovery: including meaningful liquidity and substantial trading volume for information aggregation.
  • Credible market resolution: the markets need to be resolved credibly and efficiently.

AIs can automate these operations by having specialized trader agents query LLMs to get probability estimates on events and then placing bets, as it was shown in a recent large-scale competition. It has also been suggested that multi-round dispute protocols could be used to automate market resolution with LLMs in early rounds, and only involve humans for cases that escalate to later rounds.

Once these markets work, they become a new primitive for assessing small uncertainties in a fully autonomous way, without the need to rely on a central authority which could be exposed to security threats or biases. Various kinds of applications can be built on top: micro-insurance, financial products, content moderation on decentralized social media, spam filtering, etc.

Credible and Efficient Routing to Specialized Models

Today most of the human-AI interaction is siloed in proprietary environments with generic models, either closed “frontier” models (heavy models) or open-weights models (light models). However, the early success of the GPT Store, and of similar aggregators, points to a world where the above mode of interaction is only the gateway into a vast offering of GPTs with agentic abilities and specialized skills (ie, we will soon go from explaining the rules of poker to playing poker, from planning trip itineraries to booking full trips).

In that world, there is a clear need for efficient routing of user sessions to the best specialized model that can satisfy their intent in the best way. When agents transact on user behalf there will be significant value to be extracted from serving users. There are incentives to extract value from both the router/mediator side (extracting rents) and from the end-model side (mis-reporting outcomes/performance to get more flow). So there is a clear need for credible routing mechanisms and marketplaces, where service providers will compete to satisfy user preferences. This is an upcoming area of applications that I am very excited about.

Building Blocks for New Marketplaces

As more agents with specialized skills get deployed and accumulate history onchain, the building blocks for a more powerful infrastructure can be developed. For example, agent discovery protocols that include reputation based on past outcomes and ranking of agents, auto-bidding for microservices based on predicted outcomes, and many more.

This is an iterative process that will take years to fully realize, with new iterations of this infrastructure of communication, reputation, and exchange evolving with each new wave of agent service protocols being created. The end goal will be the most efficient system of digital coordination mechanisms, extremely cheap and free of rent, which will form the backbone of an increasing share of the world economy. Eventually, as agent capabilities keep increasing and more real-world activities get automated, we can expect that the majority of societal economic exchange will be settled on this infrastructure.

Scaling Shared Ownership and Governance

Solving problems of shared ownership, equitable value distribution, and governance of productive systems of intelligent agents will be paramount once these will be at scale. Blockchains offer the substrate to enable this solutions. Today we are at an early stage of experimentation but there are some interesting models emerging. At the two extremes we have:

  • Direct ownership and governance minimization: this is a model in which protocol governance is minimized, similar to Bitcoin. The protocol is minimal and relatively set in stone. The agent assets/resources ownership mechanisms are simple, agent assets are owned directly by their creators, and accrue value proportional to their usage. There is a native network token that serves simply as utility, paying for services, and as a valuable capital asset to reward contribution.
  • Shared ownership and DAO governance: at the other extreme there is richer protocols that resemble more the applications that we see on top of Ethereum today. There is a rich protocol specification with parameters that can be changed via explicit governance processes. The native token can be used in governance and has richer incentive mechanisms that enable shared ownership of different components of the system.

The first is similar to what is being experimented with by Morpheus and the second to Olas, two early attempts building an autonomous agents economies. We are still at an early stage of these new types of agent-based protocols, there will be new applications and new capabilities that will likely change the way in which incentives an ownership models are designed. These are only two very different example that show there is a wide spectrum of solutions at the disposal of protocol designers. Finally, note that beyond agent economies, similar problems are present at other levels of the AI stack, and similar solutions can be used to incentivize AI training, data, and infrastructure services.

Statement:

  1. This article is reprinted from [Notion], the original title “The Internet of Agents”, the copyright belongs to the original author [Davide Crapis], if you have any objection to the reproduction, please contact Gate Learn team and the team will deal with it as quickly as possible in accordance with the relevant procedures.

  2. Disclaimer: The views and opinions expressed in this article are solely those of the author and do not constitute any investment advice.

  3. Articles in other languages are translated by the Gate Learn team and may not be reproduced, distributed or plagiarised as translated without reference to Gate.io.

Start Now
Sign up and get a
$100
Voucher!
Create Account