import type { Tool } from '../core/tools/tool-types.js'; import { type JsonSchema } from './schema-validator.js'; /** * Module-level registry of pending structured-output validations, keyed by * sessionKey. When `generate_structured` is called non-validateOnly, the * schema + prompt are stored here. The MossAgent completion gate reads (and * clears) this to enforce host-side validation after the LLM produces JSON. */ interface PendingStructuredValidation { schema: JsonSchema; prompt: string; attempt: number; maxRetries: number; } export declare function takePendingStructuredValidation(sessionKey: string, runId?: string): PendingStructuredValidation | undefined; export declare function peekPendingStructuredValidation(sessionKey: string, runId?: string): PendingStructuredValidation | undefined; export declare function setPendingStructuredValidation(sessionKey: string, schema: JsonSchema, prompt: string, maxRetries: number, runId?: string): void; export declare function bumpStructuredValidationAttempt(sessionKey: string, runId?: string): void; export declare function clearPendingStructuredValidation(sessionKey: string, runId?: string): void; export interface StructuredOutputInput { schema: Record; prompt: string; output?: string; validateOnly?: boolean; } export interface StructuredOutputResult { valid: boolean; data?: unknown; errors?: Array<{ path: string; message: string; }>; schemaDescription: string; raw?: string; } export interface StructuredOutputToolOptions { maxRetries?: number; } export declare function createStructuredOutputTool(options?: StructuredOutputToolOptions): Tool; export declare const structuredOutputTool: Tool; export {}; //# sourceMappingURL=structured-output-tool.d.ts.map