pub struct RunAgentInput {
pub thread_id: ThreadId,
pub run_id: RunId,
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.
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.
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§fn clone(&self) -> RunAgentInput
fn clone(&self) -> RunAgentInput
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl ComposeSchema for RunAgentInput
impl ComposeSchema for RunAgentInput
Source§impl Debug for RunAgentInput
impl Debug for RunAgentInput
Source§impl Default for RunAgentInput
impl Default for RunAgentInput
Source§fn default() -> RunAgentInput
fn default() -> RunAgentInput
Returns the “default value” for a type. Read more
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>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<RunAgentInput> for RunParams
impl From<RunAgentInput> for RunParams
Source§fn from(input: RunAgentInput) -> Self
fn from(input: RunAgentInput) -> Self
Converts to this type from the input type.
Source§impl From<RunParams> for RunAgentInput
impl From<RunParams> for RunAgentInput
Source§impl JsonSchema for RunAgentInput
impl JsonSchema for RunAgentInput
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for RunAgentInput
impl PartialEq for RunAgentInput
Source§fn eq(&self, other: &RunAgentInput) -> bool
fn eq(&self, other: &RunAgentInput) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for RunAgentInput
impl Serialize for RunAgentInput
impl StructuralPartialEq for RunAgentInput
Auto Trait Implementations§
impl Freeze for RunAgentInput
impl RefUnwindSafe for RunAgentInput
impl Send for RunAgentInput
impl Sync for RunAgentInput
impl Unpin for RunAgentInput
impl UnsafeUnpin for RunAgentInput
impl UnwindSafe for RunAgentInput
Blanket Implementations§
impl<T> AgentState for T
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more