import type { PendingQuestionType } from '../task/task-state.js'; /** * Declares what a provider adapter can do at runtime. * TaskManager reads these at startup and uses them to route behavior. */ export interface ProviderCapabilities { /** Session survives server restart (e.g. Codex rollout files). */ sessionPersistence: boolean; /** Distinct approve/decline protocol (e.g. Codex 4 approval types). */ structuredApproval: boolean; /** Can stream tokens/chunks. */ streamingOutput: boolean; /** Has explicit cancel primitive (e.g. turn/interrupt). */ abortPrimitive: boolean; /** Supports thread/read-style probe for crash recovery. */ crashRecovery: boolean; /** How the provider selects a model. */ modelRouting: 'config' | 'api-param' | 'none'; /** Emits structured rate-limit error. */ rateLimitSignal: boolean; /** Subset of the 5 PendingQuestion types this provider supports. */ pauseTypes: readonly PendingQuestionType[]; } export declare const CODEX_CAPABILITIES: Readonly; export declare const COPILOT_CAPABILITIES: Readonly; export declare const CLAUDE_CAPABILITIES: Readonly; export interface ValidationResult { ok: boolean; reason?: string; } /** * Validates that a pause type is supported by the provider's capabilities. * Returns `{ ok: false, reason }` if the provider does not support the given type. */ export declare function validateResponseAgainstCapabilities(caps: ProviderCapabilities, pauseType: PendingQuestionType): ValidationResult;