Commit Graph
139 Commits
Author SHA1 Message Date
Arnaud Gourlay cc3f578b5c Remove update queue opnum from CollectionInfo (#8127) 2026-02-16 10:17:29 +01:00
Tim Visée caa5a14866 Fix stream records transfer data race, losing pending updates (#8103)
* Add integration test to assert all queued updates are also transferred

* Plunge update queue in stream records transfers

* Migrate existing plunger usages to new plunge helper

* Skip test if not compiled with staging flag

* Only send delay operation when staging feature is enabled

* Reformat

* Fix review remarks
2026-02-13 09:55:37 +01:00
Luis CossíoandArnaud Gourlay bc6246df5a [relevance feedback] add rest and grpc interfaces (#7399)
* add rest and grpc interfaces

Also handle inference for this query

* follow refactor from base branch

* renaming from Ms Cooper

* get started on validation testing

* more validations

* test equivalence with query when less than 2 feedback elements

* rename feedback query to relevance_feedback query

* fix extraction of context pairs

* rename feedback vector to example

* make coderabbit happier

* upd test

---------

Co-authored-by: Arnaud Gourlay <arnaud.gourlay@gmail.com>
2026-02-13 09:55:37 +01:00
Luis Cossío b88a1d76ce fix: handle score_threshold in Formula queries (#8097)
* handle `score_threshold` in Formula queries

* AI: add openapi test

prompt: Upload 4 points with a numeric payload, use the payload as the
score, and set a score threshold. We can assert which ids should be in
the result and which shouldn't
2026-02-13 09:55:18 +01:00
Andrey Vasnetsov 037600e8af Weighted rrf (#8063)
* weighted rrf implementation

* test

* fmt

* fix edge

* validate number of sources and number of weights

* do not partial match

* upd schema

* review fixes

* update formula

* remove calcualtions from tests

* update comment, because AI have OCD

* fmt
2026-02-10 00:04:33 +01:00
Ivan Pleshkov 78207079dd Update queue status in metrics and telemetry (#8060)
* update queue status in metrics and telemetry

* fix python tests

* update openapi
2026-02-10 00:01:27 +01:00
Arnaud Gourlayandxzfc aeeafe4a0e Update queue info into CollectionInfo (#8010)
* Update queue info into CollectionInfo

* basic test

* fix

* cleaner

* Update lib/collection/src/shards/local_shard/mod.rs

Co-authored-by: xzfc <5121426+xzfc@users.noreply.github.com>

* fix the fix

* rename to op_num

* skip_serializing_if just in case

* first step

* test queue length with staging feature

* gate integration test based on binary feature

---------

Co-authored-by: xzfc <5121426+xzfc@users.noreply.github.com>
2026-02-09 23:39:24 +01:00
Andrey Vasnetsov 9099a7ac1b introduce update_mode parameter for upsert operation to control if we want to insert, update, or upsert (#7963)
* introduce update_mode parameter for upsert operation to control if we want to insert, update, or upsert

* add test

* upd dockstring

* require resharding once all peers have updated version

* use service error

* fix clippy again

* wait for same version before resharding in tests
2026-02-09 23:28:45 +01:00
xzfc 8fb203eeb5 Update GET collections/{}/optimizations (#7946)
* refactor(SegmentOptimizer::name): make it `&'static`

* refactor(TrackerStatus): add is_running()

* refactor: add TrackerSegmentInfo

* feat: rework optimizations endpoint

* feat(collections/{}/optimizations): trim spaces
2026-02-09 23:28:03 +01:00
Daniel Borosandgenerall 00e0a7fc24 feat/test-timeout (#7920)
* feat: add timeout tests

* fix: timeout test

* fix: api urls

* fix: test

* feat: add staging api def

* feat: add parallel executor for tests

* fix: imports

* fix: ci/cd

* rollback openapi schema change

---------

Co-authored-by: generall <andrey@vasnetsov.com>
2026-02-09 23:15:44 +01:00
Andrey Vasnetsov ac2c18e1fe Validate vector name in matrix request (#7923)
* validate `using` param

* fix slop
2026-02-09 23:08:14 +01:00
SapphireandEC2 Default User 37de1f219d Add enable_hnsw option for payload field schema (#7887)
* feat: Add enable_hnsw option for payload field indexes

Add optional enable_hnsw parameter to all payload index types to control
whether additional HNSW graph links are built for each indexed field.

- Add enable_hnsw field to all 8 payload index param types
- Update gRPC proto definitions and conversions
- Update OpenAPI schema
- Modify HNSW graph builder to respect enable_hnsw flag
- Add enable_hnsw() helper methods to PayloadSchemaParams and PayloadFieldSchema
- Update all tests to include new field (default: None)

When enable_hnsw is true and payload_M > 0, additional HNSW links will
be built for the payload field. Default value is true for backward compatibility.

* Fix Some format problems

* fix: address comment problem

---------

Co-authored-by: EC2 Default User <ec2-user@ip-10-78-171-148.ec2.internal>
2026-02-09 22:53:47 +01:00
xzfc 6c0d10abe7 Indexing progress (#7625)
* Add progress_tracker.rs

* Pass progress tracker around

* Populate progress tracker with actual data

* Expose progress on `/collections/{name}/optimizations` endpoint
2025-12-18 17:27:18 +01:00
Jojii 3a19714f49 Make indexed-only-excluded-points metric default to 0 (#7649)
* Make indexed_only_excluded in metrics default to 0

* Fix tests
2025-12-03 10:23:55 +01:00
AMIR 8eec2046d7 Add list shard keys API (#7615) 2025-12-03 10:20:40 +01:00
Arnaud Gourlay 9bfeed0292 Fix Openapi schema for DELETE issues (#7634) 2025-12-03 10:20:34 +01:00
Arnaud Gourlay 7a80e23249 Clarify multivector inline storage warning (#7523)
* Clarify multivector inline storage warning

* do what I actually wanted to do in first place

* fix test
2025-11-14 12:31:07 +01:00
Jojiiandtimvisee 0f191bfcf6 Metrics for snapshots (#7497)
* Add atomic counter for running snapshots

* Refactor collection telemetry + export prometheus metric

* Handle collection in ToC + current recovery measurements

* Fix openapi tests

* Fix tests

* Add snapshot metrics for streaming and partial snapshots.

* Fix typo in metrics name

* Adjust metrics names

---------

Co-authored-by: timvisee <tim@visee.me>
2025-11-14 12:31:06 +01:00
Andrey Vasnetsov 6257371413 remove init_from (#7454)
* wip: remove init_from

* remove init_from tests

* upd schema

* rm test
2025-11-14 12:30:16 +01:00
Andrey Vasnetsov 2a423d1f11 remove lock api (#7449)
* remove lock api

* fix api count + remove tests

* remove another test

* remove more tests
2025-11-14 12:30:16 +01:00
Jojii df2b1c6232 Metrics vectors by name per collection (#7441)
* Add vector count per vector-name to metrics API

* Add to metrics API

* Improve TinyMap::get_or_insert_default and add tests

* Minor improvements

* Update openapi

* Review remarks

* Remove `collection_vectors` since it can be calculated manually
2025-11-14 12:30:15 +01:00
xzfc d2e47f54f5 Rename HnswConfig::{copy_vectors -> inline_storage} (#7389) 2025-11-14 12:28:14 +01:00
xzfc 59b8c886b3 Add CollectionInfo::warnings field (#7293)
* refactor: swap DiffConfig parmeters

was: diff.update(&config)
now: config.update(diff)

* refactor: introduce DiffConfig::update_opt

* feat: add CollectionInfo::configuration_status field

* rename ConfigurationStatus to CollectionWarning
2025-11-14 12:26:52 +01:00
Andrey Vasnetsov 4695549910 fix strict mode validation for nested filters (#7264)
* fix strict mode validation for nested filters

* fix test
2025-09-29 11:30:25 +02:00
Arnaud Gourlay 6e26e1f4eb Fix phrase match to not match with unknown tokens (#7252)
* Fix phrase match to not match with unknown tokens

* add tests

* spelling
2025-09-29 11:30:25 +02:00
Arnaud Gourlay 57831a355c [strict-mode] Add max number of payload index count (#7222)
* [strict-mode] Add max number of payload index count

* improve docs and validation for StrictModeConfig

* fix from coderabbit

* test blocking access to payload indexes

* polish test
2025-09-29 11:29:50 +02:00
Arnaud Gourlay 9c53c57130 Fix missing REST API validation for point batch update (#7219)
* Fix missing REST API validation for point batch update

* use a valid vector
2025-09-29 11:28:29 +02:00
Andrey Vasnetsovandtimvisee f0b139f765 implement custom collection metadata (#7123)
* implement custom collection metadata

* persist metadata change

* Also unset a key in the test

---------

Co-authored-by: timvisee <tim@visee.me>
2025-08-26 13:20:08 +02:00
Andrey VasnetsovandLuis Cossío 0ce667eee5 filter text any (#7100)
* internal implementation for filter any

* implement api for match `text_any`

* allow naive implementation of text match any

* dedup after kmerge + renames

* improve `expected_should_estimation`

* congruence test

* openapi test

* setup index in each test

---------

Co-authored-by: Luis Cossío <luis.cossio@outlook.com>
2025-08-26 13:18:36 +02:00
9c8ef5574f Update if (#7006)
* implement condition parameter for upsert operation

* fmt

* update api schema

* implement conditional update for update-vectors op

* rename to update_filter for consistency

* add tests

* explicilty ignore strict mode for conditional updates

* rabbit review fix

* Also assert vector element before, confirm we don't normalize

* Simplify filter creation using new helper

* Rename merge_with_ids to with_point_ids

---------

Co-authored-by: timvisee <tim@visee.me>
Co-authored-by: Tim Visée <tim+github@visee.me>
2025-08-26 13:16:18 +02:00
Jojii 6ae07f0fd8 Always load InferenceService (#7050)
* Always load InferenceService

* Add BM25 openapi test

* Add warning to development.yaml config (#7051)
2025-08-14 14:30:26 +02:00
Tim Visée 60c216be92 Preprocess query vectors, sort sparse vectors (#6895)
* Add test to assert behavior of unsorted sparse query

* Preprocess sparse vectors

* Fix typo
2025-07-17 16:13:01 +02:00
Tim Viséeandcoderabbitai[bot] 877adc6748 Fix broken is_empty filter on new points (#6882)
* Add test to catch bug

Bug: <https://github.com/qdrant/qdrant/issues/6880>

* Fix loading null index from wrong path

* Simplify test

* Also bump total point count when removing a point

* Add debug assertion, ensure we don't create null index in selector

* Update bug link

* Remove unused import

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-07-17 14:01:38 +02:00
Luis Cossíoandgenerall e8daf9c79f [MMR] expose as query variant in rest and grpc (#6797)
* expose mmr in rest and grpc

* fix referenced vectors in mmr queries

* rename to MmrInput in grpc for consistency

* mmr is now an optional parameter of nearest query

* fix score_threshold at local shard

* fix conversion of rest -> collection

* fix and refactor planned query

* nits

* rename `lambda` to `diversity` in interface

* handle score_threshold within mmr calculation

* add openapi test

* fix candidate limit at collection level

* candidate_limit -> candidates_limit

* finish rename to candidates_limit

---------

Co-authored-by: generall <andrey@vasnetsov.com>
2025-07-17 13:56:46 +02:00
Andrey VasnetsovandArnaud Gourlay 6bc7f9c650 fix check for pure primary condition filter (#6840)
* fix check for pure primary condition filter

* avoid cloning has_id for primary condition

* fix test

* add test

---------

Co-authored-by: Arnaud Gourlay <arnaud.gourlay@gmail.com>
2025-07-17 13:54:43 +02:00
Arnaud Gourlay afe4daa38d Deleted leftover test openapi collections (#6788) 2025-07-17 13:38:30 +02:00
Luis Cossíoandtimvisee ad936a463c [phrase matching] expose phrase condition (#6670)
* add `"match": { "phrase": ... }` condition

* gen grpc and openapi

* [phrase matching] expose `phrase_matching` flag in rest and grpc (#6620)

* expose setting in rest and grpc

* phrase matching openapi test

* regen openapi

* [phrase matching] Text index fixes (#6730)

* allow rocksdb-based immutable text index

* fix repeated-token phrases

* fmt

* Update OpenAPI spec

---------

Co-authored-by: timvisee <tim@visee.me>

* add repeated word case in openapi test

* [phrase match | strict mode] Allow phrase condition when enabled in index (#6749)

* allow phrase filter when index is present

* prettier error message

* clippppppy

---------

Co-authored-by: timvisee <tim@visee.me>
2025-07-17 13:25:12 +02:00
Roman Titovandgenerall 2aafd0174d Add partial snapshot create requests count and recovery timestamp to telemetry (#6545)
Co-authored-by: generall <andrey@vasnetsov.com>
2025-05-22 23:27:14 +02:00
Arnaud Gourlayandgenerall dd97253fe9 Strict mode allows fullscan for multitenant payload index (#6498)
* Strict mode allows fullscan for multitenant payload index

* different error for missing payload index in multitenant case

* handle payload_m

* add simple test

* handle hnsw.m not set

* add another simple test

* fix test

* fallback to global HSNW config

* new error status code

* do not block on global HNSW and improver error reporting

* clearer error reporting

* review fixes

* fix test error messages

---------

Co-authored-by: generall <andrey@vasnetsov.com>
2025-05-22 23:26:16 +02:00
Arnaud GourlayandLuis Cossío bbc4beb9ec Fix UnindexedField infra to handle lookup&range index requirements (#6496)
* Fix UnindexedField infra to handle lookup&range index requirements

* more generic approach

* better test

* restore

* small unit test for sanity

* review nits

* Do not recommend parametrized index

---------

Co-authored-by: Luis Cossío <luis.cossio@outlook.com>
2025-05-22 23:24:10 +02:00
Andrey Vasnetsov 7872c182f1 Strict mode error is now 400 instead of 403 (#6560)
* strcit mode error is now 400 instead of 403

* fix test
2025-05-22 23:22:16 +02:00
Arnaud Gourlay 9b99408529 Always overwrite existing payload on upsert (#6533)
* Always overwrite existing payload on upsert

* Add REST tests
2025-05-22 23:17:18 +02:00
Arnaud Gourlay eaaa4e4ee1 Validate IntegerIndexParams (#6494)
* Validate IntegerIndexParams

* focus
2025-05-22 23:00:52 +02:00
Arnaud Gourlay 00e7ffa9b3 Strict mode detects full scan on query (#6473) 2025-05-22 22:59:16 +02:00
Arnaud Gourlay 1da478c897 Fix strict mode unindexed group_by path (#6363)
* Fix strict mode unindexed group_by path

* check index schema for matching support

* Handle disabled lookup on integer index
2025-05-22 22:56:24 +02:00
Arnaud Gourlay 4c7c730c97 Log context of openapi validation crash (#6448) 2025-05-22 22:52:50 +02:00
Arnaud Gourlay 15d674d0c0 Fix warning regarding missing wait param in openapi tests (#6434) 2025-05-22 22:50:58 +02:00
Arnaud Gourlay 377b614e1e Fix flaky test formula (#6429) 2025-05-22 22:49:44 +02:00
Luis Cossío a304a51f84 [rate limits] consider length of multivectors for query cost (#6356)
* consider length of multivectors for rate limiter

* add openapi test

* organize imports

* better cost estimation for sparse vectors

* restore groups openapi test

* address @timvisee's review

* Fix consensus test
2025-05-22 22:46:39 +02:00
Kumar Shivendu 83af9cf3ba Improve telemetry logic and test (#6399)
* Improve telemetry logic and test

* Parametrize telemetry test

* Consistency hash peeer ID across telemetry

* clean test

* Use Option in segments telemetry

* updat openapi spec

* Avoid test failure on change in order of params
2025-04-21 00:12:26 +02:00