A2a Bridge

io.github.mdfifty50-boop由 GitHub 账号 mdfifty50-boop 发布v0.1.1更新于 Nov 3, 2026

Agent-to-agent communication bridge for multi-agent systems

概览

AI 生成的概览

本地 MCP 服务器,提供代理间通信层,让助手注册代理、发现能力、委派任务并汇总结果。

可以做什么
  • 注册代理,登记能力字符串、描述以及输入输出 schema
  • 按能力以模糊相似度评分发现代理,或列出全部已注册代理
  • 把任务委派给指定代理,或广播给所有匹配某能力的代理,每个任务都有任务 ID 跟踪
  • 轮询任务状态与结果,或为任务提交结果或错误
  • 查看代理的能力卡片,含 schema、成功率和任务计数
  • 通过 a2a://agents 资源读取完整代理注册表
适用场景
适合在搭建或协调多代理系统时使用,让一个助手按能力找到其他代理、分派工作并收集结果。单代理或普通工具调用场景收益不大。
运行要求
以 stdio 本地运行,可用 npx a2a-bridge-mcp 启动(需 Node.js),或从源码 npm install 后运行。未声明认证、环境变量或请求头。按 README,代理需自行注册,并通过外部通知或轮询接收委派任务。
安装前请注意
委派任务会把输入数据传给其他已注册代理,避免在任务负载中放入密钥或敏感内容。任务结果由执行代理自行提交,状态与成功率属自报数据。注册表在进程内共享,所有注册的代理都能看到。

安装

在 SourceWeft 中

  1. 打开 控制台中的 A2a Bridge,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

a2a-bridge-mcp

MCP server for agent-to-agent communication -- capability discovery, task delegation, and result aggregation across MCP agents.

MCP connects agents to tools, but not to each other. This server adds a standardized agent-to-agent layer within the MCP protocol -- register agents, discover capabilities, delegate tasks, and broadcast work to multiple agents. Inspired by Google's A2A protocol.

Install

bash
npx a2a-bridge-mcp

Claude Desktop

Add to claude_desktop_config.json:

json
{  "mcpServers": {    "a2a-bridge": {      "command": "npx",      "args": ["a2a-bridge-mcp"]    }  }}

From source

bash
git clone https://github.com/mdfifty50-boop/a2a-bridge-mcp.gitcd a2a-bridge-mcpnpm installnode src/index.js

Tools

register_agent

Register an agent with capabilities for discovery by other agents.

ParamTypeDefaultDescription
agent_idstringrequiredUnique agent identifier
capabilitiesstring[]requiredCapability strings (e.g. ["code-review", "summarization"])
descriptionstring""Human-readable description
input_schemaobject{}JSON schema for accepted input
output_schemaobject{}JSON schema for produced output
endpointstring""Optional endpoint or transport hint

discover_agents

Find agents matching a capability need with fuzzy text similarity scoring.

ParamTypeDefaultDescription
capability_neededstringrequiredCapability to search for
min_scorenumber0.3Minimum similarity score (0-1)

Returns scored matches sorted by relevance.

delegate_task

Delegate a task to a specific registered agent. Creates a tracked task with status lifecycle.

ParamTypeDefaultDescription
from_agentstringrequiredDelegating agent ID
to_agentstringrequiredTarget agent ID
task_descriptionstringrequiredWhat the target should do
input_dataobject{}Input data for the task
timeout_msnumber30000Timeout in milliseconds

Returns a task_id for tracking.

get_task_result

Get status and result of a delegated task. Also used by executing agents to submit results.

ParamTypeDescription
task_idstringTask ID from delegate_task or broadcast_task
submit_resultobject(Optional) Submit completion result
submit_errorstring(Optional) Submit failure error

Status lifecycle: pending -> running -> completed / failed.

broadcast_task

Send a task to ALL agents matching a capability. Creates individual tracked tasks for each match.

ParamTypeDefaultDescription
from_agentstringrequiredBroadcasting agent ID
capability_neededstringrequiredCapability to match
task_descriptionstringrequiredWhat matched agents should do
input_dataobject{}Input data
min_scorenumber0.3Minimum match score
timeout_msnumber30000Timeout per agent

Returns list of task IDs for aggregation via get_task_result.

get_agent_card

Get an agent's full capability card with schemas, stats, and task history.

ParamTypeDescription
agent_idstringAgent identifier

Returns capabilities, input/output schemas, success rate, and task counts. Inspired by Google A2A agent cards.

list_agents

List all registered agents, optionally filtered by capability.

ParamTypeDefaultDescription
filterstring""Capability keyword to filter by (empty = all)

Resources

URIDescription
a2a://agentsAll registered agents with capabilities and stats

Usage Pattern

1. register_agent    -- each agent registers at startup2. discover_agents   -- find who can handle a task3. delegate_task     -- send work to a specific agent   OR broadcast_task -- send work to all matching agents4. get_task_result   -- poll for completion or submit results5. get_agent_card    -- inspect an agent's full profile6. list_agents       -- overview of the agent network

Multi-agent workflow example

Agent A (orchestrator):  1. register_agent(agent_id="orchestrator", capabilities=["planning", "coordination"])  2. discover_agents(capability_needed="code review")     -> finds Agent B (score: 0.95)  3. delegate_task(from="orchestrator", to="agent-b", task="Review PR #42")     -> task_id: "task_1234"  4. get_task_result(task_id="task_1234")     -> status: "completed", result: { approved: true, comments: [...] }
Agent B (worker):  1. register_agent(agent_id="agent-b", capabilities=["code-review", "linting"])  2. (receives task via external notification or polling)  3. get_task_result(task_id="task_1234", submit_result={ approved: true })

License

MIT

来源:README.md,提交 be04486

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

1
  1. v0.1.1最新Sep 16, 2026

评分

已满足适用检查项的 40%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分

    请在仓库或注册中心条目中声明许可证。