Skip to main content

ToolSchema

Derive Macro ToolSchema 

Source
#[derive(ToolSchema)]
{
    // Attributes available to this derive:
    #[tool]
}
Expand description

#[derive(ToolSchema)] for typed tool inputs. Derive llmkit_core::ToolSchema for a struct.

Reads #[tool(name = "...", description = "...")]; both are optional (name defaults to the lowercased type name). The type must also derive schemars::JsonSchema.