/**
 * Search MCP Tools
 *
 * Tools: ocr_search (unified: keyword/semantic/hybrid), ocr_fts_manage,
 *        ocr_search_export, ocr_benchmark_compare, ocr_rag_context,
 *        ocr_search_saved (unified: save/list/get/execute)
 *
 * CRITICAL: NEVER use console.log() - stdout is reserved for JSON-RPC protocol.
 * Use console.error() for all logging.
 *
 * @module tools/search
 */
import { type ToolResponse, type ToolDefinition } from './shared.js';
/**
 * Handle ocr_search - Unified search across keyword (BM25), semantic (vector),
 * and hybrid (BM25+semantic RRF fusion) modes.
 *
 * Always-on optimizations (hardcoded, no parameters needed):
 * - quality_boost: true (quality-weighted ranking)
 * - expand_query: true (domain synonym + corpus term expansion)
 * - exclude_duplicate_chunks: true (deduplicate by content hash)
 * - exclude headers/footers: true (filter repeated header/footer chunks)
 * - include_cluster_context: true (cluster membership in results)
 */
/**
 * Detect if a query looks like a keyword list rather than natural language.
 * Uses function-word ratio analysis: natural language has 40-60% function words,
 * while keyword dumps have less than 25%.
 *
 * This is a hard gate: keyword-list queries are rejected for semantic/hybrid search
 * because nomic-embed-text-v1.5 produces poor embeddings for keyword dumps.
 */
export declare function isKeywordListQuery(query: string): boolean;
export declare function handleSearchUnified(params: Record<string, unknown>): Promise<ToolResponse>;
/**
 * Handle ocr_fts_manage - Manage FTS5 indexes (rebuild or check status)
 * Covers both chunks FTS and VLM FTS indexes
 */
export declare function handleFTSManage(params: Record<string, unknown>): Promise<ToolResponse>;
/**
 * Search tools collection for MCP server registration
 */
export declare const searchTools: Record<string, ToolDefinition>;
//# sourceMappingURL=search.d.ts.map