pub struct RunInput {
pub inputs: IndexMap<String, Value>,
pub sys: IndexMap<String, Value>,
pub env: IndexMap<String, Value>,
pub conversation: IndexMap<String, Value>,
pub run_id: Option<String>,
pub resume: Option<ResumeFrom>,
pub max_total_tokens: Option<u64>,
pub max_cost_micros: Option<u64>,
}Expand description
Input for a run.
Fields§
§inputs: IndexMap<String, Value>Values for the start node’s declared variables (written into the entry node’s namespace).
sys: IndexMap<String, Value>System variables (sys.*), e.g. query, files, user_id, conversation_id.
env: IndexMap<String, Value>Environment variables (env.*); override document defaults. Never persisted.
conversation: IndexMap<String, Value>Conversation variables (conversation.*); override document defaults.
run_id: Option<String>Explicit run id (generated when absent).
resume: Option<ResumeFrom>Resume a paused run.
max_total_tokens: Option<u64>A token budget for this run, below the engine’s
(Limits::max_total_tokens): the lower of the two applies.
max_cost_micros: Option<u64>A cost budget for this run in micro units, below the engine’s
(Limits::max_cost_micros): the lower of the two applies.
Implementations§
Source§impl RunInput
impl RunInput
pub fn new() -> Self
Sourcepub fn input(self, name: impl Into<String>, value: impl Into<Value>) -> Self
pub fn input(self, name: impl Into<String>, value: impl Into<Value>) -> Self
Add a start input.
Sourcepub fn sys(self, name: impl Into<String>, value: impl Into<Value>) -> Self
pub fn sys(self, name: impl Into<String>, value: impl Into<Value>) -> Self
Add a system variable.
Trait Implementations§
Auto Trait Implementations§
impl Forget for RunInput
impl Freeze for RunInputwhere
*const u8 is !null: Freeze,
PhantomData<usize>: Freeze,
PhantomData<Bucket<String, Value>>: Freeze,
PhantomData<u8>: Freeze,
PhantomData<Bucket<String, IndexMap<String, Value>>>: Freeze,
PhantomData<Bucket<String, NodeSnapshot>>: Freeze,
PhantomData<Bucket<String, EdgeStatus>>: Freeze,
PhantomData<(Selector, Value)>: Freeze,
impl Move for RunInput
impl RefUnwindSafe for RunInput
impl Send for RunInput
impl Sync for RunInput
impl Unpin for RunInput
impl UnsafeUnpin for RunInputwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<usize>: UnsafeUnpin,
PhantomData<Bucket<String, Value>>: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<Bucket<String, IndexMap<String, Value>>>: UnsafeUnpin,
PhantomData<Bucket<String, NodeSnapshot>>: UnsafeUnpin,
PhantomData<Bucket<String, EdgeStatus>>: UnsafeUnpin,
PhantomData<(Selector, Value)>: UnsafeUnpin,
impl UnwindSafe for RunInputwhere
NonNull<u8>: UnwindSafe,
RawVecInner: UnwindSafe,
Arc<str>: UnwindSafe,
Arc<Vec<Value>>: UnwindSafe,
Arc<IndexMap<String, Value>>: UnwindSafe,
Arc<File>: UnwindSafe,
Arc<[Arc<str>]>: UnwindSafe,
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