Expand description
Harness-integration SDK for Aion — the inbound analogue of aion-client.
Where aion-client is the SDK for a caller driving Aion,
aion-integrations is the SDK for an agent harness Aion drives. It defines the
harness-neutral extension seam an integrator implements — the AgentHarness /
AgentSession traits — plus the reusable machinery an adapter would otherwise hand-roll,
and it re-exports the neutral aion-core types so an integrator has a single dependency.
§The seam
Implement AgentHarness (in a separate adapter crate) to teach Aion how to run one agent
harness for one activity attempt. The seam is harness-blind by construction: no signature
names a concrete harness, a transport, or a wire protocol. A session:
- advertises which neutral intervention primitives it supports via
AgentSession::capabilities— an empty set is first-class (an observability-only harness supports no interventions), - streams neutral
ActivityEvents OUT viaAgentSession::events, - accepts neutral
InterventionCommands IN viaAgentSession::intervene, and - yields a single terminal
PayloadviaAgentSession::wait_result.
§Building blocks
jsonrpc— a generic JSON-RPC 2.0 over newline-delimited stdio helper (envelopes, id correlation, a single serializing writer) that any stdio-JSON-RPC adapter reuses. It is machinery, not a harness: it names no concrete harness and no method namespace.
§Re-exported neutral types
The neutral aion-core types the integration surface speaks are re-exported from the crate
root (a curated re-export, the aion-client house style — not a blanket pub use aion_core),
so an integrator depends only on aion-integrations.
Re-exports§
pub use contract::AgentHarness;pub use contract::AgentSession;pub use contract::DynAgentHarness;pub use contract::DynAgentSession;pub use error::HarnessError;pub use spec::AgentRunSpec;
Modules§
- contract
- The harness-integration seam: the
AgentHarness/AgentSessiontraits. The harness-integration seam: theAgentHarnesstrait an integrator implements and the liveAgentSessionit produces. - error
- The harness-neutral error taxonomy for the seam. The harness-neutral error taxonomy for the integration seam.
- jsonrpc
- A generic JSON-RPC 2.0 over newline-delimited stdio building block. A generic, harness-neutral JSON-RPC 2.0 over newline-delimited stdio helper.
- spec
- The neutral run identity handed to a harness at start.
The neutral run identity handed to a harness at
crate::AgentHarness::start.
Structs§
- Activity
Event - A live transcript event for one
(workflow, activity, attempt)produced by an agent harness. - Activity
Id - Identifier for an activity scheduled within a workflow history.
- Intervention
Capabilities - The set of neutral intervention primitives a harness advertises support for.
- Intervention
Command - A mid-run control command routed operator -> server -> the worker owning the activity-attempt.
- Payload
- Type-erased user data with an explicit content type tag.
- Workflow
Id - Identifier for a logical workflow.
Enums§
- Activity
Event Kind - The payload of an
ActivityEvent— the classified kind of transcript signal. - Approval
Decision - A decision answering a pending human-in-the-loop approval gate.
- Content
Type - Stable tag describing the encoding used for a payload’s bytes.
- Inject
Priority - Priority of an injected out-of-band message.
- Intervention
Kind - The complete set of harness-neutral mid-run control primitives.
- Intervention
Primitive - A single neutral intervention primitive, independent of any command payload.
- Message
Role - The role a conversational message is attributed to.
- Progress
Detail - A fine-grained progress signal within an activity attempt.
- Stop
Kind - Why an agent run reached a terminal boundary.