pub trait Capability: Send + Sync {
// Required methods
fn name(&self) -> &str;
fn description(&self) -> &str;
fn risk_level(&self) -> RiskLevel;
fn parameters_schema(&self) -> Value;
fn source(&self) -> CapabilitySource;
fn execute<'life0, 'life1, 'async_trait>(
&'life0 self,
params: Value,
ctx: &'life1 ToolContext,
) -> Pin<Box<dyn Future<Output = Result<ToolResult, ToolError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
// Provided method
fn paired_skill(&self) -> Option<&str> { ... }
}Expand description
Executable capability surface (tool) visible to policy and the LLM catalog.
Required Methods§
fn name(&self) -> &str
fn description(&self) -> &str
fn risk_level(&self) -> RiskLevel
fn parameters_schema(&self) -> Value
fn source(&self) -> CapabilitySource
fn execute<'life0, 'life1, 'async_trait>(
&'life0 self,
params: Value,
ctx: &'life1 ToolContext,
) -> Pin<Box<dyn Future<Output = Result<ToolResult, ToolError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Provided Methods§
Sourcefn paired_skill(&self) -> Option<&str>
fn paired_skill(&self) -> Option<&str>
Optional companion skill id/path for capability discovery (e.g. plugin paired_skill).