import type { OrchestratorConfig, RoleConfig } from "../src/core/config.js"; import type { RoutedCompletionDecision } from "./llm.js"; import { type ExcludedCandidate, type ModelSelectionIdentity, type RankedModelCandidate, type TaskFeatures } from "../src/core/modelRouting.js"; export interface McpSeparationResult { required: boolean; satisfied: boolean; builderIdentity?: string; reason: string; } export interface McpRoutingMetadata { selectedIndex: number; selectedIdentity: { provider: string; model: string; family?: string; }; thinking: RoleConfig["thinking"]; policyVersion: string; score: { total: number; breakdown: RankedModelCandidate["scoreBreakdown"]; } | null; fallbackHistory: Array<{ identity: string; reason: string; }>; separation: McpSeparationResult; legacyFallback: boolean; decision?: RoutedCompletionDecision; } export interface McpCompletionCandidate extends RoleConfig { family?: string; maxOutputTokens?: number; requestedOutputTokens?: number; estimatedCostUsd?: number; } export interface McpRoute { candidates: McpCompletionCandidate[]; ranked: RankedModelCandidate[]; excluded: ExcludedCandidate[]; policyVersion: string; separation: McpSeparationResult; legacyFallback: boolean; builder?: ModelSelectionIdentity; familySeparationRequired: boolean; } export declare function defaultTaskFeatures(text: string): TaskFeatures; /** Merge caller hints without allowing them to understate prompt size, output, or risk. */ export declare function mergeTaskFeatures(text: string, hints?: TaskFeatures): TaskFeatures; export declare function resolveMcpRoute(input: { config: OrchestratorConfig; stage: "plan" | "fast-judge"; role: "planner" | "judge"; task: TaskFeatures; coderIdentity?: string; /** Rank without making the configured engine active. Used only by orchestrator_models. */ preview?: boolean; }): McpRoute; export declare function metadataFor(route: McpRoute, selectedIndex: number, fallbackHistory: McpRoutingMetadata["fallbackHistory"], decision?: RoutedCompletionDecision): McpRoutingMetadata;