pub enum StrategyStep {
Thought(String),
Action {
tool: String,
args: Value,
},
Observation(String),
Reflection {
critique: String,
revised_plan: String,
},
Branch {
branch_id: usize,
thought: String,
score: f64,
},
FinalAnswer(String),
}Expand description
A single step in a reasoning trace.
Variants§
Thought(String)
Internal reasoning / thought.
Action
An action to execute (tool call).
Observation(String)
Result of an action / tool call.
Reflection
Self-critique and revised plan (Reflexion).
Fields
Branch
A candidate branch in Tree of Thoughts.
Fields
FinalAnswer(String)
The final answer / completion signal.
Trait Implementations§
Source§impl Clone for StrategyStep
impl Clone for StrategyStep
Source§fn clone(&self) -> StrategyStep
fn clone(&self) -> StrategyStep
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for StrategyStep
impl Debug for StrategyStep
Source§impl<'de> Deserialize<'de> for StrategyStep
impl<'de> Deserialize<'de> for StrategyStep
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for StrategyStep
impl Display for StrategyStep
Auto Trait Implementations§
impl Freeze for StrategyStep
impl RefUnwindSafe for StrategyStep
impl Send for StrategyStep
impl Sync for StrategyStep
impl Unpin for StrategyStep
impl UnsafeUnpin for StrategyStep
impl UnwindSafe for StrategyStep
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.