Showing posts with label AgenticAI. Show all posts
Showing posts with label AgenticAI. Show all posts

What are the differences and relationship between MCP and A2A protocol?

 

What are the differences and relationship between MCP and A2A protocol?

After MCP (Model Context Protocol) from Anthropic getting popularity, recently Google has introduced another protocol - A2A (Agent to Agent Protocol). A natural question arises is how are they related to each other? Are they complementing or competing with each other?

In this post, let’s try to demystify the two protocols.

Current AI Agentic System (or Multi-agent System) development has two challenges:

  • Integrating agent with tools and data
  • Agent to agent communications

In a nutshell, MCP (Model Context Protocol) tackles the first challenge, and A2A (Agent to Agent Protocol) aims to tackle the second one.

MCP

MCP (Model Context Protocol) from Anthropic is an open protocol that standardizes how applications provide context to LLMs, like USB-C port for AI applications.

Just as USB-C provides a standardized way to connect your devices to various peripherals and accessories, MCP provides a standardized way to connect AI models to different data sources and tools. - MCP documentation

According to HuggingFace, an agent has an LLM as its brain and capabilities and tools as its body.

  • Tools available to an agent allow it to access new knowledge beyond the knowledge cut-off date, such as retrieving social media data or the current weather.
  • Capabilities represent everything the agent is equipped to do. One popular capability example is using a memory component to remember things, such as previous conversations and external data.

Look into the example provided by Anthropic, an agent (MCP host) can access additional context from local data sources or remote services via MCP protocol.



  • MCP Hosts: Programs like Claude Desktop, IDEs, or AI tools that want to access data through MCP
  • MCP Clients: Protocol clients that maintain 1:1 connections with servers
  • MCP Servers: Lightweight programs that each expose specific capabilities through the standardized Model Context Protocol
  • Local Data Sources: Your computer’s files, databases, and services that MCP servers can securely access
  • Remote Services: External systems available over the internet (e.g., through APIs) that MCP servers can connect to

The MCP Server is a foundational component which provides tools, resources, and capabilities to clients via APIs and endpoints. More specifically:

  • Exposing tools that clients can discover and execute
  • Managing resources with URI-based access patterns
  • Providing prompt templates and handling prompt requests
  • Supporting capability negotiation with clients
  • Implementing server-side protocol operations
  • Managing concurrent client connections
  • Providing structured logging and notifications

A2A

A2A (Agent to Agent Protocol) from Google is an open protocol that provides a standard way for agents to collaborate with each other, regardless of the underlying framework or vendor.

A2A facilitates communication between a "client" agent and a “remote” agent.

A client agent is responsible for formulating and communicating tasks, while the remote agent is responsible for acting on those tasks in an attempt to provide the correct information or take the correct action.

This interaction involves several key capabilities:

  • Capability discovery: Agents can advertise their capabilities using an “Agent Card” in JSON format, allowing the client agent to identify the best agent that can perform a task and leverage A2A to communicate with the remote agent.
  • Task management: The communication between a client and remote agent is oriented towards task completion, in which agents work to fulfill end-user requests. This “task” object is defined by the protocol and has a lifecycle. It can be completed immediately or, for long-running tasks, each of the agents can communicate to stay in sync with each other on the latest status of completing a task. The output of a task is known as an “artifact.”
  • Collaboration: Agents can send each other messages to communicate context, replies, artifacts, or user instructions.
  • User experience negotiation: Each message includes “parts,” which is a fully formed piece of content, like a generated image. Each part has a specified content type, allowing client and remote agents to negotiate the correct format needed and explicitly include negotiations of the user’s UI capabilities–e.g., iframes, video, web forms, and more.

Google highlighted A2A is a complementary to MCP rather than an alternative.

Model Context Protocol (MCP) is the emerging standard for connecting LLMs with data, resources, and tools. We already observe MCP standardizing ‘function calling’ across different models and frameworks. This is creating an ecosystem of tool service providers and dramatically lowering the complexity to connect agents with tools and data. We expect this trend to continue as more frameworks, service providers, and platforms adopt MCP.
A2A is focused on a different problem. A2A is an application level protocol that enables agents to collaborate in their natural modalities. It allows agents to communicate as agents (or as users) instead of as tools. We hope that A2A gains adoption as a complement to MCP that enables ecosystems of agents and will be working in the open with the community to make this happen.

Simply put, MCP for tools and A2A for agents.

Google even recommends that applications model A2A agents as MCP resources (represented by their AgentCard). The frameworks can then use A2A to communicate with their user, the remote agents, and other agents as illustrated below.


Discussion

With a peaceful coexisting scenario of the two standards, each agent (MCP host) can have their own connected MCP servers for accessing tools and resources via the MCP protocol. Additionally, these agents communicate with each other through the A2A protocol, as discussed in SwirlAI’s post. This applies when we treat agents as agents as independent entities rather than tools. However, this might change when agents are treated as special tools that can also be exposed via MCP servers.

It will be interesting to see how developers decided choose to adopt these standards - wheter one or both - as their decisions will eventually shape the future of these protocols. Also, MCP and A2A are both new and will keep evolving, with the possibility to extend functionalities to be better positioned in Agentic AI ecosystem.

References

What are current examples of AI agents?

 There are predictions that 2025 will be . With the first quarter of the year already behind us, we might be curious about recent announcements from major companies regarding AI agents.

Below, we provide an overview of current AI agents introduced by major companies, along with  videos to give a quick sense of what they do, followed by final remarks.

Adobe Orchestrator

Adobe has introduced a set of specialized agents with different responsibilities such as site optimization agent, content production agent, and workflow optimization agent etc., in their business-oriented platform ().

Agentforce (Salesforce)

Salesforce is a cloud-based customer relationship management (CRM) platform that helps businesses manage customer interactions, sales, marketing, and support services. Their AI agent product — Agentforce — allows to create virtual agents that are capable of doing jobs fit into configured (via easy-to-use user interface for prompt engineering and a set of predefined actions) topics and guardrails.

Claude (Anthropic)

General AI agent, while differing from Chatbot, it can navigate screens, move the cursor, click buttons, type text, and perform other actions to complete tasks on a computer.

Copilot as User Interface for Agents (Microsoft)

Copilot is an AI-powered assistant integrated into Microsoft products to help users with tasks, improve productivity, and enhance creativity. Microsoft is using the Copilot as the user interface (UI) for agents.  (as shown in the second video below). The custom agents are similar to those we can see from Agentforce.

Gemini Robotics (Google)

Google’s Gemini Robotics brings AI agent to the physical world, which can follow general (various) instructions, understand the 3D world, and react to changing environment, think and act, and interact with other agents for completing the given task.

Manus

 is a general AI agent that bridges minds and actions. Manus has gained a lot of attention after , and it claims that it excels at various tasks in work and life, getting everything done while you rest.

Nova Act (Amazon)

Amazon’s Nova Act is a Web AI agent to execute tasks within a web browser. At the time of writing, it is available as a research preview through the .

Operator (OpenAI)

Operator is also a web-based AI agent that can perform tasks within a browser, such as grocery shopping, booking tickets, and making restaurant reservations.

Final Remarks

As we can see, AI agents are primarily developed to automate workflows and improve our productivity, with a main focus on using Web browsers, computers, and hardware such as robots.

Subscription-based B2C (Business to Customer) companies like OpenAI and Antrhopic aim to provide AI agents to tend users for automating general daily workflows. B2B (Business to Business) companies like Microsoft, on the other hand, focus on offering AI agents integrated into their ecosystems to automate business workflows for their custormers.

As the year of AI agents progresses, we can expect more and more agents to be announced by various companies. MIT maintains an  that highlights state-of-the-art agents, with a focus on those already deployed in industry, to keep track of up-to-date AI agents.

One key remaining question is whether the investment in these agents is worthwhile for end users and businesses. On Reddit, there are some communities discussing their experiences regarding these agents like O, and .

What has your experience been using these agents so far, if you have been using any of them in daily life or at the workplace?

OctoTools: An Agentic Framework with Extensible Tools for Complex Reasoning

 

Figure 1. The framework of OctoTools. (1) Tool cards define tool-usage metadata and encapsulate tools, enabling training-free integration of new tools without additional training or framework refinement. (2) The planner governs both high-level and low-level planning to address the global objective and refine actions step by step. (3) The executor instantiates tool calls by generating executable commands and save structured results in the context. The final answer is summarized from the full trajectory in the context. Furthermore, the task-specific toolset optimization algorithm learns to select a beneficial subset of tools for downstream tasks.

Project page: 

Stanford University introduced a new agentic framework called , a training-free, user-friendly, and easily extensible  agentic framework designed to tackle complex reasoning across diverse domains.

The new framework contains three main building blocks as we can see from the above figure.

  1. Tool cards
  2. Planner
  3. Executor

Key insights

The authors comapared other alternatives including alternative agentic frameworks such as , , and , using 16 diverse benchmarks spanning two modalities, five domains, and four reasoning types.

  • OctoTools is able to take the advantage of available tools better than other alternatives to address task-specific challenges, as illustrated in the tool usage distribution figure below.
  • AI agent frameworks can improve task performance in different ways depending on the specific skills demanded by each task, e.g., those benefit more from step decomposition (above the blue dotted line), specialized tools (below the line), or both (along the line). OctoTools is a versatile framework for achieving such improvements
    across a diverse set of tasks.

In the following, we delve into the details of OctoTools and its key components.

1. Tool cards

Tool cards encapsulate tools in a modular manner, with associated metdata such as inputs, outputs, demos, etc. as illustrated below.

Figure 2. Tool card example

2. Planner

The planner takes the task prompt and a (sub)set of tools as input, to derive the corresponding answer. It contains four components:

  1. Query analyzer provides a high-level task plan for the given task
  2. Action predictor outputs an action regarding a sub-goal of the plan
  3. Context verifier checks if the task is completed. If yes, it goes to solution summarizer; otherwise, it goes back to the action predictor
  4. Solution summarizer summarizes the final answer once the task is verifed as completed from the trajectory of solving the task.
Figure 3. Example demonstration for Planner

3. Executor

As we can see from Figure 1, the action predicted by the action predictor is sent to the executor, which instantiates tool calls by generating executable commands and save structured results in the context. The context is fed back to the context verifier.

The executor has two components. A command generator (powered by a language model) to create a command in the form of an executable Python script; a command executor executes that command.

As we can notice here, the authors use a separate language model as a command generator with the rationale introduced as below:

Prior work often expects a single language model both for planning each step (i.e., which tool to use) and for generating the corresponding executable command. This dual responsibility can overload the model and lead to errors, especially when dealing with complex or environment-specific code.

Task-specific toolset optimization

The last component that we didn’t discuss above is the task-specific toolset optimization. For planner, instead of considering the full toolset, a subset may be selected based on 1) expert insights or 2) optimized using a small set of examples. The task-specific toolset optimization — a heuristic — comes in for the second case when a small set of validation examples are available.

In a nutshell, it starts with a pre-defined base toolset, and iteratively adds

new ones by observing the performance on the validation examples. More details can be found in the paper if you are interested in this aspect specifically.

The figure below shows the benefits brought by the optimized toolset with the task-specific toolset optimization. Using the optimized toolset increases the performance over using either base or full toolset. Obviously, the downside of using the optimized toolset would be the preparation of the validation set to apply the optimization.

Hope you enjoyed OctoTools!

See you next time!