Text Matching Using Levenshtein and Keyboard Distance Algorithms
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Current methods for matching user-inputted data to stored data in databases are inadequate in differentiating between entries that are spelled differently or use abbreviations, leading to errors and inconsistencies due to the error-prone nature of manually entered text.
Innovation Solution
A computer-implemented method using a dual authentication approach combining a string similarity algorithm, such as Levenshtein distance, and a keyboard distance algorithm to compare user-inputted text with stored text, identifying matches based on thresholds for differences and keyboard distances between characters.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If exact matching methods are used to compare user-inputted text to stored database text, then database consistency is maintained, but the system fails to identify probable matches with misspellings or abbreviations
Solution Approach 1:
The system changes the matching parameter from binary exact match to a spectrum of similarity scores using Levenshtein distance, allowing flexible threshold adjustment to balance between database consistency and matching accuracy
Solution Approach 2:
The text comparison is segmented into character-level analysis, where each character difference is individually measured and weighted, enabling precise quantification of similarity between misspelled and correct text
2Productivity
If manual text entry is allowed without verification, then data entry speed is maintained, but errors such as misspellings and duplicate entries increase
Solution Approach 1:
The system performs self-verification by automatically comparing new entries against existing database text using similarity algorithms, enabling error detection without requiring manual verification while maintaining entry speed
Solution Approach 2:
The system provides immediate feedback by calculating similarity scores and identifying potential duplicates during data entry, allowing real-time correction of errors before they are committed to the database
3Measurement precision
If sophisticated text matching algorithms are implemented, then matching accuracy for misspellings is improved, but system complexity increases
Solution Approach 1:
The system replaces complex linguistic analysis with a simpler mathematical approach using Levenshtein distance, which calculates text similarity through basic character operations (insertions, deletions, substitutions) rather than sophisticated natural language processing
Data Source
AI summary
A computer-implemented method for matching user inputted text to stored text. The user inputted text is compared to each of the text strings stored in a database using a string similarity score determined using a Levenshtein distance algorithm, the n-gram or trigram methods, the Jaro-Winkler algorithm, the Cosine similarity algorithm, the Hamming distance algorithm, the Damerau-Levenshtein distance algorithm, or similar. For each comparison, the string similarity score is analyzed to determine exact matches, non-matches, and probable matches. Probable matches are further analyzed using a keyboard distance algorithm to differentiate between matches and non-matches.


