Add Polars Support
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 34.7k
- Forks
- 2.7k
- Avg merge
- 1d 18h
- Merged PRs (30d)
- 187
Description
Is your feature request related to a problem? Please describe.
Qdrant has different search APIs (e.g. search, search batch, recommend,...), which is very cool. However, the data structure of the output if always slightly different (I'm working with the python client): a list of ScoredPoint, a list of list of ScoredPoint, groups for group searches...
However, I always use a dataframe for postprocessing operations, in particular when I work with tabular data and/or many payload fields. Hence I have to manually convert the data structures mentioned above in a dataframe, that often implies copying the data.
Though less problematic, also when uploading data to the DB, I often find myself having the data in a dataframe (including the embeddings), and I have to convert it to python data structures with the associated convertion cost.
Describe the solution you'd like
A clear and concise description of what you want to happen.
It would be nice to have a direct integration with a dataframe library like Polars (written in Rust, like Qdrant). The output of a search call is directly returned as a Polars dataframe. It would also be nice being able to directly upload the data from a dataframe to the DB.
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Manually converting the data to and from a dataframe.
Additional context
Add any other context or screenshots about the feature request here.
Polars (and Pandas 2.0) are built on top of the Apache Arrow columnar format. Supporting such a format could bring many advantages like zero copy operations and others (check: https://arrow.apache.org/).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No files, tests, or entry points are named. Start by tracing the Python client's search, search-batch, recommend, group-search, and upload APIs, then determine how Polars or Apache Arrow should represent each input and output shape. Done would require an agreed integration scope and tests covering dataframe reads and writes across these APIs.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python, rust
- Domain
- api, data
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100