Expand description
ACP (Agent Client Protocol) support for Zed editor integration.
ACP is a JSON-RPC 2.0 protocol over stdio that Zed editor uses to communicate with external agents. This module implements the server side of the protocol, translating ACP method calls into pi’s core agent/session/tool infrastructure.
§Protocol methods
initialize— exchange capabilities and protocol versionsession/new— create a new agent sessionprompt— send a prompt and stream back resultscancel— cancel an in-progress promptsession/list— list existing sessions
§Streaming
Prompt results are streamed as prompt/progress JSON-RPC notifications.
Each notification carries incremental content (text deltas, tool calls,
tool results) so the client can render in real time.
Structs§
- AcpOptions
- Options for starting the ACP server.
Functions§
- run_
stdio - Run the ACP server over stdio.