import type { ProviderId, ReasoningEffort, ReasoningPreference } from "../types.js"; import type { ToolDialect, ToolCallingMode } from "./tool-protocol.js"; import type { CatalogFacts } from "./catalog-facts.js"; import { learnedRouteRejectedFields } from "./learned-capabilities.js"; /** Mark a model as having rejected reasoning options so we stop sending them. */ export declare function markReasoningUnsupported(provider: ProviderId, model: string): void; export declare function registerRouteControlDialect(provider: ProviderId, model: string, dialect: string): void; /** Whether a model was observed to reject reasoning options this session. */ export declare function isReasoningUnsupported(provider: ProviderId, model: string): boolean; export declare function clearReasoningUnsupported(): void; export declare function effectiveThinkingEffort(provider: ProviderId, model: string, thinking: ReasoningPreference | undefined): ReasoningEffort | undefined; export declare function registerRouteAcceptedEfforts(provider: ProviderId, model: string, efforts: readonly string[]): void; export declare function registerWireRejectionEfforts(provider: ProviderId, model: string, efforts: readonly string[]): void; export declare function markReasoningMandatory(provider: ProviderId, model: string): void; export declare function routeReasoningIsMandatory(provider: ProviderId, model: string): boolean; export declare function learnedRouteEfforts(provider: ProviderId, model: string): readonly string[] | undefined; export declare function clearReasoningRejection(provider: ProviderId, model: string): void; export declare function registerModelReasoningSupport(provider: ProviderId, model: string, supported: boolean): void; export declare function learnModelEmitsReasoning(provider: ProviderId, model: string): void; export type ReasoningEvidence = "rejected" | "observed" | "catalog" | "pattern" | "endpoint" | "unknown"; export declare function modelReasoningEvidence(provider: ProviderId, model: string): ReasoningEvidence; export declare function resetReasoningKnowledge(): void; export declare function modelSupportsThinking(provider: ProviderId, model: string): boolean; export declare function displayReasoningEfforts(provider: ProviderId, model: string): readonly string[] | undefined; export declare function registerProviderModels(provider: ProviderId, models: readonly string[]): void; export interface CatalogModel { readonly id: string; readonly vision?: boolean | undefined; readonly reasoning?: boolean | undefined; readonly reasoningEfforts?: readonly string[] | undefined; readonly facts?: CatalogFacts | undefined; } export declare function registerModelCatalogFacts(provider: ProviderId, facts: CatalogFacts): void; export declare function modelCatalogFacts(provider: ProviderId | string, model: string): CatalogFacts | undefined; export declare function clearModelCatalogFacts(): void; export declare function registerModelReasoningEfforts(provider: ProviderId, model: string, efforts: readonly string[]): void; export declare function modelReasoningEfforts(provider: ProviderId, model: string): readonly string[] | undefined; export declare function modelReasoningIsMandatory(model: string): boolean; export declare function clearModelReasoningEfforts(): void; export declare function registerModelCatalog(provider: ProviderId, models: readonly CatalogModel[]): void; export declare function providerModelIsKnown(provider: ProviderId, model: string): boolean | undefined; export declare function markModelUnavailable(provider: ProviderId, model: string): void; export declare function isModelUnavailable(provider: ProviderId, model: string): boolean; export declare function recordVisionSubstitution(provider: ProviderId, substitute: string, original: string): void; export declare function visionSubstitutionOrigin(provider: ProviderId, substitute: string): string | undefined; export declare function clearProviderModelKnowledge(): void; /** * Capability lookups are keyed by canonical `ProviderId`. Passing a display * label (`"NVIDIA NIM"`) used to silently resolve to "no capability", which * Disabled vision while the rest of the app believed it was on. * Fail loudly in dev/test and warn once per bad key in production. */ export declare function warnOnUnknownProviderId(site: string, provider: string): void; /** Provider discovery/user overrides can refresh capability knowledge at runtime. */ export declare function registerModelVisionCapability(input: { provider: ProviderId; model: string; vision: boolean; source?: "provider" | "user"; observedAt?: string; }): void; export declare function learnModelVisionCapability(provider: ProviderId, model: string, vision: boolean): void; export declare function learnRouteReasoningSupport(provider: ProviderId, model: string, reasoning: boolean, controlDialect?: string): void; export declare function learnRouteAcceptedEfforts(provider: ProviderId, model: string, acceptedEfforts: readonly string[]): void; export declare function learnRouteLimits(provider: ProviderId, model: string, limits: { contextTokens?: number | undefined; maxOutputTokens?: number | undefined; }): void; export declare function learnRouteRejectedField(provider: ProviderId, model: string, field: string): void; export declare function clearModelVisionCapabilities(): void; export declare function clearLearnedVisionCapabilities(): void; export declare function clearLearnedRouteCapabilities(): void; export declare function reloadLearnedCapabilities(): void; export { learnedRouteRejectedFields }; export declare function visionCapabilitySource(provider: ProviderId, model: string): "provider" | "user" | "fallback-table"; /** * Whether the given provider/model can accept image input. When true, the * agent attaches real image bytes to the user message; when false, it falls * back to a text note and OCR/inspection tools. */ export type VisionSupport = "yes" | "no" | "unknown"; export type VisionEvidence = "observed" | "pattern" | "none"; export declare function visionEvidence(provider: ProviderId, model: string): VisionEvidence; export declare function modelVisionSupport(provider: ProviderId, model: string): VisionSupport; export declare function modelSupportsVision(provider: ProviderId, model: string): boolean; export declare function modelAcceptsImages(provider: ProviderId, model: string): boolean; export declare function preferredVisionModel(provider: ProviderId, currentModel: string): string | undefined; export declare function resolveToolDialect(provider: ProviderId, model: string, toolCalling?: ToolCallingMode): ToolDialect; export declare function modelSupportsNativeTools(provider: ProviderId, model: string, toolCalling?: ToolCallingMode): boolean;