sacp-tokio
Tokio-specific utilities for working with ACP agents.
What's in this crate?
This crate provides helpers for spawning and connecting to ACP agents using the Tokio async runtime:
AcpAgent- Configuration for spawning agent processesJrConnectionExt- Extension trait that addsJrConnection::to_agent()for easy agent spawning
Usage
The main use case is spawning an agent process and creating a connection to it in one step:
use JrConnection;
use ;
let agent = from_str?;
to_agent?
.on_receive_notification
.run_until
.await?;
The agent process is managed automatically - it's spawned when you call to_agent(),
and killed when the connection is dropped.
When to use this crate
Use sacp-tokio when you need to:
- Spawn agent processes from your code
- Test agents by programmatically launching them
- Build tools that orchestrate multiple agents
If you're implementing an agent that listens on stdin/stdout, you only need the core sacp crate.
Related Crates
- sacp - Core ACP SDK (use this for building agents)
- sacp-proxy - Framework for building ACP proxies
- sacp-conductor - Binary for orchestrating proxy chains
License
MIT OR Apache-2.0