/**
 * MCP Tool Auto-Discovery
 *
 * Defers loading of MCP tool descriptions when they would consume
 * too much of the context window, using on-demand search instead.
 */
export interface MCPToolInfo {
    name: string;
    description: string;
    server: string;
    inputSchema: Record<string, unknown>;
}
export declare class MCPAutoDiscovery {
    private thresholdPercentage;
    private loadedTools;
    private deferredTools;
    /**
     * Determine if tool descriptions should be deferred
     * Returns true if total description length exceeds threshold % of context window
     */
    shouldDeferLoading(toolDescriptions: string[], contextWindowSize: number): boolean;
    /**
     * Search deferred tools by relevance to a query
     */
    searchTools(query: string, allTools: MCPToolInfo[]): MCPToolInfo[];
    /**
     * Get currently loaded tool definitions
     */
    getLoadedTools(): MCPToolInfo[];
    /**
     * Get deferred tool names
     */
    getDeferredTools(): string[];
    /**
     * Set the threshold percentage for deferring
     */
    setThreshold(percentage: number): void;
    /**
     * Get current threshold
     */
    getThreshold(): number;
    /**
     * Partition tools into loaded and deferred sets
     */
    partitionTools(tools: MCPToolInfo[], contextWindowSize: number): {
        loaded: MCPToolInfo[];
        deferred: MCPToolInfo[];
    };
}
