pub struct ScratchpadStepState {
pub readonly_tool_successes: usize,
pub scratchpad_writes_this_step: usize,
}Expand description
Per-step scratchpad nudge state.
Reset at the start of every engine step
(message_handlers.rs:37, host_impl/mod.rs:148); mutated by
scratchpad_flow::record_tool_outcome after each tool result; read
by reminder / summary-injection flow helpers that decide whether
to nudge the model.
Fields§
§readonly_tool_successes: usizeCount of consecutive read-only tool calls (no writes / mutations observed) this step. Used by the reminder flow to decide when to prompt the model to record findings in the scratchpad.
scratchpad_writes_this_step: usizeCount of scratchpad-write tool calls this step
(scratchpad_append, scratchpad_set_area). Used to short-
circuit the read-only nudge once the model is already writing.
Implementations§
Trait Implementations§
Source§impl Clone for ScratchpadStepState
impl Clone for ScratchpadStepState
Source§fn clone(&self) -> ScratchpadStepState
fn clone(&self) -> ScratchpadStepState
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 ScratchpadStepState
impl Debug for ScratchpadStepState
Source§impl Default for ScratchpadStepState
impl Default for ScratchpadStepState
Source§fn default() -> ScratchpadStepState
fn default() -> ScratchpadStepState
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ScratchpadStepState
impl RefUnwindSafe for ScratchpadStepState
impl Send for ScratchpadStepState
impl Sync for ScratchpadStepState
impl Unpin for ScratchpadStepState
impl UnsafeUnpin for ScratchpadStepState
impl UnwindSafe for ScratchpadStepState
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