/** * Claude Code model picker and Anthropic-shaped `/v1/models` discovery. * Catalog policy, not wire translation: picker ids resolve onto RouteKit * routes before the Messages codec runs. */ import type { ModelReasoningCapabilities, ReasoningSelection } from "@velum-labs/routekit-contracts"; import type { AnthropicRequest } from "./anthropic-wire.js"; /** Historical Claude Code discovery alias prefix. Never emitted by new installs. */ export declare const CLAUDE_ALIAS_PREFIX = "claude-"; /** * Claude Code admits arbitrary custom entries in `availableModels` when they * begin with `anthropic.`. The RouteKit discriminator makes the value * reversible and reserves it from provider-native model spelling. */ export declare const CLAUDE_PICKER_PREFIX = "anthropic.routekit."; export type ClaudePickerModelRoute = { publicId: string; nativeId: string; provider: string; reasoning?: ModelReasoningCapabilities; }; export type ClaudeModelSelection = { status: "resolved"; model: string; clientModel: string; selection: ReasoningSelection; } | { status: "unsupported_effort"; model: string; message: string; } | { status: "ambiguous_model"; model: string; message: string; } | { status: "passthrough"; model: string; }; /** Claude Code's new native-picker spelling for one RouteKit catalog route. */ export declare function claudePickerClientModel(route: ClaudePickerModelRoute): string; export declare function resolveClaudeModelAlias(requested: string | undefined, modelIds?: readonly string[], modelRoutes?: readonly ClaudePickerModelRoute[]): string | undefined; /** * Resolve a Claude Code picker id (base or effort-qualified) to the served * model and request-scoped reasoning selection. */ export declare function resolveClaudeModelSelection(requested: string | undefined, modelIds?: readonly string[], modelRoutes?: readonly ClaudePickerModelRoute[]): ClaudeModelSelection; /** * Apply a request-scoped effort selection onto an Anthropic Messages body. * * Effort selections use adaptive thinking plus `output_config.effort`. Base / * auto selections leave thinking and output_config untouched so provider * defaults remain in force. */ export declare function withClaudeReasoningSelection(body: AnthropicRequest, selection: ReasoningSelection): AnthropicRequest; /** * Anthropic-shaped `/v1/models` response. IDs remain canonical RouteKit ids: * Claude Code filters arbitrary IDs from dynamic discovery, so RouteKit uses * its supported `availableModels` custom-model path for the native picker. * `modelIds` is the full advertised set (default model first); when absent we * fall back to the single backend default. */ export declare function anthropicModelsResponse(backendModel: string | undefined, modelIds?: readonly string[], _modelRoutes?: readonly ClaudePickerModelRoute[]): Response;