import { GenerativeUILibrary } from "./types.js"; import { JSONSchema7 } from "json-schema"; //#region src/buildPresentParameters.d.ts /** * Builds the JSON schema for the `present` tool from a {@link GenerativeUILibrary}. * * The model produces a node `{ $type, $key?, ...props }` where `$type` selects * a component, the optional `$key` pins a stable identity for list items that * may reorder, and the rest are its props. The schema is a flat object: `$type` * is an enum of the component names, every component's props are merged into * one optional bag, and `children` recurses via `$defs` so the tree can nest. * * It is intentionally flat rather than a per-`$type` discriminated union. Tool / * function-call schemas (OpenAI and others) require the top-level parameters to * be a plain object and reject a top-level `oneOf`/`anyOf`/`enum`. So props can't * be refined per `$type` at the root; the model is guided instead by `$type`'s * description (which lists each component) and each prop's own description. The * renderer validates nothing here — an unknown `$type` or stray prop is handled * at render time — so a looser schema only costs the model a hint, not safety. */ export declare function buildPresentParameters(library: GenerativeUILibrary): JSONSchema7; //#endregion //# sourceMappingURL=buildPresentParameters.d.ts.map