import type { ValidationErrorDetail } from '../types/core.js';
/**
 * Conservative, dependency-free type checker for tool arguments against the
 * tool's declared JSON schema. The goal is to catch the failure mode that
 * actually breaks things — a model emitting a structured value (object/array)
 * where a scalar string/number/boolean is expected, or a non-array where an
 * array is expected — and return a clear error so the model self-corrects,
 * rather than letting the bad value reach execution/rendering.
 *
 * It is deliberately LENIENT on scalar↔scalar (e.g. the string "5" for a
 * number) to avoid false positives on common model habits; it only flags
 * high-confidence type errors. Value constraints (min/max/length/pattern) are
 * intentionally NOT enforced here — those stay in per-tool validators.
 */
interface JsonSchemaNode {
    type?: string | string[];
    enum?: unknown[];
    properties?: Record<string, JsonSchemaNode>;
    items?: JsonSchemaNode;
}
/**
 * Type-check parsed tool arguments against a JSON schema. Returns one detail
 * per high-confidence type error (empty array when the args look well-typed or
 * the schema is too complex to check confidently).
 */
export declare function validateArgsAgainstSchema(args: unknown, schema: JsonSchemaNode | undefined): ValidationErrorDetail[];
/**
 * Pull the raw JSON Schema out of an AI SDK tool's `inputSchema`. Tools built
 * with `jsonSchema(...)` expose it as `inputSchema.jsonSchema`. Returns
 * undefined for anything else (or a promise-like / non-object), so callers
 * simply skip schema validation rather than risk a false positive.
 */
export declare function getToolJsonSchema(tool: unknown): JsonSchemaNode | undefined;
export {};
//# sourceMappingURL=schema-validate.d.ts.map