Addok-trigrams
Alternative indexation pattern for Addok, based on trigrams.
Installation
pip install addok-trigrams
Configuration
In your local configuration file:
-
remove unwanted RESULTS_COLLECTORS_PYPATHS:
from addok.config.default import RESULTS_COLLECTORS_PYPATHS RESULTS_COLLECTORS_PYPATHS.remove('addok.helpers.collectors.extend_results_reducing_tokens') RESULTS_COLLECTORS_PYPATHS.remove('addok.autocomplete.only_commons_but_geohash_try_autocomplete_collector') RESULTS_COLLECTORS_PYPATHS.remove('addok.autocomplete.no_meaningful_but_common_try_autocomplete_collector') RESULTS_COLLECTORS_PYPATHS.remove('addok.autocomplete.only_commons_try_autocomplete_collector') RESULTS_COLLECTORS_PYPATHS.remove('addok.autocomplete.autocomplete_meaningful_collector') RESULTS_COLLECTORS_PYPATHS.remove('addok.fuzzy.fuzzy_collector') -
remove all
autocompleteandfuzzyRESULTS_COLLECTORS_PYPATHS, add new ones:RESULTS_COLLECTORS_PYPATHS += [ 'addok_trigrams.extend_results_removing_numbers', 'addok_trigrams.extend_results_removing_one_whole_word', 'addok_trigrams.extend_results_removing_successive_trigrams', ] -
add
trigramizeto PROCESSORS_PYPATHS:from addok.config.default import PROCESSORS_PYPATHS PROCESSORS_PYPATHS += [ 'addok_trigrams.trigramize', ] -
remove pairs and autocomplete indexers from
INDEXERS_PYPATHS:from addok.config.default import INDEXERS_PYPATHS INDEXERS_PYPATHS.remove('addok.pairs.PairsIndexer') INDEXERS_PYPATHS.remove('addok.autocomplete.EdgeNgramIndexer')
By default, digit only words are not turned into trigrams. To prevent this,
set TRIGRAM_SKIP_DIGIT=False.
Usage
Use addok batch just like with genuine addok for importing documents, but no
need for running addok ngrams, given they are already part of the index
strategy.
Metadata
Release files for addok-trigrams 1.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| addok-trigrams-1.1.1.tar.gz | 3.3 kB | Without provenance | Details for addok-trigrams-1.1.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| addok_trigrams-1.1.1-py3-none-any.whl | Python 3 | none | any | Details for addok_trigrams-1.1.1-py3-none-any.whl |
Total release size: 6.7 kB
Release files / addok-trigrams-1.1.1.tar.gz
| Download URL | addok-trigrams-1.1.1.tar.gz |
|---|---|
| Size | 3.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7a7a0f3055f83e2c27b2fb5df2292317f707326b56bb1020e420e63dd1875ef0
|
|
BLAKE2b-256 checksum How to use checksums |
d275e118256b0042a35914f3063ac4efe0237d525e6a0a5c138ec4f6b18679cb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / addok_trigrams-1.1.1-py3-none-any.whl
| Download URL | addok_trigrams-1.1.1-py3-none-any.whl |
|---|---|
| Size | 3.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
af2bb4b87cd116ab92da2b2e658cddcb894d438e83c58b0482c9fd92ba4752dd
|
|
BLAKE2b-256 checksum How to use checksums |
effa883eb846c6c26bcaeae3256e9c7e326d1765c1011c04d84f5d29f9aae23e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for addok-trigrams 1.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.