pub trait Tool:
Send
+ Sync
+ 'static {
// Required methods
fn name(&self) -> &str;
fn description(&self) -> &str;
fn schema(&self) -> Value;
fn call<'life0, 'async_trait>(
&'life0 self,
input: Value,
) -> Pin<Box<dyn Future<Output = Result<ToolOutput>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Expand description
Unified contract for agent tools.
Required Methods§
Sourcefn description(&self) -> &str
fn description(&self) -> &str
Returns a short tool description.