Fast fuzzy text search
Project description
Narrow Down - Efficient near-duplicate search
Narrow Down offers a flexible but easy-to-use Python API to finding duplicates or similar documents also in very large datasets. It reduces the O(n²) problem of comparing all strings with each other to linear scale by using approximation algorithms like Locality Sensitive Hashing.
- GitHub repo: https://github.com/chr1st1ank/narrow-down.git
- Documentation: https://chr1st1ank.github.io/narrow-down
Status: Prototype. Solid and fast production quality, but API changes are still possible until version 1.0 is reached.
Features
- Document indexing and search based on the Minhash LSH algorithm
- High performance thanks to a native extension module in Rust
- Easy-to-use API with automated parameter tuning
- Works with exchangeable storage backends. Currently implemented:
- In-Memory
- Cassandra / ScyllaDB
- SQLite
- User defined backends (by implementing a small interface)
- Native asyncio interface
Installation
The Python package can be installed with pip:
pip install narrow-down
Extras
Some of the heavier functionality is available as extra:
pip install narrow-down[scylladb] # Cassandra / ScyllaDB storage backend
Similar projects
- pylsh offers a good implementation of the classic Minhash LSH scheme in Python and Cython. If you only need this and you don't need a database backend it can be a good choice.
- Datasketch implements an interesting collection of different data sketching algorithms for similarity matching, cardinality estimation and k-nearest-neighbour search. The implementation is not highly optimized but very well usable, the documentation rich and multiple database backends can be used for some of the sketches
- Milvus offers a full database stack for vector search, a different approach for fast searching. It can also be applied to text search when an emedding like Word2Vec or Bert is used to vectorize the text.
Credits
This package was created with Cookiecutter and the fedejaure/cookiecutter-modern-pypackage project template.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Hashes for narrow_down-0.9.1-cp37-abi3-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fe88704fbbc5ebb3a71834fa87e95484b6c7cec708a847df537a535569d2d1ce |
|
MD5 | 440d552f27c7f28c971998a2a83e36c6 |
|
BLAKE2b-256 | 5ff550fa9bc84c7ad46908064502a5d08d41fe846f2e903867cdd97991dfed71 |
Hashes for narrow_down-0.9.1-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d18ab19b2e636dfa72713e6713b055822fc635d0b1fdd58fa38a990d976a9dea |
|
MD5 | 2658d0d5182417d094a9928ce9e307e3 |
|
BLAKE2b-256 | 4ce424484604dee3d06ed471ca7ffdde272d2aa14ff8f43d674f846727c00a85 |
Hashes for narrow_down-0.9.1-cp37-abi3-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5433df7ec175123ac73191e5dc6473377979bbf9f39a670d39da45c6c8053bec |
|
MD5 | da0f2243d364180736daa39b91959025 |
|
BLAKE2b-256 | 9b8cfe4a2b1022c78ee478033a747abb67b1f1504e8b8127769d743fe911ade5 |