Expand description
Tool — the only side-effectful interface available to skills and agents.
A Tool is a typed, named, async function with a JSON-Schema-compatible
signature. Two transports satisfy the trait today: LocalTool (a closure
over a Rust async fn) and — under the mcp feature in a later phase — a
remote MCP server. Skills never know the difference.
Structs§
- Local
Tool - Adapter that turns any
async Fn(Value) -> Result<Value, KernelError>into aTool. Hosts can use this to surface existing async functions to the kernel without writing a dedicated tool type. - Tool
Schema - Lightweight description of a tool’s I/O contract. The
args_schemaandresult_schemaare JSON-Schema fragments; the LLM-facing rendering layer uses them to generaterig/ MCP tool definitions automatically. We do not validate against them at the kernel — validation is the tool’s responsibility — but downstream MCP exporters need them.
Traits§
- Tool
- A composable, side-effectful capability.
Type Aliases§
- Tool
Name - Stable, registry-unique identifier for a tool (e.g.
"grammar.query","memory.lookup","sampler.expand").