pub struct SerialToolRoundExecutor;Expand description
The default round policy: execute the round’s calls one by one, in request order — the classic serial loop, identical behavior.
This is the executor used when none is injected, so you usually don’t need to name it; reach for it when replacing the default with a custom policy and keeping the serial behavior handy as a fallback:
use molo::agent::SerialToolRoundExecutor;
use molo::agent::ToolRoundExecutor;
let serial: Box<dyn ToolRoundExecutor> = Box::new(SerialToolRoundExecutor::default());Trait Implementations§
Source§impl Clone for SerialToolRoundExecutor
impl Clone for SerialToolRoundExecutor
impl Copy for SerialToolRoundExecutor
Source§impl Debug for SerialToolRoundExecutor
impl Debug for SerialToolRoundExecutor
Source§impl Default for SerialToolRoundExecutor
impl Default for SerialToolRoundExecutor
Source§impl ToolRoundExecutor for SerialToolRoundExecutor
impl ToolRoundExecutor for SerialToolRoundExecutor
Source§fn execute_round<'a, 'async_trait>(
&'a mut self,
ctx: ToolRoundCtx<'a>,
calls: Vec<ToolCall>,
) -> Pin<Box<dyn Future<Output = BoxStream<'a, ToolCallOutcome>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
fn execute_round<'a, 'async_trait>(
&'a mut self,
ctx: ToolRoundCtx<'a>,
calls: Vec<ToolCall>,
) -> Pin<Box<dyn Future<Output = BoxStream<'a, ToolCallOutcome>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
Execute one tool round: decide the policy over
calls — which to
run, in what order, with what concurrency — and yield each
ToolCallOutcome as it completes. Read moreAuto Trait Implementations§
impl Freeze for SerialToolRoundExecutor
impl RefUnwindSafe for SerialToolRoundExecutor
impl Send for SerialToolRoundExecutor
impl Sync for SerialToolRoundExecutor
impl Unpin for SerialToolRoundExecutor
impl UnsafeUnpin for SerialToolRoundExecutor
impl UnwindSafe for SerialToolRoundExecutor
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