seismic
Library Listed
Seismic is designed for effective and efficient KNN retrieval over learned sparse embeddings.
- Downloads
- 3
- Dependents
- 0
- Stars
- 141
- Forks
- 16
- Contributors
- 6
- Commits
- 609
- Latest release
- 0.2.1 ·
About

Seismic is a fast and lightweight search engine for learned sparse embeddings, written in Rust with Python bindings. It indexes sparse vector collections and retrieves results in microseconds with near-exact accuracy.
Requirements
- Python >= 3.8
- Rust toolchain (only needed if installing from source for hardware-specific optimizations)
Installation
The easiest way to use Seismic is via its Python API, which can be installed in two different ways:
- the easiest way is via pip as follows:
pip install pyseismic-lsr
- via Rust compilation that allows deeper hardware optimizations as follows (requires a working Rust toolchain, installable via rustup):
RUSTFLAGS="-C target-cpu=native" pip install --no-binary :all: pyseismic-lsr
Check docs/PythonUsage.md for more details.
Quick Start
Given a collection as a jsonl file, you can quickly index it by running
from seismic import SeismicIndex
json_input_file = "" # Your data collection
index = SeismicIndex.build(json_input_file)
print("Number of documents:", index.len)
print("Avg number of non-zero components:", index.nnz / index.len)
print("Dimensionality of the vectors:", index.dim)
index.print_space_usage_byte()
Read the full README
and then exploit Seismic to retrieve your set of queries quickly
import numpy as np
from seismic import get_seismic_string
string_type = get_seismic_string() # 'U100': fixed-width dtype for token strings
query = {"a": 3.5, "certain": 3.5, "query": 0.4}
query_id = "0"
query_components = np.array(list(query.keys()), dtype=string_type)
query_values = np.array(list(query.values()), dtype=np.float32)
results = index.search(
query_id=query_id,
query_components=query_components,
query_values=query_values,
k=10,
query_cut=3,
heap_factor=0.8,
)
Each document in the jsonl file should be a JSON object with an id (integer), an optional content (string), and a vector (dictionary mapping tokens to scores, e.g., {"dog": 2.45}). See docs/RunExperiments.md for full format details.
Features
- Multiple index variants — Standard (
SeismicIndex), compressed (SeismicIndexDotPacking8), and large vocabulary (SeismicIndexLV) for collections with >65K unique tokens - RAG-ready — Build the index with
load_content=Trueand retrieve document texts alongside scores (example) - Python & Rust APIs — Use from Python via
pyseismic-lsror integrate directly in Rust viacargo add seismic(docs) - Parallel batch search — Multi-threaded query processing via
batch_search
Examples
Interactive Jupyter notebooks are available in the examples/ folder:
- HandsOnSeismic.ipynb — Quick 2-minute overview of building and querying an index
- SeismicGuide.ipynb — Comprehensive guide covering all features: indexing, k-NN graphs, search, evaluation
- RAG.ipynb — Plug Seismic into a RAG pipeline with document content retrieval
- DotPacking8Index.ipynb — Memory-efficient compressed index variant
- LargeVocabulary.ipynb — Handling collections with large vocabularies (>65K tokens)
Comparison with the state-of-the-art
Comparison with Dynamic Superblock Pruning (DSP) using the splade-v3 encoding of the MS MARCO dataset.
| Index | MRR@10 | AQT (μs) | Memory (GB) |
|---|---|---|---|
| DSP | 40.28 | 745 | 24.0 |
| Seismic | 40.27 | 185 | 7.9 |
Experiments performed in single-threaded mode on an Intel Core Ultra 7265K CPU, equipped with 124 GB of RAM.
Best Results
Seismic is an approximate algorithm designed for high-performance retrieval over learned sparse representations. We provide pre-optimized configurations for several common datasets, e.g., MsMarco. Check the detailed documentation in docs/BestResults.md and the available optimized configurations in experiments/best_configs.
Resources
Check out our docs folder for detailed guides:
- PythonUsage.md - How to use the Seismic Python API.
- RustUsage.md - How to use Seismic directly in Rust.
- Guidelines.md - Step-by-step guide to build your Seismic index with hyperparameter tuning tips.
- BestResults.md - A detailed guide on how to replicate results with optimized configurations.
- RunExperiments.md - How to run custom experiments, download datasets, and data format details.
- TomlInstructions.md - TOML configuration reference.
Bibliography
Click to expand citations
- Sebastian Bruch, Franco Maria Nardini, Cosimo Rulli, and Rossano Venturini. "Efficient Inverted Indexes for Approximate Retrieval over Learned Sparse Representations." Proc. ACM SIGIR. 2024.
- Sebastian Bruch, Franco Maria Nardini, Cosimo Rulli, and Rossano Venturini. "Pairing Clustered Inverted Indexes with κ-NN Graphs for Fast Approximate Retrieval over Learned Sparse Representations." Proc. ACM CIKM. 2024.
- Sebastian Bruch, Franco Maria Nardini, Cosimo Rulli, Rossano Venturini, and Leonardo Venuta. "Investigating the Scalability of Approximate Sparse Retrieval Algorithms to Massive Datasets." Proc. ECIR. 2025.
- Bruch, Sebastian and Fontana, Martino and Nardini, Franco Maria and Rulli, Cosimo and Venturini, Rossano. "Forward Index Compression for Learned Sparse Retrieval", ECIR 2025 (to appear)
SIGIR 2024
@inproceedings{bruch2024seismic,
author = {Bruch, Sebastian and Nardini, Franco Maria and Rulli, Cosimo and Venturini, Rossano},
title = {Efficient Inverted Indexes for Approximate Retrieval over Learned Sparse Representations},
booktitle = {Proceedings of the 47th International {ACM} {SIGIR} {C}onference on Research and Development in Information Retrieval ({SIGIR})},
pages = {152--162},
publisher = {{ACM}},
year = {2024},
url = {https://doi.org/10.1145/3626772.3657769},
doi = {10.1145/3626772.3657769}
}
CIKM 2024
@inproceedings{bruch2024pairing,
author = {Bruch, Sebastian and Nardini, Franco Maria and Rulli, Cosimo and Venturini, Rossano},
title = {Pairing Clustered Inverted Indexes with $\kappa$-NN Graphs for Fast Approximate Retrieval over Learned Sparse Representations},
booktitle = {Proceedings of the 33rd International {ACM} {C}onference on {I}nformation and {K}nowledge {M}anagement ({CIKM})},
pages = {3642--3646},
publisher = {{ACM}},
year = {2024},
url = {https://doi.org/10.1145/3627673.3679977},
doi = {10.1145/3627673.3679977}
}
ECIR 2025
@inproceedings{bruch2025investigating,
author = {Bruch, Sebastian and Nardini, Franco Maria and Rulli, Cosimo and Venturini, Rossano and Venuta, Leonardo},
title = {Investigating the Scalability of Approximate Sparse Retrieval Algorithms to Massive Datasets},
booktitle = {Advances in Information Retrieval},
pages = {437--445},
publisher = {Springer Nature Switzerland},
year = {2025},
url = {https://doi.org/10.1007/978-3-031-88714-7_43},
doi = {10.1007/978-3-031-88714-7_43}
}
ECIR 2026 (Accepted, to appear)
@article{bruch2026forward,
title={Forward Index Compression for Learned Sparse Retrieval},
author={Bruch, Sebastian and Fontana, Martino and Nardini, Franco Maria and Rulli, Cosimo and Venturini, Rossano},
journal={European Conference on Information Retrieval 2026 (to appear)},
year={2026}
}
Journal of ACM (Under Review)
@article{bruch2025efficient,
title={Efficient Sketching and Nearest Neighbor Search Algorithms for Sparse Vector Sets},
author={Bruch, Sebastian and Nardini, Franco Maria and Rulli, Cosimo and Venturini, Rossano},
journal={arXiv preprint arXiv:2509.24815},
year={2025}
}
Citation License
The source code in this repository is subject to the following citation license:
By downloading and using this software, you agree to cite the papers listed in the Bibliography section above in any kind of material you produce where it was used to conduct a search or experimentation, whether be it a research paper, dissertation, article, poster, presentation, or documentation. By using this software, you have agreed to the citation license.
Compatibility
- Runs on
- GPU support unknown
What shows it
- no dependency or feature matches a backend row
- Native code
- None found
- No native code found
- Python bindings
- Has Python bindings
- seismic needs Python
- License
- MIT
Compare with similar projects
Order: strongest tier first, then most downloads, then name, with unmeasured values last. A library counts downloads over 30 days. An app counts binary downloads per release. An app with none counts its crate downloads over 30 days. ML Rust runs this catalogue, so its closest project always gets a row.
| Project | Downloads | Dependents | Stars | Latest release | Runs on (GPU) | Native code | License |
|---|---|---|---|---|---|---|---|
|
Seismic is designed for effective and efficient KNN retrieval over learned sparse embeddings. Python bindings |
3 downloads over 30 days | 0 | 141 | 0.2.1 | GPU support unknown | No native code found | MIT |
|
kiddo Featured
A high-performance, flexible, ergonomic k-d tree library. Ideal for geo- and astro- nearest-neighbour and k-nearest-neighbor queries |
481,504 downloads over 30 days | 56 | 179 | 6.3.0 | GPU support unknown | Build uses a native toolchain: cc (feature cpp_competitors) | Apache-2.0 OR MIT |
|
kdtree-rs Featured
K-dimensional tree in Rust for fast geospatial indexing and nearest neighbors lookup |
388,481 downloads over 30 days | 29 | 286 | 0.8.1 | GPU support unknown | No native code found | Apache-2.0 OR MIT |
|
Qdrant - High-performance, massive-scale Vector Database and Vector Search Engine for the next generation of AI. Also available in the cloud https://cloud.qdrant.io/ |
34,017 binary downloads per release | Not applicable | 35,478 | Not measured | Not measured | Apache-2.0 | |
|
Postgres extension for vector search (DiskANN), complements pgvector for performance and scale. Postgres OSS licensed. |
33,328 binary downloads per release | Not applicable | 3,161 | Not measured | Not measured | PostgreSQL | |
|
splintr Listed
Tokenizer for Rust and Python: pure Rust by default, with 18 bundled vocabularies and four backends covering BPE, SentencePiece and WordPiece. Its output matches Hugging Face tokenizers id for id on 14 model families, including GPT-2, Qwen, Whisper, T5 and BERT. Python bindings |
8,204 downloads over 30 days | 7 | 63 | 0.22.2 | GPU support unknown | Binds native code: pcre2-sys (feature pcre2) | MIT |
|
In-memory vector store with efficient read and write performance for semantic caching and retrieval system. Redis for Semantic Caching. |
0 binary downloads per release | Not applicable | 376 | Not measured | Not measured | Apache-2.0 |
Why ListedNo archive, New or Featured rule places it, so it is Listed.
What it lacks for Featured
- It has 0 active dependents and 0 new dependents in 365 days. Featured needs 11 active dependents or 9 new dependents in 365 days. The repository route reads 141 stars, 16 forks and 6 contributors. It needs 4,539 stars, 434 forks and 79 contributors together.
What else the check found
- The last activity is on 26 Oct 2026, 14 days ago. The rules expect an update within 365 days. Dormancy rule
- The oldest outside issue waits 622 days for a reply, past the limit of 270. No maintainer replied in 365 days. Rot signals rule
- The latest release requires the deprecated dependency bincode. RUSTSEC-2025-0141 Rot signals rule
Exact rules: Listed, Featured library. The check on applied thresholds version 9.
Every rule outcome, as the check records it
expected-interval: version 0.2.1 base 300, capped at 2 releases = 100, raised to the 365-day floor: E = 365 daysdormancy: last activity 2026-10-26, 14 days ago, E = 365: activerot: oldest unanswered issue 622 days (limit 270), no maintainer reply in 365 daysrot: deprecated requirement `bincode (RUSTSEC-2025-0141, https://rustsec.org/advisories/RUSTSEC-2025-0141.html)`featured: not featured: active_users 0 < 11 and new_adopters 0 < 9 and repository route stars 141 (needs 4539), forks 16 (needs 434), contributors 6 (needs 79)listed: listed: no archive, new or featured rule applies
Measurements and sources
Each signal row shows the raw value, its source and the fetch date. The Sources list gathers every distinct source on this page. Movement needs more history.
Sources6 sources
- Description: the crates.io description
- crates.io database dump, fetched
- RustSec advisory database, fetched
- GitHub repository, fetched
- crates.io package, fetched
- GitHub contributors, fetched
Adoption0 active dependents, 0 new dependents in 365 days1 not measured
| Signal | Value | Source | Fetched | Counts |
|---|---|---|---|---|
| Active dependents | 0 | crates.io database dump | Yes | |
| New dependents (365 days) | 0 | crates.io database dump | Yes | |
| Peak active dependents | 0 | crates.io database dump | Yes | |
| Active dependents as a share of the peak | 1 | crates.io database dump | Yes | |
| Binary downloads per release | Not measured | Yes |
MaintenanceLatest human commit: 14 days ago3 not measured
| Signal | Value | Source | Fetched | Counts |
|---|---|---|---|---|
| Latest human commit | 2026-10-26 | GitHub repository | Yes | |
| Latest release | 2025-03-05 | crates.io database dump | Yes | |
| First release | 2024-07-04 | crates.io database dump | Yes | |
| Latest version | 0.2.1 | crates.io database dump | Yes | |
| Days the oldest outside issue waits for a reply | 622 | GitHub repository | Yes | |
| Maintainer replies over 365 days | 0 | GitHub repository | Yes | |
| Repository archived | false | GitHub repository | Yes | |
| Repository gone | false | GitHub repository | Yes | |
| Release commit or manifest in the repo | true | crates.io package | Yes | |
| Published docs | true | crates.io database dump | Yes | |
| Latest release fails cargo check | Not measured | Yes | ||
| Build check date | Not measured | Yes | ||
| Build check toolchain | Not measured | Yes |
SecurityUnpatched vulnerabilities: none
| Signal | Value | Source | Fetched | Counts |
|---|---|---|---|---|
| Unpatched vulnerabilities past the grace window | none | RustSec advisory database | Yes | |
| RustSec unmaintained advisory | none | RustSec advisory database | Yes | |
| Deprecation notice | none | crates.io database dump | Yes | |
| Deprecated requirement | bincode (RUSTSEC-2025-0141, https://rustsec.org/advisories/RUSTSEC-2025-0141.html) | crates.io database dump | Yes |
Distribution2 releases, 3 downloads over 30 days5 not measured
| Signal | Value | Source | Fetched | Counts |
|---|---|---|---|---|
| Releases | 2 | crates.io database dump | Yes | |
| Downloads over 30 days | 3 | crates.io database dump | Yes | |
| Binary downloads over the last 3 releases | Not measured | Yes | ||
| Homebrew installs on request over 365 days | Not measured | Yes | ||
| Repology repository families | Not measured | Yes | ||
| Docker pull growth over 90 days | Not measured | Yes | ||
| Docker pulls at the growth baseline | Not measured | Yes | ||
| Every version a prerelease | false | crates.io database dump | Yes | |
| Every version 0.0.x | false | crates.io database dump | Yes | |
| Every version yanked | false | crates.io database dump | Yes | |
| Crate deleted from crates.io | false | crates.io database dump | Yes |
Repository141 stars, 16 forks, 6 contributors, 609 commits. Stars alone never qualify a project.
| Signal | Value | Source | Fetched | Counts |
|---|---|---|---|---|
| GitHub stars | 141 | GitHub repository | Yes — one part of the repository route | |
| GitHub forks | 16 | GitHub repository | Yes — one part of the repository route | |
| Contributors with a GitHub account | 6 | GitHub contributors | Yes — one part of the repository route | |
| Commits on the default branch | 609 | GitHub repository | No | |
| Repository's main crate left out of the entry | none | crates.io database dump | Yes |
Facts that never count
| Signal | Value | Source | Fetched | Counts |
|---|---|---|---|---|
| License | MIT | crates.io database dump | No | |
| Runs on, from listed crates and their direct dependencies | GPU support unknown | crates.io database dump | No | |
| What shows each backend | no dependency or feature matches a backend row | crates.io database dump | No | |
| Native code, from listed crates and their dependencies | No native code found | crates.io database dump | No | |
| Python bindings, from direct dependencies of listed crates | Has Python bindings: seismic needs Python | crates.io database dump | No | |
| Crates that depend on a listed crate directly | 0 | crates.io database dump | No |
Corrections and review history
No correction applies to this entry.
Judgments
A judgment enters only through an approved issue and a merged pull request.
No judgment applies to this entry.