pub enum LoopCommand {
Continue,
InjectMessages(Vec<ChatMessage>),
Stop(Option<String>),
}Expand description
Commands sent by the caller to control the resumable loop.
Passed to Yielded::resume() after receiving a
TurnResult::Yielded.
Variants§
Continue
Continue to the next LLM iteration normally.
InjectMessages(Vec<ChatMessage>)
Inject additional messages before the next LLM call.
The injected messages are appended after the tool results from the current round. Use this to provide additional context (e.g., worker agent results, user follow-ups).
Stop(Option<String>)
Stop the loop immediately.
Returns a Completed event with TerminationReason::StopCondition.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LoopCommand
impl RefUnwindSafe for LoopCommand
impl Send for LoopCommand
impl Sync for LoopCommand
impl Unpin for LoopCommand
impl UnwindSafe for LoopCommand
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