/** * ExplainPlanParser (v3.1) * * Adapter-aware normalizer for EXPLAIN output. SQLite/MySQL/PostgreSQL/MongoDB * have native parsers; the rest 11 adapters return a raw text passthrough * shape (so the LLM can still see the plan, even if we can't structure-diff it). * Redis / similar get 'unsupported'. */ export interface NormalizedPlanNode { /** Operation label (e.g. 'SCAN TABLE', 'INDEX RANGE SCAN', 'Seq Scan', 'FULL SCAN') */ op: string; /** Target table or relation (when parseable) */ table?: string; /** Index used (when applicable) */ index?: string; /** Estimated rows (when present) */ rows?: number; /** Cost estimate (when present) */ cost?: number; /** Raw text of this row (preserved for LLM) */ raw?: string; /** Nested child nodes (when plan is hierarchical) */ children?: NormalizedPlanNode[]; } export interface NormalizedPlan { /** Adapters we could parse into structured form */ dbType: string; /** True when this adapter is fully supported; false → raw text mode */ structured: boolean; /** Total estimated cost (when present) */ totalCost?: number; /** Total estimated rows (when present) */ totalRows?: number; /** Hierarchical plan nodes */ nodes: NormalizedPlanNode[]; /** Raw text passthrough (always populated for LLM context) */ rawText: string; } export declare class ExplainPlanParser { /** * Normalize EXPLAIN output from a real adapter. * `dbType` matches ProfileManager's `profile.type` string. */ static normalize(rawText: string, dbType: string): NormalizedPlan; /** Compute SHA-256 hash of normalized raw text (for query identity). */ static hashNormalized(plan: NormalizedPlan): string; } //# sourceMappingURL=explain-parser.d.ts.map