Fast Plaid.
Project description
FastPlaid
⚡️ Overview
Traditional vector search relies on single, fixed-size embeddings (dense vectors) for documents and queries. While powerful, this approach can lose nuanced, token-level details.
-
Multi-vector search, used in models like ColBERT or ColPali, replaces a single document or image vector with a set of per-token vectors. This enables a "late interaction" mechanism, where fine-grained similarity is calculated term-by-term to boost retrieval accuracy.
-
Higher Accuracy: By matching on a finer, token-level granularity, FastPlaid can capture relevance that single-vector models miss.
-
Performance: Written in Rust, it offers blazing-fast indexing and search speeds.
-
PLAID: stands for Per-Token Late Interaction Dense Search
💻 Installation
pip install fast-plaid
⚡️ Quick Start
Get started with creating an index and performing a search in just a few lines of Python.
import torch
from fast_plaid import search
fast_plaid = search.FastPlaid(index="index")
embedding_dim = 128
# Index 100 documents, each with 300 tokens, each token is a 128-dim vector
fast_plaid.create(
documents_embeddings=[torch.randn(300, embedding_dim) for _ in range(100)]
)
# Search for 2 queries, each with 50 tokens, each token is a 128-dim vector
scores = fast_plaid.search(
queries_embeddings=torch.randn(2, 50, embedding_dim),
top_k=10,
)
print(scores)
[
[
(20, 1334.5103759765625),
(91, 1299.576171875),
(59, 1285.788818359375),
(10, 1273.534912109375),
(62, 1267.9666748046875),
(44, 1265.5655517578125),
(15, 1264.426025390625),
(34, 1261.19775390625),
(19, 1261.0517578125),
(86, 1260.94140625),
],
[
(58, 1313.8587646484375),
(75, 1313.829833984375),
(79, 1305.322509765625),
(59, 1299.12158203125),
(55, 1293.456787109375),
(44, 1288.419189453125),
(67, 1283.658935546875),
(60, 1283.2884521484375),
(53, 1282.522216796875),
(9, 1280.863037109375),
],
]
Citation
FastPlaid is based on the original PLAID: Santhanam, Keshav, et al..
You can cite FastPlaid in your work as follows:
@misc{fastplaid2025,
author = {Sourty, Raphaël},
title = {FastPlaid: A High-Performance Engine for Multi-Vector Search},
year = {2025},
url = {https://github.com/lightonai/fast-plaid}
}
@inproceedings{santhanam2022plaid,
title={{PLAID}: an efficient engine for late interaction retrieval},
author={Santhanam, Keshav and Khattab, Omar and Potts, Christopher and Zaharia, Matei},
booktitle={Proceedings of the 31st ACM International Conference on Information \& Knowledge Management},
pages={1747--1756},
year={2022}
}
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fast_plaid-1.0.0-cp312-cp312-win_amd64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp312-cp312-win_amd64.whl
- Upload date:
- Size: 1.8 MB
- Tags: CPython 3.12, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
908d9d4e9befe23ca5541b88883f5bd5b44f430831d4418fdeb6470ff0b09bca
|
|
| MD5 |
da580d53e5b47d5cb5b75ca124927eb0
|
|
| BLAKE2b-256 |
697c3fcd40e42e5607ab5e3150e5d16d20cdb02b298dab9ad97de71311d85776
|
File details
Details for the file fast_plaid-1.0.0-cp312-cp312-manylinux_2_28_x86_64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp312-cp312-manylinux_2_28_x86_64.whl
- Upload date:
- Size: 2.0 MB
- Tags: CPython 3.12, manylinux: glibc 2.28+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f46d4dc577b44513e73daf3be4f92c2d06902d7b0a2182ced2162380ee2f5c87
|
|
| MD5 |
48a81650ec78c9aca7e635a32ff573ef
|
|
| BLAKE2b-256 |
f589c22f723ce154e27dc799c40dad5f324353f11f41b2eb4fd196a1244bb6ce
|
File details
Details for the file fast_plaid-1.0.0-cp312-cp312-macosx_11_0_arm64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp312-cp312-macosx_11_0_arm64.whl
- Upload date:
- Size: 1.5 MB
- Tags: CPython 3.12, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f28f61b6900cedb0777e8a5668fbb4a26722bb3ed220b37dc1af68e70f0f3624
|
|
| MD5 |
dbb938dc7d9924aa669d55e6299a6c49
|
|
| BLAKE2b-256 |
cf1556f74e2d7796c0c754b15f768cbbb77345986b291bf449068581db2ec893
|
File details
Details for the file fast_plaid-1.0.0-cp311-cp311-win_amd64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp311-cp311-win_amd64.whl
- Upload date:
- Size: 1.8 MB
- Tags: CPython 3.11, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2bd89ef9adf3f175c30910d5c49ce1c47ced48085468ee9a2ab1eb1727d4af00
|
|
| MD5 |
c346c420fbf8a356d4f580a8b0291b60
|
|
| BLAKE2b-256 |
aa129452a682130bd93b581b13b12a54855d645ecd1ed6d600d6485c885110e8
|
File details
Details for the file fast_plaid-1.0.0-cp311-cp311-manylinux_2_28_x86_64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp311-cp311-manylinux_2_28_x86_64.whl
- Upload date:
- Size: 2.0 MB
- Tags: CPython 3.11, manylinux: glibc 2.28+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e0fd7377f31a06b684b8c0466eb2e0b2579a66801132e27339379328d4715b56
|
|
| MD5 |
8ebab6ff616364b2a5dc70f8624a7b44
|
|
| BLAKE2b-256 |
04af638a50599145612685c5e4208a8d080786a940255c805a52d209e2811e86
|
File details
Details for the file fast_plaid-1.0.0-cp311-cp311-macosx_11_0_arm64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp311-cp311-macosx_11_0_arm64.whl
- Upload date:
- Size: 1.5 MB
- Tags: CPython 3.11, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
22783be0af0167d09971107702484a119589905f69f51db9f774f2dc37863032
|
|
| MD5 |
f144deac2f7bab5c0f4cc2da1c73d109
|
|
| BLAKE2b-256 |
707407e523e26b6ec6f1a488506b0fea0527b8239853ccb21db12a5edf20e8c8
|
File details
Details for the file fast_plaid-1.0.0-cp310-cp310-win_amd64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp310-cp310-win_amd64.whl
- Upload date:
- Size: 1.8 MB
- Tags: CPython 3.10, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3e41890f6571f9b37211332914389db9972c71802b9da13ed8d9d3f569b77e1e
|
|
| MD5 |
6b734c812e1214a1d7573589c7d4ea0d
|
|
| BLAKE2b-256 |
4d9b03965ccc5bc40387284fcbb686e2cd98e4cb58072afb022b1e7869ac4eb2
|
File details
Details for the file fast_plaid-1.0.0-cp310-cp310-manylinux_2_28_x86_64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp310-cp310-manylinux_2_28_x86_64.whl
- Upload date:
- Size: 2.0 MB
- Tags: CPython 3.10, manylinux: glibc 2.28+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7efbc44aa3afd2db8c6254998cc58369079ec18322e14582b5a4de8d0e082271
|
|
| MD5 |
4a5e81d64d612f8f4717c8c0ced19e22
|
|
| BLAKE2b-256 |
b3271c573dbad4e62e848d0efff4d562f4a852c27f1757f3f5f5ca60e4709e4c
|
File details
Details for the file fast_plaid-1.0.0-cp310-cp310-macosx_11_0_arm64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp310-cp310-macosx_11_0_arm64.whl
- Upload date:
- Size: 1.5 MB
- Tags: CPython 3.10, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d780485accc056922e48d4c92fc22ac88d61f8e377bcc8ccec6b0ad47d33f363
|
|
| MD5 |
2a9e8b4decccce74cf3177e6e1afa7f1
|
|
| BLAKE2b-256 |
87c1d4f97b2a625fcd928ac031b04a552fa1cae0f09cc6e243ec1a60f425a245
|
File details
Details for the file fast_plaid-1.0.0-cp39-cp39-win_amd64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp39-cp39-win_amd64.whl
- Upload date:
- Size: 1.8 MB
- Tags: CPython 3.9, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f5f06673f5256c095e3046e1ec92a59fdd0a8bac3f9944b5cf62d561bb25735b
|
|
| MD5 |
4f630e26028d2fd07d6710201200d89c
|
|
| BLAKE2b-256 |
db904275d118ff42c4c45aa1c4633738042eb4c584214234cea040ae80e2c07a
|
File details
Details for the file fast_plaid-1.0.0-cp39-cp39-manylinux_2_28_x86_64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp39-cp39-manylinux_2_28_x86_64.whl
- Upload date:
- Size: 2.0 MB
- Tags: CPython 3.9, manylinux: glibc 2.28+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6dbb8c7821beba1dbc96be3013d2468668ac030a3f49df2e4cd348363e4dd09a
|
|
| MD5 |
5dfb7ccedc5e3259b265dd4a91e72676
|
|
| BLAKE2b-256 |
f5735ae161eb8db869a92c3ffe503af967c43e8bb6c61bae0b515c6b1884977f
|
File details
Details for the file fast_plaid-1.0.0-cp39-cp39-macosx_11_0_arm64.whl.
File metadata
- Download URL: fast_plaid-1.0.0-cp39-cp39-macosx_11_0_arm64.whl
- Upload date:
- Size: 1.5 MB
- Tags: CPython 3.9, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1ce203a50d10d40a5c228ee637721e1f5404a19677628664ed3f20e50ec0db49
|
|
| MD5 |
76426905739052fa739d35897cc4dab1
|
|
| BLAKE2b-256 |
66f3c6b29ddcbfda09e6edf9f5e7c7de8419cc5ead367277509407a6178b6cba
|