pub struct StepInput { /* private fields */ }Expand description
Input snapshot for a runtime step.
Runtime state such as context, artifacts, tool continuations, and ledger facts is read from the owning session rather than passed as raw chat history.
Implementations§
Source§impl StepInput
impl StepInput
Sourcepub fn user_text(text: &str) -> Result<Self, RuntimeError>
pub fn user_text(text: &str) -> Result<Self, RuntimeError>
Creates a user-text step input.
Sourcepub fn user_texts<I, S>(texts: I) -> Result<Self, RuntimeError>
pub fn user_texts<I, S>(texts: I) -> Result<Self, RuntimeError>
Creates a step input with multiple consecutive text-only user messages.
Sourcepub fn from_user_messages<I>(messages: I) -> Result<Self, RuntimeError>where
I: IntoIterator<Item = UserMessageInput>,
pub fn from_user_messages<I>(messages: I) -> Result<Self, RuntimeError>where
I: IntoIterator<Item = UserMessageInput>,
Creates a step input with consecutive validated user messages.
Sourcepub fn user_messages(&self) -> &[UserMessageInput]
pub fn user_messages(&self) -> &[UserMessageInput]
Borrows the validated user messages for this step.
Trait Implementations§
impl Eq for StepInput
impl StructuralPartialEq for StepInput
Auto Trait Implementations§
impl Forget for StepInput
impl Freeze for StepInputwhere
*const u8 is !null: Freeze,
PhantomData<UserMessageInput>: Freeze,
PhantomData<String>: Freeze,
impl Move for StepInput
impl RefUnwindSafe for StepInput
impl Send for StepInput
impl Sync for StepInput
impl Unpin for StepInput
impl UnsafeUnpin for StepInputwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<UserMessageInput>: UnsafeUnpin,
PhantomData<String>: UnsafeUnpin,
impl UnwindSafe for StepInput
Blanket Implementations§
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.