ai-debug-local-mcp
Version:
🎯 ENHANCED AI GUIDANCE v4.1.2: Dramatically improved tool descriptions help AI users choose the right tools instead of 'close enough' options. Ultra-fast keyboard automation (10x speed), universal recording, multi-ecosystem debugging support, and compreh
114 lines • 3.63 kB
TypeScript
/**
* Intelligent Test Review Orchestrator
*
* Revolutionary test review system that combines AI-powered context-aware analysis
* with reliable fallback to legacy pattern-matching validation.
*
* Strategy:
* 1. Prefer test-review-agent for context-aware, intelligent validation
* 2. Fallback to TestReviewerAI for reliable syntax checking
* 3. Smart routing based on environment and test complexity
*/
import { type ReviewResult } from '../test-reviewer-ai.js';
import type { TestGenerationContext, GeneratedTest } from './sub-agent-test-generation-integration.js';
export interface IntelligentReviewResult extends ReviewResult {
reviewStrategy: 'sub-agent' | 'legacy-fallback';
contextAware: boolean;
frameworkIntelligent: boolean;
issueValidated: boolean;
enhancementApplied: boolean;
orchestratorVersion: string;
}
export interface ReviewOrchestrationConfig {
preferSubAgent: boolean;
fallbackEnabled: boolean;
maxSubAgentRetries: number;
subAgentTimeout: number;
batchSizeThreshold: number;
legacyQualityThreshold: number;
subAgentQualityThreshold: number;
alwaysUseSubAgentFor: string[];
neverUseSubAgentFor: string[];
}
export declare class IntelligentTestReviewOrchestrator {
private legacyReviewer;
private config;
private subAgentAvailable;
constructor(config?: Partial<ReviewOrchestrationConfig>);
/**
* Main orchestration method - intelligently routes to best review strategy
*/
reviewTest(test: GeneratedTest, context: TestGenerationContext): Promise<IntelligentReviewResult>;
/**
* Batch review with intelligent routing
*/
reviewTestBatch(tests: GeneratedTest[], context: TestGenerationContext): Promise<IntelligentReviewResult[]>;
/**
* Smart strategy determination based on test and context
*/
private determineReviewStrategy;
/**
* Context-aware sub-agent review
*/
private reviewWithSubAgent;
/**
* Legacy fallback review
*/
private reviewWithLegacyFallback;
/**
* Legacy TestReviewerAI review
*/
private reviewWithLegacy;
/**
* Batch legacy review for performance
*/
private reviewBatchWithLegacy;
/**
* Build comprehensive review context for sub-agent
*/
private buildSubAgentReviewContext;
/**
* Build delegation prompt for test-review-agent
*/
private buildTestReviewPrompt;
/**
* Simulate sub-agent review (until full integration)
*/
private simulateSubAgentReview;
/**
* Evaluate how well test matches debugging context
*/
private evaluateContextAccuracy;
/**
* Evaluate framework-specific appropriateness
*/
private evaluateFrameworkAppropriateness;
/**
* Evaluate how effectively test prevents discovered issues
*/
private evaluateIssuePreventionEffectiveness;
/**
* Calculate how well test covers the user flow that had issues
*/
private calculateUserFlowCoverage;
/**
* Generate context-aware feedback
*/
private generateContextAwareFeedback;
/**
* Generate context-aware improvements
*/
private generateContextAwareImprovements;
/**
* Configuration methods
*/
setSubAgentAvailability(available: boolean): void;
updateConfig(newConfig: Partial<ReviewOrchestrationConfig>): void;
getOrchestrationStats(): {
subAgentUsage: number;
legacyUsage: number;
fallbackCount: number;
averageScore: number;
};
}
//# sourceMappingURL=intelligent-test-review-orchestrator.d.ts.map