Metadata-Version: 2.4
Name: seecr-sil
Version: 3.4.0
Summary: Seecr Indexing Lib: search, sorting, drilldown and suggestions on tantivy
Author-email: Thijs Janssen <thijs@seecr.nl>, Johan Jonkers <johan@seecr.nl>
License-Expression: MIT
Project-URL: Documentation, https://github.com/seecr/sil/blob/master/doc/reference.md
Project-URL: Source, https://github.com/seecr/sil
Project-URL: Issues, https://github.com/seecr/sil/issues
Project-URL: Changelog, https://github.com/seecr/sil/blob/master/CHANGELOG.md
Keywords: search,index,full-text,tantivy,drilldown,facets,cql,seecr
Classifier: Development Status :: 5 - Production/Stable
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Operating System :: POSIX
Classifier: Intended Audience :: Developers
Classifier: Topic :: Database
Classifier: Topic :: Text Processing :: Indexing
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.11
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: tantivy<0.28,>=0.27.0
Dynamic: license-file

# sil – Seecr Indexing Lib

A search index for Python applications, on [tantivy](https://github.com/quickwit-oss/tantivy):
an index profile in Python, a forgiving query language, sorting on several fields,
drilldown (counts per value), suggestions while typing, and commits on a timer. One index
is one directory; no server, no JVM.

```python
from sil.index import Index
from sil.indexfield import IndexField
from sil.indexprofile import IndexProfile

index = Index(path, IndexProfile([
    IndexField.unqualified("all"),
    IndexField.untokenized("genre", drilldown=True),
    IndexField.int("year", sortable=True),
]), immediate_commit=True)

index.add_record("book-1", {"all": "Dune Frank Herbert", "genre": "sf", "year": 1965})
index.search_query("dune", sort="year", drilldown=[{"name": "genre"}])
# {"count": 1, "docs": [{"__id__": "book-1"}], "drilldown": {"genre": [("sf", 1)]}}
```

Install with `pip install seecr-sil` (the package is `sil`). It needs Python 3.11 or
newer and tantivy.

The [reference](https://github.com/seecr/sil/blob/master/doc/reference.md) describes
everything; the [changelog](https://github.com/seecr/sil/blob/master/CHANGELOG.md) says
what changed. sil was built on Lucene (through JCC) up to 2.x; 3.0 replaced it with
tantivy.

MIT licensed, see [LICENSE](https://github.com/seecr/sil/blob/master/LICENSE). By
[Seecr](https://seecr.nl).
