import type { WatcherEvent, MinimalAnalyzableSpec, ImplChangeAnalysisResult, AnalyzeSpecFn } from '../../../types/file-hooks.js';
export type { AnalyzeSpecFn };
/**
 * Check if the spec is within rate limit window for the given project.
 * Returns true if rate-limited (should skip), false if should proceed.
 */
export declare function isRateLimited(specId: string, nowMs?: number, projectPath?: string): boolean;
/**
 * Record analysis timestamp for a spec in the given project.
 */
export declare function recordAnalysisTimestamp(specId: string, nowMs?: number, projectPath?: string): void;
/**
 * Clear all rate limit timestamps (for testing).
 */
export declare function clearRateLimitTimestamps(): void;
/**
 * Returns true for src/**\/*.ts files, excluding test files.
 * Test files are identified by the .test.ts or .spec.ts suffix.
 */
export declare function isSourceFile(filePath: string): boolean;
/**
 * Find specs related to a changed file by matching file path patterns.
 * Skips specs in terminal states (done, discarded).
 */
export declare function findRelatedSpecs(filePath: string, specs: MinimalAnalyzableSpec[]): MinimalAnalyzableSpec[];
/**
 * Handle an implementation file change event.
 * Fire-and-forget — all errors are caught internally.
 * When specs array and analyzeSpec function are provided, analyzes related specs.
 * When autoMarkDone is true (default), specs reaching 100% are automatically
 * transitioned to 'done' status via the spec store.
 */
export declare function handleOnImplChange(event: WatcherEvent, projectPath: string, specs?: MinimalAnalyzableSpec[], analyzeSpec?: AnalyzeSpecFn, autoMarkDone?: boolean): Promise<ImplChangeAnalysisResult | undefined>;
//# sourceMappingURL=on-impl-change.d.ts.map