391 Commits

Author SHA1 Message Date
George
e7aecbd67a fix: add limit > 0 rules in local mode (#1281) 2026-07-24 02:22:28 +07:00
Madan kumar
69a5c22e48 Preserve proto3 field presence for falsy values in REST/gRPC conversion (#1260)
Co-authored-by: George Panchuk <george.panchuk@qdrant.tech>
2026-07-24 02:01:15 +07:00
ErenAta16
b50caeb0cd fix: do not drop falsy shard keys in convert_points_update_operation (#1279) 2026-07-23 23:32:31 +07:00
George
ff30799c6d fix: fix embed paths (#1278)
* fix: fix embed paths

* tests: add local inference test for complex prefetch
2026-07-23 22:22:29 +07:00
Madhan Kumar Reddy
f326784879 Warn that search_params is ignored in local mode instead of silently dropping it (#1083) (#1247)
Co-authored-by: George Panchuk <george.panchuk@qdrant.tech>
2026-07-22 22:33:21 +07:00
Madan kumar
532997a781 Fix local mode filters cross-matching booleans and integers (#1259)
* Fix local mode filters cross-matching booleans and integers

Python treats bool as a subclass of int (True == 1, False == 0), but Qdrant
keeps booleans and integers as distinct payload value types. Local mode
compared them with a plain `==` / `in` / `isinstance(value, (int, float))`, so:

- MatchValue(value=1) matched a payload of True, and MatchValue(value=True)
  matched a payload of 1 (same for 0 / False)
- MatchAny / MatchExcept cross-matched the same way
- Range matched booleans as if they were 0 / 1

The server never cross-matches these (its ValueVariants keeps Integer and Bool
distinct, and booleans are not numeric for range conditions). Add a type-aware
equality helper used by the value-match conditions, and exclude booleans from
range checks. Adds an in-memory regression test.

* Cover MatchExcept in the bool/int cross-match test

MatchExcept also routes through values_match, so assert that except=[1]
keeps the True payload (bool is not the integer 1).

* Add isolated MatchAny and range asserts to the bool/int cross-match test

Lock the single-value MatchAny path and the check_range bool guard against
regressions, in addition to the existing combined-condition coverage.

* fix: handle floats in cross-match local mode filters, add congruence tests

---------

Co-authored-by: George Panchuk <george.panchuk@qdrant.tech>
2026-07-22 02:17:20 +07:00
George
6f5bff3ed6 fix: fix local mode set payload shared nested object #1271 (#1276)
Co-authored-by: Eren Ata <erena6466@gmail.com>
2026-07-22 00:29:39 +07:00
George
b4713cd874 Fix env installation (#1255)
* fix: update poetry lock

* fix: add type annotations, update poetry.lock

* fix: fix local persistence tests

* fix: replace del client with client.close in local mode persistence tests

* new: update local mode values count filter behaviour
2026-07-08 17:06:02 +07:00
George
e95b94487b fix: fix update vectors in local mode (#1244) 2026-06-26 14:52:30 +09:00
Alok Tripathi
390c284ad6 fix: check_match() raises TypeError when MatchText applied to non-string field (#1224)
* fix: check_match() raises TypeError when MatchText applied to non-string field

* tests: move non-string match test to test_nested_filter, cover MatchText and MatchTextAny

---------

Co-authored-by: George Panchuk <george.panchuk@qdrant.tech>
2026-06-26 14:07:20 +09:00
George
fe0415384c fix: update poetry lock (#1242)
* fix: update poetry lock

* fix: add type annotations, update poetry.lock

* fix: fix local persistence tests

* fix: replace del client with client.close in local mode persistence tests
2026-06-26 13:41:15 +09:00
George
790328b1aa new: remove add and query methods (#1210)
* new: deprecate add and query methods

* fix: update async client generator
2026-05-20 22:48:47 +07:00
Mohamed Arbi
d2196df5cd docs: Add docstring for ParallelWorkerPool class (#1199) 2026-05-18 19:18:26 +07:00
Mohamed Arbi
7a18316a3b fix: use HasVectorCondition in local search_distance_matrix (#1197) 2026-05-18 18:36:51 +07:00
George
d72554e640 new: update models to 1.18, add create_named_vector and delete_named_vector (#1201)
* new: update models to 1.18, add create_named_vector and delete_named_vector

* fix: add missing strict mode config updates

* fix: fix local mode create and delete vector name

* new: update turbo quant fields

* fix: persist vector deletion
2026-05-09 01:09:54 +07:00
Andrey Vasnetsov
ddfdcf4cf0 Per-request custom headers for tracing (#1173)
* implement thread-local header overwrite for setting headers for individual requests

* mypy

* fix: remove redundant import in init, remove redundant import in qdrant remote

---------

Co-authored-by: George Panchuk <george.panchuk@qdrant.tech>
2026-05-08 00:37:59 +07:00
George
f6964b69bd fix: fix geo bounding box filters on edges (#1190)
* fix: fix geo bounding box filters on edges

* tests: add test
2026-04-14 18:06:14 +07:00
George
1c1e1c54fc fix: fix local mode values count (#1191) 2026-04-14 18:06:00 +07:00
Anush
c7a5bef84b feat: Add support for custom headers (#1162)
* feat: Add support for custom headers

Signed-off-by: Anush008 <mail@anush.sh>

* add warnings when user provides user-agent or api-key in headers or options

* fix: fix is none condition

---------

Signed-off-by: Anush008 <mail@anush.sh>
Co-authored-by: George Panchuk <george.panchuk@qdrant.tech>
2026-03-13 22:04:39 +07:00
George
57e69522ea fix: do not modify payload filters in local mode in-place (#1169)
Co-authored-by: JiangNan <1394485448@qq.com>
2026-03-13 21:42:39 +07:00
George
a8100882fb new: run server version check in a thread, don't check bm25 availabil… (#1168)
* new: run server version check in a thread, don't check bm25 availability as it was introduced in 1.15.3

* fix: fix tests for auth

* fix: fix test for auth again

* fix: update stacklevel for in-thread warnings

* fix: fix auth token test for sync client

* tests: remove outdated tests
2026-03-13 21:42:11 +07:00
George
0a69a4c9a2 deprecate: completely replace fastembed bm25 with qdrant core bm25 in hosted qdrant (#1166)
* deprecate: completely replace fastembed bm25 with qdrant core bm25

* fix: fix param name in embedder, accept lower case bm25 model name

* tests: enable skipped tests, add bm25 core usage tests

* fix: fix ci, run fastembed tests in integration tests

* fix: fix pip uninstall prompt

* tests: log message when running tests wo fastembed
2026-03-13 01:23:44 +07:00
George
ee813f71e7 fix: fix type hint union with grpc enum with old protobuf (#1157)
* fix: fix type hint union with grpc enum with old protobuf

* fix: add type ignore
2026-03-10 13:44:54 +07:00
George
63f69540a6 Update models 1.17 (#1154)
* new: update models, add conversions, add conversion tests

* new: add list shard keys, add get_optimizations

* new: add weights to rrf

* new: add cluster telemetry

* new: add update_mode usage

* fix: fix mypy

* fix: populate inspection cache

* use RRF ranking as in the core

* timeouts propagation

* gen async clients

* implement score threshold for formular

* new: add tests for update mode

* fix: fix test skip comment

* Relevance feedback local mode (#1152)

* AI: implement local computation

prompt: Considering the implementation in the server, make the local
python implementation of the same scores calculation in this file:
[@distances.py](...), consider that the local mode calculates for all
points at once, while the server does it point by point.

Server impl:
```
...
```

* use constant for MARGIN

* relevance feedback integration and test

* do not exclude relevance context from result

* Revert "do not exclude relevance context from result"

This reverts commit 9c2a5cedc0.

---------

Co-authored-by: generall <andrey@vasnetsov.com>

* fix: fix conversion test

---------

Co-authored-by: generall <andrey@vasnetsov.com>
Co-authored-by: Luis Cossío <luis.cossio@qdrant.com>
2026-02-19 22:32:01 +07:00
Chris Coutinho
be220858cb fix: apply score_threshold filtering after fusion queries in local mode (#1138)
* fix: apply score_threshold filtering after fusion queries in local mode

The local/memory client was not applying score_threshold filtering after
RRF and DBSF fusion operations. This caused query_points with prefetch
and fusion queries to return results below the specified score_threshold.

This fix adds score_threshold filtering after fusion results are computed,
matching the behavior of the remote Qdrant server.

* tests: simplify score threshold tests, add formula threshold test

---------

Co-authored-by: George Panchuk <george.panchuk@qdrant.tech>
2025-12-16 22:10:54 +07:00
Kirstin
144f4ea617 Fix/lazy load local mode (#1134)
* Fix: Lazy load QdrantLocal to support read-only envs

* Fix: Lazy load QdrantLocal to support read-only envs

* Fix: Regenerate async client using Python 3.10 to match CI

* chore: add comments to portalocker import

---------

Co-authored-by: Kirstin <kirstin.taufertshoefer@qdrant.com>
Co-authored-by: George Panchuk <george.panchuk@qdrant.tech>
2025-12-11 11:27:28 +07:00
George
c7012855ef fix: propagate lookup from correctly in query_points_groups (#1133)
* fix: propagate lookup from correctly in query_points_groups

* tests: add test from lookup_from
2025-12-10 17:24:20 +07:00
George
a8beff7c96 Drop python3.9 (#1110)
* new: remove vectors_count, update http and grpc models

* fix: update inspection cache

* new: add conversions and update interface

* fix: fix some conversions

* fix: fix typo

* fix: fix isinstance

* fix: regen async

* fix: fix update_filter usage, fix isinstance

* tests: collection metadata test

* fix: address backward compatibility in test

* new: update models, add max payload index count and copy vectors

* fix; update _inspection_cache

* new: add read consistency to count points

* Allow uuids in interface (#1085)

* new: direct uuid support

* tests: add uuid tests

* fix: update inspection cache

* new: add collection metadata and tests to local mode (#1089)

* new: add collection metadata and tests to local mode

* fix: regen async client

* new: implement parametrized rrf in local mode (#1087)

* new: implement parametrized rrf in local mode

* refactoring: use a variable for a magic value

* fix: adjust conversion according to AI

* Update filter (#1090)

* new: add missing update_filter, implement it in local mode

* fix: fix type hint, fix update operation, fix rest uploader, add tests

* fix: fix update filter is None case

* fix: mypy was not a good boy

* Text any filter (#1091)

* new: add match text any local mode

* tests: add match text any tests

* new: update models, remove init_from and locks (#1100)

* new: update models, remove init_from and locks

* deprecate: remove init from tests

* deprecate: remove lock tests

* new: convert ascii_folding

* fix: fix type stub

* new: convert acorn

* new: convert shard key with fallback

* new: update grpcio and grpcio tools in generator (#1106)

* new: update grpcio and grpcio tools in generator

* fix: bind grpcio and tools versions to 1.62.0 in generator

* Remove deprecated methods (#1103)

* deprecate: remove old api methods

* deprecate: remove type stub for removed methods

* deprecate: remove old api methods from test_qdrant_client

* deprecate: replace search with query points in test_in_memory

* deprecate: replace search methods in fastembed mixin with query points

* deprecate: replace old api methods in test async qdrant client

* deprecate: replace search with query points in test delete points

* deprecate: replace discover and context with query points in test_discovery

* deprecate: replace recommend_groups with query_points_groups in test_group_recommend

* deprecate: replace search_groups in test_group_search

* deprecate: replace recommend with query points in test_recommendation

* deprecate: replace search with query points in test search

* deprecate: replace context and discover with query points in test sparse discovery

* deprecate: replace search with query points in test sparse idf search

* deprecate: replace recommend with query points in test sparse recommend

* deprecate: replace search with query points in test sparse search

* deprecate: replace missing search request with query request in qdrant_fastembed

* deprecate: replace search with query points in test multivector search queries

* deprecate: replace upload records with upload points in test_updates

* deprecate: remove redundant structs (#1104)

* deprecate: remove redundant structs

* fix: do not use removed conversions in local mode

* fix: remove redundant conversions, simplify types.QueryRequest

* deprecate: replace old style grpc vector conversion to a new one (#1105)

* deprecate: replace old style grpc vector conversion to a new one

* fix: ignore union attr in conversion

* review fixes

---------

Co-authored-by: generall <andrey@vasnetsov.com>

---------

Co-authored-by: generall <andrey@vasnetsov.com>

---------

Co-authored-by: generall <andrey@vasnetsov.com>

* new: deprecate add, query, query_batch in fastembed mixin (#1102)

* new: deprecate add, query, query_batch in fastembed mixin

* 1.16 -> 1.17

---------

Co-authored-by: generall <andrey@vasnetsov.com>

---------

Co-authored-by: generall <andrey@vasnetsov.com>

* new: yet another update

* new: add initial_state to create shard key (#1109)

* new: drop python3.9, replace union and optional with | where possible

* fix: fix missing type hints, regen async

* fix: remove redundant optional

* fix: fix ai comments

* fix: update type hints from merge

* new: update pyproject and lock

* new: replace optional and union with |

* new: remove optional and union from qdrant local

* new: replace union with | in client classes

* fix: replace remaining union, optional, etc, address review comments

* new: adjust numpy versioning

---------

Co-authored-by: generall <andrey@vasnetsov.com>
2025-12-05 16:32:24 +07:00
George
fddf1185ae new: expose the remaining cluster methods (#1123)
* new: expose the remaining cluster methods

* fix: fix type hints

* new: add deadline info to the first hw

* fix: fix review comments
2025-11-24 20:02:44 +07:00
George
5284c02238 fix: fix local mode backward compatibility (#1124)
* fix: fix local mode backward compatibility

* chore: fix comment

* fix: fix fix
2025-11-24 19:43:17 +07:00
George
fbeb023543 fix: rename common.proto to qdrant_common.proto to avoid conflicts with other libraries (#1125) 2025-11-24 18:36:42 +07:00
George
9ce7346e05 new: convert cluster operations to grpc (#1116)
* new: convert cluster operations to grpc

* fix: rollback coverage html

* fix: address ai comments

* fix: address review comments
2025-11-20 13:38:17 +07:00
George
14f461b02b new: update grpc (#1113)
* new: update grpc

* fix: make common_pb2 available under grpc
2025-11-14 20:20:41 +01:00
George
f2e0e22a17 new: expose cluster operations (#1114)
* new: expose cluster operations

* fix: fix cluster collection update return result, add tests

* fix test

---------

Co-authored-by: generall <andrey@vasnetsov.com>
2025-11-14 20:20:22 +01:00
George
27acfd0d75 new: remove vectors_count, update http and grpc models (#1069)
* new: remove vectors_count, update http and grpc models

* fix: update inspection cache

* new: add conversions and update interface

* fix: fix some conversions

* fix: fix typo

* fix: fix isinstance

* fix: regen async

* fix: fix update_filter usage, fix isinstance

* tests: collection metadata test

* fix: address backward compatibility in test

* new: update models, add max payload index count and copy vectors

* fix; update _inspection_cache

* new: add read consistency to count points

* Allow uuids in interface (#1085)

* new: direct uuid support

* tests: add uuid tests

* fix: update inspection cache

* new: add collection metadata and tests to local mode (#1089)

* new: add collection metadata and tests to local mode

* fix: regen async client

* new: implement parametrized rrf in local mode (#1087)

* new: implement parametrized rrf in local mode

* refactoring: use a variable for a magic value

* fix: adjust conversion according to AI

* Update filter (#1090)

* new: add missing update_filter, implement it in local mode

* fix: fix type hint, fix update operation, fix rest uploader, add tests

* fix: fix update filter is None case

* fix: mypy was not a good boy

* Text any filter (#1091)

* new: add match text any local mode

* tests: add match text any tests

* new: update models, remove init_from and locks (#1100)

* new: update models, remove init_from and locks

* deprecate: remove init from tests

* deprecate: remove lock tests

* new: convert ascii_folding

* fix: fix type stub

* new: convert acorn

* new: convert shard key with fallback

* new: update grpcio and grpcio tools in generator (#1106)

* new: update grpcio and grpcio tools in generator

* fix: bind grpcio and tools versions to 1.62.0 in generator

* Remove deprecated methods (#1103)

* deprecate: remove old api methods

* deprecate: remove type stub for removed methods

* deprecate: remove old api methods from test_qdrant_client

* deprecate: replace search with query points in test_in_memory

* deprecate: replace search methods in fastembed mixin with query points

* deprecate: replace old api methods in test async qdrant client

* deprecate: replace search with query points in test delete points

* deprecate: replace discover and context with query points in test_discovery

* deprecate: replace recommend_groups with query_points_groups in test_group_recommend

* deprecate: replace search_groups in test_group_search

* deprecate: replace recommend with query points in test_recommendation

* deprecate: replace search with query points in test search

* deprecate: replace context and discover with query points in test sparse discovery

* deprecate: replace search with query points in test sparse idf search

* deprecate: replace recommend with query points in test sparse recommend

* deprecate: replace search with query points in test sparse search

* deprecate: replace missing search request with query request in qdrant_fastembed

* deprecate: replace search with query points in test multivector search queries

* deprecate: replace upload records with upload points in test_updates

* deprecate: remove redundant structs (#1104)

* deprecate: remove redundant structs

* fix: do not use removed conversions in local mode

* fix: remove redundant conversions, simplify types.QueryRequest

* deprecate: replace old style grpc vector conversion to a new one (#1105)

* deprecate: replace old style grpc vector conversion to a new one

* fix: ignore union attr in conversion

* review fixes

---------

Co-authored-by: generall <andrey@vasnetsov.com>

---------

Co-authored-by: generall <andrey@vasnetsov.com>

---------

Co-authored-by: generall <andrey@vasnetsov.com>

* new: deprecate add, query, query_batch in fastembed mixin (#1102)

* new: deprecate add, query, query_batch in fastembed mixin

* 1.16 -> 1.17

---------

Co-authored-by: generall <andrey@vasnetsov.com>

---------

Co-authored-by: generall <andrey@vasnetsov.com>

* new: yet another update

* new: add initial_state to create shard key (#1109)

* chore: remove obsolete imports

* fix: add metadata parameter to recreate collection in local

* fix: fix metadata handling in local more

---------

Co-authored-by: generall <andrey@vasnetsov.com>
2025-11-14 17:01:17 +07:00
Ivan Daschinskiy
507984e9b4 Implement passing certificates creds to grpc channels (#1077)
* Implement passing certificates cres to grpc channels

* Refactor and fix AI reviewer suggestions

* Refactor and fix AI reviewer suggestions

* minor fix

* refactor: refactor options parsing a bit

* fix: fix options is None

* fix: fix warning id

---------

Co-authored-by: Дащинский Иван Андреевич <iadashchinskiy@sbertech.ru@WL-3e6f71e6.sbertech.local>
Co-authored-by: George Panchuk <george.panchuk@qdrant.tech>
2025-10-29 16:37:11 +07:00
George
6b031b3262 fix: fix overriding prefetch limit in local mode (#1081)
* fix: fix overriding prefetch limit in local mode

* fix: replace recursion with a while loop in prefetch
2025-10-27 18:14:55 +07:00
George
784b27ab1c new: queryless score 1 (#1088)
* new: queryless score 1

* Reduce hf requests (#1092)

* tests: remove redundant test

* new: improve caching, reduce number of hf requests

* fix: fix possible cache_dir key error
2025-10-24 18:48:13 +07:00
Jojii
b9fb4923fa Connection pooling (#1071)
* Connection pooling in GRPC

* Undo auto formattings

* Make next_grpc_client() protected

* Prevent partial initialization of grpc clients on channel creation error

* also apply pool_size to rest client

* Fix using non clamped pool_size in httpx

* Review remarks

* fix: fix minor things (#1075)

---------

Co-authored-by: George <george.panchuk@qdrant.tech>
2025-09-19 14:38:36 +02:00
George
200020f19a wip: builtin bm25 support (#1060)
* wip: builtin bm25 support

* remove debug print

* new: add builtin embedder, add server version check for inference

* fix: regen async

* fix: fix fastembed import

* fix: regen async

* tests: add tests for builtin inference

* fix: fix fastembed checks, improve exceptions
2025-09-15 16:18:41 +08:00
George
5caf1cd8fa fix: fix openapi usage structure (#1053)
* fix: fix openapi usage structure

* fix: update inspection cache
2025-07-31 20:54:16 +03:00
George
e4c7bfaf4f fix: fix grpc document, image, inference object without options conversion (#1052) 2025-07-31 20:41:32 +03:00
Luis Cossío
1a63b86e51 better FieldCondition conversion (#1051) 2025-07-29 11:17:56 -04:00
Luis Cossío
7b17db5a7e MMR integration and local mode (#1044)
* generate rest client

* gen grpc client

* conversions

* inpection cache

* wip implement mmr

* upd openapi models

* tests: add mmr tests

* wip: implement mmr

* new: use postprocessed scores

* fix maxsim asymmetry and empty sparse intersection

* fix: fix conversions

* fix: fix type hints

* chore: update inspection cache

* fix: revert changes to add points and update named vectors

---------

Co-authored-by: generall <andrey@vasnetsov.com>
Co-authored-by: George Panchuk <george.panchuk@qdrant.tech>
2025-07-18 12:06:50 +03:00
George
e823402cf5 new: add b64 encoding function (#1031)
* new: add b64 encoding function

* tests: remove garbage

* refactor base64 function name and params

* manual test for remove iamge inference with base64

* use tempfile

* fix: rename remove_inference->remote_inference

---------

Co-authored-by: generall <andrey@vasnetsov.com>
2025-07-15 18:41:58 +03:00
George
4da06b08d6 new: update models for v1.15, add conversions (#1038)
* new: update models for v1.15, add conversions

* rename SnowballParameters to SnowballParams

---------

Co-authored-by: Luis Cossío <luis.cossio@outlook.com>
2025-07-15 15:39:48 +02:00
George
fbf72f4a31 new: relax test comparison (#1039)
* new: relax test comparison

* rollback: rollback is context search addition

* rollback: return redundant parentheses

* Sparse no overlap distance computation (#1040)

* fix: fix sparse distance computation for recommend, discovery and context queries

* fix: use empty_is_zero

* add zero case to score cmp

* add snapshot saving on failure

---------

Co-authored-by: generall <andrey@vasnetsov.com>
2025-07-15 13:30:23 +02:00
George
bb7016fd4b fix: fix edge case in upsert, fix multivec update, add tests (#1030)
* fix: fix edge case in upsert, fix multivec update, add tests

* fix: fix tests
2025-07-10 13:22:52 +02:00
Tim Visée
bf515ae2d7 Change user agent to python-client (#1028) 2025-06-24 14:07:07 +02:00
George
a908d95125 fix: do not inspect input with cloud inference (#1024) 2025-06-13 21:35:20 +04:00