diff --git a/modules/ROOT/pages/af-agent-networks.adoc b/modules/ROOT/pages/af-agent-networks.adoc index 1a2c12506..9cfed9ce8 100644 --- a/modules/ROOT/pages/af-agent-networks.adoc +++ b/modules/ROOT/pages/af-agent-networks.adoc @@ -60,6 +60,39 @@ These servers will be published to Exchange. The asset might also be published to Exchange. . An asset that has been added to this agent network project from Exchange. +== A2A Protocol + +The Agent2Agent (A2A) Protocol governs agent-to-agent communication. This protocol powers orchestration, observability, and governance features in agent networks. MuleSoft supports v0.3.0 of the A2A Protocol Specification. + +=== Context and Task ID Scoping in Agent Networks + +In MuleSoft agent networks, the brokers receiving a request always generate a `contextId` and `taskId`. These IDs define the state and scope of a specific conversation between two agents. A `taskId` is always matched to a `contextId`, but a `contextId` can exist without a `taskId`. + +In a multi-agent network, a client sends a request to Broker_1 and Broker_1 generates the necessary IDs for that request. When Broker_1 sends a new request to the next broker or non-broker agent in line, that broker or non-broker agent establishes a unique `contextID` and `taskID` for the new request. + +NOTE: It is not mandatory for non-broker agents to generate a `contextId` and `taskId` when receiving requests from a client. + +Consider a network with a client and two brokers (1 and 2). + +* The IDs used between the client and Broker_1 are independent of the IDs used between Broker_1 and Broker_2. +* When Broker_1 delegates a task to Broker_2, Broker 2 (acting as a server) generates its own `contextId` and `taskId`. +* Broker_1 is responsible for maintaining a mapping between its own upstream `taskId` (used to respond to its client) and the downstream `taskId` it's tracking with Broker_2. +* If Broker_2 requires more information (if it returns `status: input-required`), it provides a `contextId` and `taskId` to Broker_1. Broker_1 uses these IDs to provide the requested input to Broker_2. The client never sees Broker_2's internal IDs. + +[cols="1,1,1", options="header"] +|=== +| Relationship | Role | Logic +| Client -> Broker_1 | Broker_1 is server | Generates `contextID_1` and `taskID_1` for the client. +| Agent A -> Broker_2 | Broker_2 is server | Generates `contextID_2` and `taskID_2` for Broker_1. +| Network broker | Broker_1 | Broker_1 maps `contextID_1` and `taskID_1` to `contextID_2` and `taskID_2`. +|=== + +For more information, see https://a2a-protocol.org/v0.3.0/topics/life-of-a-task/#group-related-interactions[Life of a Task - Group Related Interactions]. + +=== Non-Supported Features + +Agent network doesn't support streaming with Server-Sent Events (SSE). + == Considerations Agent networks have these considerations. @@ -69,11 +102,6 @@ Agent networks have these considerations. ** Basic ** Client Credentials ** Anypoint Client Credentials -* A2A specification 0.3.0 is supported. Brokers use the A2A protocol to accept requests to reach other agents. -* These A2A features aren't available. -** Task History -** Push Notifications Config -** Streaming * Text-based prompts and responses are supported. Image and binary message/artifact types aren't supported. * All LLM models in your agent network project must support structured responses in JSON format. For example, a `gpt4.1` model is supported; a `gpt4` model isn't. * These LLMs are supported. diff --git a/modules/ROOT/pages/af-project-files.adoc b/modules/ROOT/pages/af-project-files.adoc index c1b97a017..89453bd82 100644 --- a/modules/ROOT/pages/af-project-files.adoc +++ b/modules/ROOT/pages/af-project-files.adoc @@ -494,7 +494,7 @@ Use these properties to handle error scenarios. Define these properties within t `agents` -Reference agents defined in a different agent network, or another agent used in your company. Any agent is valid, as long as it supports A2A as its communication protocol. +Reference agents defined in a different agent network, or another agent used in your company. Any agent is valid, as long as it supports A2A as its communication protocol. For more information, see xref:af-agent-networks.adoc#a2a-protocol[] Example