pub type OnToolErrorCallback = Arc<dyn Fn(Context, Arc<dyn Tool>, Map<String, Value>, Arc<ToolError>) -> BoxFuture<'static, Result<Option<Map<String, Value>>, AgentError>> + Send + Sync>;Expand description
Called when a tool returns an error. If it returns Some result or an error, the tool’s
result/error is replaced with the returned one.
Aliased Type§
pub struct OnToolErrorCallback { /* private fields */ }