pub struct AfterGenerate {
pub model: String,
pub usage: Usage,
pub stop: StopReason,
pub error: Option<String>,
}Expand description
after Generate: the LLM call has returned. Observational — usage / stop / error
are all present (non-Option), with no room to “fill in” outputs; to influence the
next round, use BeforeTurnEnd. Only Break and observation are meaningful.
Fields§
§model: String§usage: Usage§stop: StopReason§error: Option<String>Trait Implementations§
Source§impl Clone for AfterGenerate
impl Clone for AfterGenerate
Source§fn clone(&self) -> AfterGenerate
fn clone(&self) -> AfterGenerate
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 AfterGenerate
impl Debug for AfterGenerate
Source§impl HookStep for AfterGenerate
impl HookStep for AfterGenerate
Source§fn event_name(&self) -> &'static str
fn event_name(&self) -> &'static str
Event name (snake_case). Used in envelope headers and matchers.
Source§fn to_envelope(&self) -> Value
fn to_envelope(&self) -> Value
Projects the step into an input envelope — fed to command stdin / prompt
templates. Contains a common header plus step-specific fields.
Source§fn apply_verdict(
&mut self,
verdict: &Value,
) -> Result<HookControl, VerdictError>
fn apply_verdict( &mut self, verdict: &Value, ) -> Result<HookControl, VerdictError>
Apply the handler’s output verdict (JSON) back to this step: parse the common
control / additional_context fields, then handle the step-specific “fill
output” fields. Returns a control directive. Read moreAuto Trait Implementations§
impl Freeze for AfterGenerate
impl RefUnwindSafe for AfterGenerate
impl Send for AfterGenerate
impl Sync for AfterGenerate
impl Unpin for AfterGenerate
impl UnsafeUnpin for AfterGenerate
impl UnwindSafe for AfterGenerate
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