Commit Graph

540 Commits

Author SHA1 Message Date
n0x29a
fe62cc02be InferenceUsage in grpc (#6601)
* InferenceUsage in grpc

* Update documentation for InferenceUsage

* Update lib/api/src/grpc/ops.rs

Co-authored-by: Tim Visée <tim+github@visee.me>

* clearer inference usage tracking

* remove unused inference token from delete_points

* review

---------

Co-authored-by: Tim Visée <tim+github@visee.me>
Co-authored-by: generall <andrey@vasnetsov.com>
2025-07-17 11:08:18 +02:00
n0x29a
273f53f1b7 Add inference usage tracking to REST API (#6563)
* Add inference usage tracking to REST API

---------

Co-authored-by: Andrey Vasnetsov <andrey@vasnetsov.com>
2025-07-17 11:04:50 +02:00
generall
a546e0dda5 Revert "Update logo.svg"
This reverts commit ff8da874e0.
2025-07-12 14:01:14 +02:00
Andre Zayarni
ff8da874e0 Update logo.svg 2025-07-12 06:46:14 +02:00
Roman Titov
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
Tim Visée
7c23251bea Add volatile sparse vector storage (#6569)
* Add volatile sparse vector storage

* Add and use volatile sparse vector test

* Update OpenAPI spec

* Resolve review remarks
2025-05-22 23:25:05 +02:00
Andrey Vasnetsov
3501e4b7fe Add setting to limit max number of collections (#6548)
* add setting to limit max number of colelctions

* upd openapi

* Add max_collections to config

---------

Co-authored-by: timvisee <tim@visee.me>
2025-05-22 23:21:00 +02:00
n0x29a
5393fc8a6b Refactor: move HardwareUsage to the Usage map (#6532)
---------

Co-authored-by: jojii <jojii@gmx.net>
2025-05-22 23:15:15 +02:00
LesserPanda
aaf3832003 fix-typo (#6465)
* fix-typo

* Update openapi.json fix-typo
2025-05-22 22:54:47 +02:00
Luis Cossío
4346e2bbd2 tick score boosting in roadmap (#6271) 2025-04-22 13:30:35 +02:00
Andrey Vasnetsov
9eab25fc75 bump v1.14.0 (#6404) 2025-04-21 12:17:44 +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
Andrey Vasnetsov
bbea80e7d4 Telemetry improvements (#6390)
* allow shard states in anonymize telemetry (with hashed peer ids)

* introduce level3 and level4 for telemetry, where level4 = everything, incl. segments info

* upd openapi

* fix tests

* expose vector count & size stats on shard level to avoid reading of segments

* fix spelling

* upd schema

* fix tests

* Use unwrap_or_default

* [#6390] skip serializing shard details in Level2 (#6398)

* skip serializing shard details in Level2

* upd openapi

---------

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

---------

Co-authored-by: Tim Visée <tim+github@visee.me>
Co-authored-by: Luis Cossío <luis.cossio@qdrant.com>
2025-04-21 00:10:28 +02:00
Andrey Vasnetsov
a9795f7ce4 faster mmap numeric index (#6381)
* wip: attempt to investigate slow mmap numeric index

* fmt

* Improve performance of ConditionedCounter (#6384)

* Improve Performance of ConditionedCounter

* Remove unneeded hw_counter from signatures

* Clippy

* Fix Clippy II

* Fix Clippy III

* Fix Clippy IV

* Use static string, don't allocate string

* Remove allow dead code attribute

---------

Co-authored-by: Jojii <15957865+JojiiOfficial@users.noreply.github.com>
Co-authored-by: timvisee <tim@visee.me>
2025-04-21 00:07:08 +02:00
Luis Cossío
e114801ebf sum_scores recommendation strategy (#6256)
* Add in rest and grpc

* add to QueryEnum

* implement Query trait

* connect to scorer creation

* upd tests

* additional changes

* fmt

* gen openapi and grpc docs

* coderabbit fix

* add changes in async scorer

* test sum_scores in more places, refactor to remove repetition
2025-04-20 23:47:58 +02:00
Luis Cossío
8084f4cac1 [score boosting] support datetime expressions (#6196)
* use f64 as internal expression score

* allow datetime as expression

* add test cases

* fix schema, generate openapi and grpc docs

* fmt

* clippy

* fix test precision

* graceful handling of too large numbers, more tests

* rename to DatetimeExpression for consistency

* use datetime's timestamp as seconds

* capture variable name when parsing

* homogenize DateTime into Datetime

* use interface distinction between datetime strings and payload keys

* fix rebase

* fix after rebase
2025-04-20 23:47:20 +02:00
Jojii
5cd7239b61 Measure Payload Index IO Writes (#6137)
* Prepare measurement of index creation + Remove vector deletion
measurement

* add hw_counter to add_point functions

* Adjust add_point(..) function signatures

* Add new measurement type: payload index IO write

* Measure payload index IO writes

* Some Hw measurement performance improvements

* Review remarks

* Fix measurements in distributed setups

* review fixes

---------

Co-authored-by: generall <andrey@vasnetsov.com>
2025-03-31 16:19:19 +02:00
Luis Cossío
7428eba455 [score boosting] Add decay expressions (#6154)
* Add decay expressions

* remove code duplication in conversion

* test and fix lambda roundtrip

* Remove debug print in decay midpoint validation

* Improve error messages for decay midpoint and scale validation

* use similar lambda for gauss and exp decays

* avoid abs before squaring

* add comment about decay range

* add debug assertion
2025-03-21 11:45:46 +01:00
Jojii
6d53bd9184 IO read measurements for most Payload indices (#5951)
* Add payload index filtering IO measurements for some indices

* Add payload index metric to api and telemetry

* Also account for index access overhead

* Review remarks

* Anonymize new HardwareUsage field

* Fix tests
2025-03-21 11:43:45 +01:00
Arnaud Gourlay
af5b5bedd7 Separate StrictModeConfig output structure (#6114)
* Separate StrictModeConfig output structure

* happy regen

* add strict sparse config

* introduce CollectionConfigTelemetry

* upd openapi

---------

Co-authored-by: Andrey Vasnetsov <andrey@vasnetsov.com>
2025-03-21 11:42:11 +01:00
Jojii
78f0428f3e Measure hardware IO for update operations (#5922)
* Measure update operations hardware IO

* Add support for distributed setups

* also measure update_local

* Add consensus tests for HW metrics of update operations

* add test for upserting without waiting

* Disable HW usage reporting when not waiting for update API

* Review remarks

* Fix resharding collecting hw measurements

* Fix metric type

* New struct HardwareData for better accumulation

* Ensure we always apply CPU multiplier

* Apply suggestions from code review

* Update src/actix/api/update_api.rs

Co-authored-by: Tim Visée <tim+github@visee.me>

* Fix assert_with_upper_bound_error threshold calculation.

* Clarifying why we don't measure shard cleanup

---------

Co-authored-by: Tim Visée <tim+github@visee.me>
2025-03-21 11:42:08 +01:00
Andrey Vasnetsov
706b1a3166 IsEmpty/IsNull index (#6088)
* create initial strucutres

* clippy

* start field-query refactoring

* start field-query refactoring (2/N)

* start field-query refactoring (3/N): duplicate is_empty/null condiftions as field condition

* start field-query refactoring (4/N): re-instate is_empty fallback in case new index is not built yet

* filter for is_empty/is_null

* implement add/remove point

* upd schema

* open and create of null-index

* create null-index

* fix test

* Update lib/segment/src/index/query_optimization/condition_converter.rs

Co-authored-by: Tim Visée <tim+github@visee.me>

* unit test for null-index

* more unit tests

* add openapi tests

* fmt

* fix for integartion tests

* rabbit review fix

* make [null] non-empty

---------

Co-authored-by: Tim Visée <tim+github@visee.me>
2025-03-21 11:41:12 +01:00
Luis Cossío
1a23ebc4b9 [score boosting] openapi test for formula (#6064)
* add formula to internal grpc api

* add openapi test for formula
2025-03-21 11:40:07 +01:00
Luis Cossío
9899b6fda7 [score boosting] add more expressions (#6054)
* sqrt, pow, exp, log, ln, abs

* upd openapi and grpc

* handle undefined math as negative infinity
2025-03-21 11:40:00 +01:00
Luis Cossío
a6043c5db4 [score boosting] add gRPC structures (#6035)
* add grpc structures

* grpc docs

* make by_zero_default optional
2025-03-21 11:38:19 +01:00
Luis Cossío
88701bdb82 [score boosting] Connect formula to query (#6024)
* finish connecting formula query

* upd openapi
2025-03-21 11:37:59 +01:00
Arnaud Gourlay
cb1f3220df Add strict mode for max points count (#5967)
* Add strict mode for max points count

* clarify estimated nature
2025-02-17 10:20:50 +01:00
Kumar Shivendu
0a3d31fbe3 Add docs about coverage reports (#5958)
* Add docs about running coverage tests locally

* Add link to CI coverage report

* higlight that we only cover unit tests

* Add CI coverage report image

* Add more steps

* Remove OOM instructions
2025-02-11 14:41:26 +01:00
Jojii
ec0762a560 Measure IO reads for vectors (#5912) 2025-02-11 14:40:21 +01:00
Andrey Vasnetsov
75f3a41f59 roadmap 2025 (#5906)
* roadmap 2025

* Update docs/roadmap/README.md

Co-authored-by: Arnaud Gourlay <arnaud.gourlay@gmail.com>

* Update docs/roadmap/README.md

Co-authored-by: Luis Cossío <luis.cossio@qdrant.com>

* Update docs/roadmap/README.md

Co-authored-by: Luis Cossío <luis.cossio@qdrant.com>

---------

Co-authored-by: Arnaud Gourlay <arnaud.gourlay@gmail.com>
Co-authored-by: Luis Cossío <luis.cossio@qdrant.com>
2025-02-11 14:40:01 +01:00
George
7650f07e8a deprecate old search api endpoints (#5907) 2025-02-11 14:37:32 +01:00
Jojii
77f65ef95f HwCounter rename IO metrics (#5898)
* Rename io metrics and add vector_io_write

* Chore: Cleanup obsolete TODOs and simplify retrieving HardwareCounterCells (#5899)
2025-02-11 14:37:24 +01:00
n0x29a
00933d07ae Strict mode sparsevector (#5841)
* Strict mode sparse vectors
* Update gRPC docs
* Use deny_unknown_fields (#5868)

---------

Co-authored-by: n0x29a <n0x29a@example.com>
Co-authored-by: timvisee <tim@visee.me>
Co-authored-by: Tim Visée <tim+github@visee.me>
Co-authored-by: Arnaud Gourlay <arnaud.gourlay@gmail.com>
2025-01-27 18:25:34 +01:00
Arnaud Gourlay
0140eb83fc Strict mode multivector (#5757)
* strict mode for multivector

* simplify impl

* regen docs
2025-01-23 14:28:01 +01:00
Tim Visée
ffda0b90c8 Bump version to v1.13.0 (#5814)
* Bump version to 1.13

* Update OpenAPI specification

* Update missed cherry picks
2025-01-16 15:06:38 +01:00
Tim Visée
b870197a63 Resharding: expose direction in gRPC API (#5794)
* Expose resharding direction in gRPC API

* Trim whitespaces
2025-01-16 10:50:53 +01:00
Jojii
b870f96513 [Strict mode] limits for filter and conditions (#5754)
* Add limits for filter and conditions

* clippy

* Review remarks + nested condition test

* Fix opnapi specs

* Improve error message by giving info about limits and usage
2025-01-16 10:50:36 +01:00
Tim Visée
2b7fdffb3a Resharding: expose types (#5718)
* Expose resharding related types

* Still hide some fields, end users are not intended to use them

* Remove unused JsonSchema derives
2025-01-16 10:50:28 +01:00
Roman Titov
10c6dcebb7 Remove resharding driver (#5782)
* Remove resharding driver

* Trigger CI 🙄

* fixup! Remove resharding driver

Update OpenAPI spec
2025-01-16 10:50:07 +01:00
Jojii
e87123b767 IO metrics in hw counter types (#5769)
* io metrics in hw counter types

* Add new metrics to `new_with`
2025-01-16 10:49:53 +01:00
Tim Visée
1a340ddc81 Resharding: expose operations in cluster info (#4599)
* Expose resharding operations in cluster info

* Fix collection info conversion to gRPC
2025-01-16 10:49:31 +01:00
Tim Visée
ea2a5818a4 Make resharding UUID required, hide field in OpenAPI schema (#5750) 2025-01-08 14:11:30 +01:00
Tim Visée
c7ab594e82 Resharding: add UUID to resharding operation (#5736)
* Add optional UUID to resharding operations

* Generate random UUID for resharding if not specified by user

* Update OpenAPI specification
2025-01-08 14:11:28 +01:00
Andrey Vasnetsov
0f0e4b4bdb add details-level params to openapi (#5719) 2025-01-08 14:10:46 +01:00
Tim Visée
38a951e938 Expose the PartialSnapshot replica state (#5715) 2025-01-08 14:10:37 +01:00
xzfc
555742f4f1 Add Tango.rs doc (#5688) 2025-01-08 14:09:07 +01:00
Roman Titov
69b7e0e473 Abort scale-down resharding on update error (#5670) 2025-01-08 14:09:01 +01:00
Tim Visée
05e7c48f76 Add task to clean local shard in the background (#5677)
* First naive implementation of local shard clean task

* Add wait and timeout parameters to clean shard API

* Cancel shard cleaning and mark as dirty when changing hash rings

* Expose shards undergoing cleaning in telemetry

* Properly cancel shard clean task, add drop guard to enforce

* Ensure we have a local shard to clean

* Replace existing local shard cleanup API

* Refactor how we create, manage and await clean tasks

* Invalidate only affected shards when committing read hash ring

* Expose all local shard clean task statuses in telemetry

* Properly invalidate shards when aborting resharding

* Add review remark comments

* Log clean task errors, extract task in dedicated function

* Join task when invalidating so we wait for completion

* Invalidate shard clean tasks in a batch to more efficiently join them

* Expose clean progress with number of deleted points

* Annotate cancel safety

* Fix comment

* When calling clean endpoint, ensure we have the specified local shard

* Invalidate shard cleaning when a local shard is being dropped

* Prevent anonymous type in shard clean status telemetry

* Cancel shard clean task directly by dropping future, fix possible deadlock

Before this change trying to invalidate shard cleaning tasks could
deadlock. The actual task only had two cancel points inside a read lock
on the shard holder. The shard holder is constantly released and
relocked.

In some of the places we can trigger invalidation already hold a shard
holder write lock. The task itself would have to grab a read lock in
order to reach the cancel point, in which case the locks would be
fighting each other.

Because invalidation also joins the task and waits for it to abort this
could get stuck forever.

Now we don't have cancellation points anymore and simply drop the whole
future in case of cancellation. That'll prevent it getting stuck.
2025-01-08 14:08:52 +01:00
Tim Visée
3decc3ca20 Fix collection creation validation, disallow replication factor 0 (#5643)
* Validate default collection config in settings

* Validate shard number, replication/write consistency factor in gRPC

* Cleanup

* Add more validation rules

* Also validate strict mode config in gRPC CollectionConfig

* Update OpenAPI specification
2025-01-08 14:08:25 +01:00
Jojii
bf4cae8778 [Strict Mode] Max collection size in distributed setup (#5592)
* Strict Mode: distributed checking of max collection size

* add size projections in distributed mode

* Add consensus tests

* New Test: All nodes in cluster

* fix tests

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

Co-authored-by: Arnaud Gourlay <arnaud.gourlay@gmail.com>

* increase upsert delay

* add TODO for resharding

* wait for strict mode config to be applied on second node

* remove delays

* Also wait for strict mode in other test

* clearify strict mode config option

---------

Co-authored-by: Arnaud Gourlay <arnaud.gourlay@gmail.com>
2025-01-08 14:08:12 +01:00