Skip to main content

Module schema

Module schema 

Source
Expand description

Structured output schemas for AI model tool calling.

Uses schemars to generate JSON Schema definitions that constrain model outputs to well-typed Rust structs, ensuring type safety throughout the execution pipeline.

Structs§

ExecuteCommand
A tool call request from the AI model to execute a command.
ReadFile
A tool call request to read a file.
WriteFile
A tool call request to write a file.

Enums§

ToolCall
A tool call from the model — one of the defined tool types.

Functions§

generate_schema
Generate a JSON Schema string for a given type.