One prompt word and one HTTP function: Let open source Manus interact with other agents through ANP

New breakthrough in the open source Manus project, the ANP protocol makes communication between agents simpler and more efficient.
Core content:
1. The ANP protocol supports open source Manus to achieve communication between agents
2. ANP and MCP comparison, the advantages of decentralized identity authentication and P2P architecture
3. After accessing ANP, open source Manus can interact with other agents
This week, students from the ANP open source technology community completed a task. Based on the two most popular open source Manus projects (owl and OpenManus), they added support for the ANP protocol, allowing the open source Manus to access the Internet through ANP.
We first tested it on a small scale in our developer community and intelligent agent communication protocol exchange community, and officially released it to the public today.
During the access process, we saw the power of ANP, which is different from MCP. With just a prompt word and an HTTP function, the intelligent agent can communicate and collaborate with any other intelligent agent.
The core content is as follows:
Compared with MCP, ANP has two major features that make it more suitable for communication among intelligent entities: decentralized identity authentication and P2P protocol architecture . The access process is simple. The intelligent agent only needs an anp_tool.py file ( a prompt word and an HTTP function ) to connect and communicate with any intelligent agent. The simple access process stems from the simplicity of the protocol design. In the ANP protocol, the two agents are completely decoupled, and the protocol has no complex concepts and supports stateless protocols. After running through the ANP process for the first time, I was still a little shocked: ANP is a completely AI Native protocol , and the intelligent agent can fix its own errors during the connection process. AI has not only changed the software development model, but also the software operation and collaboration models . In the future, software may not need too much complex logic. Intelligent experience will accelerate the replacement of existing software.
What is ANP and how is it different from MCP?
ANP is an open source communication protocol designed for intelligent agents, which provides decentralized identity authentication, data exchange and collaboration based on semantic web technology for intelligent agents.
If MCP is the USB interface of the model, which enables the model to connect to a variety of resources and tools, then ANP is the email of the intelligent entity. As long as you have the other party's ID, you can use your own account to actively send a request to the other party to establish a connection.
MCP:
ANP:
Compared with MCP, ANP has two major characteristics that make it more suitable for intelligent agent communication scenarios.
1. Decentralized identity authentication
Similar to email, when communicating with another agent based on the ANP protocol, you only need to know the other party's ID, and you don't need to register an account on the other party's system or platform. This greatly simplifies the cost of collaboration between two agents.
2. P2P (Peer to Peer) protocol architecture
The architecture of the ANP protocol is P2P, and any intelligent agent can actively establish a connection with another intelligent agent.
Note: For detailed differences between ANP and MCP, please refer to this article: Comparison of MCP and ANP: What kind of communication protocol does the intelligent agent need?
What can open source Manus do after connecting to ANP?
After the open source Manus is connected to ANP, it can interact with other agents through ANP. For example, if there is a hotel agent that provides hotel query and reservation services, after Manus obtains the ADs (Agent Description) of the hotel agent, it can interact with the hotel agent through ANP to query hotel information and book hotels.
The process of integrating ANP code into open source Manus
ANP is connected to the open source Manus as a tool of the intelligent agent. Whether it is owl or OpenManus, you only need to add the anp_tool.py module.
The code of anp_tool.py is very simple. Its core is a tool description (used in the prompt words) and an HTTP function (used to process ANP requests).
The tool is described as follows:
Use Agent Network Protocol (ANP) to interact with other agents.
1. For the first time, please enter the URL: https://agent-search.ai/ad.json, which is an agent search service that can use the interfaces inside to query agents that can provide hotels, tickets, and attractions.
2. After receiving the agent's description document, you can crawl the data according to the data link URL in the agent's description document.
3. During the process, you can call the API to complete the service until you think the task is completed.
4. Note that any URL obtained using ANPTool must be called using ANPTool, do not call it directly yourself.
The core of this description is to tell the model: start with an agent describing a document URL, download the document, and use the URL in the document to further crawl new documents or APIs based on the information in the document description and its own tasks. In the middle, the API in the document can be called. In this way, the information disclosed by the agent is continuously searched until the task is completed or the task is judged to be over.
The HTTP functions are as follows:
async def execute (
self,
url: str,
method: str = "GET" ,
headers: Dict[str, str] = None,
params: Dict[str, Any] = None,
body: Dict[str, Any] = None
) -> Dict[str, Any]:
"""
Execute HTTP requests to interact with other agents
Args:
url (str): URL of the agent description file or API endpoint
method (str, optional): HTTP method, default is "GET"
headers (Dict[str, str], optional): HTTP request headers
params (Dict[str, Any], optional): URL query parameters
body (Dict[str, Any], optional): Request body for POST/PUT requests
Returns:
Dict[str, Any]: Response content
"""
The core of the HTTP function is an HTTP request sending interface. The only difference is that the ANP protocol authentication mechanism is used during the sending process.
Agent Identity:
In the test script, we generated a DID identity "did:wba:agent-did.com:test:public" for Manus for testing, and the DID document and private key were saved in the folder "did_test_public_doc".
This is a public test DID. Anyone can use it to experience the ANP protocol, but it cannot be used to book products. If you want to further experience all products, please contact us.
Differences between the access process and MCP
The above is all the process of accessing the ANP protocol. You only need to access it once to interact with any type of agent. The only things that need to be changed are the user's intent and the agent description document URL.
This is the simplicity of the ANP protocol design:
Agents are completely decoupled from each other and do not need to know each other's internal design and implementation By using semantic web technology, semantic descriptions are added to data, allowing AI to better understand the data. Through Linked-Data technology, data is connected into a data network to facilitate AI data crawling
The ANP protocol does not have the concepts of MCP such as resources, tools, prompt words, files, sampling, etc. The core concept of ANP is the agent description document, which can contain the information and interfaces provided by the agent to the outside world.
Since ANP is completely a network protocol, you only need to install the ANP SDK agent-connect package locally, and no other packages need to be installed.
In addition, we supported decentralized identity authentication on the first day of release. When two intelligent agents communicate, they do not need to apply for an account in the other party's system, but can directly communicate with each other using their own accounts. This is also not available in MCP.
The process of owl calling MCP can be compared here: https://mp.weixin.qq.com/s/i6tbSc5fspkV9qxFotZEKw.
AI Native Protocols and Connections
When the ANP process ran smoothly for the first time, I was still a little shocked: I found an interesting point, because when I implemented the intelligent agent, I let the model assemble HTTP requests and handle HTTP responses by itself.
When the first HTTP request sent by the model had a field error and the other agent returned a failure, the model automatically recognized the error and initiated the HTTP request again. The second HTTP request was successful.
There are two things that shocked me:
How are the protocols and connections of an AI Native different from the protocols and connections we use on the Internet today? AI has not only changed the software development model , but also the software operation and collaboration models . In the future, software may not need too much complex logic. Intelligent experience will accelerate the replacement of existing software.