--- id: tfidf-matcher version: "0.3.0" license: unclear license_treatment: permissive maintenance: abandoned --- # tfidf-matcher — A small package that enables super-fast TF-IDF based string matching. License: permissive · Maintenance: abandoned · Downloads: 84.3K/mo ## What it is and what it does tfidf_matcher solves the scalability problem of fuzzy string matching by using TF-IDF vectorization and K-Nearest Neighbours instead of pairwise comparison. It takes two lists—an original list you want to find matches for and a lookup list to search within—and returns a pandas DataFrame with the k closest matches from the lookup list for each item in the original, along with match scores. The approach trades off some matching quality for speed, making it practical for matching hundreds or thousands of items against large reference corpora. The package depends on scikit-learn for vectorization and KNN, and pandas for result formatting. It exposes two main functions: ngrams() for generating n-grams and matcher() for the core matching operation. The author tested it successfully on 640 company names matched against a corpus of over 700,000 names, but explicitly notes the package is not well-tested beyond that use case and may produce unstable results in other scenarios. Use it for: - Deduplicate or link company names across two large databases without manual review. - Match product names from a supplier catalog to your internal inventory. - Find similar addresses or customer names across datasets for record linkage. - Bulk fuzzy search of user-provided strings against a large reference corpus. - Identify near-duplicate entries in a dataset before data cleaning. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Performs fast fuzzy string matching on large datasets using TF-IDF vectorization and K-Nearest Neighbours, scaling better than traditional fuzzy matchers by avoiding O(n²) complexity. Yes, but with caution. Install if you need fast fuzzy matching on large datasets and can tolerate the risk of an abandoned package. The MIT license and low dependency friction are favorable, and it has no known vulnerabilities. However, the last update was in April 2023, there is no active maintenance, and testing is limited to a single use case. Use only if you can verify it works for your specific data and are willing to maintain a fork if needed. ## Install pip install tfidf-matcher uv add tfidf-matcher poetry add tfidf-matcher ## Installing tfidf-matcher Before you install: Low friction to install with only scikit-learn and pandas as dependencies. However, the package is abandoned—last commit was 2023-04-06 and no updates have been made since. The repository remains public but unmaintained, so you should expect no bug fixes or compatibility updates for future Python or dependency versions. License in practice: Licensed under MIT (permissive), so you can use, modify, and distribute it freely with minimal restrictions. No commercial or proprietary concerns. Quickstart: pip install tfidf-matcher import tfidf_matcher as tm original = ["apple inc", "microsoft corp"] lookup = ["Apple Inc.", "Microsoft Corporation", "Amazon.com"] results = tm.matcher(original, lookup, k_matches=1, ngram_length=2) Requires Python >=3.5; scikit-learn and pandas must be installed. The package is abandoned and untested at scale beyond the author's single use case (640 company names vs. >700,000 corpus). Verify before relying: - Stability and correctness on datasets beyond the author's tested scenario (640 items matched against >700,000) is not documented. - Whether the package works correctly with current versions of scikit-learn and pandas, given the last update was 2023-04-06. - Memory and runtime performance characteristics on very large datasets compared to alternatives. ## Package facts - License: not declared (permissive) - Python support: supports_current - Install friction: low - Maintenance: abandoned - Downloads: 84.3K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags fuzzy string matching large scale, tfidf based string similarity, fast approximate string matching, bulk string deduplication, scalable text matching, k-nearest neighbours string search, corpus-based string matching, fuzzy-matching, text-similarity, data-deduplication [View on SkillFed](https://skillfed.io/packages/tfidf-matcher) · [View on PyPI](https://pypi.org/project/tfidf-matcher/)