freshcrate
Home > Databases > qdrant-client

qdrant-client

Client library for the Qdrant vector search engine

Description

<p align="center"> <picture> <source media="(prefers-color-scheme: dark)" srcset="https://github.com/qdrant/qdrant/raw/master/docs/logo-dark.svg"> <source media="(prefers-color-scheme: light)" srcset="https://github.com/qdrant/qdrant/raw/master/docs/logo-light.svg"> <img height="100" alt="Qdrant" src="https://github.com/qdrant/qdrant/raw/master/docs/logo.svg"> </picture> </p> <p align="center"> <b>Python Client library for the <a href="https://github.com/qdrant/qdrant">Qdrant</a> vector search engine.</b> </p> <p align=center> <a href="https://pypi.org/project/qdrant-client/"><img src="https://badge.fury.io/py/qdrant-client.svg" alt="PyPI version" height="18"></a> <a href="https://api.qdrant.tech/"><img src="https://img.shields.io/badge/Docs-OpenAPI%203.0-success" alt="OpenAPI Docs"></a> <a href="https://github.com/qdrant/qdrant-client/blob/master/LICENSE"><img src="https://img.shields.io/badge/License-Apache%202.0-success" alt="Apache 2.0 License"></a> <a href="https://qdrant.to/discord"><img src="https://img.shields.io/badge/Discord-Qdrant-5865F2.svg?logo=discord" alt="Discord"></a> <a href="https://qdrant.to/roadmap"><img src="https://img.shields.io/badge/Roadmap-2025-bc1439.svg" alt="Roadmap 2025"></a> </p> # Python Qdrant Client Client library and SDK for the [Qdrant](https://github.com/qdrant/qdrant) vector search engine. Library contains type definitions for all Qdrant API and allows to make both Sync and Async requests. Client allows calls for all [Qdrant API methods](https://api.qdrant.tech/) directly. It also provides some additional helper methods for frequently required operations, e.g. initial collection uploading. See [QuickStart](https://qdrant.tech/documentation/quick-start/#create-collection) for more details! ## Installation ``` pip install qdrant-client ``` ## Features - Type hints for all API methods - Local mode - use same API without running server - REST and gRPC support - Minimal dependencies - Extensive Test Coverage ## Local mode <p align="center"> <!--- https://github.com/qdrant/qdrant-client/raw/master --> <img max-height="180" src="https://github.com/qdrant/qdrant-client/raw/master/docs/images/try-develop-deploy.png" alt="Qdrant"> </p> Python client allows you to run same code in local mode without running Qdrant server. Simply initialize client like this: ```python from qdrant_client import QdrantClient client = QdrantClient(":memory:") # or client = QdrantClient(path="path/to/db") # Persists changes to disk ``` Local mode is useful for development, prototyping and testing. - You can use it to run tests in your CI/CD pipeline. - Run it in Colab or Jupyter Notebook, no extra dependencies required. See an [example](https://colab.research.google.com/drive/1Bz8RSVHwnNDaNtDwotfPj0w7AYzsdXZ-?usp=sharing) - When you need to scale, simply switch to server mode. ## Connect to Qdrant server To connect to Qdrant server, simply specify host and port: ```python from qdrant_client import QdrantClient client = QdrantClient(host="localhost", port=6333) # or client = QdrantClient(url="http://localhost:6333") ``` You can run Qdrant server locally with docker: ```bash docker run -p 6333:6333 qdrant/qdrant:latest ``` See more launch options in [Qdrant repository](https://github.com/qdrant/qdrant#usage). ## Connect to Qdrant cloud You can register and use [Qdrant Cloud](https://cloud.qdrant.io/) to get a free tier account with 1GB RAM. Once you have your cluster and API key, you can connect to it like this: ```python from qdrant_client import QdrantClient qdrant_client = QdrantClient( url="https://xxxxxx-xxxxx-xxxxx-xxxx-xxxxxxxxx.us-east.aws.cloud.qdrant.io:6333", api_key="<your-api-key>", ) ``` ## Inference API Qdrant Client has Inference API that allows to seamlessly create embeddings and use them in Qdrant. Inference API can be used locally with FastEmbed or remotely with models available in Qdrant Cloud. ### Local Inference with FastEmbed ``` pip install qdrant-client[fastembed] ``` FastEmbed is a library for creating fast vector embeddings on CPU. It is based on ONNX Runtime and allows to run inference both on CPU and GPU. Qdrant Client can use FastEmbed to create embeddings and upload them to Qdrant. This allows to simplify API and make it more intuitive. ```python from qdrant_client import QdrantClient, models # running qdrant in local mode suitable for experiments client = QdrantClient(":memory:") # or QdrantClient(path="path/to/db") for local mode and persistent storage model_name = "sentence-transformers/all-MiniLM-L6-v2" payload = [ {"document": "Qdrant has Langchain integrations", "source": "Langchain-docs", }, {"document": "Qdrant also has Llama Index integrations", "source": "LlamaIndex-docs"}, ] docs = [models.Document(text=data["document"], model=model_name) for data in payload] ids = [42, 2] client.create_collection( "demo_collection", vectors_config=models.Vect

Release History

VersionChangesUrgencyDate
1.17.1Imported from PyPI (1.17.1)Low4/21/2026
v1.17.1# Change Log ## Features 🌊 * #1162 - add a way to provide custom headers in http and grpc by @Anush008 @joein * #1166 - do not use fastembed for bm25 inference with hosted qdrant by @joein ## Fixes 🔧 * #1169 - do not modify date filters in local mode by @jnMetaCode * #1168 - run server version check in a thread to avoid blocking async client by @joein * #1157 - fix type hint error in grpc_uploader with older versions of protobuf by @joein Thanks to everyone who contributeLow3/13/2026
v1.17.0# Change Log ## Features ðŸšĒ * #1154 - introduce relevance feedback, add enable_hnsw option to payload indexes, add timeouts to upsert methods, weighted RRF, and more by @joein @coszio @generall ## Fixes ⚙ïļ * #1138 - fix score threshold for fusion queries by @cbcoutinho Thanks to everyone who contributed to the current release! @cbcoutinho @generall @coszio @joein Low2/19/2026
v1.16.2# Change Log ## Deprecations âģ * #1110 - drop python3.9 support by @joein ## Fixes ⚙ïļ * #1132- adjust numpy versioning by @joein * #1133 - propagate `lookup_from` correctly in query_points_groups by @joein * #1134 - fix qdrant-client import in read-only systems by @holyMolyTolli Thanks to everyone who contributed to the current release! @holyMolyTolli @joein Low12/12/2025
v1.16.1# Change Log ## Features 🊐 * #1116 - implement grpc version of `cluster_collection_update` by @joein * #1123 - expose the remaining cluster methods: `remove_peer`, `collection_cluster_info`, `recover_current_peer`, `cluster_status` by @joein ## Fixes ðŸ˜Ū * #1125 - rename `common.proto` to `qdrant_common.proto` to avoid conflicts with other libraries by @joein * #1124 - fix local mode with persistence backward compatibility by @joein * #1121 - add .pyi files for grpc files to hLow11/25/2025
v1.16.0# Change Log ## Features 🊐 * #1060 - builtin BM25 support (fastembed is not longer required to generate bm25 embeddings) by @joein * #1071 - grpc connection pooling by @JojiiOfficial * #1088 - queryless scores is now equal to 1 by @joein * #1077 - pass grpc credentials to grpc channels by @ivandasch @joein * #1085 - allow passing UUID to all methods without converting to strings by @joein * #1069 - add `TextAny` filter, `metadata` to collections, add parametrized rrf query, ACLow11/17/2025
v1.15.1# Change Log ## Fixes 🚒 * #1051 - fix grpc FieldCondition conversion by @coszio * #1052 - fix conversion for Document, Image and InferenceObject by @joein * #1053 - fix handling cloud inference responses by @joein Thanks to everyone who contributed to the release! @coszio @joein Low7/31/2025
v1.15.0# Change Log ## Features 🌟 * #1031 - add base64 encoding function to convert images for inference @joein * #1044 - added MMR (maximal margin relevance) @coszio @joein @generall ## Fixes ðŸŒĩ * #1030 - fix edge case in upsert and multivector updates @joein * #1034 - relax portalocker version by @kurtqq Thanks to everyone who contributed to the release! @kurtqq @coszio @generall @joein Low7/31/2025
v1.14.3# Change Log ## Features ðŸŽļ * #994 - add convenience methods like `list_text_models`, `list_image_models`, etc to fastembed mixin by @joein * #1024 - do not inspect models when cloud inference is enabled by @joein ## Fixes ðŸŒĩ * #990 - fix docstrings in models to get rid of invalid escape sequence warnings in python3.12+ by @joein * #977 - fix set payload in batch update points, fix operation conversion, set payload key handling, vector normalization in update operations by @joLow6/16/2025
v1.14.2# Change Log ## Fixes 🧄 * #966 - do not raise an exception in local mode on attempting to search for sparse vectors with IDF * #959 - fix deduplication of results when using order_by * #967 - fix query_batch_points behaviour in local mode with some queries when limit was not provided * #965 - fix local inference on queries with a list of prefetches, reduce the amount of inspections on vectors Thanks to everyone who contributed to this release! @coszio @joein Low4/24/2025
v1.14.1# Change Log ## Features ðŸ’Ĩ * #862 #907 #908 - native inference support in all QdrantClient's methods via seamless integration with Fastembed by @joein * #915 - support server side score boosting by @coszio * #940 - add new recommend strategy `sum_score` by @joein * #896 - delete grpcio-tools from dependencies, require just protobuf by @joein * #903 - extend strict mode settings by @generall @agourlay * #905 - make vectors config optional in order to create collections without denLow4/22/2025
v1.13.0# Change Log ## Features 📖 * #838 #836 #842 #845 #846 #847 - local inference support: raw data like texts and images can now be passed to all the methods like upsert, query_points, etc. instead of vectors by @joein * #849 - python3.13 support by @joein * #835 - propagate gpu options to fastembed models by @joein * #852 #859 #864 - improve warning coverage by @hh-space-invader @tellet-q * #861 - make qdrant server aware of client version by @tellet-q ## Fixes 🐛 * #840 - propeLow1/17/2025
v1.12.2# Change Log ## Features - #870 updated fastembed to 0.5.0 - #870 removed support for python3.8 Low1/3/2025
v1.12.1# Change Log ## Bug Fixes 🐌 * #810 - fix distance matrix api in local mode with the default vector by @joein * #812 - fix plain prefetch conversion to grpc by @joein * #812 - fix query batch points offset in local mode by @joein * #813 - raise an error on attempt to insert a non-existing named vector in local mode by @hh-space-invader * #817 - fix DBSF rescoring on empty response in local mode by @joein * #816 - fix resolving prefetch in local mode by @joein Thanks to everyLow10/29/2024
v1.12.0# Change Log ## Features ðŸŠķ * #759 - Facets API by @coszio * #767 - Distance matrix API by @agourlay * #804 - add mmap geo index by @joein ## Bug Fixes ðŸĶŸ * #797 - fix query embeddings for sparse models by @hh-space-invader * #800 - fix async grpc info call by @joein * #802 - add local_files_only to sparse embeddings by @joein Thanks to everyone, who've contributed to this release! @agourlay @coszio @hh-space-invader @generall @joein Low10/22/2024
v1.11.3# Change Log ## Bug Fixes ðŸĶŸ * #787 - fix update vectors in local mode by @joein * #785 - fix creating shard key in async grpc client by @joein @VanaMartin * #790 - fix conversion of sharding method in collection params by @joein * #782 - replace np.NINF with np.inf in local mode for numpy v2.x by @icfly2 * #791 - fix cluster collection info by making resharding operations field optional by @joein Thanks to everyone, who've contributed to this release! @VanaMartin @icfly2 @jLow9/24/2024
v1.11.2# Change Log ## Bug Fixes 🊰 * #763 - handle tuple conversion in grpc by @hh-space-invader * #772 - fix nested prefetch in local mode by @paul2302 @hh-space-invader * #773 - fix rest get_collection call for a collection with grpc-built payload indices, make parametrized integer index params optional by @joein * #775 - fix `with_vectors` in local mode when retrieving by default vector name by @joein Thanks to everyone, who've contributed to this release! @paul2302 @hh-spacLow9/19/2024
v1.11.1# Change Log ## Features ðŸ“Ē * #753 - update `fastembed` to 0.3.6 ## Bug Fixes ðŸŠē * #748 - fix `modifier.None` conversion by @joein * #750 - fix parametrized payload indices conversion by @joein ## Deprecations âģ * #742 - deprecate `rest` property in `QdrantRemote` in favour of `http` by @hh-space-invader * #740 - deprecate async grpc fixtures in `QdrantClient` in favour of `AsyncQdrantClient` by @hh-space-invader Thanks to everyone, who've contributed to this reLow8/26/2024
v1.11.0# Change Log ## Features ðŸ“Ē * #541 - added init_options property to recreate qdrant client instances from an existing one by @Anush008 * #686 - add bm42 and bm25 models support for `add` and `query` methods by @joein * #706 - add retry mechanism to `migrate` by @hh-space-invader * #678 - add info endpoint by @joein * #690 - add query points group api by @agourlay @coszio * #703 - add distribution based score fusion by @coszio * #705 - add random sampling mechanism by @coszio Low8/13/2024
v1.10.1# Change log ## Bug fixes 🐞 * https://github.com/qdrant/qdrant-client/pull/674 - fix gRPC sparse vector params conversion * https://github.com/qdrant/qdrant-client/pull/682 - fix gRPC conversion in `query_points` for flat structures * https://github.com/qdrant/qdrant-client/pull/682 - fix gRPC conversion during named multivectors uploadLow7/8/2024
v1.10.0# Change Log ## Features :tiger: * Universal query API - [[Docs](https://qdrant.tech/documentation/concepts/search/#query-api)] * Support search, recommendations, discovery, ordering by payload in a single request * Perform [hybrid search](https://qdrant.tech/documentation/concepts/hybrid-queries/#hybrid-search) by merging results from different queries with fusion * Build [multi-stage](https://qdrant.tech/documentation/concepts/hybrid-queries/#multi-stage-queries) queries Low7/8/2024
v1.9.2# Changelog ## Features 🊄 - #612 Add gpu support for fastembed and possibility to set onnx providers by @joein - #623 Replace black with ruff by @generall ## Fixes 🊛 - #627 Save and return copies of data in local mode by @joein - #637 Allow string `RecommendStrategy` with grpc by @coszio - #640 Fix integer index grpc conversion by @joein - #646 Fix boolean filters when using pydantic<2.6 by @joein Thanks to everyone who contributed to the current release: @generall @coLow6/20/2024
v1.9.1# Changelog ## Fixes 🊛 - #617 - fix local mode geo box for antimeridian crossing - #619 - fix incorrect display of QdrantClient's docstring Thanks to everyone who contributed to the current release: @agourlay @Anush008 Low5/3/2024
v1.9.0# Changelog ## Features 🊄 - #571 add discovery and recommendations api support for sparse vectors in local mode - #594 restrict access to the methods on a closed instance in local mode - #591 add a possibility to use auth token providers - #608 introduce support for uint8 vectors - #603 allow having nan values in payload in local mode --- ## Fixes 🊛 - #559 - fix update_vectors in local mode with sparse vectors - #562 - fix handling of wrong types in search in local mode - #56Low4/22/2024
v1.8.2# Changelog ## Fixes 🊛 - remove redundant `pytest` import which prevented `qdrant-client` import without `pytest` being installed by @joein Low3/28/2024
v1.8.1# Changelog ## Features 🊄 - update fastembed integration, incorporate hybrid search into `add` method #553 by @generall @joein --- ## Fixes 🊛 - fix excess upsert requests in `upload_collection` and `upload_points` #531 by @almostimplemented - allow set payload with a nested key #536 by @joein - add missing datetime formats to local mode #537 by @joein - fix congruence for naive and aware datetime in local mode #538 by @joein - propagate timeouts from methods to httpx #534 by @Low3/27/2024
v1.8.0# Changelog --- ## Features 🊄 - add `order_by` functionality to `scroll` #491 by @coszio - add grpc compression options to QdrantClient #480 by @geetu040 - add datetime ranges support #517 by @coszio - add min should clause #519 by @joein - add collection exists api #518 by @joein - update fastembed integration #493 #522 #524 @NirantK @joein @Anush008 --- ## Fixes 🊛 - fix potential edge case in scoring in context search #474 by @coszio - close lock file explicitly in loLow3/6/2024
v1.7.3- fix `search_batch` with sparse vectors in grpc #484 by @agourlay - align `close` method signature between `QdrantClient` and `QdrantRemote` #477 by @joein Low2/8/2024
v1.7.2Bugfix release 💊 - fix parallel and bugs with implicit ids in `upload_collection`, `upload_records`, `upload_points` #460 - fix setting `grpc_options` with `https` in `sync` mode, and with `http+api-key` in `async` mode #467 - fix extend json validation in local mode to fix backward compatibility issue with types like `datetime` and `uuid` #462 Low1/31/2024
v1.7.1# Changelog --- ## Features 🊄 - exposed _gRPC_ options #401 - support setting custom shard key in `upload_collection` and `upload_points` #396 - unlocked python dependency upper cup #419 - unlocked `urllib3` v2 #418 - ease access to `fastembed` models #412 - extend access for `fastembed` configuration #416 --- ## Fixes 🊛 - replaced `httpx` _data_ with _content_ #426 - forbid having _NaN_ in payload in `local mode` #397 - fix python warning which was sometimes emitted on garLow1/19/2024
v1.7.0# Changelog --- ## Features * Add Discovery API ([docs](https://qdrant.tech/documentation/concepts/explore/#discovery-api)) - https://github.com/qdrant/qdrant-client/pull/368 by @coszio - **Discovery search**: Uses a target and context pairs to limit the search space during the search - **Context search**: Using only the context pairs, get the points that live in the best zone * Add Sparse vectors support ([docs](https://qdrant.tech/documentation/concepts/collections/#collection-wiLow12/8/2023
v1.6.2# Changelog * Missing fix form previous release: https://github.com/qdrant/qdrant-client/pull/338 - add missing parameters in recommend batch APILow10/16/2023
v1.6.1# Changelog ## Features * Proper support for Async client - https://github.com/qdrant/qdrant-client/pull/319 * Now all methods of regular qdrant client are available in async version. * All method names, parameters and return types are preserved. * Both gRPC and REST version are available. * Improvements of [fastembed](https://github.com/qdrant/fastembed) integration: * Support the latest v0.1.x version of fastembed: https://github.com/qdrant/fastembed/releases/tag/0.1.0Low10/16/2023
v1.6.0# Changelog ## Imptovements * Support for Qdrant 1.6.x features * https://github.com/qdrant/qdrant-client/pull/325 - geo polygons filtering * https://github.com/qdrant/qdrant-client/pull/314 - recommendation API * Support for python 3.12 * Integration of FastEmbed v0.0.5 - https://github.com/qdrant/fastembed/releases/tag/0.0.5 ## Bug fixes * https://github.com/qdrant/qdrant-client/pull/330 - fix usage of write ordering parameter * https://github.com/qdrant/qdrant-client/pulLow10/9/2023
v1.5.0# Changelog ## Features * https://github.com/qdrant/qdrant-client/pull/280, https://github.com/qdrant/qdrant-client/commit/6f8c5172d77a1775474d6ae145e7552543803806 - Compatibility updates for Qdrant v1.5.x * https://github.com/qdrant/qdrant-client/pull/210 - [fastembed](https://github.com/qdrant/fastembed) integration. Enables lightweight, fast, Python library built for retrieval embedding generation. * https://github.com/qdrant/qdrant-client/pull/243 - Migration tool, allows easy data mLow9/7/2023
v1.3.2# Changelog --- ## Features - Pydantic v2 support #214 #224 - Forbid extra fields in pydantic models #222 --- ## Bug fixes - Local mode cosine normalization #213 - Handle `Dict[str, np.ndarray]` in uploading collection in local mode #183 - Fix grpc.insecure_connection arguments #216 - Add missing init_from param in recreate_collection #205 Low7/26/2023
v1.2.0# Change log ## Features * Support for Qdrant v1.2.0 features: * Nested filters * group-by * Optional vectors * On-disk vecors ## Bug fixes * https://github.com/qdrant/qdrant-client/issues/175Low5/24/2023
v1.1.2+ Minor fix for ids in local modeLow4/7/2023
v1.1.1# Local Mode Introduce a new way to run Qdrant from python, no server required! ![try-develop-deploy](https://user-images.githubusercontent.com/1935623/228976367-e9198649-8013-45d5-9743-c6de32ff37fe.png) Python client allows you to run same code in local mode without running Qdrant server. Simply initialize client like this: ```python from qdrant_client import QdrantClient client = QdrantClient(":memory:") # or client = QdrantClient(path="path/to/db") # Persists changes tLow3/30/2023
v1.1.0Support for Qdrant v1.1.0 features: - Quantization - Match Any condition + Minor improvementsLow3/17/2023
v1.0.2- support for Qdrant v1.0.x - Minor fixesLow2/24/2023
v0.11.0# Changes * Compatibility with v0.11.0 of QdrantLow10/26/2022
v0.10.1## Backward compatibility release Proposed update process with minimal downtime: 1. Update qdrant from `v0.9.1` -> `v0.10.0` 2. Update qdrant client to `v0.10.0` 3. Update qdrant to `v0.10.1` 4. Update qdrant client to `v0.10.1` | Version compatibility | client v0.9.x | client v0.10.0 | client v0.10.1 | |-------------------------|---------------|----------------|----------------| | qdrant v0.9.1 | + | - | - | | qdrant v0.10.0 Low9/19/2022
v0.10.0# Changelog - Support for qdrant v0.10.0 + v0.10.1 - `betterproto` grpc library replaces with `grpcio`, which perwords up to 20x faster serialization and doe snot require asyncio runtime - One drawback of `grpcio` is less intuitive datatypes, but we encourage you to use data structures provided by Pydantic instead, it includes better validation and easy-to-use interface. Pydantic structures will be automatically converted into protobuf ones. | Version compatibility | client v0.9.Low9/19/2022
v0.8.7# Changes - Support for Qdrant v0.8.5Low7/26/2022
v0.8.3# Changes - Support for Qdrant v0.8.3 - Pagination over search resultsLow6/28/2022
v0.8.0# Change log * Support for Qdrant v0.8.0 ## What's Changed * All methods are now have custom implementation in the `QdrantClient` * E.g. use `client.get_collection("my_collection")` instead of `client.http.collections_api.get_collection("my_collection")` * Points update and query APIs are now supporting gPRC mode * gPRC and REST structures are automatically inter-convertible ## Bug Fixes * bool parsing in conditions filter fixedLow6/8/2022
v0.7.0# Change log * Support for Qdrant v0.7.0 ## What's Changed * Any JSON is now supported as a Payload * Payload schema is no loner required, payload index requires [specification of the field type](https://github.com/qdrant/qdrant_client/blob/v0.7.0/tests/test_qdrant_client.py#L84) instead. * New condition filters * `Match` condition refactored to also support `bool` condition, see [example](https://github.com/qdrant/qdrant_client/blob/v0.7.0/tests/test_qdrant_client.py#L184) Low4/13/2022
v0.6.1## Improvements - This release includes initial support for the GRPC interface to the Qdrant engine. - In our benchmarks, we found out that it is about 3 times faster than the REST interface in the initial upload. ## Notes - The GRPC interface is still under development, and we hope to fully support it in upcoming releases. - The REST interface will remain in use because it's easy to debug and make experiments, e.g., with CURL calls. - See [Readme](https://github.com/qdrant/qdrant_client) Low3/10/2022
v0.6.0# Change log - Support API of Qdrant v0.6.x # Breaking changes - Collection name parameter unified across all API methods. Now it is called `collection_name` (old version: `name`) - Match request is now separated into `MatchKeyword` and `MatchInteger` - See test diff for migration examples: https://github.com/qdrant/qdrant_client/commit/b3474b7c9b722f41f7ef2dc3845047054a095243#diff-58894b5fdecb917cdf60a0d1e9dbecae4fb31921be7ca7561642be4f44c0889fLow3/4/2022
v0.5.0# Change log - Support API of Qdrant v0.5.x ## Bugs fixed - Issue with payload type when creating a new point - https://github.com/qdrant/qdrant_client/issues/14Low2/3/2022

Dependencies & License Audit

Loading dependencies...

Similar Packages

ibmcloudantPython client library for IBM Cloudant0.11.5
fionaFiona reads and writes spatial data files1.10.1
pineconePinecone client and SDK8.1.2
knowhereVector search engine inside Milvus, integrating FAISS, HNSW, DiskANN.v2.6.11
azure-storage-blobMicrosoft Azure Blob Storage Client Library for Pythonazure-template_0.1.0b6187637