anthropics / anthropics/claude-agent-sdk-python

[Proposal] New sub-agent model(1Agent=1Process=1UnixServer)

未關閉
#297 1 則留言 4 個 reaction 已指派 0 人 在 GitHub 檢視
enhancement
主要語言
Python
星號
8.1k
分支
1.3k
平均合併
2 天 31 分鐘
30 天內合併 PR
1

描述

## Code
> https://github.com/JinTanba/claude-agent-sdk-python/tree/feat/add-unix-agent-server

### Background
The current default sub-agent model is difficult to use, limited in reusability, and lacks the flexibility required for complex orchestration. This proposal introduces a new sub-agent implementation to address these issues.

### Core Concept: *1 Agent = 1 Process = 1 UnixAgentServer*
By enforcing the principle of **1 Agent = 1 Process** and implementing multi-agent orchestration through **inter-process communication (IPC)** over **Unix Domain Sockets**, we can achieve a system that is far more modular, extensible, and stable than existing solutions.
This architecture allows each agent to operate as an independent process, communicating with others efficiently via Unix sockets. As a result, the ClaudeCode ecosystem can leverage its full potential.

### Overview
- **[UnixAgentServer](https://github.com/JinTanba/claude-agent-sdk-python/blob/feat/add-unix-agent-server/src/claude_agent_sdk/unix_agent_server.py)** manages the lifecycle of an agent process.
Each instance can be launched independently and communicates through a dedicated Unix Domain Socket.
- Agents are initialized with an instance implementing the **IAgent** specification, abstracting client implementations such as `ClaudeSDKClient`.
- Agents can control other agents by issuing commands via **Bash**, or alternatively by using **UnixAgentMCP** for structured communication.

### Monitoring & Communication
For observing the progress or state of sub-agents:
- Prefer using **standard output**, compatible with ClaudeCode’s `BashOutput` tool.
- Caution: Without an automatic timeout mechanism, synchronous communication may cause blocking and halt the entire orchestration process.

貢獻指南

這個儲存庫沒有索引到貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。