pub struct RunAgentInput {
pub thread_id: ThreadId,
pub run_id: RunId,
pub protocol_version: Option<String>,
pub parent_run_id: Option<RunId>,
pub state: Value,
pub messages: Vec<Message>,
pub tools: Vec<Tool>,
pub context: Vec<Context>,
pub forwarded_props: Value,
pub resume: Option<Vec<ResumeEntry>>,
}Expand description
Everything an agent needs for one run.
This is the body of the AG-UI run request, and it is also embedded verbatim
in RunStartedEvent::input so a
recorded stream can be replayed without the original request.
Fields§
§thread_id: ThreadIdThe conversation this run belongs to.
run_id: RunIdThis run’s id, echoed on every lifecycle event.
protocol_version: Option<String>The protocol version this consumer speaks. Absent for a known legacy peer that predates version declarations.
parent_run_id: Option<RunId>The run that spawned this one, for nested / delegated agents.
state: ValueShared state, mutated by the agent through STATE_SNAPSHOT and
STATE_DELTA. Free-form JSON, opaque to the protocol.
Absent state remains the local null default; explicit null is invalid
under AG-UI 1.0 and is omitted when serializing that default.
messages: Vec<Message>Conversation history, oldest first.
tools: Vec<Tool>Tools the client is offering for this run.
context: Vec<Context>Ambient context entries.
forwarded_props: ValueArbitrary passthrough properties, opaque to the protocol.
resume: Option<Vec<ResumeEntry>>Answers to the interrupts a previous run paused on. Present only when
resuming — see crate::outcome.
Implementations§
Trait Implementations§
Source§impl Clone for RunAgentInput
impl Clone for RunAgentInput
Source§impl ComposeSchema for RunAgentInput
Available on crate feature utoipa only.
impl ComposeSchema for RunAgentInput
utoipa only.Source§impl Debug for RunAgentInput
impl Debug for RunAgentInput
Source§impl Default for RunAgentInput
impl Default for RunAgentInput
Source§impl<'de> Deserialize<'de> for RunAgentInput
impl<'de> Deserialize<'de> for RunAgentInput
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl From<RunAgentInput> for RunParams
Available on crate feature client only.
impl From<RunAgentInput> for RunParams
client only.Source§fn from(input: RunAgentInput) -> Self
fn from(input: RunAgentInput) -> Self
Source§impl From<RunParams> for RunAgentInput
Available on crate feature client only.
impl From<RunParams> for RunAgentInput
client only.Source§impl JsonSchema for RunAgentInput
Available on crate feature schemars only.
impl JsonSchema for RunAgentInput
schemars only.Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read more