agentsys 5.2.1 → 5.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +1 -1
- package/AGENTS.md +5 -3
- package/CHANGELOG.md +19 -1
- package/README.md +6 -5
- package/agent-knowledge/AGENTS.md +32 -2
- package/agent-knowledge/acp-with-codex-gemini-copilot-claude.md +504 -0
- package/agent-knowledge/kiro-supervised-autopilot.md +400 -0
- package/agent-knowledge/resources/acp-with-codex-gemini-copilot-claude-sources.json +408 -0
- package/agent-knowledge/resources/kiro-supervised-autopilot-sources.json +135 -0
- package/bin/cli.js +176 -9
- package/lib/adapter-transforms.js +196 -1
- package/lib/cross-platform/index.js +9 -3
- package/lib/discovery/index.js +22 -0
- package/lib/platform/state-dir.js +16 -2
- package/package.json +1 -1
- package/scripts/dev-install.js +137 -1
- package/scripts/gen-adapters.js +66 -4
- package/site/content.json +1 -1
|
@@ -0,0 +1,504 @@
|
|
|
1
|
+
# Learning Guide: ACP (Agent Communication Protocol) with Codex, Gemini, Copilot, and Claude
|
|
2
|
+
|
|
3
|
+
**Generated**: 2026-03-02
|
|
4
|
+
**Sources**: 24 resources analyzed
|
|
5
|
+
**Depth**: medium
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Prerequisites
|
|
10
|
+
|
|
11
|
+
- Familiarity with at least one AI coding tool (Claude Code, Codex CLI, Gemini CLI, or GitHub Copilot)
|
|
12
|
+
- Basic understanding of HTTP, REST APIs, and JSON-RPC
|
|
13
|
+
- General awareness of the Model Context Protocol (MCP)
|
|
14
|
+
- Understanding of client-server architecture and inter-process communication
|
|
15
|
+
|
|
16
|
+
## TL;DR
|
|
17
|
+
|
|
18
|
+
- **ACP** (Agent Communication Protocol) is an open protocol under the Linux Foundation for agent interoperability, using REST endpoints and MIME types. It originated from IBM's BeeAI project and is now merging with Google's **A2A** protocol.
|
|
19
|
+
- **A2A** (Agent-to-Agent) is Google's open protocol using JSON-RPC 2.0 over HTTP(S) with Agent Cards for discovery. It focuses on opaque agent-to-agent collaboration. Over 50 technology partners support it.
|
|
20
|
+
- **MCP** (Model Context Protocol) is Anthropic's open standard for connecting AI to tools and data -- it is complementary to A2A/ACP, not a competitor. MCP handles agent-to-tool communication; A2A handles agent-to-agent communication.
|
|
21
|
+
- **None of the major AI coding CLIs** (Claude Code, Codex CLI, Gemini CLI, Copilot) natively implement ACP or A2A as a built-in protocol. All four support MCP to varying degrees.
|
|
22
|
+
- **Cross-tool AI communication** is possible today via MCP bridges, the Claude Agent SDK, and Claude Code's `mcp serve` feature, but formal agent-to-agent protocols between different vendor tools remain nascent.
|
|
23
|
+
|
|
24
|
+
---
|
|
25
|
+
|
|
26
|
+
## Core Concepts
|
|
27
|
+
|
|
28
|
+
### 1. What is ACP (Agent Communication Protocol)?
|
|
29
|
+
|
|
30
|
+
ACP is an open protocol for agent interoperability that addresses the fragmentation challenge in AI development. It enables standardized communication across different agent frameworks and implementations.
|
|
31
|
+
|
|
32
|
+
**Key characteristics:**
|
|
33
|
+
- Uses simple, well-defined **REST endpoints** aligned with standard HTTP patterns
|
|
34
|
+
- Employs **MIME types** for content identification, enabling extensibility for any data format
|
|
35
|
+
- Supports synchronous, asynchronous, and streaming interactions
|
|
36
|
+
- Supports both stateful and stateless patterns
|
|
37
|
+
- Provides online and offline agent discovery
|
|
38
|
+
- Framework-agnostic: works across BeeAI, LangChain, CrewAI, and custom implementations
|
|
39
|
+
|
|
40
|
+
**Origin and governance:**
|
|
41
|
+
- Originally developed by IBM as part of the **BeeAI** project (now called "Agent Stack")
|
|
42
|
+
- Contributed to the **Linux Foundation AI & Data** program
|
|
43
|
+
- SDKs available in **Python** (`pip install acp-sdk`) and **TypeScript**
|
|
44
|
+
- Reference implementation: Agent Stack (formerly BeeAI), available at github.com/i-am-bee/beeai
|
|
45
|
+
|
|
46
|
+
**ACP SDK example (Python):**
|
|
47
|
+
|
|
48
|
+
```python
|
|
49
|
+
from acp_sdk import Server, Client, Message, MessagePart
|
|
50
|
+
|
|
51
|
+
# Server side
|
|
52
|
+
server = Server()
|
|
53
|
+
|
|
54
|
+
@server.agent()
|
|
55
|
+
async def echo(input: list[Message]):
|
|
56
|
+
"""Echoes everything"""
|
|
57
|
+
for message in input:
|
|
58
|
+
yield message
|
|
59
|
+
|
|
60
|
+
server.run(port=8000)
|
|
61
|
+
|
|
62
|
+
# Client side
|
|
63
|
+
async with Client(base_url="http://localhost:8000") as client:
|
|
64
|
+
run = await client.run_sync(
|
|
65
|
+
agent="echo",
|
|
66
|
+
input=[Message(parts=[MessagePart(content="Hello!")])]
|
|
67
|
+
)
|
|
68
|
+
print(run)
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
### 2. What is Google's A2A (Agent-to-Agent) Protocol?
|
|
72
|
+
|
|
73
|
+
A2A is an open protocol contributed by Google to the Linux Foundation, enabling communication and interoperability between opaque agentic applications.
|
|
74
|
+
|
|
75
|
+
**Key characteristics:**
|
|
76
|
+
- Uses **JSON-RPC 2.0 over HTTP(S)** as its transport layer
|
|
77
|
+
- Supports synchronous request/response, Server-Sent Events (SSE) streaming, and asynchronous push notifications
|
|
78
|
+
- Data formats: text, files, and structured JSON
|
|
79
|
+
- Designed for **opaque** agents -- no requirement to share internal state, memory, or tool implementations
|
|
80
|
+
|
|
81
|
+
**Core concepts:**
|
|
82
|
+
- **Agent Cards**: JSON documents that describe an agent's capabilities, connection info, and supported modalities. Used for discovery.
|
|
83
|
+
- **Tasks**: Units of work with a defined lifecycle, producing artifacts as outputs.
|
|
84
|
+
- **Messages**: Structured communication between client and remote agents.
|
|
85
|
+
- **Opacity principle**: Agents collaborate without exposing internal memory, proprietary logic, or specific tool implementations.
|
|
86
|
+
|
|
87
|
+
**Announced**: April 9, 2025 by Google. Over 50 technology partners including Atlassian, Salesforce, SAP, ServiceNow, Langchain, MongoDB, and many major consulting firms.
|
|
88
|
+
|
|
89
|
+
**SDKs**: Python, Go, JavaScript, Java, .NET (available via `pip install a2a-sdk` for Python).
|
|
90
|
+
|
|
91
|
+
**Licensed**: Apache 2.0 under the Linux Foundation.
|
|
92
|
+
|
|
93
|
+
### 3. ACP vs A2A: Convergence
|
|
94
|
+
|
|
95
|
+
ACP and A2A are converging under the Linux Foundation. As of early 2026:
|
|
96
|
+
- ACP's website (agentcommunicationprotocol.dev) describes ACP as "now part of A2A"
|
|
97
|
+
- Agent Stack (BeeAI) has adopted A2A as its interoperability protocol
|
|
98
|
+
- Both protocols share similar goals but had different transport choices (REST for ACP, JSON-RPC for A2A)
|
|
99
|
+
- The merged effort means new implementations should target the A2A specification
|
|
100
|
+
|
|
101
|
+
### 4. MCP (Model Context Protocol) -- The Complement
|
|
102
|
+
|
|
103
|
+
MCP is Anthropic's open standard for connecting AI applications to external systems (tools, data sources, workflows). It is explicitly **not** an agent-to-agent protocol.
|
|
104
|
+
|
|
105
|
+
**Key distinction:**
|
|
106
|
+
- **MCP**: Agent-to-tool communication (connecting AI to databases, APIs, file systems)
|
|
107
|
+
- **A2A/ACP**: Agent-to-agent communication (connecting AI agents to each other)
|
|
108
|
+
|
|
109
|
+
As Google's A2A announcement stated: "A2A complements Anthropic's Model Context Protocol (MCP), which provides helpful tools and context to agents."
|
|
110
|
+
|
|
111
|
+
**MCP architecture:**
|
|
112
|
+
- Client-server model with stdio, SSE, and HTTP transports
|
|
113
|
+
- Servers expose tools, resources, and prompts
|
|
114
|
+
- Clients (AI applications) consume these capabilities
|
|
115
|
+
- Supported by Claude Code, Codex CLI, Gemini CLI, Copilot, Kiro, Cursor, and many others
|
|
116
|
+
|
|
117
|
+
### 5. Protocol Comparison
|
|
118
|
+
|
|
119
|
+
| Feature | ACP | A2A | MCP |
|
|
120
|
+
|---------|-----|-----|-----|
|
|
121
|
+
| **Purpose** | Agent-to-agent interop | Agent-to-agent interop | Agent-to-tool integration |
|
|
122
|
+
| **Transport** | REST/HTTP | JSON-RPC 2.0 over HTTP(S) | stdio, SSE, HTTP |
|
|
123
|
+
| **Discovery** | Agent registry | Agent Cards (JSON) | Server configuration |
|
|
124
|
+
| **Streaming** | Yes | Yes (SSE) | Yes (SSE, streamable HTTP) |
|
|
125
|
+
| **Async** | Yes | Yes (push notifications) | Limited |
|
|
126
|
+
| **Creator** | IBM / Linux Foundation | Google / Linux Foundation | Anthropic |
|
|
127
|
+
| **Status** | Merging into A2A | Active, growing ecosystem | Mature, widely adopted |
|
|
128
|
+
| **Opacity** | Framework-agnostic | Fully opaque agents | N/A (tool exposure) |
|
|
129
|
+
| **SDKs** | Python, TypeScript | Python, Go, JS, Java, .NET | Python, TypeScript, + more |
|
|
130
|
+
| **When to use** | Legacy ACP deployments | Agent orchestration across vendors | Connecting AI to tools/data |
|
|
131
|
+
|
|
132
|
+
---
|
|
133
|
+
|
|
134
|
+
## How Each AI Coding Tool Relates to ACP/A2A
|
|
135
|
+
|
|
136
|
+
### Claude Code (Anthropic)
|
|
137
|
+
|
|
138
|
+
**ACP/A2A support**: No native ACP or A2A protocol implementation.
|
|
139
|
+
|
|
140
|
+
**What it does support:**
|
|
141
|
+
- **MCP** (full support): Claude Code can both consume MCP servers and act as one (`claude mcp serve`)
|
|
142
|
+
- **Subagents**: Specialized sub-agents within a single Claude Code session (Explore, Plan, custom agents)
|
|
143
|
+
- **Agent Teams** (experimental): Multiple Claude Code instances coordinating via shared task lists, mailbox messaging, and direct inter-agent communication
|
|
144
|
+
- **Agent SDK**: Python and TypeScript SDKs for building production agents with Claude Code's tools programmatically
|
|
145
|
+
|
|
146
|
+
**Cross-tool bridging:**
|
|
147
|
+
- Claude Code can serve as an MCP server, letting other tools invoke Claude's capabilities:
|
|
148
|
+
```bash
|
|
149
|
+
claude mcp serve
|
|
150
|
+
```
|
|
151
|
+
- The Agent SDK enables programmatic spawning of Claude agents that can interact with MCP servers from any provider
|
|
152
|
+
- MCP bridge servers (community-built) can connect Claude to other AI model APIs
|
|
153
|
+
|
|
154
|
+
**Agent Teams architecture:**
|
|
155
|
+
- Team lead coordinates work via shared task list
|
|
156
|
+
- Teammates communicate via a mailbox messaging system
|
|
157
|
+
- Each teammate has its own context window
|
|
158
|
+
- Supports plan approval workflows
|
|
159
|
+
- Experimental; requires `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1`
|
|
160
|
+
|
|
161
|
+
### OpenAI Codex CLI
|
|
162
|
+
|
|
163
|
+
**ACP/A2A support**: No native ACP or A2A protocol implementation.
|
|
164
|
+
|
|
165
|
+
**What it does support:**
|
|
166
|
+
- **MCP**: Basic MCP support via `shell-tool-mcp` component and MCP Registry integration
|
|
167
|
+
- **Multi-provider**: Configurable to work with various AI providers (OpenAI, Azure, Gemini, Ollama, etc.)
|
|
168
|
+
- **AGENTS.md**: Supports instruction files that merge from global to directory-level context
|
|
169
|
+
|
|
170
|
+
**Architecture:**
|
|
171
|
+
- Primarily Rust-based (96.1%), operates as a single-agent tool
|
|
172
|
+
- Three approval modes: Suggest, Auto Edit, Full Auto
|
|
173
|
+
- Sandboxed execution using Apple Seatbelt (macOS) or Docker (Linux)
|
|
174
|
+
- No multi-agent coordination or agent-to-agent communication mechanisms documented
|
|
175
|
+
|
|
176
|
+
**Cross-tool bridging:**
|
|
177
|
+
- Can be configured to use different LLM providers, but this is provider-switching, not agent-to-agent communication
|
|
178
|
+
- MCP server support enables external tool integration
|
|
179
|
+
|
|
180
|
+
### Google Gemini CLI
|
|
181
|
+
|
|
182
|
+
**ACP/A2A support**: No native A2A protocol implementation despite Google creating A2A.
|
|
183
|
+
|
|
184
|
+
**What it does support:**
|
|
185
|
+
- **MCP**: Explicit MCP support for custom integrations
|
|
186
|
+
- **Google Search grounding**: Built-in real-time information access
|
|
187
|
+
- **GitHub integration**: Dedicated GitHub Action for automated workflows
|
|
188
|
+
- **Non-interactive mode**: JSON and streaming output for automation and scripting
|
|
189
|
+
|
|
190
|
+
**Notable absence:**
|
|
191
|
+
Gemini CLI documentation contains no references to A2A or ACP support. This is notable because Google created the A2A protocol. The A2A protocol appears designed for enterprise agent orchestration scenarios rather than developer CLI tools.
|
|
192
|
+
|
|
193
|
+
### GitHub Copilot
|
|
194
|
+
|
|
195
|
+
**ACP/A2A support**: No native ACP or A2A protocol implementation.
|
|
196
|
+
|
|
197
|
+
**What it does support:**
|
|
198
|
+
- **MCP**: Full MCP support through Copilot Extensions in VS Code, JetBrains, and other IDEs
|
|
199
|
+
- **GitHub MCP Server**: Dedicated server for code tasks, coding agent invocation, and code scanning
|
|
200
|
+
- **Extensions ecosystem**: Third-party tool integrations via MCP
|
|
201
|
+
- **Push protection**: Security features for AI-generated code
|
|
202
|
+
|
|
203
|
+
**Organization controls:**
|
|
204
|
+
- MCP server policy management for Copilot Business/Enterprise
|
|
205
|
+
- Allowlist/denylist controls for MCP servers
|
|
206
|
+
|
|
207
|
+
### Kiro (AWS)
|
|
208
|
+
|
|
209
|
+
**ACP/A2A support**: No documented ACP or A2A support.
|
|
210
|
+
|
|
211
|
+
**What it does support:**
|
|
212
|
+
- **MCP**: Full MCP server support with configuration UI
|
|
213
|
+
- **Agentic features**: Specs, hooks, steering, and agentic chat
|
|
214
|
+
- Built on Claude (AWS product)
|
|
215
|
+
- MCP server management with connection status indicators
|
|
216
|
+
|
|
217
|
+
---
|
|
218
|
+
|
|
219
|
+
## Cross-AI-Tool Communication Patterns
|
|
220
|
+
|
|
221
|
+
### Pattern 1: MCP Bridge Servers
|
|
222
|
+
|
|
223
|
+
Community-built MCP servers that bridge to other AI providers:
|
|
224
|
+
|
|
225
|
+
| Server | Description | Source |
|
|
226
|
+
|--------|-------------|--------|
|
|
227
|
+
| `mcp-server-gemini-bridge` | Bridge to Google Gemini API (Pro, Flash) | jaspertvdm (GitHub) |
|
|
228
|
+
| `mcp-server-openai-bridge` | Bridge to OpenAI API (GPT-4, GPT-4o) | jaspertvdm (GitHub) |
|
|
229
|
+
| `mcp-server-ollama-bridge` | Bridge to local Ollama LLM server | jaspertvdm (GitHub) |
|
|
230
|
+
| `Grok-MCP` | Access to xAI's Grok API | merterbak (GitHub) |
|
|
231
|
+
| `blockrun-mcp` | Access 30+ AI models without API keys | blockrunai (GitHub) |
|
|
232
|
+
|
|
233
|
+
**Example: Using Claude Code to consult Gemini via MCP bridge:**
|
|
234
|
+
```bash
|
|
235
|
+
# Add Gemini bridge as MCP server in Claude Code
|
|
236
|
+
claude mcp add --transport stdio gemini-bridge -- npx -y mcp-server-gemini-bridge
|
|
237
|
+
|
|
238
|
+
# Then in Claude Code, the Gemini bridge tools become available
|
|
239
|
+
# Claude can call Gemini for a second opinion on code
|
|
240
|
+
```
|
|
241
|
+
|
|
242
|
+
### Pattern 2: Agent-to-Agent MCP Servers
|
|
243
|
+
|
|
244
|
+
Dedicated MCP servers for agent discovery and communication:
|
|
245
|
+
|
|
246
|
+
| Server | Description |
|
|
247
|
+
|--------|-------------|
|
|
248
|
+
| `agentnet` | Agent-to-agent referral network for AI agent discovery and recommendation |
|
|
249
|
+
| `prolink` | Agent-to-agent marketplace middleware with MCP-native discovery and negotiation |
|
|
250
|
+
| `hashnet-mcp-js` | Registry Broker for discovering, registering, and chatting with AI agents |
|
|
251
|
+
| `agenium` | Network protocol enabling agent discovery via `agent://` URIs with mTLS trust |
|
|
252
|
+
|
|
253
|
+
### Pattern 3: Claude Code as MCP Server
|
|
254
|
+
|
|
255
|
+
Claude Code can expose its tools as an MCP server for other applications:
|
|
256
|
+
|
|
257
|
+
```bash
|
|
258
|
+
# Start Claude Code as an MCP server
|
|
259
|
+
claude mcp serve
|
|
260
|
+
```
|
|
261
|
+
|
|
262
|
+
**Configuration for Claude Desktop:**
|
|
263
|
+
```json
|
|
264
|
+
{
|
|
265
|
+
"mcpServers": {
|
|
266
|
+
"claude-code": {
|
|
267
|
+
"type": "stdio",
|
|
268
|
+
"command": "claude",
|
|
269
|
+
"args": ["mcp", "serve"],
|
|
270
|
+
"env": {}
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
}
|
|
274
|
+
```
|
|
275
|
+
|
|
276
|
+
This means any MCP client (Kiro, Cursor, Gemini CLI, etc.) could potentially use Claude Code's tools.
|
|
277
|
+
|
|
278
|
+
### Pattern 4: Claude Agent SDK for Programmatic Orchestration
|
|
279
|
+
|
|
280
|
+
The Claude Agent SDK enables building custom multi-agent systems:
|
|
281
|
+
|
|
282
|
+
```python
|
|
283
|
+
import asyncio
|
|
284
|
+
from claude_agent_sdk import query, ClaudeAgentOptions, AgentDefinition
|
|
285
|
+
|
|
286
|
+
async def main():
|
|
287
|
+
async for message in query(
|
|
288
|
+
prompt="Use the researcher agent to analyze this codebase",
|
|
289
|
+
options=ClaudeAgentOptions(
|
|
290
|
+
allowed_tools=["Read", "Glob", "Grep", "Task"],
|
|
291
|
+
agents={
|
|
292
|
+
"researcher": AgentDefinition(
|
|
293
|
+
description="Research specialist for code analysis",
|
|
294
|
+
prompt="Analyze code quality and architecture patterns.",
|
|
295
|
+
tools=["Read", "Glob", "Grep"],
|
|
296
|
+
)
|
|
297
|
+
},
|
|
298
|
+
mcp_servers={
|
|
299
|
+
"gemini": {"command": "npx", "args": ["mcp-server-gemini-bridge"]}
|
|
300
|
+
}
|
|
301
|
+
),
|
|
302
|
+
):
|
|
303
|
+
if hasattr(message, "result"):
|
|
304
|
+
print(message.result)
|
|
305
|
+
|
|
306
|
+
asyncio.run(main())
|
|
307
|
+
```
|
|
308
|
+
|
|
309
|
+
### Pattern 5: Sequential Thinking MCP Server
|
|
310
|
+
|
|
311
|
+
The Sequential Thinking MCP server enables structured reasoning across tool calls:
|
|
312
|
+
|
|
313
|
+
```json
|
|
314
|
+
{
|
|
315
|
+
"mcpServers": {
|
|
316
|
+
"sequential-thinking": {
|
|
317
|
+
"command": "npx",
|
|
318
|
+
"args": ["-y", "@modelcontextprotocol/server-sequential-thinking"]
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
}
|
|
322
|
+
```
|
|
323
|
+
|
|
324
|
+
**How it works:**
|
|
325
|
+
- Decomposes problems into sequential reasoning steps
|
|
326
|
+
- Supports revision of previous thoughts
|
|
327
|
+
- Enables branching into alternative reasoning paths
|
|
328
|
+
- Dynamically adjusts the total thought count
|
|
329
|
+
- Useful for complex problems where the full scope is not initially clear
|
|
330
|
+
|
|
331
|
+
**Parameters:**
|
|
332
|
+
- `thought` (string): Current reasoning step
|
|
333
|
+
- `nextThoughtNeeded` (boolean): Whether continuation is needed
|
|
334
|
+
- `thoughtNumber` / `totalThoughts` (integer): Position tracking
|
|
335
|
+
- `isRevision` / `revisesThought`: For reconsidering previous thinking
|
|
336
|
+
- `branchFromThought` / `branchId`: For alternative reasoning paths
|
|
337
|
+
|
|
338
|
+
This is not cross-AI communication per se, but enables more sophisticated reasoning within a single AI tool.
|
|
339
|
+
|
|
340
|
+
---
|
|
341
|
+
|
|
342
|
+
## Common Pitfalls
|
|
343
|
+
|
|
344
|
+
| Pitfall | Why It Happens | How to Avoid |
|
|
345
|
+
|---------|---------------|--------------|
|
|
346
|
+
| Confusing ACP with A2A | They were separate protocols now merging | Target A2A for new implementations; ACP is being absorbed |
|
|
347
|
+
| Expecting AI CLIs to support A2A natively | A2A is designed for enterprise agent orchestration, not developer CLI tools | Use MCP bridges for cross-tool communication today |
|
|
348
|
+
| Treating MCP as an agent-to-agent protocol | MCP is for tool integration, not agent collaboration | Use A2A/ACP for agent-to-agent; MCP for agent-to-tool |
|
|
349
|
+
| Assuming Gemini CLI supports A2A | Google created A2A but hasn't built it into Gemini CLI | Gemini CLI uses MCP; A2A is separate infrastructure |
|
|
350
|
+
| Using MCP bridges in production without security review | Community MCP bridges are educational examples | Implement proper authentication, rate limiting, and input validation |
|
|
351
|
+
| Over-engineering with agent teams | Agent teams consume significantly more tokens | Use subagents for focused tasks; teams only when inter-agent coordination is needed |
|
|
352
|
+
| Expecting ACP SDK to be stable | ACP is merging into A2A | Monitor Linux Foundation announcements for migration guidance |
|
|
353
|
+
|
|
354
|
+
---
|
|
355
|
+
|
|
356
|
+
## Best Practices
|
|
357
|
+
|
|
358
|
+
1. **Use MCP as the universal adapter layer**: All major AI coding tools support MCP. Build MCP servers to create cross-tool capabilities. (Sources: MCP docs, Claude Code docs, Gemini CLI docs, Codex CLI docs)
|
|
359
|
+
|
|
360
|
+
2. **Target A2A for new agent-to-agent work**: ACP is merging into A2A. New implementations should use the A2A SDK. (Source: agentcommunicationprotocol.dev, A2A GitHub)
|
|
361
|
+
|
|
362
|
+
3. **Use Claude Code's `mcp serve` for lightweight bridging**: Expose Claude's tools to any MCP-compatible client without building custom infrastructure. (Source: Claude Code MCP documentation)
|
|
363
|
+
|
|
364
|
+
4. **Leverage the Claude Agent SDK for complex orchestration**: When you need programmatic control over multi-agent workflows with MCP integration. (Source: Claude Agent SDK overview)
|
|
365
|
+
|
|
366
|
+
5. **Start with subagents before agent teams**: Subagents have lower token costs and simpler coordination. Use teams only when agents need to communicate with each other. (Source: Claude Code subagents and agent teams docs)
|
|
367
|
+
|
|
368
|
+
6. **Keep cross-AI bridges stateless**: MCP bridge servers should not maintain conversation state across calls. Each invocation should be self-contained. (Source: MCP server best practices)
|
|
369
|
+
|
|
370
|
+
7. **Use Agent Stack (BeeAI) for A2A reference implementations**: Agent Stack is the official reference implementation for A2A-compatible agent deployment. (Source: Agent Stack GitHub)
|
|
371
|
+
|
|
372
|
+
8. **Monitor the A2A specification evolution**: The protocol is actively evolving with new features planned for Agent Card authorization, credential management, and enhanced discovery. (Source: A2A GitHub repository)
|
|
373
|
+
|
|
374
|
+
---
|
|
375
|
+
|
|
376
|
+
## Current Maturity Assessment
|
|
377
|
+
|
|
378
|
+
| Aspect | Maturity Level | Notes |
|
|
379
|
+
|--------|---------------|-------|
|
|
380
|
+
| **MCP ecosystem** | Mature | Hundreds of servers, supported by all major tools |
|
|
381
|
+
| **A2A specification** | Growing | 50+ partners, SDKs in 5 languages, under Linux Foundation |
|
|
382
|
+
| **ACP specification** | Transitioning | Merging into A2A; existing ACP deployments should plan migration |
|
|
383
|
+
| **Cross-CLI agent communication** | Nascent | No AI CLI natively implements A2A; MCP bridges are community-built |
|
|
384
|
+
| **Claude Code agent teams** | Experimental | Functional but with known limitations; disabled by default |
|
|
385
|
+
| **MCP bridge servers** | Early | Community-built, not production-hardened |
|
|
386
|
+
| **Agent Stack (BeeAI) production readiness** | Developing | 1000+ GitHub stars, modular architecture, but still evolving |
|
|
387
|
+
| **Sequential Thinking MCP** | Stable | Part of official MCP reference servers |
|
|
388
|
+
|
|
389
|
+
---
|
|
390
|
+
|
|
391
|
+
## Real-World Cross-AI Communication Examples
|
|
392
|
+
|
|
393
|
+
### Example 1: Claude Code consulting Gemini via MCP bridge
|
|
394
|
+
```bash
|
|
395
|
+
# Setup
|
|
396
|
+
claude mcp add --transport stdio gemini -- npx -y mcp-server-gemini-bridge
|
|
397
|
+
|
|
398
|
+
# In Claude Code session:
|
|
399
|
+
# "Get Gemini's perspective on the best approach for this database migration"
|
|
400
|
+
# Claude calls the Gemini MCP bridge tool, gets Gemini's response, synthesizes both perspectives
|
|
401
|
+
```
|
|
402
|
+
|
|
403
|
+
### Example 2: Multi-agent research with Claude Agent SDK
|
|
404
|
+
```python
|
|
405
|
+
# A lead agent delegates research to subagents, each with different MCP servers
|
|
406
|
+
from claude_agent_sdk import query, ClaudeAgentOptions, AgentDefinition
|
|
407
|
+
|
|
408
|
+
async def multi_source_research():
|
|
409
|
+
async for msg in query(
|
|
410
|
+
prompt="Research best practices for API rate limiting. "
|
|
411
|
+
"Use the researcher agent to analyze our codebase "
|
|
412
|
+
"and the web-researcher to find current best practices.",
|
|
413
|
+
options=ClaudeAgentOptions(
|
|
414
|
+
allowed_tools=["Read", "Glob", "Grep", "Task", "WebSearch"],
|
|
415
|
+
agents={
|
|
416
|
+
"researcher": AgentDefinition(
|
|
417
|
+
description="Codebase analysis specialist",
|
|
418
|
+
prompt="Analyze the existing codebase for patterns.",
|
|
419
|
+
tools=["Read", "Glob", "Grep"],
|
|
420
|
+
),
|
|
421
|
+
"web-researcher": AgentDefinition(
|
|
422
|
+
description="Web research specialist",
|
|
423
|
+
prompt="Search the web for current best practices.",
|
|
424
|
+
tools=["WebSearch", "WebFetch"],
|
|
425
|
+
)
|
|
426
|
+
}
|
|
427
|
+
),
|
|
428
|
+
):
|
|
429
|
+
if hasattr(msg, "result"):
|
|
430
|
+
print(msg.result)
|
|
431
|
+
```
|
|
432
|
+
|
|
433
|
+
### Example 3: A2A-compatible agent via Agent Stack
|
|
434
|
+
```python
|
|
435
|
+
# Deploy an agent that is automatically A2A-compatible
|
|
436
|
+
# Using Agent Stack (BeeAI)
|
|
437
|
+
|
|
438
|
+
# 1. Define your agent in any framework (LangGraph, CrewAI, custom)
|
|
439
|
+
# 2. Deploy via Agent Stack CLI
|
|
440
|
+
# 3. Agent is automatically exposed as an A2A-compatible service
|
|
441
|
+
|
|
442
|
+
# Other A2A-compatible agents can discover and communicate with it
|
|
443
|
+
# via Agent Cards and JSON-RPC 2.0
|
|
444
|
+
```
|
|
445
|
+
|
|
446
|
+
### Example 4: Claude Code agent team for parallel investigation
|
|
447
|
+
```text
|
|
448
|
+
# In Claude Code with agent teams enabled:
|
|
449
|
+
|
|
450
|
+
I need to investigate why our API is slow. Create an agent team:
|
|
451
|
+
- One teammate to profile the database queries
|
|
452
|
+
- One teammate to analyze the application logs
|
|
453
|
+
- One teammate to check the network latency metrics
|
|
454
|
+
Have them share findings and build a unified diagnosis.
|
|
455
|
+
```
|
|
456
|
+
|
|
457
|
+
---
|
|
458
|
+
|
|
459
|
+
## Open Source Implementations
|
|
460
|
+
|
|
461
|
+
### A2A Protocol
|
|
462
|
+
- **A2A SDKs**: Python, Go, JavaScript, Java, .NET (github.com/google/A2A)
|
|
463
|
+
- **Agent Stack**: Reference A2A implementation (github.com/i-am-bee/beeai)
|
|
464
|
+
- **DeepLearning.AI Course**: Official course on building A2A-compliant agents
|
|
465
|
+
|
|
466
|
+
### ACP Protocol (Legacy/Transitioning)
|
|
467
|
+
- **ACP SDK (Python)**: `pip install acp-sdk` -- v1.0.3, maintained by IBM (pypi.org/project/acp-sdk)
|
|
468
|
+
- **ACP SDK (TypeScript)**: Available via npm
|
|
469
|
+
|
|
470
|
+
### MCP Ecosystem
|
|
471
|
+
- **Official MCP servers**: github.com/modelcontextprotocol/servers
|
|
472
|
+
- **Sequential Thinking**: `@modelcontextprotocol/server-sequential-thinking`
|
|
473
|
+
- **AI Bridge servers**: Community-built bridges to Gemini, OpenAI, Ollama, Grok
|
|
474
|
+
|
|
475
|
+
### Claude Agent SDK
|
|
476
|
+
- **Python**: `pip install claude-agent-sdk` (github.com/anthropics/claude-agent-sdk-python)
|
|
477
|
+
- **TypeScript**: `npm install @anthropic-ai/claude-agent-sdk`
|
|
478
|
+
- **Demo agents**: github.com/anthropics/claude-agent-sdk-demos
|
|
479
|
+
|
|
480
|
+
---
|
|
481
|
+
|
|
482
|
+
## Further Reading
|
|
483
|
+
|
|
484
|
+
| Resource | Type | Why Recommended |
|
|
485
|
+
|----------|------|-----------------|
|
|
486
|
+
| [A2A Protocol Specification](https://a2a-protocol.org/) | Spec | Official A2A specification and documentation |
|
|
487
|
+
| [ACP Website](https://agentcommunicationprotocol.dev/) | Docs | ACP protocol overview (now merging into A2A) |
|
|
488
|
+
| [Agent Stack (BeeAI)](https://github.com/i-am-bee/beeai) | Code | Reference A2A implementation with full agent infrastructure |
|
|
489
|
+
| [MCP Introduction](https://modelcontextprotocol.io/introduction) | Docs | Official MCP documentation and architecture |
|
|
490
|
+
| [Claude Code MCP Guide](https://code.claude.com/docs/en/mcp) | Docs | Comprehensive guide to MCP in Claude Code |
|
|
491
|
+
| [Claude Code Subagents](https://code.claude.com/docs/en/sub-agents) | Docs | Creating and managing specialized AI subagents |
|
|
492
|
+
| [Claude Code Agent Teams](https://code.claude.com/docs/en/agent-teams) | Docs | Multi-agent coordination with shared tasks and messaging |
|
|
493
|
+
| [Claude Agent SDK](https://platform.claude.com/docs/en/agent-sdk/overview) | Docs | Programmatic access to Claude Code's capabilities |
|
|
494
|
+
| [Claude Agent SDK Demos](https://github.com/anthropics/claude-agent-sdk-demos) | Code | Example agents including multi-agent research pattern |
|
|
495
|
+
| [Codex CLI](https://github.com/openai/codex) | Code | OpenAI's coding agent with MCP support |
|
|
496
|
+
| [Gemini CLI](https://github.com/google-gemini/gemini-cli) | Code | Google's terminal AI with MCP support |
|
|
497
|
+
| [Google A2A Blog Post](https://developers.googleblog.com/en/a2a-a-new-era-of-agent-interoperability/) | Blog | Google's announcement and vision for A2A |
|
|
498
|
+
| [ACP SDK (Python)](https://pypi.org/project/acp-sdk/) | Package | Python SDK for building ACP agents |
|
|
499
|
+
| [MCP Servers Repository](https://github.com/modelcontextprotocol/servers) | Code | Official MCP reference servers including Sequential Thinking |
|
|
500
|
+
| [Awesome MCP Servers](https://github.com/punkpeye/awesome-mcp-servers) | List | Curated list of MCP servers including AI bridges |
|
|
501
|
+
|
|
502
|
+
---
|
|
503
|
+
|
|
504
|
+
*This guide was synthesized from 24 sources. See `resources/acp-with-codex-gemini-copilot-claude-sources.json` for full source list with quality scores.*
|