/** * AST-aware structural code search tool using @ast-grep/napi. * Finds code patterns by AST structure rather than text matching. * * @plan PLAN-20260211-ASTGREP.P05 */ import { BaseDeclarativeTool, type ToolInvocation, type ToolResult } from './tools.js'; import type { Config } from '../config/config.js'; import type { MessageBus } from '../confirmation-bus/message-bus.js'; export interface AstGrepToolParams { pattern?: string; rule?: Record; language?: string; path?: string; globs?: string[]; maxResults?: number; } export declare class AstGrepTool extends BaseDeclarativeTool { private readonly config; static readonly Name = "ast_grep"; constructor(config: Config, _messageBus?: MessageBus); protected createInvocation(params: AstGrepToolParams, _messageBus?: MessageBus): ToolInvocation; }