/** * @license * Copyright 2026 Steven Roussey * SPDX-License-Identifier: Apache-2.0 */ import type { Capability, ModelRecord } from "@workglow/ai/worker"; /** * Closed list of capability-set specs the OpenAI provider serves. Derived * from {@link OPENAI_CAPABILITY_SETS}. Used by the main-thread provider * shells when registering worker-mode proxies so the dispatcher can route * requests to the worker proxy. */ export declare const OPENAI_RUN_FN_SPECS: { serves: ["cache.checkpoint"] | ["image.editing"] | ["image.generation"] | ["model.count-tokens"] | ["model.info"] | ["model.search"] | ["text.embedding"] | ["text.generation"] | ["text.rewriter"] | ["text.summary"] | ["text.generation", "json-mode"] | ["text.generation", "tool-use"]; }[]; export declare function openAiWorkerRunFnSpecs(): readonly { readonly serves: readonly Capability[]; }[]; /** * Shape used by the model-name regexes — `model_id` is required, the rest * is loosely-typed metadata only used to opportunistically widen the * inferred capability set. */ type CapabilityHints = Pick; /** * Heuristic capability inference for an OpenAI {@link ModelRecord}. Pattern- * matches the canonical OpenAI model id strings (and the `provider_config. * model_name` if present) to a closed set of {@link Capability}s. Falls back * to the model's stored `capabilities` array (or a baseline of search + * info) when no pattern matches. * * Main-thread method only — workers do not run capability inference. */ export declare function inferOpenAiCapabilities(model: CapabilityHints): readonly Capability[]; export {};