a2aproject / a2aproject/A2A

[Feat]: Add source field in Message for multiple Agent discussion situation.

Open
#1,286 1 comment 4 reactions 0 assignees View on GitHub
Dominant language
Shell
Stars
25.7k
Forks
2.6k
Avg merge
3d 6h
Merged PRs (30d)
16

Description

### Is your feature request related to a problem? Please describe.

In the current A2A (Agent-to-Agent) protocol, messages are only defined with a kind of either User or Assistant. This design leads to the loss of critical information in multi-agent scenarios, such as collaborative or discussion-based workflows: specifically, which agent originated an Assistant message. This ambiguity can cause tasks executed in multi-agent environments to produce unexpected or incorrect results.

For example, in a multi-agent Werewolf game, if the messages lack a source identifier, the agents would be unable to perform analysis or make decisions based on who said what.

### Describe the solution you'd like

My current workaround is to add a `source` field within the Message's metadata to specify the origin. However, this approach is contingent upon the A2A server-side implementation. If a given A2A server does not support parsing this field, or uses a different field name for the same purpose, this capability is lost.

Therefore, I propose that the A2A protocol should natively support the attribution of message origins. This could be achieved by introducing a dedicated source field directly into the message structure. Adopting this change would provide all A2A servers with a unified standard for identifying a message's source, thereby ensuring compatibility and reliability in multi-agent collaboration and discussion scenarios.

### Describe alternatives you've considered

_No response_

### Additional context

_No response_

### Code of Conduct

- [x] I agree to follow this project's Code of Conduct

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.