UNPKG

faf-cli

Version:

😽 TURBO-CAT: The Rapid Catalytic Converter • Project DNA ✨ for ANY AI • Fully Integrated with React, Next.js, Svelte, TypeScript, Vite & n8n • FREE FOREVER • 10,000+ developers • Championship Edition

64 lines • 1.83 kB
/** * 🎯 Universal Fuzzy Detection - Google-style intelligence for ALL inputs * "Close enough is good enough" */ interface FuzzyMatch { detected: boolean; type: string; confidence: 'high' | 'medium' | 'low' | 'none'; suggestion?: string; needsConfirmation: boolean; corrected?: string; } export declare class UniversalFuzzyDetector { private static readonly PROJECT_PATTERNS; private static readonly TYPO_CORRECTIONS; private static readonly LANGUAGE_PATTERNS; /** * Detect project type with fuzzy matching */ static detectProjectType(input: string): FuzzyMatch; /** * Detect language with fuzzy matching */ static detectLanguage(input: string): FuzzyMatch; /** * Detect with pattern matching */ private static detectWithPatterns; /** * Correct common typos across all inputs */ private static correctTypos; /** * Fuzzy match with Levenshtein distance */ private static fuzzyMatch; /** * Calculate Levenshtein distance */ private static levenshteinDistance; /** * Check for project context */ private static hasProjectContext; /** * Guess project type from context */ private static guessProjectType; /** * Get all suggestions for input */ static getSuggestions(input: string, limit?: number): string[]; } export {}; /** * Examples: * * detectProjectType("raect app") → "react" (typo corrected) * detectProjectType("chr ext") → "chrome-extension" (fuzzy match) * detectProjectType("moblie game") → "mobile" + "game" (multiple detections) * detectLanguage("typscript") → "typescript" (typo corrected) * detectLanguage("js") → "javascript" (abbreviation) */ //# sourceMappingURL=universal-fuzzy-detector.d.ts.map