pub enum BeforeToolExecuteAction {
Block(String),
Suspend(SuspendTicket),
SetToolResult(ToolResult),
State(AnyStateAction),
}Expand description
Actions valid in BeforeToolExecute.
Variants§
Block(String)
Block tool execution with a denial reason.
Suspend(SuspendTicket)
Suspend tool execution pending external confirmation.
SetToolResult(ToolResult)
Short-circuit tool execution with a pre-built result.
State(AnyStateAction)
Emit a persistent state change.
Implementations§
Source§impl BeforeToolExecuteAction
impl BeforeToolExecuteAction
Sourcepub fn from_decision(decision: ToolCallAction) -> Self
pub fn from_decision(decision: ToolCallAction) -> Self
Convenience: forward a ToolCallAction as a BeforeToolExecuteAction.
Trait Implementations§
Source§impl From<AnyStateAction> for BeforeToolExecuteAction
impl From<AnyStateAction> for BeforeToolExecuteAction
Source§fn from(sa: AnyStateAction) -> Self
fn from(sa: AnyStateAction) -> Self
Converts to this type from the input type.
Source§impl From<BeforeToolExecuteAction> for ActionSet<BeforeToolExecuteAction>
impl From<BeforeToolExecuteAction> for ActionSet<BeforeToolExecuteAction>
Source§fn from(a: BeforeToolExecuteAction) -> Self
fn from(a: BeforeToolExecuteAction) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for BeforeToolExecuteAction
impl !RefUnwindSafe for BeforeToolExecuteAction
impl Send for BeforeToolExecuteAction
impl !Sync for BeforeToolExecuteAction
impl Unpin for BeforeToolExecuteAction
impl !UnwindSafe for BeforeToolExecuteAction
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