Expand description
§serdes-ai-a2a
Agent-to-Agent (A2A) protocol support for serdesAI.
This crate enables agents to communicate with each other using a standardized protocol based on the FastA2A specification.
§Features
- Agent cards for capability discovery
- Task submission and tracking
- Streaming results
- Storage and broker abstractions
§Example
ⓘ
use serdes_ai_a2a::{agent_to_a2a, A2AConfig};
use serdes_ai_agent::Agent;
let agent = Agent::new(model).build();
let a2a_server = agent_to_a2a(
agent,
A2AConfig::new()
.name("my-agent")
.url("http://localhost:8000")
.description("A helpful assistant")
);
// Start the server
a2a_server.serve("0.0.0.0:8000").await?;Re-exports§
pub use broker::Broker;pub use broker::BrokerError;pub use broker::InMemoryBroker;pub use storage::InMemoryStorage;pub use storage::Storage;pub use storage::StorageError;pub use task::Task;pub use task::TaskError;pub use task::TaskResult;pub use task::TaskStatus;pub use worker::AgentWorker;pub use worker::WorkerHandle;pub use schema::*;
Modules§
- broker
- Broker abstraction for task distribution.
- prelude
- Prelude for common imports.
- schema
- A2A protocol schema types.
- storage
- Storage abstraction for A2A tasks.
- task
- Task types for the A2A protocol.
- worker
- Worker for processing A2A tasks.
Structs§
Functions§
- agent_
to_ a2a - Convert an Agent to an A2A server.