pub trait ToolDyn: WasmCompatSend + WasmCompatSync {
// Required methods
fn name(&self) -> String;
fn definition<'a>(
&'a self,
prompt: String,
) -> Pin<Box<dyn Future<Output = ToolDefinition> + Send + 'a>>;
fn call<'a>(
&'a self,
args: String,
) -> Pin<Box<dyn Future<Output = Result<String, ToolError>> + Send + 'a>>;
}Expand description
Wrapper trait to allow for dynamic dispatch of simple tools