import type { z } from 'zod'; import { defineTool } from '../defineTool.js'; export declare const STRUCTURED_OUTPUT_TOOL_NAME: "structured_output"; /** * Creates a structured output tool that wraps a Zod schema. * * This tool is used to force the model to produce validated output by presenting * the output schema as a special tool that must be called. The tool executes * immediately upon invocation (validation happens via Zod schema). * * @param schema - A Zod schema that defines the output structure * @returns A ToolDefinition that validates and returns the structured output * * @example * ```typescript * const outputSchema = z.object({ * title: z.string(), * summary: z.string(), * }) * * const tool = createStructuredOutputTool(outputSchema) * // Model calls: structured_output({ title: "...", summary: "..." }) * // Tool returns: { success: true, output: JSON.stringify({...}) } * ``` */ export declare function createStructuredOutputTool(schema: TSchema): ReturnType>; //# sourceMappingURL=structuredOutput.d.ts.map