import type { RuntimeToolEligibilityContract } from "../../protocol/wire/index.js";
export type ToolChoiceLike = "auto" | "none" | "required" | {
    type: "function";
    function?: {
        name?: string;
    };
} | Record<string, unknown> | undefined;
export interface ToolChoiceToolLike {
    type?: string;
    function?: {
        name?: string;
        description?: string;
        parameters?: Record<string, unknown>;
    };
    name?: string;
    description?: string;
    requiresApproval?: boolean;
}
export type ToolEligibilityLike = RuntimeToolEligibilityContract;
export interface ToolChoiceCompatibilityPolicy {
    allowNamedToolChoice?: boolean;
    allowRequiredToolChoice?: boolean;
    requiredFallback?: "required" | "auto" | "none";
    namedFallback?: "required" | "auto" | "none";
    requireAutoWhenThinking?: boolean;
}
export interface ApplyToolChoicePolicyInput<TTool extends ToolChoiceToolLike> {
    tools: readonly TTool[];
    toolChoice: ToolChoiceLike;
    eligibility?: readonly ToolEligibilityLike[];
    thinkingEnabled?: boolean;
    compatibility?: ToolChoiceCompatibilityPolicy;
}
export interface ApplyToolChoicePolicyResult<TTool extends ToolChoiceToolLike> {
    tools: TTool[];
    normalizedToolChoice?: ToolChoiceLike;
    extraSystemPrompt?: string;
    warnings: string[];
}
export declare function filterEligibleTools<TTool extends ToolChoiceToolLike>(params: {
    tools: readonly TTool[];
    eligibility?: readonly ToolEligibilityLike[];
}): TTool[];
export declare function normalizeAnthropicFunctionToolDefinition(tool: unknown): Record<string, unknown> | undefined;
export declare function normalizeAnthropicToolChoice(toolChoice: unknown): unknown;
export declare function applyToolChoiceCompatibility(params: {
    toolChoice: ToolChoiceLike;
    thinkingEnabled?: boolean;
    compatibility?: ToolChoiceCompatibilityPolicy;
}): {
    normalizedToolChoice?: ToolChoiceLike;
    warnings: string[];
};
export declare function applyToolChoicePolicy<TTool extends ToolChoiceToolLike>(params: ApplyToolChoicePolicyInput<TTool>): ApplyToolChoicePolicyResult<TTool>;
