pub enum TurnResult {
ToolsExecuted {
calls: Vec<(String, String, Value)>,
results: Vec<ToolOutput>,
},
FinalResponse(AgentResult),
CompactionOccurred {
old_tokens: usize,
new_tokens: usize,
},
MaxTurnsReached,
Error(LoopError),
}Expand description
The result of a single turn in the agentic loop.
Variants§
ToolsExecuted
Tool calls were executed and results appended.
Fields
§
results: Vec<ToolOutput>The tool outputs.
FinalResponse(AgentResult)
The model returned a final text response.
CompactionOccurred
Context compaction occurred.
Fields
MaxTurnsReached
The turn limit was reached.
Error(LoopError)
An error occurred.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TurnResult
impl !RefUnwindSafe for TurnResult
impl Send for TurnResult
impl Sync for TurnResult
impl Unpin for TurnResult
impl UnsafeUnpin for TurnResult
impl !UnwindSafe for TurnResult
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