Skip to main content

qdrant_client/
qdrant.rs

1// This file is @generated by prost-build.
2/// `Struct` represents a structured data value, consisting of fields
3/// which map to dynamically typed values. In some languages, `Struct`
4/// might be supported by a native representation. For example, in
5/// scripting languages like JS a struct is represented as an
6/// object. The details of that representation are described together
7/// with the proto support for the language.
8///
9/// The JSON representation for `Struct` is a JSON object.
10#[derive(Clone, PartialEq, ::prost::Message)]
11pub struct Struct {
12    /// Unordered map of dynamically typed values.
13    #[prost(map = "string, message", tag = "1")]
14    pub fields: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
15}
16/// `Value` represents a dynamically typed value which can be either
17/// null, a number, a string, a boolean, a recursive struct value, or a
18/// list of values. A producer of value is expected to set one of those
19/// variants, absence of any variant indicates an error.
20///
21/// The JSON representation for `Value` is a JSON value.
22#[derive(Clone, PartialEq, ::prost::Message)]
23pub struct Value {
24    /// The kind of value.
25    #[prost(oneof = "value::Kind", tags = "1, 2, 3, 4, 5, 6, 7")]
26    pub kind: ::core::option::Option<value::Kind>,
27}
28/// Nested message and enum types in `Value`.
29pub mod value {
30    /// The kind of value.
31    #[derive(Clone, PartialEq, ::prost::Oneof)]
32    pub enum Kind {
33        /// Represents a null value.
34        #[prost(enumeration = "super::NullValue", tag = "1")]
35        NullValue(i32),
36        /// Represents a double value.
37        #[prost(double, tag = "2")]
38        DoubleValue(f64),
39        /// Represents an integer value
40        #[prost(int64, tag = "3")]
41        IntegerValue(i64),
42        /// Represents a string value.
43        #[prost(string, tag = "4")]
44        StringValue(::prost::alloc::string::String),
45        /// Represents a boolean value.
46        #[prost(bool, tag = "5")]
47        BoolValue(bool),
48        /// Represents a structured value.
49        #[prost(message, tag = "6")]
50        StructValue(super::Struct),
51        /// Represents a repeated `Value`.
52        #[prost(message, tag = "7")]
53        ListValue(super::ListValue),
54    }
55}
56/// `ListValue` is a wrapper around a repeated field of values.
57///
58/// The JSON representation for `ListValue` is a JSON array.
59#[derive(Clone, PartialEq, ::prost::Message)]
60pub struct ListValue {
61    /// Repeated field of dynamically typed values.
62    #[prost(message, repeated, tag = "1")]
63    pub values: ::prost::alloc::vec::Vec<Value>,
64}
65/// `NullValue` is a singleton enumeration to represent the null value for the
66/// `Value` type union.
67///
68/// The JSON representation for `NullValue` is JSON `null`.
69#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
70#[repr(i32)]
71pub enum NullValue {
72    /// Null value.
73    NullValue = 0,
74}
75impl NullValue {
76    /// String value of the enum field names used in the ProtoBuf definition.
77    ///
78    /// The values are not transformed in any way and thus are considered stable
79    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
80    pub fn as_str_name(&self) -> &'static str {
81        match self {
82            Self::NullValue => "NULL_VALUE",
83        }
84    }
85    /// Creates an enum from field names used in the ProtoBuf definition.
86    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
87        match value {
88            "NULL_VALUE" => Some(Self::NullValue),
89            _ => None,
90        }
91    }
92}
93#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
94pub struct PointId {
95    #[prost(oneof = "point_id::PointIdOptions", tags = "1, 2")]
96    pub point_id_options: ::core::option::Option<point_id::PointIdOptions>,
97}
98/// Nested message and enum types in `PointId`.
99pub mod point_id {
100    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
101    pub enum PointIdOptions {
102        /// Numerical ID of the point
103        #[prost(uint64, tag = "1")]
104        Num(u64),
105        /// UUID
106        #[prost(string, tag = "2")]
107        Uuid(::prost::alloc::string::String),
108    }
109}
110#[derive(Clone, Copy, PartialEq, ::prost::Message)]
111pub struct GeoPoint {
112    #[prost(double, tag = "1")]
113    pub lon: f64,
114    #[prost(double, tag = "2")]
115    pub lat: f64,
116}
117#[derive(Clone, PartialEq, ::prost::Message)]
118pub struct Filter {
119    /// At least one of those conditions should match
120    #[prost(message, repeated, tag = "1")]
121    pub should: ::prost::alloc::vec::Vec<Condition>,
122    /// All conditions must match
123    #[prost(message, repeated, tag = "2")]
124    pub must: ::prost::alloc::vec::Vec<Condition>,
125    /// All conditions must NOT match
126    #[prost(message, repeated, tag = "3")]
127    pub must_not: ::prost::alloc::vec::Vec<Condition>,
128    /// At least minimum amount of given conditions should match
129    #[prost(message, optional, tag = "4")]
130    pub min_should: ::core::option::Option<MinShould>,
131}
132#[derive(Clone, PartialEq, ::prost::Message)]
133pub struct MinShould {
134    #[prost(message, repeated, tag = "1")]
135    pub conditions: ::prost::alloc::vec::Vec<Condition>,
136    #[prost(uint64, tag = "2")]
137    pub min_count: u64,
138}
139#[derive(Clone, PartialEq, ::prost::Message)]
140pub struct Condition {
141    #[prost(oneof = "condition::ConditionOneOf", tags = "1, 2, 3, 4, 5, 6, 7, 8")]
142    pub condition_one_of: ::core::option::Option<condition::ConditionOneOf>,
143}
144/// Nested message and enum types in `Condition`.
145pub mod condition {
146    #[derive(Clone, PartialEq, ::prost::Oneof)]
147    pub enum ConditionOneOf {
148        #[prost(message, tag = "1")]
149        Field(super::FieldCondition),
150        #[prost(message, tag = "2")]
151        IsEmpty(super::IsEmptyCondition),
152        #[prost(message, tag = "3")]
153        HasId(super::HasIdCondition),
154        #[prost(message, tag = "4")]
155        Filter(super::Filter),
156        #[prost(message, tag = "5")]
157        IsNull(super::IsNullCondition),
158        #[prost(message, tag = "6")]
159        Nested(super::NestedCondition),
160        #[prost(message, tag = "7")]
161        HasVector(super::HasVectorCondition),
162        #[prost(message, tag = "8")]
163        Slice(super::SliceCondition),
164    }
165}
166#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
167pub struct IsEmptyCondition {
168    #[prost(string, tag = "1")]
169    pub key: ::prost::alloc::string::String,
170}
171#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
172pub struct IsNullCondition {
173    #[prost(string, tag = "1")]
174    pub key: ::prost::alloc::string::String,
175}
176#[derive(Clone, PartialEq, ::prost::Message)]
177pub struct HasIdCondition {
178    #[prost(message, repeated, tag = "1")]
179    pub has_id: ::prost::alloc::vec::Vec<PointId>,
180}
181#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
182pub struct HasVectorCondition {
183    #[prost(string, tag = "1")]
184    pub has_vector: ::prost::alloc::string::String,
185}
186#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
187pub struct SliceCondition {
188    /// Total number of disjoint deterministic slices the id space is split into, must be >= 1
189    #[prost(uint32, tag = "1")]
190    pub total: u32,
191    /// Which slice to select, must be less than `total`
192    #[prost(uint32, tag = "2")]
193    pub index: u32,
194}
195#[derive(Clone, PartialEq, ::prost::Message)]
196pub struct NestedCondition {
197    /// Path to nested object
198    #[prost(string, tag = "1")]
199    pub key: ::prost::alloc::string::String,
200    /// Filter condition
201    #[prost(message, optional, tag = "2")]
202    pub filter: ::core::option::Option<Filter>,
203}
204#[derive(Clone, PartialEq, ::prost::Message)]
205pub struct FieldCondition {
206    #[prost(string, tag = "1")]
207    pub key: ::prost::alloc::string::String,
208    /// Check if point has field with a given value
209    #[prost(message, optional, tag = "2")]
210    pub r#match: ::core::option::Option<Match>,
211    /// Check if points value lies in a given range
212    #[prost(message, optional, tag = "3")]
213    pub range: ::core::option::Option<Range>,
214    /// Check if points geolocation lies in a given area
215    #[prost(message, optional, tag = "4")]
216    pub geo_bounding_box: ::core::option::Option<GeoBoundingBox>,
217    /// Check if geo point is within a given radius
218    #[prost(message, optional, tag = "5")]
219    pub geo_radius: ::core::option::Option<GeoRadius>,
220    /// Check number of values for a specific field
221    #[prost(message, optional, tag = "6")]
222    pub values_count: ::core::option::Option<ValuesCount>,
223    /// Check if geo point is within a given polygon
224    #[prost(message, optional, tag = "7")]
225    pub geo_polygon: ::core::option::Option<GeoPolygon>,
226    /// Check if datetime is within a given range
227    #[prost(message, optional, tag = "8")]
228    pub datetime_range: ::core::option::Option<DatetimeRange>,
229    /// Check if field is empty
230    #[prost(bool, optional, tag = "9")]
231    pub is_empty: ::core::option::Option<bool>,
232    /// Check if field is null
233    #[prost(bool, optional, tag = "10")]
234    pub is_null: ::core::option::Option<bool>,
235}
236#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
237pub struct Match {
238    #[prost(
239        oneof = "r#match::MatchValue",
240        tags = "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12"
241    )]
242    pub match_value: ::core::option::Option<r#match::MatchValue>,
243}
244/// Nested message and enum types in `Match`.
245pub mod r#match {
246    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
247    pub enum MatchValue {
248        /// Match string keyword
249        #[prost(string, tag = "1")]
250        Keyword(::prost::alloc::string::String),
251        /// Match integer
252        #[prost(int64, tag = "2")]
253        Integer(i64),
254        /// Match boolean
255        #[prost(bool, tag = "3")]
256        Boolean(bool),
257        /// Match text
258        #[prost(string, tag = "4")]
259        Text(::prost::alloc::string::String),
260        /// Match multiple keywords
261        #[prost(message, tag = "5")]
262        Keywords(super::RepeatedStrings),
263        /// Match multiple integers
264        #[prost(message, tag = "6")]
265        Integers(super::RepeatedIntegers),
266        /// Match any other value except those integers
267        #[prost(message, tag = "7")]
268        ExceptIntegers(super::RepeatedIntegers),
269        /// Match any other value except those keywords
270        #[prost(message, tag = "8")]
271        ExceptKeywords(super::RepeatedStrings),
272        /// Match phrase text
273        #[prost(string, tag = "9")]
274        Phrase(::prost::alloc::string::String),
275        /// Match any word in the text
276        #[prost(string, tag = "10")]
277        TextAny(::prost::alloc::string::String),
278        /// Match keywords starting with the given prefix
279        #[prost(string, tag = "11")]
280        Prefix(::prost::alloc::string::String),
281        /// Match keywords containing the given substring
282        #[prost(string, tag = "12")]
283        Substring(::prost::alloc::string::String),
284    }
285}
286#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
287pub struct RepeatedStrings {
288    #[prost(string, repeated, tag = "1")]
289    pub strings: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
290}
291#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
292pub struct RepeatedIntegers {
293    #[prost(int64, repeated, tag = "1")]
294    pub integers: ::prost::alloc::vec::Vec<i64>,
295}
296#[derive(Clone, Copy, PartialEq, ::prost::Message)]
297pub struct Range {
298    #[prost(double, optional, tag = "1")]
299    pub lt: ::core::option::Option<f64>,
300    #[prost(double, optional, tag = "2")]
301    pub gt: ::core::option::Option<f64>,
302    #[prost(double, optional, tag = "3")]
303    pub gte: ::core::option::Option<f64>,
304    #[prost(double, optional, tag = "4")]
305    pub lte: ::core::option::Option<f64>,
306}
307#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
308pub struct DatetimeRange {
309    #[prost(message, optional, tag = "1")]
310    pub lt: ::core::option::Option<::prost_types::Timestamp>,
311    #[prost(message, optional, tag = "2")]
312    pub gt: ::core::option::Option<::prost_types::Timestamp>,
313    #[prost(message, optional, tag = "3")]
314    pub gte: ::core::option::Option<::prost_types::Timestamp>,
315    #[prost(message, optional, tag = "4")]
316    pub lte: ::core::option::Option<::prost_types::Timestamp>,
317}
318#[derive(Clone, Copy, PartialEq, ::prost::Message)]
319pub struct GeoBoundingBox {
320    /// north-west corner
321    #[prost(message, optional, tag = "1")]
322    pub top_left: ::core::option::Option<GeoPoint>,
323    /// south-east corner
324    #[prost(message, optional, tag = "2")]
325    pub bottom_right: ::core::option::Option<GeoPoint>,
326}
327#[derive(Clone, Copy, PartialEq, ::prost::Message)]
328pub struct GeoRadius {
329    /// Center of the circle
330    #[prost(message, optional, tag = "1")]
331    pub center: ::core::option::Option<GeoPoint>,
332    /// In meters
333    #[prost(float, tag = "2")]
334    pub radius: f32,
335}
336#[derive(Clone, PartialEq, ::prost::Message)]
337pub struct GeoLineString {
338    /// Ordered sequence of GeoPoints representing the line
339    #[prost(message, repeated, tag = "1")]
340    pub points: ::prost::alloc::vec::Vec<GeoPoint>,
341}
342/// For a valid GeoPolygon, both the exterior and interior GeoLineStrings must
343/// consist of a minimum of 4 points.
344/// Additionally, the first and last points of each GeoLineString must be the same.
345#[derive(Clone, PartialEq, ::prost::Message)]
346pub struct GeoPolygon {
347    /// The exterior line bounds the surface
348    #[prost(message, optional, tag = "1")]
349    pub exterior: ::core::option::Option<GeoLineString>,
350    /// Interior lines (if present) bound holes within the surface
351    #[prost(message, repeated, tag = "2")]
352    pub interiors: ::prost::alloc::vec::Vec<GeoLineString>,
353}
354#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
355pub struct ValuesCount {
356    #[prost(uint64, optional, tag = "1")]
357    pub lt: ::core::option::Option<u64>,
358    #[prost(uint64, optional, tag = "2")]
359    pub gt: ::core::option::Option<u64>,
360    #[prost(uint64, optional, tag = "3")]
361    pub gte: ::core::option::Option<u64>,
362    #[prost(uint64, optional, tag = "4")]
363    pub lte: ::core::option::Option<u64>,
364}
365#[derive(Clone, Copy, PartialEq, ::prost::Message)]
366pub struct VectorParams {
367    /// Size of the vectors
368    #[prost(uint64, tag = "1")]
369    pub size: u64,
370    /// Distance function used for comparing vectors
371    #[prost(enumeration = "Distance", tag = "2")]
372    pub distance: i32,
373    /// Configuration of vector HNSW graph.
374    /// If omitted - the collection configuration will be used
375    #[prost(message, optional, tag = "3")]
376    pub hnsw_config: ::core::option::Option<HnswConfigDiff>,
377    /// Configuration of vector quantization config.
378    /// If omitted - the collection configuration will be used
379    #[prost(message, optional, tag = "4")]
380    pub quantization_config: ::core::option::Option<QuantizationConfig>,
381    /// Deprecated: use `memory` instead.
382    /// If true - serve vectors from disk.
383    /// If set to false, the vectors will be loaded in RAM.
384    #[deprecated]
385    #[prost(bool, optional, tag = "5")]
386    pub on_disk: ::core::option::Option<bool>,
387    /// Data type of the vectors
388    #[prost(enumeration = "Datatype", optional, tag = "6")]
389    pub datatype: ::core::option::Option<i32>,
390    /// Configuration for multi-vector search
391    #[prost(message, optional, tag = "7")]
392    pub multivector_config: ::core::option::Option<MultiVectorConfig>,
393    /// Memory placement of the original vector storage.
394    /// Overrides the deprecated `on_disk` flag if both are set.
395    /// `Pinned` is not supported for dense vector storage.
396    #[prost(enumeration = "Memory", optional, tag = "8")]
397    pub memory: ::core::option::Option<i32>,
398}
399#[derive(Clone, Copy, PartialEq, ::prost::Message)]
400pub struct VectorParamsDiff {
401    /// Update params for HNSW index.
402    /// If empty object - it will be unset
403    #[prost(message, optional, tag = "1")]
404    pub hnsw_config: ::core::option::Option<HnswConfigDiff>,
405    /// Update quantization params. If none - it is left unchanged.
406    #[prost(message, optional, tag = "2")]
407    pub quantization_config: ::core::option::Option<QuantizationConfigDiff>,
408    /// Deprecated: use `memory` instead.
409    /// If true - serve vectors from disk.
410    /// If set to false, the vectors will be loaded in RAM.
411    #[deprecated]
412    #[prost(bool, optional, tag = "3")]
413    pub on_disk: ::core::option::Option<bool>,
414    /// Memory placement of the original vector storage.
415    /// Overrides the deprecated `on_disk` flag if both are set.
416    /// `Pinned` is not supported for dense vector storage.
417    #[prost(enumeration = "Memory", optional, tag = "4")]
418    pub memory: ::core::option::Option<i32>,
419}
420#[derive(Clone, PartialEq, ::prost::Message)]
421pub struct VectorParamsMap {
422    #[prost(map = "string, message", tag = "1")]
423    pub map: ::std::collections::HashMap<::prost::alloc::string::String, VectorParams>,
424}
425#[derive(Clone, PartialEq, ::prost::Message)]
426pub struct VectorParamsDiffMap {
427    #[prost(map = "string, message", tag = "1")]
428    pub map: ::std::collections::HashMap<
429        ::prost::alloc::string::String,
430        VectorParamsDiff,
431    >,
432}
433#[derive(Clone, PartialEq, ::prost::Message)]
434pub struct VectorsConfig {
435    #[prost(oneof = "vectors_config::Config", tags = "1, 2")]
436    pub config: ::core::option::Option<vectors_config::Config>,
437}
438/// Nested message and enum types in `VectorsConfig`.
439pub mod vectors_config {
440    #[derive(Clone, PartialEq, ::prost::Oneof)]
441    pub enum Config {
442        #[prost(message, tag = "1")]
443        Params(super::VectorParams),
444        #[prost(message, tag = "2")]
445        ParamsMap(super::VectorParamsMap),
446    }
447}
448#[derive(Clone, PartialEq, ::prost::Message)]
449pub struct VectorsConfigDiff {
450    #[prost(oneof = "vectors_config_diff::Config", tags = "1, 2")]
451    pub config: ::core::option::Option<vectors_config_diff::Config>,
452}
453/// Nested message and enum types in `VectorsConfigDiff`.
454pub mod vectors_config_diff {
455    #[derive(Clone, PartialEq, ::prost::Oneof)]
456    pub enum Config {
457        #[prost(message, tag = "1")]
458        Params(super::VectorParamsDiff),
459        #[prost(message, tag = "2")]
460        ParamsMap(super::VectorParamsDiffMap),
461    }
462}
463#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
464pub struct SparseVectorParams {
465    /// Configuration of sparse index
466    #[prost(message, optional, tag = "1")]
467    pub index: ::core::option::Option<SparseIndexConfig>,
468    /// If set - apply modifier to the vector values
469    #[prost(enumeration = "Modifier", optional, tag = "2")]
470    pub modifier: ::core::option::Option<i32>,
471}
472#[derive(Clone, PartialEq, ::prost::Message)]
473pub struct SparseVectorConfig {
474    #[prost(map = "string, message", tag = "1")]
475    pub map: ::std::collections::HashMap<
476        ::prost::alloc::string::String,
477        SparseVectorParams,
478    >,
479}
480#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
481pub struct MultiVectorConfig {
482    /// Comparator for multi-vector search
483    #[prost(enumeration = "MultiVectorComparator", tag = "1")]
484    pub comparator: i32,
485}
486#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
487pub struct GetCollectionInfoRequest {
488    /// Name of the collection
489    #[prost(string, tag = "1")]
490    pub collection_name: ::prost::alloc::string::String,
491}
492#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
493pub struct CollectionExistsRequest {
494    #[prost(string, tag = "1")]
495    pub collection_name: ::prost::alloc::string::String,
496}
497#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
498pub struct CollectionExists {
499    #[prost(bool, tag = "1")]
500    pub exists: bool,
501}
502#[derive(Clone, Copy, PartialEq, ::prost::Message)]
503pub struct CollectionExistsResponse {
504    #[prost(message, optional, tag = "1")]
505    pub result: ::core::option::Option<CollectionExists>,
506    /// Time spent to process
507    #[prost(double, tag = "2")]
508    pub time: f64,
509}
510#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
511pub struct ListCollectionsRequest {}
512#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
513pub struct CollectionDescription {
514    /// Name of the collection
515    #[prost(string, tag = "1")]
516    pub name: ::prost::alloc::string::String,
517}
518#[derive(Clone, PartialEq, ::prost::Message)]
519pub struct GetCollectionInfoResponse {
520    #[prost(message, optional, tag = "1")]
521    pub result: ::core::option::Option<CollectionInfo>,
522    /// Time spent to process
523    #[prost(double, tag = "2")]
524    pub time: f64,
525}
526#[derive(Clone, PartialEq, ::prost::Message)]
527pub struct ListCollectionsResponse {
528    #[prost(message, repeated, tag = "1")]
529    pub collections: ::prost::alloc::vec::Vec<CollectionDescription>,
530    /// Time spent to process
531    #[prost(double, tag = "2")]
532    pub time: f64,
533}
534#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
535pub struct MaxOptimizationThreads {
536    #[prost(oneof = "max_optimization_threads::Variant", tags = "1, 2")]
537    pub variant: ::core::option::Option<max_optimization_threads::Variant>,
538}
539/// Nested message and enum types in `MaxOptimizationThreads`.
540pub mod max_optimization_threads {
541    #[derive(
542        Clone,
543        Copy,
544        Debug,
545        PartialEq,
546        Eq,
547        Hash,
548        PartialOrd,
549        Ord,
550        ::prost::Enumeration
551    )]
552    #[repr(i32)]
553    pub enum Setting {
554        Auto = 0,
555    }
556    impl Setting {
557        /// String value of the enum field names used in the ProtoBuf definition.
558        ///
559        /// The values are not transformed in any way and thus are considered stable
560        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
561        pub fn as_str_name(&self) -> &'static str {
562            match self {
563                Self::Auto => "Auto",
564            }
565        }
566        /// Creates an enum from field names used in the ProtoBuf definition.
567        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
568            match value {
569                "Auto" => Some(Self::Auto),
570                _ => None,
571            }
572        }
573    }
574    #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
575    pub enum Variant {
576        #[prost(uint64, tag = "1")]
577        Value(u64),
578        #[prost(enumeration = "Setting", tag = "2")]
579        Setting(i32),
580    }
581}
582#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
583pub struct OptimizerStatus {
584    #[prost(bool, tag = "1")]
585    pub ok: bool,
586    #[prost(string, tag = "2")]
587    pub error: ::prost::alloc::string::String,
588}
589#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
590pub struct CollectionWarning {
591    #[prost(string, tag = "1")]
592    pub message: ::prost::alloc::string::String,
593}
594#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
595pub struct HnswConfigDiff {
596    /// Number of edges per node in the index graph.
597    /// Larger the value - more accurate the search, more space required.
598    /// Set to 0 to disable the main HNSW graph. Additional payload-aware links
599    /// may still be built when the effective payload M is positive (see payload_m).
600    /// This setting alone does not guarantee exact search.
601    #[prost(uint64, optional, tag = "1")]
602    pub m: ::core::option::Option<u64>,
603    /// Number of neighbours to consider during the index building.
604    /// Larger the value - more accurate the search, more time required to build the index.
605    #[prost(uint64, optional, tag = "2")]
606    pub ef_construct: ::core::option::Option<u64>,
607    /// Minimal size threshold (in KiloBytes) below which full-scan is preferred over HNSW search.
608    /// This measures the total size of vectors being queried against.
609    /// When the maximum estimated amount of points that a condition satisfies is smaller than
610    /// `full_scan_threshold`, the query planner will use full-scan search instead of HNSW index
611    /// traversal for better performance.
612    /// Note: 1Kb = 1 vector of size 256
613    #[prost(uint64, optional, tag = "3")]
614    pub full_scan_threshold: ::core::option::Option<u64>,
615    /// Number of parallel threads used for background index building.
616    /// If 0 - automatically select from 8 to 16.
617    /// Best to keep between 8 and 16 to prevent likelihood of building broken/inefficient HNSW graphs.
618    /// On small CPUs, less threads are used.
619    #[prost(uint64, optional, tag = "4")]
620    pub max_indexing_threads: ::core::option::Option<u64>,
621    /// Deprecated: use `memory` instead.
622    /// Store HNSW index on disk. If set to false, the index will be stored in RAM.
623    #[deprecated]
624    #[prost(bool, optional, tag = "5")]
625    pub on_disk: ::core::option::Option<bool>,
626    /// Number of additional payload-aware links per node. If unset, the value of m is used.
627    /// An effective value of 0 disables these additional links. A positive value allows
628    /// them for indexed payload fields with HNSW enabled, even when m is 0.
629    #[prost(uint64, optional, tag = "6")]
630    pub payload_m: ::core::option::Option<u64>,
631    /// Store copies of original and quantized vectors within the HNSW index file. Default: false.
632    /// Enabling this option will trade the search speed for disk usage by reducing amount of
633    /// random seeks during the search.
634    /// Requires quantized vectors to be enabled. Multi-vectors are not supported.
635    #[prost(bool, optional, tag = "7")]
636    pub inline_storage: ::core::option::Option<bool>,
637    /// Memory placement of the HNSW graph.
638    /// Overrides the deprecated `on_disk` flag if both are set.
639    #[prost(enumeration = "Memory", optional, tag = "8")]
640    pub memory: ::core::option::Option<i32>,
641}
642#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
643pub struct SparseIndexConfig {
644    /// Prefer a full scan search upto (excluding) this number of vectors.
645    /// Note: this is number of vectors, not KiloBytes.
646    #[prost(uint64, optional, tag = "1")]
647    pub full_scan_threshold: ::core::option::Option<u64>,
648    /// Deprecated: use `memory` instead.
649    /// Store inverted index on disk. If set to false, the index will be stored in RAM.
650    #[deprecated]
651    #[prost(bool, optional, tag = "2")]
652    pub on_disk: ::core::option::Option<bool>,
653    /// Datatype used to store weights in the index.
654    #[prost(enumeration = "Datatype", optional, tag = "3")]
655    pub datatype: ::core::option::Option<i32>,
656    /// Memory placement of the index.
657    /// Overrides the deprecated `on_disk` flag if both are set.
658    #[prost(enumeration = "Memory", optional, tag = "4")]
659    pub memory: ::core::option::Option<i32>,
660}
661#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
662pub struct WalConfigDiff {
663    /// Size of a single WAL block file
664    #[prost(uint64, optional, tag = "1")]
665    pub wal_capacity_mb: ::core::option::Option<u64>,
666    /// Number of segments to create in advance
667    #[prost(uint64, optional, tag = "2")]
668    pub wal_segments_ahead: ::core::option::Option<u64>,
669    /// Number of closed segments to retain
670    #[prost(uint64, optional, tag = "3")]
671    pub wal_retain_closed: ::core::option::Option<u64>,
672}
673#[derive(Clone, Copy, PartialEq, ::prost::Message)]
674pub struct OptimizersConfigDiff {
675    /// The minimal fraction of deleted vectors in a segment, required to perform
676    /// segment optimization
677    #[prost(double, optional, tag = "1")]
678    pub deleted_threshold: ::core::option::Option<f64>,
679    /// The minimal number of vectors in a segment, required to perform segment
680    /// optimization
681    #[prost(uint64, optional, tag = "2")]
682    pub vacuum_min_vector_number: ::core::option::Option<u64>,
683    /// Target amount of segments the optimizer will try to keep.
684    /// Real amount of segments may vary depending on multiple parameters:
685    ///
686    /// * Amount of stored points.
687    /// * Current write RPS.
688    ///
689    /// It is recommended to select the default number of segments as a factor of the number of search threads,
690    /// so that each segment would be handled evenly by one of the threads.
691    #[prost(uint64, optional, tag = "3")]
692    pub default_segment_number: ::core::option::Option<u64>,
693    /// Deprecated:
694    ///
695    /// Do not create segments larger than this size (in kilobytes).
696    /// Large segments might require disproportionately long indexation times,
697    /// therefore it makes sense to limit the size of segments.
698    ///
699    /// If indexing speed is more important - make this parameter lower.
700    /// If search speed is more important - make this parameter higher.
701    /// Note: 1Kb = 1 vector of size 256
702    /// If not set, will be automatically selected considering the number of available CPUs.
703    #[prost(uint64, optional, tag = "4")]
704    pub max_segment_size: ::core::option::Option<u64>,
705    /// Maximum size (in kilobytes) of vectors to store in-memory per segment.
706    /// Segments larger than this threshold will be stored as read-only memmapped file.
707    ///
708    /// Memmap storage is disabled by default, to enable it, set this threshold to a reasonable value.
709    ///
710    /// To disable memmap storage, set this to `0`.
711    ///
712    /// Note: 1Kb = 1 vector of size 256
713    #[prost(uint64, optional, tag = "5")]
714    pub memmap_threshold: ::core::option::Option<u64>,
715    /// Maximum size (in kilobytes) of vectors allowed for plain index, exceeding
716    /// this threshold will enable vector indexing
717    ///
718    /// Default value is 20,000, based on
719    /// <<https://github.com/google-research/google-research/blob/master/scann/docs/algorithms.md>.>
720    ///
721    /// To disable vector indexing, set to `0`.
722    ///
723    /// Note: 1kB = 1 vector of size 256.
724    #[prost(uint64, optional, tag = "6")]
725    pub indexing_threshold: ::core::option::Option<u64>,
726    /// Interval between forced flushes.
727    #[prost(uint64, optional, tag = "7")]
728    pub flush_interval_sec: ::core::option::Option<u64>,
729    /// Deprecated in favor of `max_optimization_threads`
730    #[prost(uint64, optional, tag = "8")]
731    pub deprecated_max_optimization_threads: ::core::option::Option<u64>,
732    /// Max number of threads (jobs) for running optimizations per shard.
733    /// Note: each optimization job will also use `max_indexing_threads` threads by itself for index building.
734    /// If "auto" - have no limit and choose dynamically to saturate CPU.
735    /// If 0 - no optimization threads, optimizations will be disabled.
736    #[prost(message, optional, tag = "9")]
737    pub max_optimization_threads: ::core::option::Option<MaxOptimizationThreads>,
738    /// If enabled, the service will try to prevent the creation of large unoptimized segments.
739    /// When enabled, new points written to segments larger than the indexing threshold are stored
740    /// as "deferred points": they are persisted in the WAL and segments, but excluded from
741    /// read/search results until the corresponding segments are optimized (e.g. indexed,
742    /// quantized, or moved to mmap storage).
743    /// Update requests with wait=true will only return after the deferred points become visible,
744    /// which may significantly increase the perceived latency between submitting an update and its
745    /// completion. Update requests with wait=false are not affected.
746    /// Default is disabled.
747    #[prost(bool, optional, tag = "10")]
748    pub prevent_unoptimized: ::core::option::Option<bool>,
749}
750#[derive(Clone, Copy, PartialEq, ::prost::Message)]
751pub struct ScalarQuantization {
752    /// Type of quantization
753    #[prost(enumeration = "QuantizationType", tag = "1")]
754    pub r#type: i32,
755    /// Number of bits to use for quantization
756    #[prost(float, optional, tag = "2")]
757    pub quantile: ::core::option::Option<f32>,
758    /// Deprecated: use `memory` instead.
759    /// If true - quantized vectors always will be stored in RAM, ignoring the config of main storage
760    #[deprecated]
761    #[prost(bool, optional, tag = "3")]
762    pub always_ram: ::core::option::Option<bool>,
763    /// Memory placement of quantized vectors.
764    /// Overrides the deprecated `always_ram` flag if both are set.
765    #[prost(enumeration = "Memory", optional, tag = "4")]
766    pub memory: ::core::option::Option<i32>,
767}
768#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
769pub struct ProductQuantization {
770    /// Compression ratio
771    #[prost(enumeration = "CompressionRatio", tag = "1")]
772    pub compression: i32,
773    /// Deprecated: use `memory` instead.
774    /// If true - quantized vectors always will be stored in RAM, ignoring the config of main storage
775    #[deprecated]
776    #[prost(bool, optional, tag = "2")]
777    pub always_ram: ::core::option::Option<bool>,
778    /// Memory placement of quantized vectors.
779    /// Overrides the deprecated `always_ram` flag if both are set.
780    #[prost(enumeration = "Memory", optional, tag = "3")]
781    pub memory: ::core::option::Option<i32>,
782}
783#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
784pub struct BinaryQuantizationQueryEncoding {
785    #[prost(oneof = "binary_quantization_query_encoding::Variant", tags = "4")]
786    pub variant: ::core::option::Option<binary_quantization_query_encoding::Variant>,
787}
788/// Nested message and enum types in `BinaryQuantizationQueryEncoding`.
789pub mod binary_quantization_query_encoding {
790    #[derive(
791        Clone,
792        Copy,
793        Debug,
794        PartialEq,
795        Eq,
796        Hash,
797        PartialOrd,
798        Ord,
799        ::prost::Enumeration
800    )]
801    #[repr(i32)]
802    pub enum Setting {
803        Default = 0,
804        Binary = 1,
805        Scalar4Bits = 2,
806        Scalar8Bits = 3,
807    }
808    impl Setting {
809        /// String value of the enum field names used in the ProtoBuf definition.
810        ///
811        /// The values are not transformed in any way and thus are considered stable
812        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
813        pub fn as_str_name(&self) -> &'static str {
814            match self {
815                Self::Default => "Default",
816                Self::Binary => "Binary",
817                Self::Scalar4Bits => "Scalar4Bits",
818                Self::Scalar8Bits => "Scalar8Bits",
819            }
820        }
821        /// Creates an enum from field names used in the ProtoBuf definition.
822        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
823            match value {
824                "Default" => Some(Self::Default),
825                "Binary" => Some(Self::Binary),
826                "Scalar4Bits" => Some(Self::Scalar4Bits),
827                "Scalar8Bits" => Some(Self::Scalar8Bits),
828                _ => None,
829            }
830        }
831    }
832    #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
833    pub enum Variant {
834        #[prost(enumeration = "Setting", tag = "4")]
835        Setting(i32),
836    }
837}
838#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
839pub struct BinaryQuantization {
840    /// Deprecated: use `memory` instead.
841    /// If true - quantized vectors always will be stored in RAM, ignoring the config of main storage
842    #[deprecated]
843    #[prost(bool, optional, tag = "1")]
844    pub always_ram: ::core::option::Option<bool>,
845    /// Binary quantization encoding method
846    #[prost(enumeration = "BinaryQuantizationEncoding", optional, tag = "2")]
847    pub encoding: ::core::option::Option<i32>,
848    /// Asymmetric quantization configuration allows a query to have different
849    /// quantization than stored vectors.
850    /// It can increase the accuracy of search at the cost of performance.
851    #[prost(message, optional, tag = "3")]
852    pub query_encoding: ::core::option::Option<BinaryQuantizationQueryEncoding>,
853    /// Memory placement of quantized vectors.
854    /// Overrides the deprecated `always_ram` flag if both are set.
855    #[prost(enumeration = "Memory", optional, tag = "4")]
856    pub memory: ::core::option::Option<i32>,
857}
858#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
859pub struct TurboQuantization {
860    /// Deprecated: use `memory` instead.
861    #[deprecated]
862    #[prost(bool, optional, tag = "1")]
863    pub always_ram: ::core::option::Option<bool>,
864    #[prost(enumeration = "TurboQuantBitSize", optional, tag = "2")]
865    pub bits: ::core::option::Option<i32>,
866    /// Memory placement of quantized vectors.
867    /// Overrides the deprecated `always_ram` flag if both are set.
868    #[prost(enumeration = "Memory", optional, tag = "3")]
869    pub memory: ::core::option::Option<i32>,
870}
871#[derive(Clone, Copy, PartialEq, ::prost::Message)]
872pub struct QuantizationConfig {
873    #[prost(oneof = "quantization_config::Quantization", tags = "1, 2, 3, 4")]
874    pub quantization: ::core::option::Option<quantization_config::Quantization>,
875}
876/// Nested message and enum types in `QuantizationConfig`.
877pub mod quantization_config {
878    #[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
879    pub enum Quantization {
880        #[prost(message, tag = "1")]
881        Scalar(super::ScalarQuantization),
882        #[prost(message, tag = "2")]
883        Product(super::ProductQuantization),
884        #[prost(message, tag = "3")]
885        Binary(super::BinaryQuantization),
886        #[prost(message, tag = "4")]
887        Turboquant(super::TurboQuantization),
888    }
889}
890#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
891pub struct Disabled {}
892#[derive(Clone, Copy, PartialEq, ::prost::Message)]
893pub struct QuantizationConfigDiff {
894    #[prost(oneof = "quantization_config_diff::Quantization", tags = "1, 2, 3, 4, 5")]
895    pub quantization: ::core::option::Option<quantization_config_diff::Quantization>,
896}
897/// Nested message and enum types in `QuantizationConfigDiff`.
898pub mod quantization_config_diff {
899    #[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
900    pub enum Quantization {
901        #[prost(message, tag = "1")]
902        Scalar(super::ScalarQuantization),
903        #[prost(message, tag = "2")]
904        Product(super::ProductQuantization),
905        #[prost(message, tag = "3")]
906        Disabled(super::Disabled),
907        #[prost(message, tag = "4")]
908        Binary(super::BinaryQuantization),
909        #[prost(message, tag = "5")]
910        Turboquant(super::TurboQuantization),
911    }
912}
913#[derive(Clone, PartialEq, ::prost::Message)]
914pub struct StrictModeConfig {
915    /// Whether strict mode is enabled for a collection or not.
916    #[prost(bool, optional, tag = "1")]
917    pub enabled: ::core::option::Option<bool>,
918    /// Max allowed `limit` parameter for all APIs that don't have their own max limit.
919    #[prost(uint32, optional, tag = "2")]
920    pub max_query_limit: ::core::option::Option<u32>,
921    /// Max allowed `timeout` parameter.
922    #[prost(uint32, optional, tag = "3")]
923    pub max_timeout: ::core::option::Option<u32>,
924    /// Allow usage of unindexed fields in retrieval based (e.g. search) filters.
925    #[prost(bool, optional, tag = "4")]
926    pub unindexed_filtering_retrieve: ::core::option::Option<bool>,
927    /// Allow usage of unindexed fields in filtered updates (e.g. delete by payload).
928    #[prost(bool, optional, tag = "5")]
929    pub unindexed_filtering_update: ::core::option::Option<bool>,
930    /// Max HNSW ef value allowed in search parameters.
931    #[prost(uint32, optional, tag = "6")]
932    pub search_max_hnsw_ef: ::core::option::Option<u32>,
933    /// Whether exact search is allowed.
934    #[prost(bool, optional, tag = "7")]
935    pub search_allow_exact: ::core::option::Option<bool>,
936    /// Max oversampling value allowed in search
937    #[prost(float, optional, tag = "8")]
938    pub search_max_oversampling: ::core::option::Option<f32>,
939    /// Max batchsize when upserting
940    #[prost(uint64, optional, tag = "9")]
941    pub upsert_max_batchsize: ::core::option::Option<u64>,
942    /// Max batchsize when searching
943    #[prost(uint64, optional, tag = "20")]
944    pub search_max_batchsize: ::core::option::Option<u64>,
945    /// Max size of a collections vector storage in bytes, ignoring replicas.
946    #[prost(uint64, optional, tag = "10")]
947    pub max_collection_vector_size_bytes: ::core::option::Option<u64>,
948    /// Max number of read operations per minute per replica
949    #[prost(uint32, optional, tag = "11")]
950    pub read_rate_limit: ::core::option::Option<u32>,
951    /// Max number of write operations per minute per replica
952    #[prost(uint32, optional, tag = "12")]
953    pub write_rate_limit: ::core::option::Option<u32>,
954    /// Max size of a collections payload storage in bytes, ignoring replicas.
955    #[prost(uint64, optional, tag = "13")]
956    pub max_collection_payload_size_bytes: ::core::option::Option<u64>,
957    /// Max conditions a filter can have.
958    #[prost(uint64, optional, tag = "14")]
959    pub filter_max_conditions: ::core::option::Option<u64>,
960    /// Max size of a condition, eg. items in `MatchAny`.
961    #[prost(uint64, optional, tag = "15")]
962    pub condition_max_size: ::core::option::Option<u64>,
963    /// Multivector strict mode configuration
964    #[prost(message, optional, tag = "16")]
965    pub multivector_config: ::core::option::Option<StrictModeMultivectorConfig>,
966    /// Sparse vector strict mode configuration
967    #[prost(message, optional, tag = "17")]
968    pub sparse_config: ::core::option::Option<StrictModeSparseConfig>,
969    /// Max number of points estimated in a collection
970    #[prost(uint64, optional, tag = "18")]
971    pub max_points_count: ::core::option::Option<u64>,
972    /// Max number of payload indexes in a collection
973    #[prost(uint64, optional, tag = "19")]
974    pub max_payload_index_count: ::core::option::Option<u64>,
975    /// Deprecated: memory is node-wide, use the global quota config instead. Removal planned for 1.21.
976    /// Reject memory-consuming update operations when process resident memory exceeds this percentage of total RAM (cgroup-aware, 1-100).
977    /// Delete-style operations are still allowed so memory can be freed.
978    #[deprecated]
979    #[prost(uint32, optional, tag = "21")]
980    pub max_resident_memory_percent: ::core::option::Option<u32>,
981}
982#[derive(Clone, PartialEq, ::prost::Message)]
983pub struct StrictModeSparseConfig {
984    #[prost(map = "string, message", tag = "1")]
985    pub sparse_config: ::std::collections::HashMap<
986        ::prost::alloc::string::String,
987        StrictModeSparse,
988    >,
989}
990#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
991pub struct StrictModeSparse {
992    /// Max length of sparse vector
993    #[prost(uint64, optional, tag = "10")]
994    pub max_length: ::core::option::Option<u64>,
995}
996#[derive(Clone, PartialEq, ::prost::Message)]
997pub struct StrictModeMultivectorConfig {
998    #[prost(map = "string, message", tag = "1")]
999    pub multivector_config: ::std::collections::HashMap<
1000        ::prost::alloc::string::String,
1001        StrictModeMultivector,
1002    >,
1003}
1004#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1005pub struct StrictModeMultivector {
1006    /// Max number of vectors in a multivector
1007    #[prost(uint64, optional, tag = "1")]
1008    pub max_vectors: ::core::option::Option<u64>,
1009}
1010/// Params of the payload storage
1011#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1012pub struct PayloadStorageParams {
1013    /// Memory placement of the payload storage.
1014    /// Overrides the deprecated `on_disk_payload` flag if both are set.
1015    /// `Pinned` is not supported for payload storage.
1016    #[prost(enumeration = "Memory", optional, tag = "1")]
1017    pub memory: ::core::option::Option<i32>,
1018}
1019#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1020pub struct IdTrackerParams {
1021    /// Memory placement of the point id mapping in indexed segments:
1022    /// `Cold` keeps it on disk and reads it on demand, `Cached` keeps it on disk
1023    /// but primes the page cache with it on load, `Pinned` keeps it in RAM.
1024    #[prost(enumeration = "Memory", optional, tag = "1")]
1025    pub memory: ::core::option::Option<i32>,
1026}
1027#[derive(Clone, PartialEq, ::prost::Message)]
1028pub struct CreateCollection {
1029    /// Name of the collection
1030    #[prost(string, tag = "1")]
1031    pub collection_name: ::prost::alloc::string::String,
1032    /// Configuration of vector index
1033    #[prost(message, optional, tag = "4")]
1034    pub hnsw_config: ::core::option::Option<HnswConfigDiff>,
1035    /// Configuration of the Write-Ahead-Log
1036    #[prost(message, optional, tag = "5")]
1037    pub wal_config: ::core::option::Option<WalConfigDiff>,
1038    /// Configuration of the optimizers
1039    #[prost(message, optional, tag = "6")]
1040    pub optimizers_config: ::core::option::Option<OptimizersConfigDiff>,
1041    /// Number of shards in the collection, default is 1 for standalone, otherwise
1042    /// equal to the number of nodes. Minimum is 1
1043    #[prost(uint32, optional, tag = "7")]
1044    pub shard_number: ::core::option::Option<u32>,
1045    /// Deprecated: use `payload.memory` instead.
1046    /// If true - point's payload will not be stored in memory
1047    #[deprecated]
1048    #[prost(bool, optional, tag = "8")]
1049    pub on_disk_payload: ::core::option::Option<bool>,
1050    /// Wait timeout for operation commit in seconds, if not specified - default
1051    /// value will be supplied
1052    #[prost(uint64, optional, tag = "9")]
1053    pub timeout: ::core::option::Option<u64>,
1054    /// Configuration for vectors
1055    #[prost(message, optional, tag = "10")]
1056    pub vectors_config: ::core::option::Option<VectorsConfig>,
1057    /// Number of replicas of each shard that network tries to maintain, default = 1
1058    #[prost(uint32, optional, tag = "11")]
1059    pub replication_factor: ::core::option::Option<u32>,
1060    /// How many replicas should apply the operation for us to consider it successful, default = 1
1061    #[prost(uint32, optional, tag = "12")]
1062    pub write_consistency_factor: ::core::option::Option<u32>,
1063    /// Quantization configuration of vector
1064    #[prost(message, optional, tag = "14")]
1065    pub quantization_config: ::core::option::Option<QuantizationConfig>,
1066    /// Sharding method
1067    #[prost(enumeration = "ShardingMethod", optional, tag = "15")]
1068    pub sharding_method: ::core::option::Option<i32>,
1069    /// Configuration for sparse vectors
1070    #[prost(message, optional, tag = "16")]
1071    pub sparse_vectors_config: ::core::option::Option<SparseVectorConfig>,
1072    /// Configuration for strict mode
1073    #[prost(message, optional, tag = "17")]
1074    pub strict_mode_config: ::core::option::Option<StrictModeConfig>,
1075    /// Arbitrary JSON metadata for the collection
1076    #[prost(map = "string, message", tag = "18")]
1077    pub metadata: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
1078    /// Configuration of the payload storage
1079    #[prost(message, optional, tag = "19")]
1080    pub payload: ::core::option::Option<PayloadStorageParams>,
1081    /// Configuration of the point id tracker
1082    #[prost(message, optional, tag = "20")]
1083    pub id_tracker: ::core::option::Option<IdTrackerParams>,
1084}
1085#[derive(Clone, PartialEq, ::prost::Message)]
1086pub struct UpdateCollection {
1087    /// Name of the collection
1088    #[prost(string, tag = "1")]
1089    pub collection_name: ::prost::alloc::string::String,
1090    /// New configuration parameters for the collection.
1091    /// This operation is blocking, it will only proceed once all current
1092    /// optimizations are complete
1093    #[prost(message, optional, tag = "2")]
1094    pub optimizers_config: ::core::option::Option<OptimizersConfigDiff>,
1095    /// Wait timeout for operation commit in seconds if blocking.
1096    /// If not specified - default value will be supplied.
1097    #[prost(uint64, optional, tag = "3")]
1098    pub timeout: ::core::option::Option<u64>,
1099    /// New configuration parameters for the collection
1100    #[prost(message, optional, tag = "4")]
1101    pub params: ::core::option::Option<CollectionParamsDiff>,
1102    /// New HNSW parameters for the collection index
1103    #[prost(message, optional, tag = "5")]
1104    pub hnsw_config: ::core::option::Option<HnswConfigDiff>,
1105    /// New vector parameters
1106    #[prost(message, optional, tag = "6")]
1107    pub vectors_config: ::core::option::Option<VectorsConfigDiff>,
1108    /// Quantization configuration of vector
1109    #[prost(message, optional, tag = "7")]
1110    pub quantization_config: ::core::option::Option<QuantizationConfigDiff>,
1111    /// New sparse vector parameters
1112    #[prost(message, optional, tag = "8")]
1113    pub sparse_vectors_config: ::core::option::Option<SparseVectorConfig>,
1114    /// New strict mode configuration
1115    #[prost(message, optional, tag = "9")]
1116    pub strict_mode_config: ::core::option::Option<StrictModeConfig>,
1117    /// Arbitrary JSON-like metadata for the collection, will be merged with
1118    /// already stored metadata
1119    #[prost(map = "string, message", tag = "10")]
1120    pub metadata: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
1121}
1122#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1123pub struct DeleteCollection {
1124    /// Name of the collection
1125    #[prost(string, tag = "1")]
1126    pub collection_name: ::prost::alloc::string::String,
1127    /// Wait timeout for operation commit in seconds.
1128    /// If not specified - default value will be supplied.
1129    #[prost(uint64, optional, tag = "2")]
1130    pub timeout: ::core::option::Option<u64>,
1131}
1132#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1133pub struct CollectionOperationResponse {
1134    /// if operation made changes
1135    #[prost(bool, tag = "1")]
1136    pub result: bool,
1137    /// Time spent to process
1138    #[prost(double, tag = "2")]
1139    pub time: f64,
1140}
1141#[derive(Clone, PartialEq, ::prost::Message)]
1142pub struct CollectionParams {
1143    /// Number of shards in collection
1144    #[prost(uint32, tag = "3")]
1145    pub shard_number: u32,
1146    /// Deprecated: use `payload.memory` instead.
1147    /// If true - point's payload will not be stored in memory
1148    #[deprecated]
1149    #[prost(bool, tag = "4")]
1150    pub on_disk_payload: bool,
1151    /// Configuration for vectors
1152    #[prost(message, optional, tag = "5")]
1153    pub vectors_config: ::core::option::Option<VectorsConfig>,
1154    /// Number of replicas of each shard that network tries to maintain
1155    #[prost(uint32, optional, tag = "6")]
1156    pub replication_factor: ::core::option::Option<u32>,
1157    /// How many replicas should apply the operation for us to consider it successful
1158    #[prost(uint32, optional, tag = "7")]
1159    pub write_consistency_factor: ::core::option::Option<u32>,
1160    /// Fan-out every read request to these many additional remote nodes (and return first available response)
1161    #[prost(uint32, optional, tag = "8")]
1162    pub read_fan_out_factor: ::core::option::Option<u32>,
1163    /// Sharding method
1164    #[prost(enumeration = "ShardingMethod", optional, tag = "9")]
1165    pub sharding_method: ::core::option::Option<i32>,
1166    /// Configuration for sparse vectors
1167    #[prost(message, optional, tag = "10")]
1168    pub sparse_vectors_config: ::core::option::Option<SparseVectorConfig>,
1169    /// Define number of milliseconds to wait before attempting to read from another replica.
1170    #[prost(uint64, optional, tag = "11")]
1171    pub read_fan_out_delay_ms: ::core::option::Option<u64>,
1172    /// Configuration of the payload storage
1173    #[prost(message, optional, tag = "12")]
1174    pub payload: ::core::option::Option<PayloadStorageParams>,
1175    /// Configuration of the point id tracker
1176    #[prost(message, optional, tag = "13")]
1177    pub id_tracker: ::core::option::Option<IdTrackerParams>,
1178}
1179#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1180pub struct CollectionParamsDiff {
1181    /// Number of replicas of each shard that network tries to maintain
1182    #[prost(uint32, optional, tag = "1")]
1183    pub replication_factor: ::core::option::Option<u32>,
1184    /// How many replicas should apply the operation for us to consider it successful
1185    #[prost(uint32, optional, tag = "2")]
1186    pub write_consistency_factor: ::core::option::Option<u32>,
1187    /// Deprecated: use `payload.memory` instead.
1188    /// If true - point's payload will not be stored in memory
1189    #[deprecated]
1190    #[prost(bool, optional, tag = "3")]
1191    pub on_disk_payload: ::core::option::Option<bool>,
1192    /// Fan-out every read request to these many additional remote nodes (and return first available response)
1193    #[prost(uint32, optional, tag = "4")]
1194    pub read_fan_out_factor: ::core::option::Option<u32>,
1195    /// Define number of milliseconds to wait before attempting to read from another replica.
1196    #[prost(uint64, optional, tag = "5")]
1197    pub read_fan_out_delay_ms: ::core::option::Option<u64>,
1198    /// Update params of the payload storage
1199    #[prost(message, optional, tag = "6")]
1200    pub payload: ::core::option::Option<PayloadStorageParams>,
1201    /// Update params of the point id tracker
1202    #[prost(message, optional, tag = "7")]
1203    pub id_tracker: ::core::option::Option<IdTrackerParams>,
1204}
1205#[derive(Clone, PartialEq, ::prost::Message)]
1206pub struct CollectionConfig {
1207    /// Collection parameters
1208    #[prost(message, optional, tag = "1")]
1209    pub params: ::core::option::Option<CollectionParams>,
1210    /// Configuration of vector index
1211    #[prost(message, optional, tag = "2")]
1212    pub hnsw_config: ::core::option::Option<HnswConfigDiff>,
1213    /// Configuration of the optimizers
1214    #[prost(message, optional, tag = "3")]
1215    pub optimizer_config: ::core::option::Option<OptimizersConfigDiff>,
1216    /// Configuration of the Write-Ahead-Log
1217    #[prost(message, optional, tag = "4")]
1218    pub wal_config: ::core::option::Option<WalConfigDiff>,
1219    /// Configuration of the vector quantization
1220    #[prost(message, optional, tag = "5")]
1221    pub quantization_config: ::core::option::Option<QuantizationConfig>,
1222    /// Configuration of strict mode.
1223    #[prost(message, optional, tag = "6")]
1224    pub strict_mode_config: ::core::option::Option<StrictModeConfig>,
1225    /// Arbitrary JSON metadata for the collection
1226    #[prost(map = "string, message", tag = "7")]
1227    pub metadata: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
1228}
1229#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1230pub struct KeywordIndexParams {
1231    /// If true - used for tenant optimization.
1232    #[prost(bool, optional, tag = "1")]
1233    pub is_tenant: ::core::option::Option<bool>,
1234    /// Deprecated: use `memory` instead.
1235    /// If true - store index on disk.
1236    #[deprecated]
1237    #[prost(bool, optional, tag = "2")]
1238    pub on_disk: ::core::option::Option<bool>,
1239    /// Enable HNSW graph building for this payload field.
1240    /// If true, builds additional HNSW links (Need payload_m > 0).
1241    /// Default: true.
1242    #[prost(bool, optional, tag = "3")]
1243    pub enable_hnsw: ::core::option::Option<bool>,
1244    /// If set, enable prefix matching (`match: { "prefix": ... }`) on this field.
1245    #[prost(message, optional, tag = "4")]
1246    pub prefix: ::core::option::Option<KeywordPrefixParams>,
1247    /// Memory placement of the index.
1248    /// Overrides the deprecated `on_disk` flag if both are set.
1249    #[prost(enumeration = "Memory", optional, tag = "5")]
1250    pub memory: ::core::option::Option<i32>,
1251    /// Index every object of this array as a separate entry, e.g. `offers` for the field `offers\[\].price`.
1252    /// The field must be inside the array's elements. `is_empty` on the field matches a point when one of
1253    /// its elements lacks the field, and never a point without elements. Default: disabled.
1254    #[prost(string, optional, tag = "6")]
1255    pub nested: ::core::option::Option<::prost::alloc::string::String>,
1256}
1257/// Prefix matching options for the keyword index. Has no options yet:
1258/// presence of this message enables prefix matching.
1259#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1260pub struct KeywordPrefixParams {}
1261#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1262pub struct IntegerIndexParams {
1263    /// If true - support direct lookups. Default is true.
1264    #[prost(bool, optional, tag = "1")]
1265    pub lookup: ::core::option::Option<bool>,
1266    /// If true - support ranges filters. Default is true.
1267    #[prost(bool, optional, tag = "2")]
1268    pub range: ::core::option::Option<bool>,
1269    /// If true - use this key to organize storage of the collection data.
1270    /// This option assumes that this key will be used in majority of filtered requests.
1271    /// Default is false.
1272    #[prost(bool, optional, tag = "3")]
1273    pub is_principal: ::core::option::Option<bool>,
1274    /// Deprecated: use `memory` instead.
1275    /// If true - store index on disk. Default is false.
1276    #[deprecated]
1277    #[prost(bool, optional, tag = "4")]
1278    pub on_disk: ::core::option::Option<bool>,
1279    /// Enable HNSW graph building for this payload field.
1280    /// If true, builds additional HNSW links (Need payload_m > 0).
1281    /// Default: true.
1282    #[prost(bool, optional, tag = "5")]
1283    pub enable_hnsw: ::core::option::Option<bool>,
1284    /// Memory placement of the index.
1285    /// Overrides the deprecated `on_disk` flag if both are set.
1286    #[prost(enumeration = "Memory", optional, tag = "6")]
1287    pub memory: ::core::option::Option<i32>,
1288    /// Index every object of this array as a separate entry, e.g. `offers` for the field `offers\[\].price`.
1289    /// The field must be inside the array's elements. `is_empty` on the field matches a point when one of
1290    /// its elements lacks the field, and never a point without elements. Default: disabled.
1291    #[prost(string, optional, tag = "7")]
1292    pub nested: ::core::option::Option<::prost::alloc::string::String>,
1293}
1294#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1295pub struct FloatIndexParams {
1296    /// Deprecated: use `memory` instead.
1297    /// If true - store index on disk.
1298    #[deprecated]
1299    #[prost(bool, optional, tag = "1")]
1300    pub on_disk: ::core::option::Option<bool>,
1301    /// If true - use this key to organize storage of the collection data.
1302    /// This option assumes that this key will be used in majority of filtered requests.
1303    #[prost(bool, optional, tag = "2")]
1304    pub is_principal: ::core::option::Option<bool>,
1305    /// Enable HNSW graph building for this payload field.
1306    /// If true, builds additional HNSW links (Need payload_m > 0).
1307    /// Default: true.
1308    #[prost(bool, optional, tag = "3")]
1309    pub enable_hnsw: ::core::option::Option<bool>,
1310    /// Memory placement of the index.
1311    /// Overrides the deprecated `on_disk` flag if both are set.
1312    #[prost(enumeration = "Memory", optional, tag = "4")]
1313    pub memory: ::core::option::Option<i32>,
1314    /// Index every object of this array as a separate entry, e.g. `offers` for the field `offers\[\].price`.
1315    /// The field must be inside the array's elements. `is_empty` on the field matches a point when one of
1316    /// its elements lacks the field, and never a point without elements. Default: disabled.
1317    #[prost(string, optional, tag = "5")]
1318    pub nested: ::core::option::Option<::prost::alloc::string::String>,
1319}
1320#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1321pub struct GeoIndexParams {
1322    /// Deprecated: use `memory` instead.
1323    /// If true - store index on disk.
1324    #[deprecated]
1325    #[prost(bool, optional, tag = "1")]
1326    pub on_disk: ::core::option::Option<bool>,
1327    /// Enable HNSW graph building for this payload field.
1328    /// If true, builds additional HNSW links (Need payload_m > 0).
1329    /// Default: true.
1330    #[prost(bool, optional, tag = "2")]
1331    pub enable_hnsw: ::core::option::Option<bool>,
1332    /// Memory placement of the index.
1333    /// Overrides the deprecated `on_disk` flag if both are set.
1334    #[prost(enumeration = "Memory", optional, tag = "3")]
1335    pub memory: ::core::option::Option<i32>,
1336    /// Index every object of this array as a separate entry, e.g. `offers` for the field `offers\[\].price`.
1337    /// The field must be inside the array's elements. `is_empty` on the field matches a point when one of
1338    /// its elements lacks the field, and never a point without elements. Default: disabled.
1339    #[prost(string, optional, tag = "4")]
1340    pub nested: ::core::option::Option<::prost::alloc::string::String>,
1341}
1342#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1343pub struct StopwordsSet {
1344    /// List of languages to use stopwords from
1345    #[prost(string, repeated, tag = "1")]
1346    pub languages: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1347    /// List of custom stopwords
1348    #[prost(string, repeated, tag = "2")]
1349    pub custom: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1350}
1351#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1352pub struct TextIndexParams {
1353    /// Tokenizer type
1354    #[prost(enumeration = "TokenizerType", tag = "1")]
1355    pub tokenizer: i32,
1356    /// If true - all tokens will be lowercase
1357    #[prost(bool, optional, tag = "2")]
1358    pub lowercase: ::core::option::Option<bool>,
1359    /// Minimal token length
1360    #[prost(uint64, optional, tag = "3")]
1361    pub min_token_len: ::core::option::Option<u64>,
1362    /// Maximal token length
1363    #[prost(uint64, optional, tag = "4")]
1364    pub max_token_len: ::core::option::Option<u64>,
1365    /// Deprecated: use `memory` instead.
1366    /// If true - store index on disk.
1367    #[deprecated]
1368    #[prost(bool, optional, tag = "5")]
1369    pub on_disk: ::core::option::Option<bool>,
1370    /// Stopwords for the text index
1371    #[prost(message, optional, tag = "6")]
1372    pub stopwords: ::core::option::Option<StopwordsSet>,
1373    /// If true - support phrase matching.
1374    #[prost(bool, optional, tag = "7")]
1375    pub phrase_matching: ::core::option::Option<bool>,
1376    /// Set an algorithm for stemming.
1377    #[prost(message, optional, tag = "8")]
1378    pub stemmer: ::core::option::Option<StemmingAlgorithm>,
1379    /// If true, normalize tokens by folding accented characters to ASCII (e.g., "ação" -> "acao").
1380    /// Default: false.
1381    #[prost(bool, optional, tag = "9")]
1382    pub ascii_folding: ::core::option::Option<bool>,
1383    /// Enable HNSW graph building for this payload field.
1384    /// If true, builds additional HNSW links (Need payload_m > 0).
1385    /// Default: true.
1386    #[prost(bool, optional, tag = "10")]
1387    pub enable_hnsw: ::core::option::Option<bool>,
1388    /// Memory placement of the index.
1389    /// Overrides the deprecated `on_disk` flag if both are set.
1390    #[prost(enumeration = "Memory", optional, tag = "11")]
1391    pub memory: ::core::option::Option<i32>,
1392    /// Enable ranking points by BM25 over this field.
1393    /// Changing it rebuilds the index.
1394    /// Default: disabled.
1395    #[prost(message, optional, tag = "12")]
1396    pub scoring: ::core::option::Option<TextScoringParams>,
1397    /// Index every object of this array as a separate entry, e.g. `offers` for the field `offers\[\].title`.
1398    /// The field must be inside the array's elements. Every query on the field, not only nested filters,
1399    /// treats each element as its own document: a condition matches a point when a single element
1400    /// matches it, and BM25 scores elements separately. `is_empty` on the field matches a point when
1401    /// one of its elements lacks the field, and never a point without elements. Default: disabled.
1402    #[prost(string, optional, tag = "13")]
1403    pub nested: ::core::option::Option<::prost::alloc::string::String>,
1404}
1405#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1406pub struct TextScoringParams {
1407    /// How documents are ranked
1408    #[prost(enumeration = "TextScoringType", tag = "1")]
1409    pub r#type: i32,
1410}
1411#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1412pub struct StemmingAlgorithm {
1413    #[prost(oneof = "stemming_algorithm::StemmingParams", tags = "1, 2")]
1414    pub stemming_params: ::core::option::Option<stemming_algorithm::StemmingParams>,
1415}
1416/// Nested message and enum types in `StemmingAlgorithm`.
1417pub mod stemming_algorithm {
1418    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
1419    pub enum StemmingParams {
1420        /// Parameters for snowball stemming
1421        #[prost(message, tag = "1")]
1422        Snowball(super::SnowballParams),
1423        /// Explicitly disable stemming (overrides the language default)
1424        #[prost(message, tag = "2")]
1425        Disabled(super::DisabledStemmer),
1426    }
1427}
1428#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1429pub struct SnowballParams {
1430    /// Which language the algorithm should stem.
1431    #[prost(string, tag = "1")]
1432    pub language: ::prost::alloc::string::String,
1433}
1434/// Marker selecting the "no stemming" algorithm.
1435#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1436pub struct DisabledStemmer {}
1437#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1438pub struct BoolIndexParams {
1439    /// Deprecated: use `memory` instead.
1440    /// If true - store index on disk.
1441    #[deprecated]
1442    #[prost(bool, optional, tag = "1")]
1443    pub on_disk: ::core::option::Option<bool>,
1444    /// Enable HNSW graph building for this payload field.
1445    /// If true, builds additional HNSW links (Need payload_m > 0).
1446    /// Default: true.
1447    #[prost(bool, optional, tag = "2")]
1448    pub enable_hnsw: ::core::option::Option<bool>,
1449    /// Memory placement of the index.
1450    /// Overrides the deprecated `on_disk` flag if both are set.
1451    #[prost(enumeration = "Memory", optional, tag = "3")]
1452    pub memory: ::core::option::Option<i32>,
1453    /// Index every object of this array as a separate entry, e.g. `offers` for the field `offers\[\].price`.
1454    /// The field must be inside the array's elements. `is_empty` on the field matches a point when one of
1455    /// its elements lacks the field, and never a point without elements. Default: disabled.
1456    #[prost(string, optional, tag = "4")]
1457    pub nested: ::core::option::Option<::prost::alloc::string::String>,
1458}
1459#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1460pub struct DatetimeIndexParams {
1461    /// Deprecated: use `memory` instead.
1462    /// If true - store index on disk.
1463    #[deprecated]
1464    #[prost(bool, optional, tag = "1")]
1465    pub on_disk: ::core::option::Option<bool>,
1466    /// If true - use this key to organize storage of the collection data.
1467    /// This option assumes that this key will be used in majority of filtered requests.
1468    #[prost(bool, optional, tag = "2")]
1469    pub is_principal: ::core::option::Option<bool>,
1470    /// Enable HNSW graph building for this payload field.
1471    /// If true, builds additional HNSW links (Need payload_m > 0).
1472    /// Default: true.
1473    #[prost(bool, optional, tag = "3")]
1474    pub enable_hnsw: ::core::option::Option<bool>,
1475    /// Memory placement of the index.
1476    /// Overrides the deprecated `on_disk` flag if both are set.
1477    #[prost(enumeration = "Memory", optional, tag = "4")]
1478    pub memory: ::core::option::Option<i32>,
1479    /// Index every object of this array as a separate entry, e.g. `offers` for the field `offers\[\].price`.
1480    /// The field must be inside the array's elements. `is_empty` on the field matches a point when one of
1481    /// its elements lacks the field, and never a point without elements. Default: disabled.
1482    #[prost(string, optional, tag = "5")]
1483    pub nested: ::core::option::Option<::prost::alloc::string::String>,
1484}
1485#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1486pub struct UuidIndexParams {
1487    /// If true - used for tenant optimization.
1488    #[prost(bool, optional, tag = "1")]
1489    pub is_tenant: ::core::option::Option<bool>,
1490    /// Deprecated: use `memory` instead.
1491    /// If true - store index on disk.
1492    #[deprecated]
1493    #[prost(bool, optional, tag = "2")]
1494    pub on_disk: ::core::option::Option<bool>,
1495    /// Enable HNSW graph building for this payload field.
1496    /// If true, builds additional HNSW links (Need payload_m > 0).
1497    /// Default: true.
1498    #[prost(bool, optional, tag = "3")]
1499    pub enable_hnsw: ::core::option::Option<bool>,
1500    /// Memory placement of the index.
1501    /// Overrides the deprecated `on_disk` flag if both are set.
1502    #[prost(enumeration = "Memory", optional, tag = "4")]
1503    pub memory: ::core::option::Option<i32>,
1504    /// Index every object of this array as a separate entry, e.g. `offers` for the field `offers\[\].price`.
1505    /// The field must be inside the array's elements. `is_empty` on the field matches a point when one of
1506    /// its elements lacks the field, and never a point without elements. Default: disabled.
1507    #[prost(string, optional, tag = "5")]
1508    pub nested: ::core::option::Option<::prost::alloc::string::String>,
1509}
1510#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1511pub struct PayloadIndexParams {
1512    #[prost(
1513        oneof = "payload_index_params::IndexParams",
1514        tags = "3, 2, 4, 5, 1, 6, 7, 8"
1515    )]
1516    pub index_params: ::core::option::Option<payload_index_params::IndexParams>,
1517}
1518/// Nested message and enum types in `PayloadIndexParams`.
1519pub mod payload_index_params {
1520    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
1521    pub enum IndexParams {
1522        /// Parameters for keyword index
1523        #[prost(message, tag = "3")]
1524        KeywordIndexParams(super::KeywordIndexParams),
1525        /// Parameters for integer index
1526        #[prost(message, tag = "2")]
1527        IntegerIndexParams(super::IntegerIndexParams),
1528        /// Parameters for float index
1529        #[prost(message, tag = "4")]
1530        FloatIndexParams(super::FloatIndexParams),
1531        /// Parameters for geo index
1532        #[prost(message, tag = "5")]
1533        GeoIndexParams(super::GeoIndexParams),
1534        /// Parameters for text index
1535        #[prost(message, tag = "1")]
1536        TextIndexParams(super::TextIndexParams),
1537        /// Parameters for bool index
1538        #[prost(message, tag = "6")]
1539        BoolIndexParams(super::BoolIndexParams),
1540        /// Parameters for datetime index
1541        #[prost(message, tag = "7")]
1542        DatetimeIndexParams(super::DatetimeIndexParams),
1543        /// Parameters for uuid index
1544        #[prost(message, tag = "8")]
1545        UuidIndexParams(super::UuidIndexParams),
1546    }
1547}
1548#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1549pub struct PayloadSchemaInfo {
1550    /// Field data type
1551    #[prost(enumeration = "PayloadSchemaType", tag = "1")]
1552    pub data_type: i32,
1553    /// Field index parameters
1554    #[prost(message, optional, tag = "2")]
1555    pub params: ::core::option::Option<PayloadIndexParams>,
1556    /// Number of points indexed within this field
1557    #[prost(uint64, optional, tag = "3")]
1558    pub points: ::core::option::Option<u64>,
1559}
1560#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1561pub struct UpdateQueueInfo {
1562    /// Number of elements in the queue
1563    #[prost(uint64, tag = "1")]
1564    pub length: u64,
1565    /// Number of points that are deferred (i.e hidden from search as they're not yet optimized).
1566    #[prost(uint64, optional, tag = "2")]
1567    pub deferred_points: ::core::option::Option<u64>,
1568}
1569#[derive(Clone, PartialEq, ::prost::Message)]
1570pub struct CollectionInfo {
1571    /// operating condition of the collection
1572    #[prost(enumeration = "CollectionStatus", tag = "1")]
1573    pub status: i32,
1574    /// status of collection optimizers
1575    #[prost(message, optional, tag = "2")]
1576    pub optimizer_status: ::core::option::Option<OptimizerStatus>,
1577    /// Number of independent segments
1578    #[prost(uint64, tag = "4")]
1579    pub segments_count: u64,
1580    /// Configuration
1581    #[prost(message, optional, tag = "7")]
1582    pub config: ::core::option::Option<CollectionConfig>,
1583    /// Collection data types
1584    #[prost(map = "string, message", tag = "8")]
1585    pub payload_schema: ::std::collections::HashMap<
1586        ::prost::alloc::string::String,
1587        PayloadSchemaInfo,
1588    >,
1589    /// Approximate number of points in the collection
1590    #[prost(uint64, optional, tag = "9")]
1591    pub points_count: ::core::option::Option<u64>,
1592    /// Approximate number of indexed vectors in the collection.
1593    #[prost(uint64, optional, tag = "10")]
1594    pub indexed_vectors_count: ::core::option::Option<u64>,
1595    /// Warnings related to the collection
1596    #[prost(message, repeated, tag = "11")]
1597    pub warnings: ::prost::alloc::vec::Vec<CollectionWarning>,
1598    /// Update queue info
1599    #[prost(message, optional, tag = "12")]
1600    pub update_queue: ::core::option::Option<UpdateQueueInfo>,
1601    /// Time of the collection creation, absent for collections created before it was recorded
1602    #[prost(message, optional, tag = "13")]
1603    pub created_at: ::core::option::Option<::prost_types::Timestamp>,
1604}
1605#[derive(Clone, PartialEq, ::prost::Message)]
1606pub struct ChangeAliases {
1607    /// List of actions
1608    #[prost(message, repeated, tag = "1")]
1609    pub actions: ::prost::alloc::vec::Vec<AliasOperations>,
1610    /// Wait timeout for operation commit in seconds.
1611    /// If not specified - default value will be supplied.
1612    #[prost(uint64, optional, tag = "2")]
1613    pub timeout: ::core::option::Option<u64>,
1614}
1615#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1616pub struct AliasOperations {
1617    #[prost(oneof = "alias_operations::Action", tags = "1, 2, 3")]
1618    pub action: ::core::option::Option<alias_operations::Action>,
1619}
1620/// Nested message and enum types in `AliasOperations`.
1621pub mod alias_operations {
1622    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
1623    pub enum Action {
1624        #[prost(message, tag = "1")]
1625        CreateAlias(super::CreateAlias),
1626        #[prost(message, tag = "2")]
1627        RenameAlias(super::RenameAlias),
1628        #[prost(message, tag = "3")]
1629        DeleteAlias(super::DeleteAlias),
1630    }
1631}
1632#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1633pub struct CreateAlias {
1634    /// Name of the collection
1635    #[prost(string, tag = "1")]
1636    pub collection_name: ::prost::alloc::string::String,
1637    /// New name of the alias
1638    #[prost(string, tag = "2")]
1639    pub alias_name: ::prost::alloc::string::String,
1640}
1641#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1642pub struct RenameAlias {
1643    /// Name of the alias to rename
1644    #[prost(string, tag = "1")]
1645    pub old_alias_name: ::prost::alloc::string::String,
1646    /// Name of the alias
1647    #[prost(string, tag = "2")]
1648    pub new_alias_name: ::prost::alloc::string::String,
1649}
1650#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1651pub struct DeleteAlias {
1652    /// Name of the alias
1653    #[prost(string, tag = "1")]
1654    pub alias_name: ::prost::alloc::string::String,
1655}
1656#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1657pub struct ListAliasesRequest {}
1658#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1659pub struct ListCollectionAliasesRequest {
1660    /// Name of the collection
1661    #[prost(string, tag = "1")]
1662    pub collection_name: ::prost::alloc::string::String,
1663}
1664#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1665pub struct AliasDescription {
1666    /// Name of the alias
1667    #[prost(string, tag = "1")]
1668    pub alias_name: ::prost::alloc::string::String,
1669    /// Name of the collection
1670    #[prost(string, tag = "2")]
1671    pub collection_name: ::prost::alloc::string::String,
1672}
1673#[derive(Clone, PartialEq, ::prost::Message)]
1674pub struct ListAliasesResponse {
1675    #[prost(message, repeated, tag = "1")]
1676    pub aliases: ::prost::alloc::vec::Vec<AliasDescription>,
1677    /// Time spent to process
1678    #[prost(double, tag = "2")]
1679    pub time: f64,
1680}
1681#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1682pub struct CollectionClusterInfoRequest {
1683    /// Name of the collection
1684    #[prost(string, tag = "1")]
1685    pub collection_name: ::prost::alloc::string::String,
1686}
1687#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1688pub struct ShardKey {
1689    #[prost(oneof = "shard_key::Key", tags = "1, 2")]
1690    pub key: ::core::option::Option<shard_key::Key>,
1691}
1692/// Nested message and enum types in `ShardKey`.
1693pub mod shard_key {
1694    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
1695    pub enum Key {
1696        /// String key
1697        #[prost(string, tag = "1")]
1698        Keyword(::prost::alloc::string::String),
1699        /// Number key
1700        #[prost(uint64, tag = "2")]
1701        Number(u64),
1702    }
1703}
1704#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1705pub struct LocalShardInfo {
1706    /// Local shard id
1707    #[prost(uint32, tag = "1")]
1708    pub shard_id: u32,
1709    /// Number of points in the shard
1710    #[prost(uint64, tag = "2")]
1711    pub points_count: u64,
1712    /// Is replica active
1713    #[prost(enumeration = "ReplicaState", tag = "3")]
1714    pub state: i32,
1715    /// User-defined shard key
1716    #[prost(message, optional, tag = "4")]
1717    pub shard_key: ::core::option::Option<ShardKey>,
1718}
1719#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1720pub struct RemoteShardInfo {
1721    /// Local shard id
1722    #[prost(uint32, tag = "1")]
1723    pub shard_id: u32,
1724    /// Remote peer id
1725    #[prost(uint64, tag = "2")]
1726    pub peer_id: u64,
1727    /// Is replica active
1728    #[prost(enumeration = "ReplicaState", tag = "3")]
1729    pub state: i32,
1730    /// User-defined shard key
1731    #[prost(message, optional, tag = "4")]
1732    pub shard_key: ::core::option::Option<ShardKey>,
1733}
1734#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1735pub struct ShardTransferInfo {
1736    /// Local shard id
1737    #[prost(uint32, tag = "1")]
1738    pub shard_id: u32,
1739    #[prost(uint32, optional, tag = "5")]
1740    pub to_shard_id: ::core::option::Option<u32>,
1741    #[prost(uint64, tag = "2")]
1742    pub from: u64,
1743    #[prost(uint64, tag = "3")]
1744    pub to: u64,
1745    /// If `true` transfer is a synchronization of a replicas;
1746    /// If `false` transfer is a moving of a shard from one peer to another
1747    #[prost(bool, tag = "4")]
1748    pub sync: bool,
1749}
1750#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1751pub struct ReshardingInfo {
1752    #[prost(uint32, tag = "1")]
1753    pub shard_id: u32,
1754    #[prost(uint64, tag = "2")]
1755    pub peer_id: u64,
1756    #[prost(message, optional, tag = "3")]
1757    pub shard_key: ::core::option::Option<ShardKey>,
1758    #[prost(enumeration = "ReshardingDirection", tag = "4")]
1759    pub direction: i32,
1760}
1761#[derive(Clone, PartialEq, ::prost::Message)]
1762pub struct CollectionClusterInfoResponse {
1763    /// ID of this peer
1764    #[prost(uint64, tag = "1")]
1765    pub peer_id: u64,
1766    /// Total number of shards
1767    #[prost(uint64, tag = "2")]
1768    pub shard_count: u64,
1769    /// Local shards
1770    #[prost(message, repeated, tag = "3")]
1771    pub local_shards: ::prost::alloc::vec::Vec<LocalShardInfo>,
1772    /// Remote shards
1773    #[prost(message, repeated, tag = "4")]
1774    pub remote_shards: ::prost::alloc::vec::Vec<RemoteShardInfo>,
1775    /// Shard transfers
1776    #[prost(message, repeated, tag = "5")]
1777    pub shard_transfers: ::prost::alloc::vec::Vec<ShardTransferInfo>,
1778    /// Resharding operations
1779    #[prost(message, repeated, tag = "6")]
1780    pub resharding_operations: ::prost::alloc::vec::Vec<ReshardingInfo>,
1781    /// Time spent to process
1782    #[prost(double, tag = "7")]
1783    pub time: f64,
1784}
1785#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1786pub struct MoveShard {
1787    /// Local shard id
1788    #[prost(uint32, tag = "1")]
1789    pub shard_id: u32,
1790    #[prost(uint32, optional, tag = "5")]
1791    pub to_shard_id: ::core::option::Option<u32>,
1792    #[prost(uint64, tag = "2")]
1793    pub from_peer_id: u64,
1794    #[prost(uint64, tag = "3")]
1795    pub to_peer_id: u64,
1796    #[prost(enumeration = "ShardTransferMethod", optional, tag = "4")]
1797    pub method: ::core::option::Option<i32>,
1798}
1799#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1800pub struct ReplicateShard {
1801    /// Local shard id
1802    #[prost(uint32, tag = "1")]
1803    pub shard_id: u32,
1804    #[prost(uint32, optional, tag = "5")]
1805    pub to_shard_id: ::core::option::Option<u32>,
1806    #[prost(uint64, tag = "2")]
1807    pub from_peer_id: u64,
1808    #[prost(uint64, tag = "3")]
1809    pub to_peer_id: u64,
1810    #[prost(enumeration = "ShardTransferMethod", optional, tag = "4")]
1811    pub method: ::core::option::Option<i32>,
1812}
1813#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1814pub struct AbortShardTransfer {
1815    /// Local shard id
1816    #[prost(uint32, tag = "1")]
1817    pub shard_id: u32,
1818    #[prost(uint32, optional, tag = "4")]
1819    pub to_shard_id: ::core::option::Option<u32>,
1820    #[prost(uint64, tag = "2")]
1821    pub from_peer_id: u64,
1822    #[prost(uint64, tag = "3")]
1823    pub to_peer_id: u64,
1824}
1825#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1826pub struct RestartTransfer {
1827    /// Local shard id
1828    #[prost(uint32, tag = "1")]
1829    pub shard_id: u32,
1830    #[prost(uint32, optional, tag = "5")]
1831    pub to_shard_id: ::core::option::Option<u32>,
1832    #[prost(uint64, tag = "2")]
1833    pub from_peer_id: u64,
1834    #[prost(uint64, tag = "3")]
1835    pub to_peer_id: u64,
1836    #[prost(enumeration = "ShardTransferMethod", tag = "4")]
1837    pub method: i32,
1838}
1839#[derive(Clone, PartialEq, ::prost::Message)]
1840pub struct ReplicatePoints {
1841    /// Source shard key
1842    #[prost(message, optional, tag = "1")]
1843    pub from_shard_key: ::core::option::Option<ShardKey>,
1844    /// Target shard key
1845    #[prost(message, optional, tag = "2")]
1846    pub to_shard_key: ::core::option::Option<ShardKey>,
1847    /// If set - only points matching the filter will be replicated
1848    #[prost(message, optional, tag = "3")]
1849    pub filter: ::core::option::Option<Filter>,
1850}
1851#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1852pub struct Replica {
1853    #[prost(uint32, tag = "1")]
1854    pub shard_id: u32,
1855    #[prost(uint64, tag = "2")]
1856    pub peer_id: u64,
1857}
1858#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1859pub struct CreateShardKey {
1860    /// User-defined shard key
1861    #[prost(message, optional, tag = "1")]
1862    pub shard_key: ::core::option::Option<ShardKey>,
1863    /// Number of shards to create per shard key
1864    #[prost(uint32, optional, tag = "2")]
1865    pub shards_number: ::core::option::Option<u32>,
1866    /// Number of replicas of each shard to create
1867    #[prost(uint32, optional, tag = "3")]
1868    pub replication_factor: ::core::option::Option<u32>,
1869    /// List of peer ids, allowed to create shards. If empty - all peers are allowed
1870    #[prost(uint64, repeated, tag = "4")]
1871    pub placement: ::prost::alloc::vec::Vec<u64>,
1872    /// Initial state of created replicas. Warning: use with care.
1873    #[prost(enumeration = "ReplicaState", optional, tag = "5")]
1874    pub initial_state: ::core::option::Option<i32>,
1875}
1876#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1877pub struct DeleteShardKey {
1878    /// Shard key to delete
1879    #[prost(message, optional, tag = "1")]
1880    pub shard_key: ::core::option::Option<ShardKey>,
1881}
1882#[derive(Clone, PartialEq, ::prost::Message)]
1883pub struct UpdateCollectionClusterSetupRequest {
1884    /// Name of the collection
1885    #[prost(string, tag = "1")]
1886    pub collection_name: ::prost::alloc::string::String,
1887    /// Wait timeout for operation commit in seconds.
1888    /// If not specified - default value will be supplied.
1889    #[prost(uint64, optional, tag = "6")]
1890    pub timeout: ::core::option::Option<u64>,
1891    #[prost(
1892        oneof = "update_collection_cluster_setup_request::Operation",
1893        tags = "2, 3, 4, 5, 7, 8, 9, 10"
1894    )]
1895    pub operation: ::core::option::Option<
1896        update_collection_cluster_setup_request::Operation,
1897    >,
1898}
1899/// Nested message and enum types in `UpdateCollectionClusterSetupRequest`.
1900pub mod update_collection_cluster_setup_request {
1901    #[derive(Clone, PartialEq, ::prost::Oneof)]
1902    pub enum Operation {
1903        #[prost(message, tag = "2")]
1904        MoveShard(super::MoveShard),
1905        #[prost(message, tag = "3")]
1906        ReplicateShard(super::ReplicateShard),
1907        #[prost(message, tag = "4")]
1908        AbortTransfer(super::AbortShardTransfer),
1909        #[prost(message, tag = "5")]
1910        DropReplica(super::Replica),
1911        #[prost(message, tag = "7")]
1912        CreateShardKey(super::CreateShardKey),
1913        #[prost(message, tag = "8")]
1914        DeleteShardKey(super::DeleteShardKey),
1915        #[prost(message, tag = "9")]
1916        RestartTransfer(super::RestartTransfer),
1917        #[prost(message, tag = "10")]
1918        ReplicatePoints(super::ReplicatePoints),
1919    }
1920}
1921#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1922pub struct UpdateCollectionClusterSetupResponse {
1923    #[prost(bool, tag = "1")]
1924    pub result: bool,
1925    /// Time spent to process
1926    #[prost(double, tag = "2")]
1927    pub time: f64,
1928}
1929#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1930pub struct CreateShardKeyRequest {
1931    /// Name of the collection
1932    #[prost(string, tag = "1")]
1933    pub collection_name: ::prost::alloc::string::String,
1934    /// Request to create shard key
1935    #[prost(message, optional, tag = "2")]
1936    pub request: ::core::option::Option<CreateShardKey>,
1937    /// Wait timeout for operation commit in seconds.
1938    /// If not specified - default value will be supplied.
1939    #[prost(uint64, optional, tag = "3")]
1940    pub timeout: ::core::option::Option<u64>,
1941}
1942#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1943pub struct DeleteShardKeyRequest {
1944    /// Name of the collection
1945    #[prost(string, tag = "1")]
1946    pub collection_name: ::prost::alloc::string::String,
1947    /// Request to delete shard key
1948    #[prost(message, optional, tag = "2")]
1949    pub request: ::core::option::Option<DeleteShardKey>,
1950    /// Wait timeout for operation commit in seconds.
1951    /// If not specified - default value will be supplied.
1952    #[prost(uint64, optional, tag = "3")]
1953    pub timeout: ::core::option::Option<u64>,
1954}
1955#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1956pub struct ListShardKeysRequest {
1957    /// Name of the collection
1958    #[prost(string, tag = "1")]
1959    pub collection_name: ::prost::alloc::string::String,
1960}
1961#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1962pub struct CreateShardKeyResponse {
1963    #[prost(bool, tag = "1")]
1964    pub result: bool,
1965    /// Time spent to process
1966    #[prost(double, tag = "2")]
1967    pub time: f64,
1968}
1969#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1970pub struct DeleteShardKeyResponse {
1971    #[prost(bool, tag = "1")]
1972    pub result: bool,
1973    /// Time spent to process
1974    #[prost(double, tag = "2")]
1975    pub time: f64,
1976}
1977#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1978pub struct ShardKeyDescription {
1979    #[prost(message, optional, tag = "1")]
1980    pub key: ::core::option::Option<ShardKey>,
1981}
1982#[derive(Clone, PartialEq, ::prost::Message)]
1983pub struct ListShardKeysResponse {
1984    #[prost(message, repeated, tag = "1")]
1985    pub shard_keys: ::prost::alloc::vec::Vec<ShardKeyDescription>,
1986    /// Time spent to process
1987    #[prost(double, tag = "2")]
1988    pub time: f64,
1989}
1990#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1991#[repr(i32)]
1992pub enum Datatype {
1993    Default = 0,
1994    Float32 = 1,
1995    Uint8 = 2,
1996    Float16 = 3,
1997    Turbo4 = 4,
1998    Turbo8 = 5,
1999    Turbo16 = 6,
2000}
2001impl Datatype {
2002    /// String value of the enum field names used in the ProtoBuf definition.
2003    ///
2004    /// The values are not transformed in any way and thus are considered stable
2005    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2006    pub fn as_str_name(&self) -> &'static str {
2007        match self {
2008            Self::Default => "Default",
2009            Self::Float32 => "Float32",
2010            Self::Uint8 => "Uint8",
2011            Self::Float16 => "Float16",
2012            Self::Turbo4 => "Turbo4",
2013            Self::Turbo8 => "Turbo8",
2014            Self::Turbo16 => "Turbo16",
2015        }
2016    }
2017    /// Creates an enum from field names used in the ProtoBuf definition.
2018    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2019        match value {
2020            "Default" => Some(Self::Default),
2021            "Float32" => Some(Self::Float32),
2022            "Uint8" => Some(Self::Uint8),
2023            "Float16" => Some(Self::Float16),
2024            "Turbo4" => Some(Self::Turbo4),
2025            "Turbo8" => Some(Self::Turbo8),
2026            "Turbo16" => Some(Self::Turbo16),
2027            _ => None,
2028        }
2029    }
2030}
2031/// Memory placement of a component's data.
2032/// Data is always persisted on disk regardless of this setting;
2033/// it only controls how the data is held in RAM.
2034#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2035#[repr(i32)]
2036pub enum Memory {
2037    Unknown = 0,
2038    /// Data is not pre-loaded from disk to RAM; cached with usage.
2039    Cold = 1,
2040    /// Data is pre-loaded into disk-cache RAM on start, but may be evicted under memory pressure.
2041    Cached = 2,
2042    /// Data is loaded in RAM and never evicted.
2043    Pinned = 3,
2044}
2045impl Memory {
2046    /// String value of the enum field names used in the ProtoBuf definition.
2047    ///
2048    /// The values are not transformed in any way and thus are considered stable
2049    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2050    pub fn as_str_name(&self) -> &'static str {
2051        match self {
2052            Self::Unknown => "MemoryUnknown",
2053            Self::Cold => "Cold",
2054            Self::Cached => "Cached",
2055            Self::Pinned => "Pinned",
2056        }
2057    }
2058    /// Creates an enum from field names used in the ProtoBuf definition.
2059    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2060        match value {
2061            "MemoryUnknown" => Some(Self::Unknown),
2062            "Cold" => Some(Self::Cold),
2063            "Cached" => Some(Self::Cached),
2064            "Pinned" => Some(Self::Pinned),
2065            _ => None,
2066        }
2067    }
2068}
2069#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2070#[repr(i32)]
2071pub enum Modifier {
2072    None = 0,
2073    /// Apply Inverse Document Frequency
2074    Idf = 1,
2075}
2076impl Modifier {
2077    /// String value of the enum field names used in the ProtoBuf definition.
2078    ///
2079    /// The values are not transformed in any way and thus are considered stable
2080    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2081    pub fn as_str_name(&self) -> &'static str {
2082        match self {
2083            Self::None => "None",
2084            Self::Idf => "Idf",
2085        }
2086    }
2087    /// Creates an enum from field names used in the ProtoBuf definition.
2088    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2089        match value {
2090            "None" => Some(Self::None),
2091            "Idf" => Some(Self::Idf),
2092            _ => None,
2093        }
2094    }
2095}
2096#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2097#[repr(i32)]
2098pub enum MultiVectorComparator {
2099    MaxSim = 0,
2100}
2101impl MultiVectorComparator {
2102    /// String value of the enum field names used in the ProtoBuf definition.
2103    ///
2104    /// The values are not transformed in any way and thus are considered stable
2105    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2106    pub fn as_str_name(&self) -> &'static str {
2107        match self {
2108            Self::MaxSim => "MaxSim",
2109        }
2110    }
2111    /// Creates an enum from field names used in the ProtoBuf definition.
2112    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2113        match value {
2114            "MaxSim" => Some(Self::MaxSim),
2115            _ => None,
2116        }
2117    }
2118}
2119#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2120#[repr(i32)]
2121pub enum Distance {
2122    UnknownDistance = 0,
2123    Cosine = 1,
2124    Euclid = 2,
2125    Dot = 3,
2126    Manhattan = 4,
2127}
2128impl Distance {
2129    /// String value of the enum field names used in the ProtoBuf definition.
2130    ///
2131    /// The values are not transformed in any way and thus are considered stable
2132    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2133    pub fn as_str_name(&self) -> &'static str {
2134        match self {
2135            Self::UnknownDistance => "UnknownDistance",
2136            Self::Cosine => "Cosine",
2137            Self::Euclid => "Euclid",
2138            Self::Dot => "Dot",
2139            Self::Manhattan => "Manhattan",
2140        }
2141    }
2142    /// Creates an enum from field names used in the ProtoBuf definition.
2143    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2144        match value {
2145            "UnknownDistance" => Some(Self::UnknownDistance),
2146            "Cosine" => Some(Self::Cosine),
2147            "Euclid" => Some(Self::Euclid),
2148            "Dot" => Some(Self::Dot),
2149            "Manhattan" => Some(Self::Manhattan),
2150            _ => None,
2151        }
2152    }
2153}
2154#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2155#[repr(i32)]
2156pub enum CollectionStatus {
2157    UnknownCollectionStatus = 0,
2158    /// All segments are ready
2159    Green = 1,
2160    /// Optimization in process
2161    Yellow = 2,
2162    /// Something went wrong
2163    Red = 3,
2164    /// Optimization is pending
2165    Grey = 4,
2166}
2167impl CollectionStatus {
2168    /// String value of the enum field names used in the ProtoBuf definition.
2169    ///
2170    /// The values are not transformed in any way and thus are considered stable
2171    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2172    pub fn as_str_name(&self) -> &'static str {
2173        match self {
2174            Self::UnknownCollectionStatus => "UnknownCollectionStatus",
2175            Self::Green => "Green",
2176            Self::Yellow => "Yellow",
2177            Self::Red => "Red",
2178            Self::Grey => "Grey",
2179        }
2180    }
2181    /// Creates an enum from field names used in the ProtoBuf definition.
2182    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2183        match value {
2184            "UnknownCollectionStatus" => Some(Self::UnknownCollectionStatus),
2185            "Green" => Some(Self::Green),
2186            "Yellow" => Some(Self::Yellow),
2187            "Red" => Some(Self::Red),
2188            "Grey" => Some(Self::Grey),
2189            _ => None,
2190        }
2191    }
2192}
2193#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2194#[repr(i32)]
2195pub enum PayloadSchemaType {
2196    UnknownType = 0,
2197    Keyword = 1,
2198    Integer = 2,
2199    Float = 3,
2200    Geo = 4,
2201    Text = 5,
2202    Bool = 6,
2203    Datetime = 7,
2204    Uuid = 8,
2205}
2206impl PayloadSchemaType {
2207    /// String value of the enum field names used in the ProtoBuf definition.
2208    ///
2209    /// The values are not transformed in any way and thus are considered stable
2210    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2211    pub fn as_str_name(&self) -> &'static str {
2212        match self {
2213            Self::UnknownType => "UnknownType",
2214            Self::Keyword => "Keyword",
2215            Self::Integer => "Integer",
2216            Self::Float => "Float",
2217            Self::Geo => "Geo",
2218            Self::Text => "Text",
2219            Self::Bool => "Bool",
2220            Self::Datetime => "Datetime",
2221            Self::Uuid => "Uuid",
2222        }
2223    }
2224    /// Creates an enum from field names used in the ProtoBuf definition.
2225    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2226        match value {
2227            "UnknownType" => Some(Self::UnknownType),
2228            "Keyword" => Some(Self::Keyword),
2229            "Integer" => Some(Self::Integer),
2230            "Float" => Some(Self::Float),
2231            "Geo" => Some(Self::Geo),
2232            "Text" => Some(Self::Text),
2233            "Bool" => Some(Self::Bool),
2234            "Datetime" => Some(Self::Datetime),
2235            "Uuid" => Some(Self::Uuid),
2236            _ => None,
2237        }
2238    }
2239}
2240#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2241#[repr(i32)]
2242pub enum QuantizationType {
2243    UnknownQuantization = 0,
2244    Int8 = 1,
2245}
2246impl QuantizationType {
2247    /// String value of the enum field names used in the ProtoBuf definition.
2248    ///
2249    /// The values are not transformed in any way and thus are considered stable
2250    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2251    pub fn as_str_name(&self) -> &'static str {
2252        match self {
2253            Self::UnknownQuantization => "UnknownQuantization",
2254            Self::Int8 => "Int8",
2255        }
2256    }
2257    /// Creates an enum from field names used in the ProtoBuf definition.
2258    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2259        match value {
2260            "UnknownQuantization" => Some(Self::UnknownQuantization),
2261            "Int8" => Some(Self::Int8),
2262            _ => None,
2263        }
2264    }
2265}
2266#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2267#[repr(i32)]
2268pub enum CompressionRatio {
2269    X4 = 0,
2270    X8 = 1,
2271    X16 = 2,
2272    X32 = 3,
2273    X64 = 4,
2274}
2275impl CompressionRatio {
2276    /// String value of the enum field names used in the ProtoBuf definition.
2277    ///
2278    /// The values are not transformed in any way and thus are considered stable
2279    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2280    pub fn as_str_name(&self) -> &'static str {
2281        match self {
2282            Self::X4 => "x4",
2283            Self::X8 => "x8",
2284            Self::X16 => "x16",
2285            Self::X32 => "x32",
2286            Self::X64 => "x64",
2287        }
2288    }
2289    /// Creates an enum from field names used in the ProtoBuf definition.
2290    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2291        match value {
2292            "x4" => Some(Self::X4),
2293            "x8" => Some(Self::X8),
2294            "x16" => Some(Self::X16),
2295            "x32" => Some(Self::X32),
2296            "x64" => Some(Self::X64),
2297            _ => None,
2298        }
2299    }
2300}
2301#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2302#[repr(i32)]
2303pub enum BinaryQuantizationEncoding {
2304    OneBit = 0,
2305    TwoBits = 1,
2306    OneAndHalfBits = 2,
2307}
2308impl BinaryQuantizationEncoding {
2309    /// String value of the enum field names used in the ProtoBuf definition.
2310    ///
2311    /// The values are not transformed in any way and thus are considered stable
2312    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2313    pub fn as_str_name(&self) -> &'static str {
2314        match self {
2315            Self::OneBit => "OneBit",
2316            Self::TwoBits => "TwoBits",
2317            Self::OneAndHalfBits => "OneAndHalfBits",
2318        }
2319    }
2320    /// Creates an enum from field names used in the ProtoBuf definition.
2321    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2322        match value {
2323            "OneBit" => Some(Self::OneBit),
2324            "TwoBits" => Some(Self::TwoBits),
2325            "OneAndHalfBits" => Some(Self::OneAndHalfBits),
2326            _ => None,
2327        }
2328    }
2329}
2330#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2331#[repr(i32)]
2332pub enum TurboQuantBitSize {
2333    Bits1 = 0,
2334    /// 1.5 bit variant (not 15 bits)
2335    Bits15 = 1,
2336    Bits2 = 2,
2337    Bits4 = 3,
2338    Bits8 = 4,
2339}
2340impl TurboQuantBitSize {
2341    /// String value of the enum field names used in the ProtoBuf definition.
2342    ///
2343    /// The values are not transformed in any way and thus are considered stable
2344    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2345    pub fn as_str_name(&self) -> &'static str {
2346        match self {
2347            Self::Bits1 => "Bits1",
2348            Self::Bits15 => "Bits1_5",
2349            Self::Bits2 => "Bits2",
2350            Self::Bits4 => "Bits4",
2351            Self::Bits8 => "Bits8",
2352        }
2353    }
2354    /// Creates an enum from field names used in the ProtoBuf definition.
2355    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2356        match value {
2357            "Bits1" => Some(Self::Bits1),
2358            "Bits1_5" => Some(Self::Bits15),
2359            "Bits2" => Some(Self::Bits2),
2360            "Bits4" => Some(Self::Bits4),
2361            "Bits8" => Some(Self::Bits8),
2362            _ => None,
2363        }
2364    }
2365}
2366#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2367#[repr(i32)]
2368pub enum ShardingMethod {
2369    /// Auto-sharding based on record ids
2370    Auto = 0,
2371    /// Shard by user-defined key
2372    Custom = 1,
2373}
2374impl ShardingMethod {
2375    /// String value of the enum field names used in the ProtoBuf definition.
2376    ///
2377    /// The values are not transformed in any way and thus are considered stable
2378    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2379    pub fn as_str_name(&self) -> &'static str {
2380        match self {
2381            Self::Auto => "Auto",
2382            Self::Custom => "Custom",
2383        }
2384    }
2385    /// Creates an enum from field names used in the ProtoBuf definition.
2386    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2387        match value {
2388            "Auto" => Some(Self::Auto),
2389            "Custom" => Some(Self::Custom),
2390            _ => None,
2391        }
2392    }
2393}
2394#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2395#[repr(i32)]
2396pub enum TokenizerType {
2397    Unknown = 0,
2398    Prefix = 1,
2399    Whitespace = 2,
2400    Word = 3,
2401    Multilingual = 4,
2402    Code = 5,
2403}
2404impl TokenizerType {
2405    /// String value of the enum field names used in the ProtoBuf definition.
2406    ///
2407    /// The values are not transformed in any way and thus are considered stable
2408    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2409    pub fn as_str_name(&self) -> &'static str {
2410        match self {
2411            Self::Unknown => "Unknown",
2412            Self::Prefix => "Prefix",
2413            Self::Whitespace => "Whitespace",
2414            Self::Word => "Word",
2415            Self::Multilingual => "Multilingual",
2416            Self::Code => "Code",
2417        }
2418    }
2419    /// Creates an enum from field names used in the ProtoBuf definition.
2420    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2421        match value {
2422            "Unknown" => Some(Self::Unknown),
2423            "Prefix" => Some(Self::Prefix),
2424            "Whitespace" => Some(Self::Whitespace),
2425            "Word" => Some(Self::Word),
2426            "Multilingual" => Some(Self::Multilingual),
2427            "Code" => Some(Self::Code),
2428            _ => None,
2429        }
2430    }
2431}
2432#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2433#[repr(i32)]
2434pub enum TextScoringType {
2435    Bm25 = 0,
2436}
2437impl TextScoringType {
2438    /// String value of the enum field names used in the ProtoBuf definition.
2439    ///
2440    /// The values are not transformed in any way and thus are considered stable
2441    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2442    pub fn as_str_name(&self) -> &'static str {
2443        match self {
2444            Self::Bm25 => "Bm25",
2445        }
2446    }
2447    /// Creates an enum from field names used in the ProtoBuf definition.
2448    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2449        match value {
2450            "Bm25" => Some(Self::Bm25),
2451            _ => None,
2452        }
2453    }
2454}
2455#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2456#[repr(i32)]
2457pub enum ReplicaState {
2458    /// Active and sound
2459    Active = 0,
2460    /// Failed for some reason
2461    Dead = 1,
2462    /// The shard is partially loaded and is currently receiving data from other shards
2463    Partial = 2,
2464    /// Collection is being created
2465    Initializing = 3,
2466    /// A shard which receives data, but is not used for search.
2467    /// Useful for backup shards.
2468    Listener = 4,
2469    /// Deprecated: snapshot shard transfer is in progress.
2470    /// Updates should not be sent to (and are ignored by) the shard.
2471    PartialSnapshot = 5,
2472    /// Shard is undergoing recovery by an external node.
2473    /// Normally rejects updates, accepts updates if force is true.
2474    Recovery = 6,
2475    /// Points are being migrated to this shard as part of scale-up resharding
2476    Resharding = 7,
2477    /// Points are being migrated to this shard as part of scale-down resharding
2478    ReshardingScaleDown = 8,
2479    /// Active for readers, Partial for writers
2480    ActiveRead = 9,
2481    /// State for manually creation/recovery of a shard.
2482    /// Usually when snapshot is uploaded.
2483    /// This state is equivalent to `Partial`, except:
2484    ///
2485    /// * it can't receive updates
2486    /// * it is not treated as broken on startup
2487    ManualRecovery = 10,
2488}
2489impl ReplicaState {
2490    /// String value of the enum field names used in the ProtoBuf definition.
2491    ///
2492    /// The values are not transformed in any way and thus are considered stable
2493    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2494    pub fn as_str_name(&self) -> &'static str {
2495        match self {
2496            Self::Active => "Active",
2497            Self::Dead => "Dead",
2498            Self::Partial => "Partial",
2499            Self::Initializing => "Initializing",
2500            Self::Listener => "Listener",
2501            Self::PartialSnapshot => "PartialSnapshot",
2502            Self::Recovery => "Recovery",
2503            Self::Resharding => "Resharding",
2504            Self::ReshardingScaleDown => "ReshardingScaleDown",
2505            Self::ActiveRead => "ActiveRead",
2506            Self::ManualRecovery => "ManualRecovery",
2507        }
2508    }
2509    /// Creates an enum from field names used in the ProtoBuf definition.
2510    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2511        match value {
2512            "Active" => Some(Self::Active),
2513            "Dead" => Some(Self::Dead),
2514            "Partial" => Some(Self::Partial),
2515            "Initializing" => Some(Self::Initializing),
2516            "Listener" => Some(Self::Listener),
2517            "PartialSnapshot" => Some(Self::PartialSnapshot),
2518            "Recovery" => Some(Self::Recovery),
2519            "Resharding" => Some(Self::Resharding),
2520            "ReshardingScaleDown" => Some(Self::ReshardingScaleDown),
2521            "ActiveRead" => Some(Self::ActiveRead),
2522            "ManualRecovery" => Some(Self::ManualRecovery),
2523            _ => None,
2524        }
2525    }
2526}
2527/// Resharding direction, scale up or down in number of shards
2528#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2529#[repr(i32)]
2530pub enum ReshardingDirection {
2531    /// Scale up, add a new shard
2532    Up = 0,
2533    /// Scale down, remove a shard
2534    Down = 1,
2535}
2536impl ReshardingDirection {
2537    /// String value of the enum field names used in the ProtoBuf definition.
2538    ///
2539    /// The values are not transformed in any way and thus are considered stable
2540    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2541    pub fn as_str_name(&self) -> &'static str {
2542        match self {
2543            Self::Up => "Up",
2544            Self::Down => "Down",
2545        }
2546    }
2547    /// Creates an enum from field names used in the ProtoBuf definition.
2548    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2549        match value {
2550            "Up" => Some(Self::Up),
2551            "Down" => Some(Self::Down),
2552            _ => None,
2553        }
2554    }
2555}
2556#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2557#[repr(i32)]
2558pub enum ShardTransferMethod {
2559    /// Stream shard records in batches
2560    StreamRecords = 0,
2561    /// Snapshot the shard and recover it on the target peer
2562    Snapshot = 1,
2563    /// Resolve WAL delta between peers and transfer the difference
2564    WalDelta = 2,
2565    /// Stream shard records in batches for resharding
2566    ReshardingStreamRecords = 3,
2567}
2568impl ShardTransferMethod {
2569    /// String value of the enum field names used in the ProtoBuf definition.
2570    ///
2571    /// The values are not transformed in any way and thus are considered stable
2572    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2573    pub fn as_str_name(&self) -> &'static str {
2574        match self {
2575            Self::StreamRecords => "StreamRecords",
2576            Self::Snapshot => "Snapshot",
2577            Self::WalDelta => "WalDelta",
2578            Self::ReshardingStreamRecords => "ReshardingStreamRecords",
2579        }
2580    }
2581    /// Creates an enum from field names used in the ProtoBuf definition.
2582    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2583        match value {
2584            "StreamRecords" => Some(Self::StreamRecords),
2585            "Snapshot" => Some(Self::Snapshot),
2586            "WalDelta" => Some(Self::WalDelta),
2587            "ReshardingStreamRecords" => Some(Self::ReshardingStreamRecords),
2588            _ => None,
2589        }
2590    }
2591}
2592/// Generated client implementations.
2593pub mod collections_client {
2594    #![allow(
2595        unused_variables,
2596        dead_code,
2597        missing_docs,
2598        clippy::wildcard_imports,
2599        clippy::let_unit_value,
2600    )]
2601    use tonic::codegen::*;
2602    use tonic::codegen::http::Uri;
2603    #[derive(Debug, Clone)]
2604    pub struct CollectionsClient<T> {
2605        inner: tonic::client::Grpc<T>,
2606    }
2607    impl CollectionsClient<tonic::transport::Channel> {
2608        /// Attempt to create a new client by connecting to a given endpoint.
2609        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
2610        where
2611            D: TryInto<tonic::transport::Endpoint>,
2612            D::Error: Into<StdError>,
2613        {
2614            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
2615            Ok(Self::new(conn))
2616        }
2617    }
2618    impl<T> CollectionsClient<T>
2619    where
2620        T: tonic::client::GrpcService<tonic::body::Body>,
2621        T::Error: Into<StdError>,
2622        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
2623        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
2624    {
2625        pub fn new(inner: T) -> Self {
2626            let inner = tonic::client::Grpc::new(inner);
2627            Self { inner }
2628        }
2629        pub fn with_origin(inner: T, origin: Uri) -> Self {
2630            let inner = tonic::client::Grpc::with_origin(inner, origin);
2631            Self { inner }
2632        }
2633        pub fn with_interceptor<F>(
2634            inner: T,
2635            interceptor: F,
2636        ) -> CollectionsClient<InterceptedService<T, F>>
2637        where
2638            F: tonic::service::Interceptor,
2639            T::ResponseBody: Default,
2640            T: tonic::codegen::Service<
2641                http::Request<tonic::body::Body>,
2642                Response = http::Response<
2643                    <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
2644                >,
2645            >,
2646            <T as tonic::codegen::Service<
2647                http::Request<tonic::body::Body>,
2648            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
2649        {
2650            CollectionsClient::new(InterceptedService::new(inner, interceptor))
2651        }
2652        /// Compress requests with the given encoding.
2653        ///
2654        /// This requires the server to support it otherwise it might respond with an
2655        /// error.
2656        #[must_use]
2657        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2658            self.inner = self.inner.send_compressed(encoding);
2659            self
2660        }
2661        /// Enable decompressing responses.
2662        #[must_use]
2663        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2664            self.inner = self.inner.accept_compressed(encoding);
2665            self
2666        }
2667        /// Limits the maximum size of a decoded message.
2668        ///
2669        /// Default: `4MB`
2670        #[must_use]
2671        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2672            self.inner = self.inner.max_decoding_message_size(limit);
2673            self
2674        }
2675        /// Limits the maximum size of an encoded message.
2676        ///
2677        /// Default: `usize::MAX`
2678        #[must_use]
2679        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2680            self.inner = self.inner.max_encoding_message_size(limit);
2681            self
2682        }
2683        /// Get detailed information about specified existing collection
2684        pub async fn get(
2685            &mut self,
2686            request: impl tonic::IntoRequest<super::GetCollectionInfoRequest>,
2687        ) -> std::result::Result<
2688            tonic::Response<super::GetCollectionInfoResponse>,
2689            tonic::Status,
2690        > {
2691            self.inner
2692                .ready()
2693                .await
2694                .map_err(|e| {
2695                    tonic::Status::unknown(
2696                        format!("Service was not ready: {}", e.into()),
2697                    )
2698                })?;
2699            let codec = tonic_prost::ProstCodec::default();
2700            let path = http::uri::PathAndQuery::from_static("/qdrant.Collections/Get");
2701            let mut req = request.into_request();
2702            req.extensions_mut().insert(GrpcMethod::new("qdrant.Collections", "Get"));
2703            self.inner.unary(req, path, codec).await
2704        }
2705        /// Get list of names of all existing collections
2706        pub async fn list(
2707            &mut self,
2708            request: impl tonic::IntoRequest<super::ListCollectionsRequest>,
2709        ) -> std::result::Result<
2710            tonic::Response<super::ListCollectionsResponse>,
2711            tonic::Status,
2712        > {
2713            self.inner
2714                .ready()
2715                .await
2716                .map_err(|e| {
2717                    tonic::Status::unknown(
2718                        format!("Service was not ready: {}", e.into()),
2719                    )
2720                })?;
2721            let codec = tonic_prost::ProstCodec::default();
2722            let path = http::uri::PathAndQuery::from_static("/qdrant.Collections/List");
2723            let mut req = request.into_request();
2724            req.extensions_mut().insert(GrpcMethod::new("qdrant.Collections", "List"));
2725            self.inner.unary(req, path, codec).await
2726        }
2727        /// Create new collection with given parameters
2728        pub async fn create(
2729            &mut self,
2730            request: impl tonic::IntoRequest<super::CreateCollection>,
2731        ) -> std::result::Result<
2732            tonic::Response<super::CollectionOperationResponse>,
2733            tonic::Status,
2734        > {
2735            self.inner
2736                .ready()
2737                .await
2738                .map_err(|e| {
2739                    tonic::Status::unknown(
2740                        format!("Service was not ready: {}", e.into()),
2741                    )
2742                })?;
2743            let codec = tonic_prost::ProstCodec::default();
2744            let path = http::uri::PathAndQuery::from_static(
2745                "/qdrant.Collections/Create",
2746            );
2747            let mut req = request.into_request();
2748            req.extensions_mut().insert(GrpcMethod::new("qdrant.Collections", "Create"));
2749            self.inner.unary(req, path, codec).await
2750        }
2751        /// Update parameters of the existing collection
2752        pub async fn update(
2753            &mut self,
2754            request: impl tonic::IntoRequest<super::UpdateCollection>,
2755        ) -> std::result::Result<
2756            tonic::Response<super::CollectionOperationResponse>,
2757            tonic::Status,
2758        > {
2759            self.inner
2760                .ready()
2761                .await
2762                .map_err(|e| {
2763                    tonic::Status::unknown(
2764                        format!("Service was not ready: {}", e.into()),
2765                    )
2766                })?;
2767            let codec = tonic_prost::ProstCodec::default();
2768            let path = http::uri::PathAndQuery::from_static(
2769                "/qdrant.Collections/Update",
2770            );
2771            let mut req = request.into_request();
2772            req.extensions_mut().insert(GrpcMethod::new("qdrant.Collections", "Update"));
2773            self.inner.unary(req, path, codec).await
2774        }
2775        /// Drop collection and all associated data
2776        pub async fn delete(
2777            &mut self,
2778            request: impl tonic::IntoRequest<super::DeleteCollection>,
2779        ) -> std::result::Result<
2780            tonic::Response<super::CollectionOperationResponse>,
2781            tonic::Status,
2782        > {
2783            self.inner
2784                .ready()
2785                .await
2786                .map_err(|e| {
2787                    tonic::Status::unknown(
2788                        format!("Service was not ready: {}", e.into()),
2789                    )
2790                })?;
2791            let codec = tonic_prost::ProstCodec::default();
2792            let path = http::uri::PathAndQuery::from_static(
2793                "/qdrant.Collections/Delete",
2794            );
2795            let mut req = request.into_request();
2796            req.extensions_mut().insert(GrpcMethod::new("qdrant.Collections", "Delete"));
2797            self.inner.unary(req, path, codec).await
2798        }
2799        /// Update Aliases of the existing collection
2800        pub async fn update_aliases(
2801            &mut self,
2802            request: impl tonic::IntoRequest<super::ChangeAliases>,
2803        ) -> std::result::Result<
2804            tonic::Response<super::CollectionOperationResponse>,
2805            tonic::Status,
2806        > {
2807            self.inner
2808                .ready()
2809                .await
2810                .map_err(|e| {
2811                    tonic::Status::unknown(
2812                        format!("Service was not ready: {}", e.into()),
2813                    )
2814                })?;
2815            let codec = tonic_prost::ProstCodec::default();
2816            let path = http::uri::PathAndQuery::from_static(
2817                "/qdrant.Collections/UpdateAliases",
2818            );
2819            let mut req = request.into_request();
2820            req.extensions_mut()
2821                .insert(GrpcMethod::new("qdrant.Collections", "UpdateAliases"));
2822            self.inner.unary(req, path, codec).await
2823        }
2824        /// Get list of all aliases for a collection
2825        pub async fn list_collection_aliases(
2826            &mut self,
2827            request: impl tonic::IntoRequest<super::ListCollectionAliasesRequest>,
2828        ) -> std::result::Result<
2829            tonic::Response<super::ListAliasesResponse>,
2830            tonic::Status,
2831        > {
2832            self.inner
2833                .ready()
2834                .await
2835                .map_err(|e| {
2836                    tonic::Status::unknown(
2837                        format!("Service was not ready: {}", e.into()),
2838                    )
2839                })?;
2840            let codec = tonic_prost::ProstCodec::default();
2841            let path = http::uri::PathAndQuery::from_static(
2842                "/qdrant.Collections/ListCollectionAliases",
2843            );
2844            let mut req = request.into_request();
2845            req.extensions_mut()
2846                .insert(GrpcMethod::new("qdrant.Collections", "ListCollectionAliases"));
2847            self.inner.unary(req, path, codec).await
2848        }
2849        /// Get list of all aliases for all existing collections
2850        pub async fn list_aliases(
2851            &mut self,
2852            request: impl tonic::IntoRequest<super::ListAliasesRequest>,
2853        ) -> std::result::Result<
2854            tonic::Response<super::ListAliasesResponse>,
2855            tonic::Status,
2856        > {
2857            self.inner
2858                .ready()
2859                .await
2860                .map_err(|e| {
2861                    tonic::Status::unknown(
2862                        format!("Service was not ready: {}", e.into()),
2863                    )
2864                })?;
2865            let codec = tonic_prost::ProstCodec::default();
2866            let path = http::uri::PathAndQuery::from_static(
2867                "/qdrant.Collections/ListAliases",
2868            );
2869            let mut req = request.into_request();
2870            req.extensions_mut()
2871                .insert(GrpcMethod::new("qdrant.Collections", "ListAliases"));
2872            self.inner.unary(req, path, codec).await
2873        }
2874        /// Get cluster information for a collection
2875        pub async fn collection_cluster_info(
2876            &mut self,
2877            request: impl tonic::IntoRequest<super::CollectionClusterInfoRequest>,
2878        ) -> std::result::Result<
2879            tonic::Response<super::CollectionClusterInfoResponse>,
2880            tonic::Status,
2881        > {
2882            self.inner
2883                .ready()
2884                .await
2885                .map_err(|e| {
2886                    tonic::Status::unknown(
2887                        format!("Service was not ready: {}", e.into()),
2888                    )
2889                })?;
2890            let codec = tonic_prost::ProstCodec::default();
2891            let path = http::uri::PathAndQuery::from_static(
2892                "/qdrant.Collections/CollectionClusterInfo",
2893            );
2894            let mut req = request.into_request();
2895            req.extensions_mut()
2896                .insert(GrpcMethod::new("qdrant.Collections", "CollectionClusterInfo"));
2897            self.inner.unary(req, path, codec).await
2898        }
2899        /// Check the existence of a collection
2900        pub async fn collection_exists(
2901            &mut self,
2902            request: impl tonic::IntoRequest<super::CollectionExistsRequest>,
2903        ) -> std::result::Result<
2904            tonic::Response<super::CollectionExistsResponse>,
2905            tonic::Status,
2906        > {
2907            self.inner
2908                .ready()
2909                .await
2910                .map_err(|e| {
2911                    tonic::Status::unknown(
2912                        format!("Service was not ready: {}", e.into()),
2913                    )
2914                })?;
2915            let codec = tonic_prost::ProstCodec::default();
2916            let path = http::uri::PathAndQuery::from_static(
2917                "/qdrant.Collections/CollectionExists",
2918            );
2919            let mut req = request.into_request();
2920            req.extensions_mut()
2921                .insert(GrpcMethod::new("qdrant.Collections", "CollectionExists"));
2922            self.inner.unary(req, path, codec).await
2923        }
2924        /// Update cluster setup for a collection
2925        pub async fn update_collection_cluster_setup(
2926            &mut self,
2927            request: impl tonic::IntoRequest<super::UpdateCollectionClusterSetupRequest>,
2928        ) -> std::result::Result<
2929            tonic::Response<super::UpdateCollectionClusterSetupResponse>,
2930            tonic::Status,
2931        > {
2932            self.inner
2933                .ready()
2934                .await
2935                .map_err(|e| {
2936                    tonic::Status::unknown(
2937                        format!("Service was not ready: {}", e.into()),
2938                    )
2939                })?;
2940            let codec = tonic_prost::ProstCodec::default();
2941            let path = http::uri::PathAndQuery::from_static(
2942                "/qdrant.Collections/UpdateCollectionClusterSetup",
2943            );
2944            let mut req = request.into_request();
2945            req.extensions_mut()
2946                .insert(
2947                    GrpcMethod::new("qdrant.Collections", "UpdateCollectionClusterSetup"),
2948                );
2949            self.inner.unary(req, path, codec).await
2950        }
2951        /// Create shard key
2952        pub async fn create_shard_key(
2953            &mut self,
2954            request: impl tonic::IntoRequest<super::CreateShardKeyRequest>,
2955        ) -> std::result::Result<
2956            tonic::Response<super::CreateShardKeyResponse>,
2957            tonic::Status,
2958        > {
2959            self.inner
2960                .ready()
2961                .await
2962                .map_err(|e| {
2963                    tonic::Status::unknown(
2964                        format!("Service was not ready: {}", e.into()),
2965                    )
2966                })?;
2967            let codec = tonic_prost::ProstCodec::default();
2968            let path = http::uri::PathAndQuery::from_static(
2969                "/qdrant.Collections/CreateShardKey",
2970            );
2971            let mut req = request.into_request();
2972            req.extensions_mut()
2973                .insert(GrpcMethod::new("qdrant.Collections", "CreateShardKey"));
2974            self.inner.unary(req, path, codec).await
2975        }
2976        /// Delete shard key
2977        pub async fn delete_shard_key(
2978            &mut self,
2979            request: impl tonic::IntoRequest<super::DeleteShardKeyRequest>,
2980        ) -> std::result::Result<
2981            tonic::Response<super::DeleteShardKeyResponse>,
2982            tonic::Status,
2983        > {
2984            self.inner
2985                .ready()
2986                .await
2987                .map_err(|e| {
2988                    tonic::Status::unknown(
2989                        format!("Service was not ready: {}", e.into()),
2990                    )
2991                })?;
2992            let codec = tonic_prost::ProstCodec::default();
2993            let path = http::uri::PathAndQuery::from_static(
2994                "/qdrant.Collections/DeleteShardKey",
2995            );
2996            let mut req = request.into_request();
2997            req.extensions_mut()
2998                .insert(GrpcMethod::new("qdrant.Collections", "DeleteShardKey"));
2999            self.inner.unary(req, path, codec).await
3000        }
3001        /// List shard keys
3002        pub async fn list_shard_keys(
3003            &mut self,
3004            request: impl tonic::IntoRequest<super::ListShardKeysRequest>,
3005        ) -> std::result::Result<
3006            tonic::Response<super::ListShardKeysResponse>,
3007            tonic::Status,
3008        > {
3009            self.inner
3010                .ready()
3011                .await
3012                .map_err(|e| {
3013                    tonic::Status::unknown(
3014                        format!("Service was not ready: {}", e.into()),
3015                    )
3016                })?;
3017            let codec = tonic_prost::ProstCodec::default();
3018            let path = http::uri::PathAndQuery::from_static(
3019                "/qdrant.Collections/ListShardKeys",
3020            );
3021            let mut req = request.into_request();
3022            req.extensions_mut()
3023                .insert(GrpcMethod::new("qdrant.Collections", "ListShardKeys"));
3024            self.inner.unary(req, path, codec).await
3025        }
3026    }
3027}
3028/// Generated server implementations.
3029pub mod collections_server {
3030    #![allow(
3031        unused_variables,
3032        dead_code,
3033        missing_docs,
3034        clippy::wildcard_imports,
3035        clippy::let_unit_value,
3036    )]
3037    use tonic::codegen::*;
3038    /// Generated trait containing gRPC methods that should be implemented for use with CollectionsServer.
3039    #[async_trait]
3040    pub trait Collections: std::marker::Send + std::marker::Sync + 'static {
3041        /// Get detailed information about specified existing collection
3042        async fn get(
3043            &self,
3044            request: tonic::Request<super::GetCollectionInfoRequest>,
3045        ) -> std::result::Result<
3046            tonic::Response<super::GetCollectionInfoResponse>,
3047            tonic::Status,
3048        >;
3049        /// Get list of names of all existing collections
3050        async fn list(
3051            &self,
3052            request: tonic::Request<super::ListCollectionsRequest>,
3053        ) -> std::result::Result<
3054            tonic::Response<super::ListCollectionsResponse>,
3055            tonic::Status,
3056        >;
3057        /// Create new collection with given parameters
3058        async fn create(
3059            &self,
3060            request: tonic::Request<super::CreateCollection>,
3061        ) -> std::result::Result<
3062            tonic::Response<super::CollectionOperationResponse>,
3063            tonic::Status,
3064        >;
3065        /// Update parameters of the existing collection
3066        async fn update(
3067            &self,
3068            request: tonic::Request<super::UpdateCollection>,
3069        ) -> std::result::Result<
3070            tonic::Response<super::CollectionOperationResponse>,
3071            tonic::Status,
3072        >;
3073        /// Drop collection and all associated data
3074        async fn delete(
3075            &self,
3076            request: tonic::Request<super::DeleteCollection>,
3077        ) -> std::result::Result<
3078            tonic::Response<super::CollectionOperationResponse>,
3079            tonic::Status,
3080        >;
3081        /// Update Aliases of the existing collection
3082        async fn update_aliases(
3083            &self,
3084            request: tonic::Request<super::ChangeAliases>,
3085        ) -> std::result::Result<
3086            tonic::Response<super::CollectionOperationResponse>,
3087            tonic::Status,
3088        >;
3089        /// Get list of all aliases for a collection
3090        async fn list_collection_aliases(
3091            &self,
3092            request: tonic::Request<super::ListCollectionAliasesRequest>,
3093        ) -> std::result::Result<
3094            tonic::Response<super::ListAliasesResponse>,
3095            tonic::Status,
3096        >;
3097        /// Get list of all aliases for all existing collections
3098        async fn list_aliases(
3099            &self,
3100            request: tonic::Request<super::ListAliasesRequest>,
3101        ) -> std::result::Result<
3102            tonic::Response<super::ListAliasesResponse>,
3103            tonic::Status,
3104        >;
3105        /// Get cluster information for a collection
3106        async fn collection_cluster_info(
3107            &self,
3108            request: tonic::Request<super::CollectionClusterInfoRequest>,
3109        ) -> std::result::Result<
3110            tonic::Response<super::CollectionClusterInfoResponse>,
3111            tonic::Status,
3112        >;
3113        /// Check the existence of a collection
3114        async fn collection_exists(
3115            &self,
3116            request: tonic::Request<super::CollectionExistsRequest>,
3117        ) -> std::result::Result<
3118            tonic::Response<super::CollectionExistsResponse>,
3119            tonic::Status,
3120        >;
3121        /// Update cluster setup for a collection
3122        async fn update_collection_cluster_setup(
3123            &self,
3124            request: tonic::Request<super::UpdateCollectionClusterSetupRequest>,
3125        ) -> std::result::Result<
3126            tonic::Response<super::UpdateCollectionClusterSetupResponse>,
3127            tonic::Status,
3128        >;
3129        /// Create shard key
3130        async fn create_shard_key(
3131            &self,
3132            request: tonic::Request<super::CreateShardKeyRequest>,
3133        ) -> std::result::Result<
3134            tonic::Response<super::CreateShardKeyResponse>,
3135            tonic::Status,
3136        >;
3137        /// Delete shard key
3138        async fn delete_shard_key(
3139            &self,
3140            request: tonic::Request<super::DeleteShardKeyRequest>,
3141        ) -> std::result::Result<
3142            tonic::Response<super::DeleteShardKeyResponse>,
3143            tonic::Status,
3144        >;
3145        /// List shard keys
3146        async fn list_shard_keys(
3147            &self,
3148            request: tonic::Request<super::ListShardKeysRequest>,
3149        ) -> std::result::Result<
3150            tonic::Response<super::ListShardKeysResponse>,
3151            tonic::Status,
3152        >;
3153    }
3154    #[derive(Debug)]
3155    pub struct CollectionsServer<T> {
3156        inner: Arc<T>,
3157        accept_compression_encodings: EnabledCompressionEncodings,
3158        send_compression_encodings: EnabledCompressionEncodings,
3159        max_decoding_message_size: Option<usize>,
3160        max_encoding_message_size: Option<usize>,
3161    }
3162    impl<T> CollectionsServer<T> {
3163        pub fn new(inner: T) -> Self {
3164            Self::from_arc(Arc::new(inner))
3165        }
3166        pub fn from_arc(inner: Arc<T>) -> Self {
3167            Self {
3168                inner,
3169                accept_compression_encodings: Default::default(),
3170                send_compression_encodings: Default::default(),
3171                max_decoding_message_size: None,
3172                max_encoding_message_size: None,
3173            }
3174        }
3175        pub fn with_interceptor<F>(
3176            inner: T,
3177            interceptor: F,
3178        ) -> InterceptedService<Self, F>
3179        where
3180            F: tonic::service::Interceptor,
3181        {
3182            InterceptedService::new(Self::new(inner), interceptor)
3183        }
3184        /// Enable decompressing requests with the given encoding.
3185        #[must_use]
3186        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3187            self.accept_compression_encodings.enable(encoding);
3188            self
3189        }
3190        /// Compress responses with the given encoding, if the client supports it.
3191        #[must_use]
3192        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3193            self.send_compression_encodings.enable(encoding);
3194            self
3195        }
3196        /// Limits the maximum size of a decoded message.
3197        ///
3198        /// Default: `4MB`
3199        #[must_use]
3200        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3201            self.max_decoding_message_size = Some(limit);
3202            self
3203        }
3204        /// Limits the maximum size of an encoded message.
3205        ///
3206        /// Default: `usize::MAX`
3207        #[must_use]
3208        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3209            self.max_encoding_message_size = Some(limit);
3210            self
3211        }
3212    }
3213    impl<T, B> tonic::codegen::Service<http::Request<B>> for CollectionsServer<T>
3214    where
3215        T: Collections,
3216        B: Body + std::marker::Send + 'static,
3217        B::Error: Into<StdError> + std::marker::Send + 'static,
3218    {
3219        type Response = http::Response<tonic::body::Body>;
3220        type Error = std::convert::Infallible;
3221        type Future = BoxFuture<Self::Response, Self::Error>;
3222        fn poll_ready(
3223            &mut self,
3224            _cx: &mut Context<'_>,
3225        ) -> Poll<std::result::Result<(), Self::Error>> {
3226            Poll::Ready(Ok(()))
3227        }
3228        fn call(&mut self, req: http::Request<B>) -> Self::Future {
3229            match req.uri().path() {
3230                "/qdrant.Collections/Get" => {
3231                    #[allow(non_camel_case_types)]
3232                    struct GetSvc<T: Collections>(pub Arc<T>);
3233                    impl<
3234                        T: Collections,
3235                    > tonic::server::UnaryService<super::GetCollectionInfoRequest>
3236                    for GetSvc<T> {
3237                        type Response = super::GetCollectionInfoResponse;
3238                        type Future = BoxFuture<
3239                            tonic::Response<Self::Response>,
3240                            tonic::Status,
3241                        >;
3242                        fn call(
3243                            &mut self,
3244                            request: tonic::Request<super::GetCollectionInfoRequest>,
3245                        ) -> Self::Future {
3246                            let inner = Arc::clone(&self.0);
3247                            let fut = async move {
3248                                <T as Collections>::get(&inner, request).await
3249                            };
3250                            Box::pin(fut)
3251                        }
3252                    }
3253                    let accept_compression_encodings = self.accept_compression_encodings;
3254                    let send_compression_encodings = self.send_compression_encodings;
3255                    let max_decoding_message_size = self.max_decoding_message_size;
3256                    let max_encoding_message_size = self.max_encoding_message_size;
3257                    let inner = self.inner.clone();
3258                    let fut = async move {
3259                        let method = GetSvc(inner);
3260                        let codec = tonic_prost::ProstCodec::default();
3261                        let mut grpc = tonic::server::Grpc::new(codec)
3262                            .apply_compression_config(
3263                                accept_compression_encodings,
3264                                send_compression_encodings,
3265                            )
3266                            .apply_max_message_size_config(
3267                                max_decoding_message_size,
3268                                max_encoding_message_size,
3269                            );
3270                        let res = grpc.unary(method, req).await;
3271                        Ok(res)
3272                    };
3273                    Box::pin(fut)
3274                }
3275                "/qdrant.Collections/List" => {
3276                    #[allow(non_camel_case_types)]
3277                    struct ListSvc<T: Collections>(pub Arc<T>);
3278                    impl<
3279                        T: Collections,
3280                    > tonic::server::UnaryService<super::ListCollectionsRequest>
3281                    for ListSvc<T> {
3282                        type Response = super::ListCollectionsResponse;
3283                        type Future = BoxFuture<
3284                            tonic::Response<Self::Response>,
3285                            tonic::Status,
3286                        >;
3287                        fn call(
3288                            &mut self,
3289                            request: tonic::Request<super::ListCollectionsRequest>,
3290                        ) -> Self::Future {
3291                            let inner = Arc::clone(&self.0);
3292                            let fut = async move {
3293                                <T as Collections>::list(&inner, request).await
3294                            };
3295                            Box::pin(fut)
3296                        }
3297                    }
3298                    let accept_compression_encodings = self.accept_compression_encodings;
3299                    let send_compression_encodings = self.send_compression_encodings;
3300                    let max_decoding_message_size = self.max_decoding_message_size;
3301                    let max_encoding_message_size = self.max_encoding_message_size;
3302                    let inner = self.inner.clone();
3303                    let fut = async move {
3304                        let method = ListSvc(inner);
3305                        let codec = tonic_prost::ProstCodec::default();
3306                        let mut grpc = tonic::server::Grpc::new(codec)
3307                            .apply_compression_config(
3308                                accept_compression_encodings,
3309                                send_compression_encodings,
3310                            )
3311                            .apply_max_message_size_config(
3312                                max_decoding_message_size,
3313                                max_encoding_message_size,
3314                            );
3315                        let res = grpc.unary(method, req).await;
3316                        Ok(res)
3317                    };
3318                    Box::pin(fut)
3319                }
3320                "/qdrant.Collections/Create" => {
3321                    #[allow(non_camel_case_types)]
3322                    struct CreateSvc<T: Collections>(pub Arc<T>);
3323                    impl<
3324                        T: Collections,
3325                    > tonic::server::UnaryService<super::CreateCollection>
3326                    for CreateSvc<T> {
3327                        type Response = super::CollectionOperationResponse;
3328                        type Future = BoxFuture<
3329                            tonic::Response<Self::Response>,
3330                            tonic::Status,
3331                        >;
3332                        fn call(
3333                            &mut self,
3334                            request: tonic::Request<super::CreateCollection>,
3335                        ) -> Self::Future {
3336                            let inner = Arc::clone(&self.0);
3337                            let fut = async move {
3338                                <T as Collections>::create(&inner, request).await
3339                            };
3340                            Box::pin(fut)
3341                        }
3342                    }
3343                    let accept_compression_encodings = self.accept_compression_encodings;
3344                    let send_compression_encodings = self.send_compression_encodings;
3345                    let max_decoding_message_size = self.max_decoding_message_size;
3346                    let max_encoding_message_size = self.max_encoding_message_size;
3347                    let inner = self.inner.clone();
3348                    let fut = async move {
3349                        let method = CreateSvc(inner);
3350                        let codec = tonic_prost::ProstCodec::default();
3351                        let mut grpc = tonic::server::Grpc::new(codec)
3352                            .apply_compression_config(
3353                                accept_compression_encodings,
3354                                send_compression_encodings,
3355                            )
3356                            .apply_max_message_size_config(
3357                                max_decoding_message_size,
3358                                max_encoding_message_size,
3359                            );
3360                        let res = grpc.unary(method, req).await;
3361                        Ok(res)
3362                    };
3363                    Box::pin(fut)
3364                }
3365                "/qdrant.Collections/Update" => {
3366                    #[allow(non_camel_case_types)]
3367                    struct UpdateSvc<T: Collections>(pub Arc<T>);
3368                    impl<
3369                        T: Collections,
3370                    > tonic::server::UnaryService<super::UpdateCollection>
3371                    for UpdateSvc<T> {
3372                        type Response = super::CollectionOperationResponse;
3373                        type Future = BoxFuture<
3374                            tonic::Response<Self::Response>,
3375                            tonic::Status,
3376                        >;
3377                        fn call(
3378                            &mut self,
3379                            request: tonic::Request<super::UpdateCollection>,
3380                        ) -> Self::Future {
3381                            let inner = Arc::clone(&self.0);
3382                            let fut = async move {
3383                                <T as Collections>::update(&inner, request).await
3384                            };
3385                            Box::pin(fut)
3386                        }
3387                    }
3388                    let accept_compression_encodings = self.accept_compression_encodings;
3389                    let send_compression_encodings = self.send_compression_encodings;
3390                    let max_decoding_message_size = self.max_decoding_message_size;
3391                    let max_encoding_message_size = self.max_encoding_message_size;
3392                    let inner = self.inner.clone();
3393                    let fut = async move {
3394                        let method = UpdateSvc(inner);
3395                        let codec = tonic_prost::ProstCodec::default();
3396                        let mut grpc = tonic::server::Grpc::new(codec)
3397                            .apply_compression_config(
3398                                accept_compression_encodings,
3399                                send_compression_encodings,
3400                            )
3401                            .apply_max_message_size_config(
3402                                max_decoding_message_size,
3403                                max_encoding_message_size,
3404                            );
3405                        let res = grpc.unary(method, req).await;
3406                        Ok(res)
3407                    };
3408                    Box::pin(fut)
3409                }
3410                "/qdrant.Collections/Delete" => {
3411                    #[allow(non_camel_case_types)]
3412                    struct DeleteSvc<T: Collections>(pub Arc<T>);
3413                    impl<
3414                        T: Collections,
3415                    > tonic::server::UnaryService<super::DeleteCollection>
3416                    for DeleteSvc<T> {
3417                        type Response = super::CollectionOperationResponse;
3418                        type Future = BoxFuture<
3419                            tonic::Response<Self::Response>,
3420                            tonic::Status,
3421                        >;
3422                        fn call(
3423                            &mut self,
3424                            request: tonic::Request<super::DeleteCollection>,
3425                        ) -> Self::Future {
3426                            let inner = Arc::clone(&self.0);
3427                            let fut = async move {
3428                                <T as Collections>::delete(&inner, request).await
3429                            };
3430                            Box::pin(fut)
3431                        }
3432                    }
3433                    let accept_compression_encodings = self.accept_compression_encodings;
3434                    let send_compression_encodings = self.send_compression_encodings;
3435                    let max_decoding_message_size = self.max_decoding_message_size;
3436                    let max_encoding_message_size = self.max_encoding_message_size;
3437                    let inner = self.inner.clone();
3438                    let fut = async move {
3439                        let method = DeleteSvc(inner);
3440                        let codec = tonic_prost::ProstCodec::default();
3441                        let mut grpc = tonic::server::Grpc::new(codec)
3442                            .apply_compression_config(
3443                                accept_compression_encodings,
3444                                send_compression_encodings,
3445                            )
3446                            .apply_max_message_size_config(
3447                                max_decoding_message_size,
3448                                max_encoding_message_size,
3449                            );
3450                        let res = grpc.unary(method, req).await;
3451                        Ok(res)
3452                    };
3453                    Box::pin(fut)
3454                }
3455                "/qdrant.Collections/UpdateAliases" => {
3456                    #[allow(non_camel_case_types)]
3457                    struct UpdateAliasesSvc<T: Collections>(pub Arc<T>);
3458                    impl<
3459                        T: Collections,
3460                    > tonic::server::UnaryService<super::ChangeAliases>
3461                    for UpdateAliasesSvc<T> {
3462                        type Response = super::CollectionOperationResponse;
3463                        type Future = BoxFuture<
3464                            tonic::Response<Self::Response>,
3465                            tonic::Status,
3466                        >;
3467                        fn call(
3468                            &mut self,
3469                            request: tonic::Request<super::ChangeAliases>,
3470                        ) -> Self::Future {
3471                            let inner = Arc::clone(&self.0);
3472                            let fut = async move {
3473                                <T as Collections>::update_aliases(&inner, request).await
3474                            };
3475                            Box::pin(fut)
3476                        }
3477                    }
3478                    let accept_compression_encodings = self.accept_compression_encodings;
3479                    let send_compression_encodings = self.send_compression_encodings;
3480                    let max_decoding_message_size = self.max_decoding_message_size;
3481                    let max_encoding_message_size = self.max_encoding_message_size;
3482                    let inner = self.inner.clone();
3483                    let fut = async move {
3484                        let method = UpdateAliasesSvc(inner);
3485                        let codec = tonic_prost::ProstCodec::default();
3486                        let mut grpc = tonic::server::Grpc::new(codec)
3487                            .apply_compression_config(
3488                                accept_compression_encodings,
3489                                send_compression_encodings,
3490                            )
3491                            .apply_max_message_size_config(
3492                                max_decoding_message_size,
3493                                max_encoding_message_size,
3494                            );
3495                        let res = grpc.unary(method, req).await;
3496                        Ok(res)
3497                    };
3498                    Box::pin(fut)
3499                }
3500                "/qdrant.Collections/ListCollectionAliases" => {
3501                    #[allow(non_camel_case_types)]
3502                    struct ListCollectionAliasesSvc<T: Collections>(pub Arc<T>);
3503                    impl<
3504                        T: Collections,
3505                    > tonic::server::UnaryService<super::ListCollectionAliasesRequest>
3506                    for ListCollectionAliasesSvc<T> {
3507                        type Response = super::ListAliasesResponse;
3508                        type Future = BoxFuture<
3509                            tonic::Response<Self::Response>,
3510                            tonic::Status,
3511                        >;
3512                        fn call(
3513                            &mut self,
3514                            request: tonic::Request<super::ListCollectionAliasesRequest>,
3515                        ) -> Self::Future {
3516                            let inner = Arc::clone(&self.0);
3517                            let fut = async move {
3518                                <T as Collections>::list_collection_aliases(&inner, request)
3519                                    .await
3520                            };
3521                            Box::pin(fut)
3522                        }
3523                    }
3524                    let accept_compression_encodings = self.accept_compression_encodings;
3525                    let send_compression_encodings = self.send_compression_encodings;
3526                    let max_decoding_message_size = self.max_decoding_message_size;
3527                    let max_encoding_message_size = self.max_encoding_message_size;
3528                    let inner = self.inner.clone();
3529                    let fut = async move {
3530                        let method = ListCollectionAliasesSvc(inner);
3531                        let codec = tonic_prost::ProstCodec::default();
3532                        let mut grpc = tonic::server::Grpc::new(codec)
3533                            .apply_compression_config(
3534                                accept_compression_encodings,
3535                                send_compression_encodings,
3536                            )
3537                            .apply_max_message_size_config(
3538                                max_decoding_message_size,
3539                                max_encoding_message_size,
3540                            );
3541                        let res = grpc.unary(method, req).await;
3542                        Ok(res)
3543                    };
3544                    Box::pin(fut)
3545                }
3546                "/qdrant.Collections/ListAliases" => {
3547                    #[allow(non_camel_case_types)]
3548                    struct ListAliasesSvc<T: Collections>(pub Arc<T>);
3549                    impl<
3550                        T: Collections,
3551                    > tonic::server::UnaryService<super::ListAliasesRequest>
3552                    for ListAliasesSvc<T> {
3553                        type Response = super::ListAliasesResponse;
3554                        type Future = BoxFuture<
3555                            tonic::Response<Self::Response>,
3556                            tonic::Status,
3557                        >;
3558                        fn call(
3559                            &mut self,
3560                            request: tonic::Request<super::ListAliasesRequest>,
3561                        ) -> Self::Future {
3562                            let inner = Arc::clone(&self.0);
3563                            let fut = async move {
3564                                <T as Collections>::list_aliases(&inner, request).await
3565                            };
3566                            Box::pin(fut)
3567                        }
3568                    }
3569                    let accept_compression_encodings = self.accept_compression_encodings;
3570                    let send_compression_encodings = self.send_compression_encodings;
3571                    let max_decoding_message_size = self.max_decoding_message_size;
3572                    let max_encoding_message_size = self.max_encoding_message_size;
3573                    let inner = self.inner.clone();
3574                    let fut = async move {
3575                        let method = ListAliasesSvc(inner);
3576                        let codec = tonic_prost::ProstCodec::default();
3577                        let mut grpc = tonic::server::Grpc::new(codec)
3578                            .apply_compression_config(
3579                                accept_compression_encodings,
3580                                send_compression_encodings,
3581                            )
3582                            .apply_max_message_size_config(
3583                                max_decoding_message_size,
3584                                max_encoding_message_size,
3585                            );
3586                        let res = grpc.unary(method, req).await;
3587                        Ok(res)
3588                    };
3589                    Box::pin(fut)
3590                }
3591                "/qdrant.Collections/CollectionClusterInfo" => {
3592                    #[allow(non_camel_case_types)]
3593                    struct CollectionClusterInfoSvc<T: Collections>(pub Arc<T>);
3594                    impl<
3595                        T: Collections,
3596                    > tonic::server::UnaryService<super::CollectionClusterInfoRequest>
3597                    for CollectionClusterInfoSvc<T> {
3598                        type Response = super::CollectionClusterInfoResponse;
3599                        type Future = BoxFuture<
3600                            tonic::Response<Self::Response>,
3601                            tonic::Status,
3602                        >;
3603                        fn call(
3604                            &mut self,
3605                            request: tonic::Request<super::CollectionClusterInfoRequest>,
3606                        ) -> Self::Future {
3607                            let inner = Arc::clone(&self.0);
3608                            let fut = async move {
3609                                <T as Collections>::collection_cluster_info(&inner, request)
3610                                    .await
3611                            };
3612                            Box::pin(fut)
3613                        }
3614                    }
3615                    let accept_compression_encodings = self.accept_compression_encodings;
3616                    let send_compression_encodings = self.send_compression_encodings;
3617                    let max_decoding_message_size = self.max_decoding_message_size;
3618                    let max_encoding_message_size = self.max_encoding_message_size;
3619                    let inner = self.inner.clone();
3620                    let fut = async move {
3621                        let method = CollectionClusterInfoSvc(inner);
3622                        let codec = tonic_prost::ProstCodec::default();
3623                        let mut grpc = tonic::server::Grpc::new(codec)
3624                            .apply_compression_config(
3625                                accept_compression_encodings,
3626                                send_compression_encodings,
3627                            )
3628                            .apply_max_message_size_config(
3629                                max_decoding_message_size,
3630                                max_encoding_message_size,
3631                            );
3632                        let res = grpc.unary(method, req).await;
3633                        Ok(res)
3634                    };
3635                    Box::pin(fut)
3636                }
3637                "/qdrant.Collections/CollectionExists" => {
3638                    #[allow(non_camel_case_types)]
3639                    struct CollectionExistsSvc<T: Collections>(pub Arc<T>);
3640                    impl<
3641                        T: Collections,
3642                    > tonic::server::UnaryService<super::CollectionExistsRequest>
3643                    for CollectionExistsSvc<T> {
3644                        type Response = super::CollectionExistsResponse;
3645                        type Future = BoxFuture<
3646                            tonic::Response<Self::Response>,
3647                            tonic::Status,
3648                        >;
3649                        fn call(
3650                            &mut self,
3651                            request: tonic::Request<super::CollectionExistsRequest>,
3652                        ) -> Self::Future {
3653                            let inner = Arc::clone(&self.0);
3654                            let fut = async move {
3655                                <T as Collections>::collection_exists(&inner, request).await
3656                            };
3657                            Box::pin(fut)
3658                        }
3659                    }
3660                    let accept_compression_encodings = self.accept_compression_encodings;
3661                    let send_compression_encodings = self.send_compression_encodings;
3662                    let max_decoding_message_size = self.max_decoding_message_size;
3663                    let max_encoding_message_size = self.max_encoding_message_size;
3664                    let inner = self.inner.clone();
3665                    let fut = async move {
3666                        let method = CollectionExistsSvc(inner);
3667                        let codec = tonic_prost::ProstCodec::default();
3668                        let mut grpc = tonic::server::Grpc::new(codec)
3669                            .apply_compression_config(
3670                                accept_compression_encodings,
3671                                send_compression_encodings,
3672                            )
3673                            .apply_max_message_size_config(
3674                                max_decoding_message_size,
3675                                max_encoding_message_size,
3676                            );
3677                        let res = grpc.unary(method, req).await;
3678                        Ok(res)
3679                    };
3680                    Box::pin(fut)
3681                }
3682                "/qdrant.Collections/UpdateCollectionClusterSetup" => {
3683                    #[allow(non_camel_case_types)]
3684                    struct UpdateCollectionClusterSetupSvc<T: Collections>(pub Arc<T>);
3685                    impl<
3686                        T: Collections,
3687                    > tonic::server::UnaryService<
3688                        super::UpdateCollectionClusterSetupRequest,
3689                    > for UpdateCollectionClusterSetupSvc<T> {
3690                        type Response = super::UpdateCollectionClusterSetupResponse;
3691                        type Future = BoxFuture<
3692                            tonic::Response<Self::Response>,
3693                            tonic::Status,
3694                        >;
3695                        fn call(
3696                            &mut self,
3697                            request: tonic::Request<
3698                                super::UpdateCollectionClusterSetupRequest,
3699                            >,
3700                        ) -> Self::Future {
3701                            let inner = Arc::clone(&self.0);
3702                            let fut = async move {
3703                                <T as Collections>::update_collection_cluster_setup(
3704                                        &inner,
3705                                        request,
3706                                    )
3707                                    .await
3708                            };
3709                            Box::pin(fut)
3710                        }
3711                    }
3712                    let accept_compression_encodings = self.accept_compression_encodings;
3713                    let send_compression_encodings = self.send_compression_encodings;
3714                    let max_decoding_message_size = self.max_decoding_message_size;
3715                    let max_encoding_message_size = self.max_encoding_message_size;
3716                    let inner = self.inner.clone();
3717                    let fut = async move {
3718                        let method = UpdateCollectionClusterSetupSvc(inner);
3719                        let codec = tonic_prost::ProstCodec::default();
3720                        let mut grpc = tonic::server::Grpc::new(codec)
3721                            .apply_compression_config(
3722                                accept_compression_encodings,
3723                                send_compression_encodings,
3724                            )
3725                            .apply_max_message_size_config(
3726                                max_decoding_message_size,
3727                                max_encoding_message_size,
3728                            );
3729                        let res = grpc.unary(method, req).await;
3730                        Ok(res)
3731                    };
3732                    Box::pin(fut)
3733                }
3734                "/qdrant.Collections/CreateShardKey" => {
3735                    #[allow(non_camel_case_types)]
3736                    struct CreateShardKeySvc<T: Collections>(pub Arc<T>);
3737                    impl<
3738                        T: Collections,
3739                    > tonic::server::UnaryService<super::CreateShardKeyRequest>
3740                    for CreateShardKeySvc<T> {
3741                        type Response = super::CreateShardKeyResponse;
3742                        type Future = BoxFuture<
3743                            tonic::Response<Self::Response>,
3744                            tonic::Status,
3745                        >;
3746                        fn call(
3747                            &mut self,
3748                            request: tonic::Request<super::CreateShardKeyRequest>,
3749                        ) -> Self::Future {
3750                            let inner = Arc::clone(&self.0);
3751                            let fut = async move {
3752                                <T as Collections>::create_shard_key(&inner, request).await
3753                            };
3754                            Box::pin(fut)
3755                        }
3756                    }
3757                    let accept_compression_encodings = self.accept_compression_encodings;
3758                    let send_compression_encodings = self.send_compression_encodings;
3759                    let max_decoding_message_size = self.max_decoding_message_size;
3760                    let max_encoding_message_size = self.max_encoding_message_size;
3761                    let inner = self.inner.clone();
3762                    let fut = async move {
3763                        let method = CreateShardKeySvc(inner);
3764                        let codec = tonic_prost::ProstCodec::default();
3765                        let mut grpc = tonic::server::Grpc::new(codec)
3766                            .apply_compression_config(
3767                                accept_compression_encodings,
3768                                send_compression_encodings,
3769                            )
3770                            .apply_max_message_size_config(
3771                                max_decoding_message_size,
3772                                max_encoding_message_size,
3773                            );
3774                        let res = grpc.unary(method, req).await;
3775                        Ok(res)
3776                    };
3777                    Box::pin(fut)
3778                }
3779                "/qdrant.Collections/DeleteShardKey" => {
3780                    #[allow(non_camel_case_types)]
3781                    struct DeleteShardKeySvc<T: Collections>(pub Arc<T>);
3782                    impl<
3783                        T: Collections,
3784                    > tonic::server::UnaryService<super::DeleteShardKeyRequest>
3785                    for DeleteShardKeySvc<T> {
3786                        type Response = super::DeleteShardKeyResponse;
3787                        type Future = BoxFuture<
3788                            tonic::Response<Self::Response>,
3789                            tonic::Status,
3790                        >;
3791                        fn call(
3792                            &mut self,
3793                            request: tonic::Request<super::DeleteShardKeyRequest>,
3794                        ) -> Self::Future {
3795                            let inner = Arc::clone(&self.0);
3796                            let fut = async move {
3797                                <T as Collections>::delete_shard_key(&inner, request).await
3798                            };
3799                            Box::pin(fut)
3800                        }
3801                    }
3802                    let accept_compression_encodings = self.accept_compression_encodings;
3803                    let send_compression_encodings = self.send_compression_encodings;
3804                    let max_decoding_message_size = self.max_decoding_message_size;
3805                    let max_encoding_message_size = self.max_encoding_message_size;
3806                    let inner = self.inner.clone();
3807                    let fut = async move {
3808                        let method = DeleteShardKeySvc(inner);
3809                        let codec = tonic_prost::ProstCodec::default();
3810                        let mut grpc = tonic::server::Grpc::new(codec)
3811                            .apply_compression_config(
3812                                accept_compression_encodings,
3813                                send_compression_encodings,
3814                            )
3815                            .apply_max_message_size_config(
3816                                max_decoding_message_size,
3817                                max_encoding_message_size,
3818                            );
3819                        let res = grpc.unary(method, req).await;
3820                        Ok(res)
3821                    };
3822                    Box::pin(fut)
3823                }
3824                "/qdrant.Collections/ListShardKeys" => {
3825                    #[allow(non_camel_case_types)]
3826                    struct ListShardKeysSvc<T: Collections>(pub Arc<T>);
3827                    impl<
3828                        T: Collections,
3829                    > tonic::server::UnaryService<super::ListShardKeysRequest>
3830                    for ListShardKeysSvc<T> {
3831                        type Response = super::ListShardKeysResponse;
3832                        type Future = BoxFuture<
3833                            tonic::Response<Self::Response>,
3834                            tonic::Status,
3835                        >;
3836                        fn call(
3837                            &mut self,
3838                            request: tonic::Request<super::ListShardKeysRequest>,
3839                        ) -> Self::Future {
3840                            let inner = Arc::clone(&self.0);
3841                            let fut = async move {
3842                                <T as Collections>::list_shard_keys(&inner, request).await
3843                            };
3844                            Box::pin(fut)
3845                        }
3846                    }
3847                    let accept_compression_encodings = self.accept_compression_encodings;
3848                    let send_compression_encodings = self.send_compression_encodings;
3849                    let max_decoding_message_size = self.max_decoding_message_size;
3850                    let max_encoding_message_size = self.max_encoding_message_size;
3851                    let inner = self.inner.clone();
3852                    let fut = async move {
3853                        let method = ListShardKeysSvc(inner);
3854                        let codec = tonic_prost::ProstCodec::default();
3855                        let mut grpc = tonic::server::Grpc::new(codec)
3856                            .apply_compression_config(
3857                                accept_compression_encodings,
3858                                send_compression_encodings,
3859                            )
3860                            .apply_max_message_size_config(
3861                                max_decoding_message_size,
3862                                max_encoding_message_size,
3863                            );
3864                        let res = grpc.unary(method, req).await;
3865                        Ok(res)
3866                    };
3867                    Box::pin(fut)
3868                }
3869                _ => {
3870                    Box::pin(async move {
3871                        let mut response = http::Response::new(
3872                            tonic::body::Body::default(),
3873                        );
3874                        let headers = response.headers_mut();
3875                        headers
3876                            .insert(
3877                                tonic::Status::GRPC_STATUS,
3878                                (tonic::Code::Unimplemented as i32).into(),
3879                            );
3880                        headers
3881                            .insert(
3882                                http::header::CONTENT_TYPE,
3883                                tonic::metadata::GRPC_CONTENT_TYPE,
3884                            );
3885                        Ok(response)
3886                    })
3887                }
3888            }
3889        }
3890    }
3891    impl<T> Clone for CollectionsServer<T> {
3892        fn clone(&self) -> Self {
3893            let inner = self.inner.clone();
3894            Self {
3895                inner,
3896                accept_compression_encodings: self.accept_compression_encodings,
3897                send_compression_encodings: self.send_compression_encodings,
3898                max_decoding_message_size: self.max_decoding_message_size,
3899                max_encoding_message_size: self.max_encoding_message_size,
3900            }
3901        }
3902    }
3903    /// Generated gRPC service name
3904    pub const SERVICE_NAME: &str = "qdrant.Collections";
3905    impl<T> tonic::server::NamedService for CollectionsServer<T> {
3906        const NAME: &'static str = SERVICE_NAME;
3907    }
3908}
3909#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
3910pub struct WriteOrdering {
3911    /// Write ordering guarantees
3912    #[prost(enumeration = "WriteOrderingType", tag = "1")]
3913    pub r#type: i32,
3914}
3915#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
3916pub struct ReadConsistency {
3917    #[prost(oneof = "read_consistency::Value", tags = "1, 2")]
3918    pub value: ::core::option::Option<read_consistency::Value>,
3919}
3920/// Nested message and enum types in `ReadConsistency`.
3921pub mod read_consistency {
3922    #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
3923    pub enum Value {
3924        /// Common read consistency configurations
3925        #[prost(enumeration = "super::ReadConsistencyType", tag = "1")]
3926        Type(i32),
3927        /// Send request to a specified number of nodes,
3928        /// and return points which are present on all of them
3929        #[prost(uint64, tag = "2")]
3930        Factor(u64),
3931    }
3932}
3933#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3934pub struct SparseIndices {
3935    #[prost(uint32, repeated, tag = "1")]
3936    pub data: ::prost::alloc::vec::Vec<u32>,
3937}
3938#[derive(Clone, PartialEq, ::prost::Message)]
3939pub struct Document {
3940    /// Text of the document
3941    #[prost(string, tag = "1")]
3942    pub text: ::prost::alloc::string::String,
3943    /// Model name
3944    #[prost(string, tag = "3")]
3945    pub model: ::prost::alloc::string::String,
3946    /// Model options
3947    #[prost(map = "string, message", tag = "4")]
3948    pub options: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
3949}
3950#[derive(Clone, PartialEq, ::prost::Message)]
3951pub struct Image {
3952    /// Image data, either base64 encoded or URL
3953    #[prost(message, optional, tag = "1")]
3954    pub image: ::core::option::Option<Value>,
3955    /// Model name
3956    #[prost(string, tag = "2")]
3957    pub model: ::prost::alloc::string::String,
3958    /// Model options
3959    #[prost(map = "string, message", tag = "3")]
3960    pub options: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
3961}
3962#[derive(Clone, PartialEq, ::prost::Message)]
3963pub struct InferenceObject {
3964    /// Object to infer
3965    #[prost(message, optional, tag = "1")]
3966    pub object: ::core::option::Option<Value>,
3967    /// Model name
3968    #[prost(string, tag = "2")]
3969    pub model: ::prost::alloc::string::String,
3970    /// Model options
3971    #[prost(map = "string, message", tag = "3")]
3972    pub options: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
3973}
3974#[derive(Clone, PartialEq, ::prost::Message)]
3975pub struct Vector {
3976    /// Vector data (flatten for multi vectors), deprecated
3977    #[deprecated]
3978    #[prost(float, repeated, packed = "false", tag = "1")]
3979    /**
3980
3981Deprecated since 1.16.0, use [`vector`](crate::qdrant::Vector::vector) field instead.*/
3982    pub data: ::prost::alloc::vec::Vec<f32>,
3983    /// Sparse indices for sparse vectors, deprecated
3984    #[deprecated]
3985    #[prost(message, optional, tag = "2")]
3986    /**
3987
3988Deprecated since 1.16.0, use [`vector`](crate::qdrant::Vector::vector) field instead.*/
3989    pub indices: ::core::option::Option<SparseIndices>,
3990    /// Number of vectors per multi vector, deprecated
3991    #[deprecated]
3992    #[prost(uint32, optional, tag = "3")]
3993    /**
3994
3995Deprecated since 1.16.0, use [`vector`](crate::qdrant::Vector::vector) field instead.*/
3996    pub vectors_count: ::core::option::Option<u32>,
3997    #[prost(oneof = "vector::Vector", tags = "101, 102, 103, 104, 105, 106")]
3998    pub vector: ::core::option::Option<vector::Vector>,
3999}
4000/// Nested message and enum types in `Vector`.
4001pub mod vector {
4002    #[derive(Clone, PartialEq, ::prost::Oneof)]
4003    pub enum Vector {
4004        /// Dense vector
4005        #[prost(message, tag = "101")]
4006        Dense(super::DenseVector),
4007        /// Sparse vector
4008        #[prost(message, tag = "102")]
4009        Sparse(super::SparseVector),
4010        /// Multi dense vector
4011        #[prost(message, tag = "103")]
4012        MultiDense(super::MultiDenseVector),
4013        #[prost(message, tag = "104")]
4014        Document(super::Document),
4015        #[prost(message, tag = "105")]
4016        Image(super::Image),
4017        #[prost(message, tag = "106")]
4018        Object(super::InferenceObject),
4019    }
4020}
4021#[derive(Clone, PartialEq, ::prost::Message)]
4022pub struct VectorOutput {
4023    /// Vector data (flatten for multi vectors), deprecated
4024    #[deprecated]
4025    #[prost(float, repeated, packed = "false", tag = "1")]
4026    /**
4027
4028Deprecated since 1.16.0, use [`into_vector`](crate::qdrant::VectorOutput::into_vector) method instead.*/
4029    pub data: ::prost::alloc::vec::Vec<f32>,
4030    /// Sparse indices for sparse vectors, deprecated
4031    #[deprecated]
4032    #[prost(message, optional, tag = "2")]
4033    /**
4034
4035Deprecated since 1.16.0, use [`into_vector`](crate::qdrant::VectorOutput::into_vector) method instead.*/
4036    pub indices: ::core::option::Option<SparseIndices>,
4037    /// Number of vectors per multi vector, deprecated
4038    #[deprecated]
4039    #[prost(uint32, optional, tag = "3")]
4040    /**
4041
4042Deprecated since 1.16.0, use [`into_vector`](crate::qdrant::VectorOutput::into_vector) method instead.*/
4043    pub vectors_count: ::core::option::Option<u32>,
4044    #[prost(oneof = "vector_output::Vector", tags = "101, 102, 103")]
4045    pub vector: ::core::option::Option<vector_output::Vector>,
4046}
4047/// Nested message and enum types in `VectorOutput`.
4048pub mod vector_output {
4049    #[derive(Clone, PartialEq, ::prost::Oneof)]
4050    pub enum Vector {
4051        /// Dense vector
4052        #[prost(message, tag = "101")]
4053        Dense(super::DenseVector),
4054        /// Sparse vector
4055        #[prost(message, tag = "102")]
4056        Sparse(super::SparseVector),
4057        /// Multi dense vector
4058        #[prost(message, tag = "103")]
4059        MultiDense(super::MultiDenseVector),
4060    }
4061}
4062#[derive(Clone, PartialEq, ::prost::Message)]
4063pub struct DenseVector {
4064    #[prost(float, repeated, tag = "1")]
4065    pub data: ::prost::alloc::vec::Vec<f32>,
4066}
4067#[derive(Clone, PartialEq, ::prost::Message)]
4068pub struct SparseVector {
4069    #[prost(float, repeated, tag = "1")]
4070    pub values: ::prost::alloc::vec::Vec<f32>,
4071    #[prost(uint32, repeated, tag = "2")]
4072    pub indices: ::prost::alloc::vec::Vec<u32>,
4073}
4074#[derive(Clone, PartialEq, ::prost::Message)]
4075pub struct MultiDenseVector {
4076    #[prost(message, repeated, tag = "1")]
4077    pub vectors: ::prost::alloc::vec::Vec<DenseVector>,
4078}
4079/// Vector type to be used in queries.
4080/// Ids will be substituted with their corresponding vectors from the collection.
4081#[derive(Clone, PartialEq, ::prost::Message)]
4082pub struct VectorInput {
4083    #[prost(oneof = "vector_input::Variant", tags = "1, 2, 3, 4, 5, 6, 7")]
4084    pub variant: ::core::option::Option<vector_input::Variant>,
4085}
4086/// Nested message and enum types in `VectorInput`.
4087pub mod vector_input {
4088    #[derive(Clone, PartialEq, ::prost::Oneof)]
4089    pub enum Variant {
4090        #[prost(message, tag = "1")]
4091        Id(super::PointId),
4092        #[prost(message, tag = "2")]
4093        Dense(super::DenseVector),
4094        #[prost(message, tag = "3")]
4095        Sparse(super::SparseVector),
4096        #[prost(message, tag = "4")]
4097        MultiDense(super::MultiDenseVector),
4098        #[prost(message, tag = "5")]
4099        Document(super::Document),
4100        #[prost(message, tag = "6")]
4101        Image(super::Image),
4102        #[prost(message, tag = "7")]
4103        Object(super::InferenceObject),
4104    }
4105}
4106#[derive(Clone, PartialEq, ::prost::Message)]
4107pub struct ShardKeySelector {
4108    /// List of shard keys which should be used in the request
4109    #[prost(message, repeated, tag = "1")]
4110    pub shard_keys: ::prost::alloc::vec::Vec<ShardKey>,
4111    #[prost(message, optional, tag = "2")]
4112    pub fallback: ::core::option::Option<ShardKey>,
4113}
4114#[derive(Clone, PartialEq, ::prost::Message)]
4115pub struct UpsertPoints {
4116    /// name of the collection
4117    #[prost(string, tag = "1")]
4118    pub collection_name: ::prost::alloc::string::String,
4119    /// Wait until the changes have been applied?
4120    #[prost(bool, optional, tag = "2")]
4121    pub wait: ::core::option::Option<bool>,
4122    #[prost(message, repeated, tag = "3")]
4123    pub points: ::prost::alloc::vec::Vec<PointStruct>,
4124    /// Write ordering guarantees
4125    #[prost(message, optional, tag = "4")]
4126    pub ordering: ::core::option::Option<WriteOrdering>,
4127    /// Option for custom sharding to specify used shard keys
4128    #[prost(message, optional, tag = "5")]
4129    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4130    /// Filter to apply when updating existing points. Only points matching this filter will be updated.
4131    /// Points that don't match will keep their current state. New points will be inserted regardless of the filter.
4132    #[prost(message, optional, tag = "6")]
4133    pub update_filter: ::core::option::Option<Filter>,
4134    /// Timeout for the request in seconds
4135    #[prost(uint64, optional, tag = "7")]
4136    pub timeout: ::core::option::Option<u64>,
4137    /// Mode of the upsert operation: insert_only, upsert (default), update_only
4138    #[prost(enumeration = "UpdateMode", optional, tag = "8")]
4139    pub update_mode: ::core::option::Option<i32>,
4140}
4141#[derive(Clone, PartialEq, ::prost::Message)]
4142pub struct DeletePoints {
4143    /// name of the collection
4144    #[prost(string, tag = "1")]
4145    pub collection_name: ::prost::alloc::string::String,
4146    /// Wait until the changes have been applied?
4147    #[prost(bool, optional, tag = "2")]
4148    pub wait: ::core::option::Option<bool>,
4149    /// Affected points
4150    #[prost(message, optional, tag = "3")]
4151    pub points: ::core::option::Option<PointsSelector>,
4152    /// Write ordering guarantees
4153    #[prost(message, optional, tag = "4")]
4154    pub ordering: ::core::option::Option<WriteOrdering>,
4155    /// Option for custom sharding to specify used shard keys
4156    #[prost(message, optional, tag = "5")]
4157    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4158    /// Timeout for the request in seconds
4159    #[prost(uint64, optional, tag = "6")]
4160    pub timeout: ::core::option::Option<u64>,
4161}
4162#[derive(Clone, PartialEq, ::prost::Message)]
4163pub struct GetPoints {
4164    /// name of the collection
4165    #[prost(string, tag = "1")]
4166    pub collection_name: ::prost::alloc::string::String,
4167    /// List of points to retrieve
4168    #[prost(message, repeated, tag = "2")]
4169    pub ids: ::prost::alloc::vec::Vec<PointId>,
4170    /// Options for specifying which payload to include or not
4171    #[prost(message, optional, tag = "4")]
4172    pub with_payload: ::core::option::Option<WithPayloadSelector>,
4173    /// Options for specifying which vectors to include into response
4174    #[prost(message, optional, tag = "5")]
4175    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
4176    /// Options for specifying read consistency guarantees
4177    #[prost(message, optional, tag = "6")]
4178    pub read_consistency: ::core::option::Option<ReadConsistency>,
4179    /// Specify in which shards to look for the points, if not specified - look in all shards
4180    #[prost(message, optional, tag = "7")]
4181    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4182    /// If set, overrides global timeout setting for this request. Unit is seconds.
4183    #[prost(uint64, optional, tag = "8")]
4184    pub timeout: ::core::option::Option<u64>,
4185}
4186#[derive(Clone, PartialEq, ::prost::Message)]
4187pub struct UpdatePointVectors {
4188    /// name of the collection
4189    #[prost(string, tag = "1")]
4190    pub collection_name: ::prost::alloc::string::String,
4191    /// Wait until the changes have been applied?
4192    #[prost(bool, optional, tag = "2")]
4193    pub wait: ::core::option::Option<bool>,
4194    /// List of points and vectors to update
4195    #[prost(message, repeated, tag = "3")]
4196    pub points: ::prost::alloc::vec::Vec<PointVectors>,
4197    /// Write ordering guarantees
4198    #[prost(message, optional, tag = "4")]
4199    pub ordering: ::core::option::Option<WriteOrdering>,
4200    /// Option for custom sharding to specify used shard keys
4201    #[prost(message, optional, tag = "5")]
4202    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4203    /// If specified, only points that match this filter will be updated
4204    #[prost(message, optional, tag = "6")]
4205    pub update_filter: ::core::option::Option<Filter>,
4206    /// Timeout for the request in seconds
4207    #[prost(uint64, optional, tag = "7")]
4208    pub timeout: ::core::option::Option<u64>,
4209}
4210#[derive(Clone, PartialEq, ::prost::Message)]
4211pub struct PointVectors {
4212    /// ID to update vectors for
4213    #[prost(message, optional, tag = "1")]
4214    pub id: ::core::option::Option<PointId>,
4215    /// Named vectors to update, leave others intact
4216    #[prost(message, optional, tag = "2")]
4217    pub vectors: ::core::option::Option<Vectors>,
4218}
4219#[derive(Clone, PartialEq, ::prost::Message)]
4220pub struct DeletePointVectors {
4221    /// name of the collection
4222    #[prost(string, tag = "1")]
4223    pub collection_name: ::prost::alloc::string::String,
4224    /// Wait until the changes have been applied?
4225    #[prost(bool, optional, tag = "2")]
4226    pub wait: ::core::option::Option<bool>,
4227    /// Affected points
4228    #[prost(message, optional, tag = "3")]
4229    pub points_selector: ::core::option::Option<PointsSelector>,
4230    /// List of vector names to delete
4231    #[prost(message, optional, tag = "4")]
4232    pub vectors: ::core::option::Option<VectorsSelector>,
4233    /// Write ordering guarantees
4234    #[prost(message, optional, tag = "5")]
4235    pub ordering: ::core::option::Option<WriteOrdering>,
4236    /// Option for custom sharding to specify used shard keys
4237    #[prost(message, optional, tag = "6")]
4238    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4239    /// Timeout for the request in seconds
4240    #[prost(uint64, optional, tag = "7")]
4241    pub timeout: ::core::option::Option<u64>,
4242}
4243#[derive(Clone, PartialEq, ::prost::Message)]
4244pub struct SetPayloadPoints {
4245    /// name of the collection
4246    #[prost(string, tag = "1")]
4247    pub collection_name: ::prost::alloc::string::String,
4248    /// Wait until the changes have been applied?
4249    #[prost(bool, optional, tag = "2")]
4250    pub wait: ::core::option::Option<bool>,
4251    /// New payload values
4252    #[prost(map = "string, message", tag = "3")]
4253    pub payload: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
4254    /// Affected points
4255    #[prost(message, optional, tag = "5")]
4256    pub points_selector: ::core::option::Option<PointsSelector>,
4257    /// Write ordering guarantees
4258    #[prost(message, optional, tag = "6")]
4259    pub ordering: ::core::option::Option<WriteOrdering>,
4260    /// Option for custom sharding to specify used shard keys
4261    #[prost(message, optional, tag = "7")]
4262    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4263    /// Option for indicate property of payload
4264    #[prost(string, optional, tag = "8")]
4265    pub key: ::core::option::Option<::prost::alloc::string::String>,
4266    /// Timeout for the request in seconds
4267    #[prost(uint64, optional, tag = "9")]
4268    pub timeout: ::core::option::Option<u64>,
4269}
4270#[derive(Clone, PartialEq, ::prost::Message)]
4271pub struct DeletePayloadPoints {
4272    /// name of the collection
4273    #[prost(string, tag = "1")]
4274    pub collection_name: ::prost::alloc::string::String,
4275    /// Wait until the changes have been applied?
4276    #[prost(bool, optional, tag = "2")]
4277    pub wait: ::core::option::Option<bool>,
4278    /// List of keys to delete
4279    #[prost(string, repeated, tag = "3")]
4280    pub keys: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
4281    /// Affected points
4282    #[prost(message, optional, tag = "5")]
4283    pub points_selector: ::core::option::Option<PointsSelector>,
4284    /// Write ordering guarantees
4285    #[prost(message, optional, tag = "6")]
4286    pub ordering: ::core::option::Option<WriteOrdering>,
4287    /// Option for custom sharding to specify used shard keys
4288    #[prost(message, optional, tag = "7")]
4289    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4290    /// Timeout for the request in seconds
4291    #[prost(uint64, optional, tag = "8")]
4292    pub timeout: ::core::option::Option<u64>,
4293}
4294#[derive(Clone, PartialEq, ::prost::Message)]
4295pub struct ClearPayloadPoints {
4296    /// name of the collection
4297    #[prost(string, tag = "1")]
4298    pub collection_name: ::prost::alloc::string::String,
4299    /// Wait until the changes have been applied?
4300    #[prost(bool, optional, tag = "2")]
4301    pub wait: ::core::option::Option<bool>,
4302    /// Affected points
4303    #[prost(message, optional, tag = "3")]
4304    pub points: ::core::option::Option<PointsSelector>,
4305    /// Write ordering guarantees
4306    #[prost(message, optional, tag = "4")]
4307    pub ordering: ::core::option::Option<WriteOrdering>,
4308    /// Option for custom sharding to specify used shard keys
4309    #[prost(message, optional, tag = "5")]
4310    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4311    /// Timeout for the request in seconds
4312    #[prost(uint64, optional, tag = "6")]
4313    pub timeout: ::core::option::Option<u64>,
4314}
4315#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4316pub struct CreateFieldIndexCollection {
4317    /// name of the collection
4318    #[prost(string, tag = "1")]
4319    pub collection_name: ::prost::alloc::string::String,
4320    /// Wait until the changes have been applied?
4321    #[prost(bool, optional, tag = "2")]
4322    pub wait: ::core::option::Option<bool>,
4323    /// Field name to index
4324    #[prost(string, tag = "3")]
4325    pub field_name: ::prost::alloc::string::String,
4326    /// Field type.
4327    #[prost(enumeration = "FieldType", optional, tag = "4")]
4328    pub field_type: ::core::option::Option<i32>,
4329    /// Payload index params.
4330    #[prost(message, optional, tag = "5")]
4331    pub field_index_params: ::core::option::Option<PayloadIndexParams>,
4332    /// Write ordering guarantees
4333    #[prost(message, optional, tag = "6")]
4334    pub ordering: ::core::option::Option<WriteOrdering>,
4335    /// Timeout for the request in seconds
4336    #[prost(uint64, optional, tag = "7")]
4337    pub timeout: ::core::option::Option<u64>,
4338}
4339#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4340pub struct DeleteFieldIndexCollection {
4341    /// name of the collection
4342    #[prost(string, tag = "1")]
4343    pub collection_name: ::prost::alloc::string::String,
4344    /// Wait until the changes have been applied?
4345    #[prost(bool, optional, tag = "2")]
4346    pub wait: ::core::option::Option<bool>,
4347    /// Field name to delete
4348    #[prost(string, tag = "3")]
4349    pub field_name: ::prost::alloc::string::String,
4350    /// Write ordering guarantees
4351    #[prost(message, optional, tag = "4")]
4352    pub ordering: ::core::option::Option<WriteOrdering>,
4353    /// Timeout for the request in seconds
4354    #[prost(uint64, optional, tag = "5")]
4355    pub timeout: ::core::option::Option<u64>,
4356}
4357/// Dense vector creation parameters.
4358/// Only includes immutable properties that define the vector space.
4359/// Storage type, index, and quantization are configured separately.
4360#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
4361pub struct DenseVectorCreationConfig {
4362    /// Size/dimensionality of the vectors
4363    #[prost(uint64, tag = "1")]
4364    pub size: u64,
4365    /// Distance function used for comparing vectors
4366    #[prost(enumeration = "Distance", tag = "2")]
4367    pub distance: i32,
4368    /// Configuration for multi-vector search (e.g., ColBERT)
4369    #[prost(message, optional, tag = "3")]
4370    pub multivector_config: ::core::option::Option<MultiVectorConfig>,
4371    /// Data type of the vectors (Float32, Float16, Uint8, Turbo4, Turbo8, Turbo16)
4372    #[prost(enumeration = "Datatype", optional, tag = "4")]
4373    pub datatype: ::core::option::Option<i32>,
4374}
4375/// Sparse vector creation parameters.
4376/// Only includes immutable properties that define the vector space.
4377#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
4378pub struct SparseVectorCreationConfig {
4379    /// If set - apply modifier to the vector values (e.g., IDF)
4380    #[prost(enumeration = "Modifier", optional, tag = "1")]
4381    pub modifier: ::core::option::Option<i32>,
4382    /// Data type used to store weights in the index
4383    #[prost(enumeration = "Datatype", optional, tag = "2")]
4384    pub datatype: ::core::option::Option<i32>,
4385}
4386#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4387pub struct CreateVectorNameRequest {
4388    /// Name of the collection
4389    #[prost(string, tag = "1")]
4390    pub collection_name: ::prost::alloc::string::String,
4391    /// Wait until the changes have been applied?
4392    #[prost(bool, optional, tag = "2")]
4393    pub wait: ::core::option::Option<bool>,
4394    /// Name of the new vector
4395    #[prost(string, tag = "3")]
4396    pub vector_name: ::prost::alloc::string::String,
4397    /// If set, overrides global timeout setting for this request. Unit is seconds.
4398    #[prost(uint64, optional, tag = "6")]
4399    pub timeout: ::core::option::Option<u64>,
4400    /// Write ordering guarantees
4401    #[prost(message, optional, tag = "7")]
4402    pub ordering: ::core::option::Option<WriteOrdering>,
4403    /// Configuration for the new vector - either dense or sparse
4404    #[prost(oneof = "create_vector_name_request::VectorConfig", tags = "4, 5")]
4405    pub vector_config: ::core::option::Option<create_vector_name_request::VectorConfig>,
4406}
4407/// Nested message and enum types in `CreateVectorNameRequest`.
4408pub mod create_vector_name_request {
4409    /// Configuration for the new vector - either dense or sparse
4410    #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
4411    pub enum VectorConfig {
4412        /// Dense vector parameters
4413        #[prost(message, tag = "4")]
4414        DenseConfig(super::DenseVectorCreationConfig),
4415        /// Sparse vector parameters
4416        #[prost(message, tag = "5")]
4417        SparseConfig(super::SparseVectorCreationConfig),
4418    }
4419}
4420#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4421pub struct DeleteVectorNameRequest {
4422    /// Name of the collection
4423    #[prost(string, tag = "1")]
4424    pub collection_name: ::prost::alloc::string::String,
4425    /// Wait until the changes have been applied?
4426    #[prost(bool, optional, tag = "2")]
4427    pub wait: ::core::option::Option<bool>,
4428    /// Name of the vector to delete
4429    #[prost(string, tag = "3")]
4430    pub vector_name: ::prost::alloc::string::String,
4431    /// If set, overrides global timeout setting for this request. Unit is seconds.
4432    #[prost(uint64, optional, tag = "4")]
4433    pub timeout: ::core::option::Option<u64>,
4434    /// Write ordering guarantees
4435    #[prost(message, optional, tag = "5")]
4436    pub ordering: ::core::option::Option<WriteOrdering>,
4437}
4438#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4439pub struct PayloadIncludeSelector {
4440    /// List of payload keys to include into result
4441    #[prost(string, repeated, tag = "1")]
4442    pub fields: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
4443}
4444#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4445pub struct PayloadExcludeSelector {
4446    /// List of payload keys to exclude from the result
4447    #[prost(string, repeated, tag = "1")]
4448    pub fields: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
4449}
4450#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4451pub struct WithPayloadSelector {
4452    #[prost(oneof = "with_payload_selector::SelectorOptions", tags = "1, 2, 3")]
4453    pub selector_options: ::core::option::Option<with_payload_selector::SelectorOptions>,
4454}
4455/// Nested message and enum types in `WithPayloadSelector`.
4456pub mod with_payload_selector {
4457    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
4458    pub enum SelectorOptions {
4459        /// If `true` - return all payload, if `false` - none
4460        #[prost(bool, tag = "1")]
4461        Enable(bool),
4462        #[prost(message, tag = "2")]
4463        Include(super::PayloadIncludeSelector),
4464        #[prost(message, tag = "3")]
4465        Exclude(super::PayloadExcludeSelector),
4466    }
4467}
4468#[derive(Clone, PartialEq, ::prost::Message)]
4469pub struct NamedVectors {
4470    #[prost(map = "string, message", tag = "1")]
4471    pub vectors: ::std::collections::HashMap<::prost::alloc::string::String, Vector>,
4472}
4473#[derive(Clone, PartialEq, ::prost::Message)]
4474pub struct NamedVectorsOutput {
4475    #[prost(map = "string, message", tag = "1")]
4476    pub vectors: ::std::collections::HashMap<
4477        ::prost::alloc::string::String,
4478        VectorOutput,
4479    >,
4480}
4481#[derive(Clone, PartialEq, ::prost::Message)]
4482pub struct Vectors {
4483    #[prost(oneof = "vectors::VectorsOptions", tags = "1, 2")]
4484    pub vectors_options: ::core::option::Option<vectors::VectorsOptions>,
4485}
4486/// Nested message and enum types in `Vectors`.
4487pub mod vectors {
4488    #[derive(Clone, PartialEq, ::prost::Oneof)]
4489    pub enum VectorsOptions {
4490        #[prost(message, tag = "1")]
4491        Vector(super::Vector),
4492        #[prost(message, tag = "2")]
4493        Vectors(super::NamedVectors),
4494    }
4495}
4496#[derive(Clone, PartialEq, ::prost::Message)]
4497pub struct VectorsOutput {
4498    #[prost(oneof = "vectors_output::VectorsOptions", tags = "1, 2")]
4499    pub vectors_options: ::core::option::Option<vectors_output::VectorsOptions>,
4500}
4501/// Nested message and enum types in `VectorsOutput`.
4502pub mod vectors_output {
4503    #[derive(Clone, PartialEq, ::prost::Oneof)]
4504    pub enum VectorsOptions {
4505        #[prost(message, tag = "1")]
4506        Vector(super::VectorOutput),
4507        #[prost(message, tag = "2")]
4508        Vectors(super::NamedVectorsOutput),
4509    }
4510}
4511#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4512pub struct VectorsSelector {
4513    /// List of vectors to include into result
4514    #[prost(string, repeated, tag = "1")]
4515    pub names: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
4516}
4517#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4518pub struct WithVectorsSelector {
4519    #[prost(oneof = "with_vectors_selector::SelectorOptions", tags = "1, 2")]
4520    pub selector_options: ::core::option::Option<with_vectors_selector::SelectorOptions>,
4521}
4522/// Nested message and enum types in `WithVectorsSelector`.
4523pub mod with_vectors_selector {
4524    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
4525    pub enum SelectorOptions {
4526        /// If `true` - return all vectors, if `false` - none
4527        #[prost(bool, tag = "1")]
4528        Enable(bool),
4529        /// List of vectors to include into result
4530        #[prost(message, tag = "2")]
4531        Include(super::VectorsSelector),
4532    }
4533}
4534#[derive(Clone, Copy, PartialEq, ::prost::Message)]
4535pub struct QuantizationSearchParams {
4536    /// If set to true, search will ignore quantized vector data
4537    #[prost(bool, optional, tag = "1")]
4538    pub ignore: ::core::option::Option<bool>,
4539    /// If true, use original vectors to re-score top-k results.
4540    /// If ignored, qdrant decides automatically does rescore enabled or not.
4541    #[prost(bool, optional, tag = "2")]
4542    pub rescore: ::core::option::Option<bool>,
4543    /// Oversampling factor for quantization.
4544    ///
4545    /// Defines how many extra vectors should be preselected using quantized index,
4546    /// and then re-scored using original vectors.
4547    ///
4548    /// For example, if `oversampling` is 2.4 and `limit` is 100,
4549    /// then 240 vectors will be preselected using quantized index,
4550    /// and then top-100 will be returned after re-scoring.
4551    #[prost(double, optional, tag = "3")]
4552    pub oversampling: ::core::option::Option<f64>,
4553}
4554#[derive(Clone, Copy, PartialEq, ::prost::Message)]
4555pub struct AcornSearchParams {
4556    /// If true, then ACORN may be used for the HNSW search based on filters
4557    /// selectivity.
4558    ///
4559    /// Improves search recall for searches with multiple low-selectivity
4560    /// payload filters, at cost of performance.
4561    #[prost(bool, optional, tag = "1")]
4562    pub enable: ::core::option::Option<bool>,
4563    /// Maximum selectivity of filters to enable ACORN.
4564    ///
4565    /// If estimated filters selectivity is higher than this value,
4566    /// ACORN will not be used. Selectivity is estimated as:
4567    /// `estimated number of points satisfying the filters / total number of points`.
4568    ///
4569    /// 0.0 for never, 1.0 for always. Default is 0.4.
4570    #[prost(double, optional, tag = "2")]
4571    pub max_selectivity: ::core::option::Option<f64>,
4572}
4573/// Population over which IDF statistics are computed for scoring - the IDF corpus.
4574/// Only applicable to sparse vectors with the IDF modifier enabled, and to BM25 over a text index.
4575#[derive(Clone, PartialEq, ::prost::Message)]
4576pub struct IdfParams {
4577    /// Filter defining the corpus: IDF statistics are computed over the points matching this filter.
4578    /// If unset, statistics are collection-wide (global) - same as omitting `idf` entirely.
4579    #[prost(message, optional, tag = "1")]
4580    pub corpus: ::core::option::Option<Filter>,
4581}
4582#[derive(Clone, PartialEq, ::prost::Message)]
4583pub struct SearchParams {
4584    /// Params relevant to HNSW index. Size of the beam in a beam-search.
4585    /// Larger the value - more accurate the result, more time required for search.
4586    #[prost(uint64, optional, tag = "1")]
4587    pub hnsw_ef: ::core::option::Option<u64>,
4588    /// Search without approximation. If set to true, search may run long but with exact results.
4589    #[prost(bool, optional, tag = "2")]
4590    pub exact: ::core::option::Option<bool>,
4591    /// If set to true, search will ignore quantized vector data
4592    #[prost(message, optional, tag = "3")]
4593    pub quantization: ::core::option::Option<QuantizationSearchParams>,
4594    /// If enabled, the engine will only perform search among indexed or small segments.
4595    /// Using this option prevents slow searches in case of delayed index, but does not
4596    /// guarantee that all uploaded vectors will be included in search results
4597    #[prost(bool, optional, tag = "4")]
4598    pub indexed_only: ::core::option::Option<bool>,
4599    /// ACORN search params
4600    #[prost(message, optional, tag = "5")]
4601    pub acorn: ::core::option::Option<AcornSearchParams>,
4602    /// Which population IDF statistics are computed over.
4603    /// If unset, statistics are collection-wide (global).
4604    #[prost(message, optional, tag = "6")]
4605    pub idf: ::core::option::Option<IdfParams>,
4606}
4607#[derive(Clone, PartialEq, ::prost::Message)]
4608pub struct SearchPoints {
4609    /// name of the collection
4610    #[prost(string, tag = "1")]
4611    pub collection_name: ::prost::alloc::string::String,
4612    /// vector
4613    #[prost(float, repeated, tag = "2")]
4614    pub vector: ::prost::alloc::vec::Vec<f32>,
4615    /// Filter conditions - return only those points that satisfy the specified conditions
4616    #[prost(message, optional, tag = "3")]
4617    pub filter: ::core::option::Option<Filter>,
4618    /// Max number of result
4619    #[prost(uint64, tag = "4")]
4620    pub limit: u64,
4621    /// Options for specifying which payload to include or not
4622    #[prost(message, optional, tag = "6")]
4623    pub with_payload: ::core::option::Option<WithPayloadSelector>,
4624    /// Search config
4625    #[prost(message, optional, tag = "7")]
4626    pub params: ::core::option::Option<SearchParams>,
4627    /// If provided - cut off results with worse scores
4628    #[prost(float, optional, tag = "8")]
4629    pub score_threshold: ::core::option::Option<f32>,
4630    /// Offset of the result
4631    #[prost(uint64, optional, tag = "9")]
4632    pub offset: ::core::option::Option<u64>,
4633    /// Which vector to use for search, if not specified - use default vector
4634    #[prost(string, optional, tag = "10")]
4635    pub vector_name: ::core::option::Option<::prost::alloc::string::String>,
4636    /// Options for specifying which vectors to include into response
4637    #[prost(message, optional, tag = "11")]
4638    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
4639    /// Options for specifying read consistency guarantees
4640    #[prost(message, optional, tag = "12")]
4641    pub read_consistency: ::core::option::Option<ReadConsistency>,
4642    /// If set, overrides global timeout setting for this request. Unit is seconds.
4643    #[prost(uint64, optional, tag = "13")]
4644    pub timeout: ::core::option::Option<u64>,
4645    /// Specify in which shards to look for the points, if not specified - look in all shards
4646    #[prost(message, optional, tag = "14")]
4647    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4648    #[prost(message, optional, tag = "15")]
4649    pub sparse_indices: ::core::option::Option<SparseIndices>,
4650}
4651#[derive(Clone, PartialEq, ::prost::Message)]
4652pub struct SearchBatchPoints {
4653    /// Name of the collection
4654    #[prost(string, tag = "1")]
4655    pub collection_name: ::prost::alloc::string::String,
4656    #[prost(message, repeated, tag = "2")]
4657    pub search_points: ::prost::alloc::vec::Vec<SearchPoints>,
4658    /// Options for specifying read consistency guarantees
4659    #[prost(message, optional, tag = "3")]
4660    pub read_consistency: ::core::option::Option<ReadConsistency>,
4661    /// If set, overrides global timeout setting for this request. Unit is seconds.
4662    #[prost(uint64, optional, tag = "4")]
4663    pub timeout: ::core::option::Option<u64>,
4664}
4665#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4666pub struct WithLookup {
4667    /// Name of the collection to use for points lookup
4668    #[prost(string, tag = "1")]
4669    pub collection: ::prost::alloc::string::String,
4670    /// Options for specifying which payload to include (or not)
4671    #[prost(message, optional, tag = "2")]
4672    pub with_payload: ::core::option::Option<WithPayloadSelector>,
4673    /// Options for specifying which vectors to include (or not)
4674    #[prost(message, optional, tag = "3")]
4675    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
4676}
4677#[derive(Clone, PartialEq, ::prost::Message)]
4678pub struct SearchPointGroups {
4679    /// Name of the collection
4680    #[prost(string, tag = "1")]
4681    pub collection_name: ::prost::alloc::string::String,
4682    /// Vector to compare against
4683    #[prost(float, repeated, tag = "2")]
4684    pub vector: ::prost::alloc::vec::Vec<f32>,
4685    /// Filter conditions - return only those points that satisfy the specified conditions
4686    #[prost(message, optional, tag = "3")]
4687    pub filter: ::core::option::Option<Filter>,
4688    /// Max number of result
4689    #[prost(uint32, tag = "4")]
4690    pub limit: u32,
4691    /// Options for specifying which payload to include or not
4692    #[prost(message, optional, tag = "5")]
4693    pub with_payload: ::core::option::Option<WithPayloadSelector>,
4694    /// Search config
4695    #[prost(message, optional, tag = "6")]
4696    pub params: ::core::option::Option<SearchParams>,
4697    /// If provided - cut off results with worse scores
4698    #[prost(float, optional, tag = "7")]
4699    pub score_threshold: ::core::option::Option<f32>,
4700    /// Which vector to use for search, if not specified - use default vector
4701    #[prost(string, optional, tag = "8")]
4702    pub vector_name: ::core::option::Option<::prost::alloc::string::String>,
4703    /// Options for specifying which vectors to include into response
4704    #[prost(message, optional, tag = "9")]
4705    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
4706    /// Payload field to group by, must be a string or number field.
4707    /// If there are multiple values for the field, all of them will be used.
4708    /// One point can be in multiple groups.
4709    #[prost(string, tag = "10")]
4710    pub group_by: ::prost::alloc::string::String,
4711    /// Maximum amount of points to return per group
4712    #[prost(uint32, tag = "11")]
4713    pub group_size: u32,
4714    /// Options for specifying read consistency guarantees
4715    #[prost(message, optional, tag = "12")]
4716    pub read_consistency: ::core::option::Option<ReadConsistency>,
4717    /// Options for specifying how to use the group id to lookup points in another collection
4718    #[prost(message, optional, tag = "13")]
4719    pub with_lookup: ::core::option::Option<WithLookup>,
4720    /// If set, overrides global timeout setting for this request. Unit is seconds.
4721    #[prost(uint64, optional, tag = "14")]
4722    pub timeout: ::core::option::Option<u64>,
4723    /// Specify in which shards to look for the points, if not specified - look in all shards
4724    #[prost(message, optional, tag = "15")]
4725    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4726    #[prost(message, optional, tag = "16")]
4727    pub sparse_indices: ::core::option::Option<SparseIndices>,
4728}
4729#[derive(Clone, PartialEq, ::prost::Message)]
4730pub struct StartFrom {
4731    #[prost(oneof = "start_from::Value", tags = "1, 2, 3, 4")]
4732    pub value: ::core::option::Option<start_from::Value>,
4733}
4734/// Nested message and enum types in `StartFrom`.
4735pub mod start_from {
4736    #[derive(Clone, PartialEq, ::prost::Oneof)]
4737    pub enum Value {
4738        #[prost(double, tag = "1")]
4739        Float(f64),
4740        #[prost(int64, tag = "2")]
4741        Integer(i64),
4742        #[prost(message, tag = "3")]
4743        Timestamp(::prost_types::Timestamp),
4744        #[prost(string, tag = "4")]
4745        Datetime(::prost::alloc::string::String),
4746    }
4747}
4748#[derive(Clone, PartialEq, ::prost::Message)]
4749pub struct OrderBy {
4750    /// Payload key to order by
4751    #[prost(string, tag = "1")]
4752    pub key: ::prost::alloc::string::String,
4753    /// Ascending or descending order
4754    #[prost(enumeration = "Direction", optional, tag = "2")]
4755    pub direction: ::core::option::Option<i32>,
4756    /// Start from this value
4757    #[prost(message, optional, tag = "3")]
4758    pub start_from: ::core::option::Option<StartFrom>,
4759}
4760#[derive(Clone, PartialEq, ::prost::Message)]
4761pub struct ScrollPoints {
4762    #[prost(string, tag = "1")]
4763    pub collection_name: ::prost::alloc::string::String,
4764    /// Filter conditions - return only those points that satisfy the specified conditions
4765    #[prost(message, optional, tag = "2")]
4766    pub filter: ::core::option::Option<Filter>,
4767    /// Start with this ID
4768    #[prost(message, optional, tag = "3")]
4769    pub offset: ::core::option::Option<PointId>,
4770    /// Max number of result
4771    #[prost(uint32, optional, tag = "4")]
4772    pub limit: ::core::option::Option<u32>,
4773    /// Options for specifying which payload to include or not
4774    #[prost(message, optional, tag = "6")]
4775    pub with_payload: ::core::option::Option<WithPayloadSelector>,
4776    /// Options for specifying which vectors to include into response
4777    #[prost(message, optional, tag = "7")]
4778    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
4779    /// Options for specifying read consistency guarantees
4780    #[prost(message, optional, tag = "8")]
4781    pub read_consistency: ::core::option::Option<ReadConsistency>,
4782    /// Specify in which shards to look for the points, if not specified - look in all shards
4783    #[prost(message, optional, tag = "9")]
4784    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4785    /// Order the records by a payload field
4786    #[prost(message, optional, tag = "10")]
4787    pub order_by: ::core::option::Option<OrderBy>,
4788    /// If set, overrides global timeout setting for this request. Unit is seconds.
4789    #[prost(uint64, optional, tag = "11")]
4790    pub timeout: ::core::option::Option<u64>,
4791}
4792#[derive(Clone, PartialEq, ::prost::Message)]
4793pub struct LookupLocation {
4794    #[prost(string, tag = "1")]
4795    pub collection_name: ::prost::alloc::string::String,
4796    /// Which vector to use for search, if not specified - use default vector
4797    #[prost(string, optional, tag = "2")]
4798    pub vector_name: ::core::option::Option<::prost::alloc::string::String>,
4799    /// Specify in which shards to look for the points, if not specified - look in all shards
4800    #[prost(message, optional, tag = "3")]
4801    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4802}
4803#[derive(Clone, PartialEq, ::prost::Message)]
4804pub struct RecommendPoints {
4805    /// name of the collection
4806    #[prost(string, tag = "1")]
4807    pub collection_name: ::prost::alloc::string::String,
4808    /// Look for vectors closest to the vectors from these points
4809    #[prost(message, repeated, tag = "2")]
4810    pub positive: ::prost::alloc::vec::Vec<PointId>,
4811    /// Try to avoid vectors like the vector from these points
4812    #[prost(message, repeated, tag = "3")]
4813    pub negative: ::prost::alloc::vec::Vec<PointId>,
4814    /// Filter conditions - return only those points that satisfy the specified conditions
4815    #[prost(message, optional, tag = "4")]
4816    pub filter: ::core::option::Option<Filter>,
4817    /// Max number of result
4818    #[prost(uint64, tag = "5")]
4819    pub limit: u64,
4820    /// Options for specifying which payload to include or not
4821    #[prost(message, optional, tag = "7")]
4822    pub with_payload: ::core::option::Option<WithPayloadSelector>,
4823    /// Search config
4824    #[prost(message, optional, tag = "8")]
4825    pub params: ::core::option::Option<SearchParams>,
4826    /// If provided - cut off results with worse scores
4827    #[prost(float, optional, tag = "9")]
4828    pub score_threshold: ::core::option::Option<f32>,
4829    /// Offset of the result
4830    #[prost(uint64, optional, tag = "10")]
4831    pub offset: ::core::option::Option<u64>,
4832    /// Define which vector to use for recommendation, if not specified - default vector
4833    #[prost(string, optional, tag = "11")]
4834    pub using: ::core::option::Option<::prost::alloc::string::String>,
4835    /// Options for specifying which vectors to include into response
4836    #[prost(message, optional, tag = "12")]
4837    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
4838    /// Name of the collection to use for points lookup, if not specified - use current collection
4839    #[prost(message, optional, tag = "13")]
4840    pub lookup_from: ::core::option::Option<LookupLocation>,
4841    /// Options for specifying read consistency guarantees
4842    #[prost(message, optional, tag = "14")]
4843    pub read_consistency: ::core::option::Option<ReadConsistency>,
4844    /// How to use the example vectors to find the results
4845    #[prost(enumeration = "RecommendStrategy", optional, tag = "16")]
4846    pub strategy: ::core::option::Option<i32>,
4847    /// Look for vectors closest to those
4848    #[prost(message, repeated, tag = "17")]
4849    pub positive_vectors: ::prost::alloc::vec::Vec<Vector>,
4850    /// Try to avoid vectors like this
4851    #[prost(message, repeated, tag = "18")]
4852    pub negative_vectors: ::prost::alloc::vec::Vec<Vector>,
4853    /// If set, overrides global timeout setting for this request. Unit is seconds.
4854    #[prost(uint64, optional, tag = "19")]
4855    pub timeout: ::core::option::Option<u64>,
4856    /// Specify in which shards to look for the points, if not specified - look in all shards
4857    #[prost(message, optional, tag = "20")]
4858    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4859}
4860#[derive(Clone, PartialEq, ::prost::Message)]
4861pub struct RecommendBatchPoints {
4862    /// Name of the collection
4863    #[prost(string, tag = "1")]
4864    pub collection_name: ::prost::alloc::string::String,
4865    #[prost(message, repeated, tag = "2")]
4866    pub recommend_points: ::prost::alloc::vec::Vec<RecommendPoints>,
4867    /// Options for specifying read consistency guarantees
4868    #[prost(message, optional, tag = "3")]
4869    pub read_consistency: ::core::option::Option<ReadConsistency>,
4870    /// If set, overrides global timeout setting for this request. Unit is seconds.
4871    #[prost(uint64, optional, tag = "4")]
4872    pub timeout: ::core::option::Option<u64>,
4873}
4874#[derive(Clone, PartialEq, ::prost::Message)]
4875pub struct RecommendPointGroups {
4876    /// Name of the collection
4877    #[prost(string, tag = "1")]
4878    pub collection_name: ::prost::alloc::string::String,
4879    /// Look for vectors closest to the vectors from these points
4880    #[prost(message, repeated, tag = "2")]
4881    pub positive: ::prost::alloc::vec::Vec<PointId>,
4882    /// Try to avoid vectors like the vector from these points
4883    #[prost(message, repeated, tag = "3")]
4884    pub negative: ::prost::alloc::vec::Vec<PointId>,
4885    /// Filter conditions - return only those points that satisfy the specified conditions
4886    #[prost(message, optional, tag = "4")]
4887    pub filter: ::core::option::Option<Filter>,
4888    /// Max number of groups in result
4889    #[prost(uint32, tag = "5")]
4890    pub limit: u32,
4891    /// Options for specifying which payload to include or not
4892    #[prost(message, optional, tag = "6")]
4893    pub with_payload: ::core::option::Option<WithPayloadSelector>,
4894    /// Search config
4895    #[prost(message, optional, tag = "7")]
4896    pub params: ::core::option::Option<SearchParams>,
4897    /// If provided - cut off results with worse scores
4898    #[prost(float, optional, tag = "8")]
4899    pub score_threshold: ::core::option::Option<f32>,
4900    /// Define which vector to use for recommendation, if not specified - default vector
4901    #[prost(string, optional, tag = "9")]
4902    pub using: ::core::option::Option<::prost::alloc::string::String>,
4903    /// Options for specifying which vectors to include into response
4904    #[prost(message, optional, tag = "10")]
4905    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
4906    /// Name of the collection to use for points lookup, if not specified - use current collection
4907    #[prost(message, optional, tag = "11")]
4908    pub lookup_from: ::core::option::Option<LookupLocation>,
4909    /// Payload field to group by, must be a string or number field.
4910    /// If there are multiple values for the field, all of them will be used.
4911    /// One point can be in multiple groups.
4912    #[prost(string, tag = "12")]
4913    pub group_by: ::prost::alloc::string::String,
4914    /// Maximum amount of points to return per group
4915    #[prost(uint32, tag = "13")]
4916    pub group_size: u32,
4917    /// Options for specifying read consistency guarantees
4918    #[prost(message, optional, tag = "14")]
4919    pub read_consistency: ::core::option::Option<ReadConsistency>,
4920    /// Options for specifying how to use the group id to lookup points in another collection
4921    #[prost(message, optional, tag = "15")]
4922    pub with_lookup: ::core::option::Option<WithLookup>,
4923    /// How to use the example vectors to find the results
4924    #[prost(enumeration = "RecommendStrategy", optional, tag = "17")]
4925    pub strategy: ::core::option::Option<i32>,
4926    /// Look for vectors closest to those
4927    #[prost(message, repeated, tag = "18")]
4928    pub positive_vectors: ::prost::alloc::vec::Vec<Vector>,
4929    /// Try to avoid vectors like this
4930    #[prost(message, repeated, tag = "19")]
4931    pub negative_vectors: ::prost::alloc::vec::Vec<Vector>,
4932    /// If set, overrides global timeout setting for this request. Unit is seconds.
4933    #[prost(uint64, optional, tag = "20")]
4934    pub timeout: ::core::option::Option<u64>,
4935    /// Specify in which shards to look for the points, if not specified - look in all shards
4936    #[prost(message, optional, tag = "21")]
4937    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
4938}
4939#[derive(Clone, PartialEq, ::prost::Message)]
4940pub struct TargetVector {
4941    #[prost(oneof = "target_vector::Target", tags = "1")]
4942    pub target: ::core::option::Option<target_vector::Target>,
4943}
4944/// Nested message and enum types in `TargetVector`.
4945pub mod target_vector {
4946    #[derive(Clone, PartialEq, ::prost::Oneof)]
4947    pub enum Target {
4948        #[prost(message, tag = "1")]
4949        Single(super::VectorExample),
4950    }
4951}
4952#[derive(Clone, PartialEq, ::prost::Message)]
4953pub struct VectorExample {
4954    #[prost(oneof = "vector_example::Example", tags = "1, 2")]
4955    pub example: ::core::option::Option<vector_example::Example>,
4956}
4957/// Nested message and enum types in `VectorExample`.
4958pub mod vector_example {
4959    #[derive(Clone, PartialEq, ::prost::Oneof)]
4960    pub enum Example {
4961        #[prost(message, tag = "1")]
4962        Id(super::PointId),
4963        #[prost(message, tag = "2")]
4964        Vector(super::Vector),
4965    }
4966}
4967#[derive(Clone, PartialEq, ::prost::Message)]
4968pub struct ContextExamplePair {
4969    #[prost(message, optional, tag = "1")]
4970    pub positive: ::core::option::Option<VectorExample>,
4971    #[prost(message, optional, tag = "2")]
4972    pub negative: ::core::option::Option<VectorExample>,
4973}
4974#[derive(Clone, PartialEq, ::prost::Message)]
4975pub struct DiscoverPoints {
4976    /// name of the collection
4977    #[prost(string, tag = "1")]
4978    pub collection_name: ::prost::alloc::string::String,
4979    /// Use this as the primary search objective
4980    #[prost(message, optional, tag = "2")]
4981    pub target: ::core::option::Option<TargetVector>,
4982    /// Search will be constrained by these pairs of examples
4983    #[prost(message, repeated, tag = "3")]
4984    pub context: ::prost::alloc::vec::Vec<ContextExamplePair>,
4985    /// Filter conditions - return only those points that satisfy the specified conditions
4986    #[prost(message, optional, tag = "4")]
4987    pub filter: ::core::option::Option<Filter>,
4988    /// Max number of result
4989    #[prost(uint64, tag = "5")]
4990    pub limit: u64,
4991    /// Options for specifying which payload to include or not
4992    #[prost(message, optional, tag = "6")]
4993    pub with_payload: ::core::option::Option<WithPayloadSelector>,
4994    /// Search config
4995    #[prost(message, optional, tag = "7")]
4996    pub params: ::core::option::Option<SearchParams>,
4997    /// Offset of the result
4998    #[prost(uint64, optional, tag = "8")]
4999    pub offset: ::core::option::Option<u64>,
5000    /// Define which vector to use for recommendation, if not specified - default vector
5001    #[prost(string, optional, tag = "9")]
5002    pub using: ::core::option::Option<::prost::alloc::string::String>,
5003    /// Options for specifying which vectors to include into response
5004    #[prost(message, optional, tag = "10")]
5005    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
5006    /// Name of the collection to use for points lookup, if not specified - use current collection
5007    #[prost(message, optional, tag = "11")]
5008    pub lookup_from: ::core::option::Option<LookupLocation>,
5009    /// Options for specifying read consistency guarantees
5010    #[prost(message, optional, tag = "12")]
5011    pub read_consistency: ::core::option::Option<ReadConsistency>,
5012    /// If set, overrides global timeout setting for this request. Unit is seconds.
5013    #[prost(uint64, optional, tag = "13")]
5014    pub timeout: ::core::option::Option<u64>,
5015    /// Specify in which shards to look for the points, if not specified - look in all shards
5016    #[prost(message, optional, tag = "14")]
5017    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
5018}
5019#[derive(Clone, PartialEq, ::prost::Message)]
5020pub struct DiscoverBatchPoints {
5021    /// Name of the collection
5022    #[prost(string, tag = "1")]
5023    pub collection_name: ::prost::alloc::string::String,
5024    #[prost(message, repeated, tag = "2")]
5025    pub discover_points: ::prost::alloc::vec::Vec<DiscoverPoints>,
5026    /// Options for specifying read consistency guarantees
5027    #[prost(message, optional, tag = "3")]
5028    pub read_consistency: ::core::option::Option<ReadConsistency>,
5029    /// If set, overrides global timeout setting for this request. Unit is seconds.
5030    #[prost(uint64, optional, tag = "4")]
5031    pub timeout: ::core::option::Option<u64>,
5032}
5033#[derive(Clone, PartialEq, ::prost::Message)]
5034pub struct CountPoints {
5035    /// Name of the collection
5036    #[prost(string, tag = "1")]
5037    pub collection_name: ::prost::alloc::string::String,
5038    /// Filter conditions - return only those points that satisfy the specified conditions
5039    #[prost(message, optional, tag = "2")]
5040    pub filter: ::core::option::Option<Filter>,
5041    /// If `true` - return exact count, if `false` - return approximate count
5042    #[prost(bool, optional, tag = "3")]
5043    pub exact: ::core::option::Option<bool>,
5044    /// Options for specifying read consistency guarantees
5045    #[prost(message, optional, tag = "4")]
5046    pub read_consistency: ::core::option::Option<ReadConsistency>,
5047    /// Specify in which shards to look for the points, if not specified - look in all shards
5048    #[prost(message, optional, tag = "5")]
5049    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
5050    /// If set, overrides global timeout setting for this request. Unit is seconds.
5051    #[prost(uint64, optional, tag = "6")]
5052    pub timeout: ::core::option::Option<u64>,
5053}
5054#[derive(Clone, PartialEq, ::prost::Message)]
5055pub struct RecommendInput {
5056    /// Look for vectors closest to the vectors from these points
5057    #[prost(message, repeated, tag = "1")]
5058    pub positive: ::prost::alloc::vec::Vec<VectorInput>,
5059    /// Try to avoid vectors like the vector from these points
5060    #[prost(message, repeated, tag = "2")]
5061    pub negative: ::prost::alloc::vec::Vec<VectorInput>,
5062    /// How to use the provided vectors to find the results
5063    #[prost(enumeration = "RecommendStrategy", optional, tag = "3")]
5064    pub strategy: ::core::option::Option<i32>,
5065}
5066#[derive(Clone, PartialEq, ::prost::Message)]
5067pub struct ContextInputPair {
5068    /// A positive vector
5069    #[prost(message, optional, tag = "1")]
5070    pub positive: ::core::option::Option<VectorInput>,
5071    /// Repel from this vector
5072    #[prost(message, optional, tag = "2")]
5073    pub negative: ::core::option::Option<VectorInput>,
5074}
5075#[derive(Clone, PartialEq, ::prost::Message)]
5076pub struct DiscoverInput {
5077    /// Use this as the primary search objective
5078    #[prost(message, optional, tag = "1")]
5079    pub target: ::core::option::Option<VectorInput>,
5080    /// Search space will be constrained by these pairs of vectors
5081    #[prost(message, optional, tag = "2")]
5082    pub context: ::core::option::Option<ContextInput>,
5083}
5084#[derive(Clone, PartialEq, ::prost::Message)]
5085pub struct ContextInput {
5086    /// Search space will be constrained by these pairs of vectors
5087    #[prost(message, repeated, tag = "1")]
5088    pub pairs: ::prost::alloc::vec::Vec<ContextInputPair>,
5089}
5090#[derive(Clone, PartialEq, ::prost::Message)]
5091pub struct RelevanceFeedbackInput {
5092    /// The original query vector
5093    #[prost(message, optional, tag = "1")]
5094    pub target: ::core::option::Option<VectorInput>,
5095    /// Previous results scored by the feedback provider.
5096    #[prost(message, repeated, tag = "2")]
5097    pub feedback: ::prost::alloc::vec::Vec<FeedbackItem>,
5098    /// Formula and trained coefficients to use.
5099    #[prost(message, optional, tag = "3")]
5100    pub strategy: ::core::option::Option<FeedbackStrategy>,
5101}
5102#[derive(Clone, PartialEq, ::prost::Message)]
5103pub struct FeedbackItem {
5104    /// The id or vector from the original model
5105    #[prost(message, optional, tag = "1")]
5106    pub example: ::core::option::Option<VectorInput>,
5107    /// Score for this vector as determined by the feedback provider
5108    #[prost(float, tag = "2")]
5109    pub score: f32,
5110}
5111#[derive(Clone, Copy, PartialEq, ::prost::Message)]
5112pub struct FeedbackStrategy {
5113    #[prost(oneof = "feedback_strategy::Variant", tags = "1")]
5114    pub variant: ::core::option::Option<feedback_strategy::Variant>,
5115}
5116/// Nested message and enum types in `FeedbackStrategy`.
5117pub mod feedback_strategy {
5118    #[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
5119    pub enum Variant {
5120        /// a * score + sim(confidence^b * c * delta)
5121        #[prost(message, tag = "1")]
5122        Naive(super::NaiveFeedbackStrategy),
5123    }
5124}
5125#[derive(Clone, Copy, PartialEq, ::prost::Message)]
5126pub struct NaiveFeedbackStrategy {
5127    #[prost(float, tag = "1")]
5128    pub a: f32,
5129    #[prost(float, tag = "2")]
5130    pub b: f32,
5131    #[prost(float, tag = "3")]
5132    pub c: f32,
5133}
5134#[derive(Clone, PartialEq, ::prost::Message)]
5135pub struct Formula {
5136    #[prost(message, optional, tag = "1")]
5137    pub expression: ::core::option::Option<Expression>,
5138    #[prost(map = "string, message", tag = "2")]
5139    pub defaults: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
5140}
5141#[derive(Clone, PartialEq, ::prost::Message)]
5142pub struct Expression {
5143    #[prost(
5144        oneof = "expression::Variant",
5145        tags = "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22"
5146    )]
5147    pub variant: ::core::option::Option<expression::Variant>,
5148}
5149/// Nested message and enum types in `Expression`.
5150pub mod expression {
5151    #[derive(Clone, PartialEq, ::prost::Oneof)]
5152    pub enum Variant {
5153        #[prost(float, tag = "1")]
5154        Constant(f32),
5155        /// Payload key or reference to score.
5156        #[prost(string, tag = "2")]
5157        Variable(::prost::alloc::string::String),
5158        /// Payload condition. If true, becomes 1.0; otherwise 0.0
5159        #[prost(message, tag = "3")]
5160        Condition(super::Condition),
5161        /// Geographic distance in meters
5162        #[prost(message, tag = "4")]
5163        GeoDistance(super::GeoDistance),
5164        /// Date-time constant
5165        #[prost(string, tag = "5")]
5166        Datetime(::prost::alloc::string::String),
5167        /// Payload key with date-time values
5168        #[prost(string, tag = "6")]
5169        DatetimeKey(::prost::alloc::string::String),
5170        /// Multiply
5171        #[prost(message, tag = "7")]
5172        Mult(super::MultExpression),
5173        /// Sum
5174        #[prost(message, tag = "8")]
5175        Sum(super::SumExpression),
5176        /// Divide
5177        #[prost(message, tag = "9")]
5178        Div(::prost::alloc::boxed::Box<super::DivExpression>),
5179        /// Negate
5180        #[prost(message, tag = "10")]
5181        Neg(::prost::alloc::boxed::Box<super::Expression>),
5182        /// Absolute value
5183        #[prost(message, tag = "11")]
5184        Abs(::prost::alloc::boxed::Box<super::Expression>),
5185        /// Square root
5186        #[prost(message, tag = "12")]
5187        Sqrt(::prost::alloc::boxed::Box<super::Expression>),
5188        /// Power
5189        #[prost(message, tag = "13")]
5190        Pow(::prost::alloc::boxed::Box<super::PowExpression>),
5191        /// Exponential
5192        #[prost(message, tag = "14")]
5193        Exp(::prost::alloc::boxed::Box<super::Expression>),
5194        /// Logarithm
5195        #[prost(message, tag = "15")]
5196        Log10(::prost::alloc::boxed::Box<super::Expression>),
5197        /// Natural logarithm
5198        #[prost(message, tag = "16")]
5199        Ln(::prost::alloc::boxed::Box<super::Expression>),
5200        /// Exponential decay
5201        #[prost(message, tag = "17")]
5202        ExpDecay(::prost::alloc::boxed::Box<super::DecayParamsExpression>),
5203        /// Gaussian decay
5204        #[prost(message, tag = "18")]
5205        GaussDecay(::prost::alloc::boxed::Box<super::DecayParamsExpression>),
5206        /// Linear decay
5207        #[prost(message, tag = "19")]
5208        LinDecay(::prost::alloc::boxed::Box<super::DecayParamsExpression>),
5209        /// Inverse hyperbolic cosine
5210        #[prost(message, tag = "20")]
5211        Acosh(::prost::alloc::boxed::Box<super::Expression>),
5212        /// Maximum
5213        #[prost(message, tag = "21")]
5214        Max(super::MaxExpression),
5215        /// Minimum
5216        #[prost(message, tag = "22")]
5217        Min(super::MinExpression),
5218    }
5219}
5220#[derive(Clone, PartialEq, ::prost::Message)]
5221pub struct GeoDistance {
5222    #[prost(message, optional, tag = "1")]
5223    pub origin: ::core::option::Option<GeoPoint>,
5224    #[prost(string, tag = "2")]
5225    pub to: ::prost::alloc::string::String,
5226}
5227#[derive(Clone, PartialEq, ::prost::Message)]
5228pub struct MultExpression {
5229    #[prost(message, repeated, tag = "1")]
5230    pub mult: ::prost::alloc::vec::Vec<Expression>,
5231}
5232#[derive(Clone, PartialEq, ::prost::Message)]
5233pub struct SumExpression {
5234    #[prost(message, repeated, tag = "1")]
5235    pub sum: ::prost::alloc::vec::Vec<Expression>,
5236}
5237#[derive(Clone, PartialEq, ::prost::Message)]
5238pub struct MaxExpression {
5239    #[prost(message, repeated, tag = "1")]
5240    pub max: ::prost::alloc::vec::Vec<Expression>,
5241}
5242#[derive(Clone, PartialEq, ::prost::Message)]
5243pub struct MinExpression {
5244    #[prost(message, repeated, tag = "1")]
5245    pub min: ::prost::alloc::vec::Vec<Expression>,
5246}
5247#[derive(Clone, PartialEq, ::prost::Message)]
5248pub struct DivExpression {
5249    #[prost(message, optional, boxed, tag = "1")]
5250    pub left: ::core::option::Option<::prost::alloc::boxed::Box<Expression>>,
5251    #[prost(message, optional, boxed, tag = "2")]
5252    pub right: ::core::option::Option<::prost::alloc::boxed::Box<Expression>>,
5253    #[prost(float, optional, tag = "3")]
5254    pub by_zero_default: ::core::option::Option<f32>,
5255}
5256#[derive(Clone, PartialEq, ::prost::Message)]
5257pub struct PowExpression {
5258    #[prost(message, optional, boxed, tag = "1")]
5259    pub base: ::core::option::Option<::prost::alloc::boxed::Box<Expression>>,
5260    #[prost(message, optional, boxed, tag = "2")]
5261    pub exponent: ::core::option::Option<::prost::alloc::boxed::Box<Expression>>,
5262}
5263#[derive(Clone, PartialEq, ::prost::Message)]
5264pub struct DecayParamsExpression {
5265    /// The variable to decay
5266    #[prost(message, optional, boxed, tag = "1")]
5267    pub x: ::core::option::Option<::prost::alloc::boxed::Box<Expression>>,
5268    /// The target value to start decaying from. Defaults to 0.
5269    #[prost(message, optional, boxed, tag = "2")]
5270    pub target: ::core::option::Option<::prost::alloc::boxed::Box<Expression>>,
5271    /// The scale factor of the decay, in terms of `x`.
5272    /// Defaults to 1.0. Must be a non-zero positive number.
5273    #[prost(float, optional, tag = "3")]
5274    pub scale: ::core::option::Option<f32>,
5275    /// The midpoint of the decay.
5276    /// Should be between 0 and 1. Defaults to 0.5.
5277    /// Output will be this value when `|x - target| == scale`.
5278    #[prost(float, optional, tag = "4")]
5279    pub midpoint: ::core::option::Option<f32>,
5280}
5281#[derive(Clone, PartialEq, ::prost::Message)]
5282pub struct NearestInputWithMmr {
5283    /// The vector to search for nearest neighbors.
5284    #[prost(message, optional, tag = "1")]
5285    pub nearest: ::core::option::Option<VectorInput>,
5286    /// Perform MMR (Maximal Marginal Relevance) reranking after search,
5287    /// using the same vector in this query to calculate relevance.
5288    #[prost(message, optional, tag = "2")]
5289    pub mmr: ::core::option::Option<Mmr>,
5290}
5291/// Maximal Marginal Relevance (MMR) algorithm for re-ranking the points.
5292#[derive(Clone, Copy, PartialEq, ::prost::Message)]
5293pub struct Mmr {
5294    /// Tunable parameter for the MMR algorithm.
5295    /// Determines the balance between diversity and relevance.
5296    ///
5297    /// A higher value favors diversity (dissimilarity to selected results),
5298    /// while a lower value favors relevance (similarity to the query vector).
5299    ///
5300    /// Must be in the range \[0, 1\].
5301    /// Default value is 0.5.
5302    #[prost(float, optional, tag = "2")]
5303    pub diversity: ::core::option::Option<f32>,
5304    /// The maximum number of candidates to consider for re-ranking.
5305    ///
5306    /// If not specified, the `limit` value is used.
5307    #[prost(uint32, optional, tag = "3")]
5308    pub candidates_limit: ::core::option::Option<u32>,
5309}
5310/// Parameterized reciprocal rank fusion
5311#[derive(Clone, PartialEq, ::prost::Message)]
5312pub struct Rrf {
5313    /// K parameter for reciprocal rank fusion
5314    #[prost(uint32, optional, tag = "1")]
5315    pub k: ::core::option::Option<u32>,
5316    /// Weights for each prefetch source.
5317    /// Higher weight gives more influence on the final ranking.
5318    /// If not specified, all prefetches are weighted equally.
5319    /// The number of weights should match the number of prefetches.
5320    #[prost(float, repeated, tag = "2")]
5321    pub weights: ::prost::alloc::vec::Vec<f32>,
5322}
5323#[derive(Clone, PartialEq, ::prost::Message)]
5324pub struct Query {
5325    #[prost(oneof = "query::Variant", tags = "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12")]
5326    pub variant: ::core::option::Option<query::Variant>,
5327}
5328/// Nested message and enum types in `Query`.
5329pub mod query {
5330    #[derive(Clone, PartialEq, ::prost::Oneof)]
5331    pub enum Variant {
5332        /// Find the nearest neighbors to this vector.
5333        #[prost(message, tag = "1")]
5334        Nearest(super::VectorInput),
5335        /// Use multiple positive and negative vectors to find the results.
5336        #[prost(message, tag = "2")]
5337        Recommend(super::RecommendInput),
5338        /// Search for nearest points, but constrain the search space with context
5339        #[prost(message, tag = "3")]
5340        Discover(super::DiscoverInput),
5341        /// Return points that live in positive areas.
5342        #[prost(message, tag = "4")]
5343        Context(super::ContextInput),
5344        /// Order the points by a payload field.
5345        #[prost(message, tag = "5")]
5346        OrderBy(super::OrderBy),
5347        /// Fuse the results of multiple prefetches.
5348        #[prost(enumeration = "super::Fusion", tag = "6")]
5349        Fusion(i32),
5350        /// Sample points from the collection.
5351        #[prost(enumeration = "super::Sample", tag = "7")]
5352        Sample(i32),
5353        /// Score boosting via an arbitrary formula
5354        #[prost(message, tag = "8")]
5355        Formula(super::Formula),
5356        /// Search nearest neighbors, but re-rank based on the Maximal Marginal Relevance algorithm.
5357        #[prost(message, tag = "9")]
5358        NearestWithMmr(super::NearestInputWithMmr),
5359        /// Parameterized reciprocal rank fusion
5360        #[prost(message, tag = "10")]
5361        Rrf(super::Rrf),
5362        /// Search with feedback from some oracle.
5363        #[prost(message, tag = "11")]
5364        RelevanceFeedback(super::RelevanceFeedbackInput),
5365        /// Rank by BM25 over the text index of the payload field named by `using`.
5366        #[prost(message, tag = "12")]
5367        Text(super::TextQuery),
5368    }
5369}
5370/// Rank by BM25 over the text index of the payload field named by `using`,
5371/// which must have `scoring` set. A point scores when it holds any of the
5372/// query's terms: required or excluded terms belong in the request's filter.
5373#[derive(Clone, PartialEq, ::prost::Message)]
5374pub struct TextQuery {
5375    /// Text to search for, tokenized by the field's text index.
5376    #[prost(string, tag = "1")]
5377    pub query: ::prost::alloc::string::String,
5378    /// Parameters of the scorer, keyed by its name. They must match the
5379    /// `scoring` type of the field's text index. If absent, the scorer runs
5380    /// with its defaults.
5381    #[prost(oneof = "text_query::Scoring", tags = "2")]
5382    pub scoring: ::core::option::Option<text_query::Scoring>,
5383}
5384/// Nested message and enum types in `TextQuery`.
5385pub mod text_query {
5386    /// Parameters of the scorer, keyed by its name. They must match the
5387    /// `scoring` type of the field's text index. If absent, the scorer runs
5388    /// with its defaults.
5389    #[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
5390    pub enum Scoring {
5391        /// BM25 parameters, for a field scored with BM25.
5392        #[prost(message, tag = "2")]
5393        Bm25(super::Bm25Params),
5394    }
5395}
5396#[derive(Clone, Copy, PartialEq, ::prost::Message)]
5397pub struct Bm25Params {
5398    /// Term frequency saturation. Default is 1.2.
5399    #[prost(float, optional, tag = "1")]
5400    pub k: ::core::option::Option<f32>,
5401    /// Document length normalization, from 0 (none) to 1 (full). Default is 0.75.
5402    #[prost(float, optional, tag = "2")]
5403    pub b: ::core::option::Option<f32>,
5404}
5405#[derive(Clone, PartialEq, ::prost::Message)]
5406pub struct PrefetchQuery {
5407    /// Sub-requests to perform first.
5408    /// If present, the query will be performed on the results of the prefetches.
5409    #[prost(message, repeated, tag = "1")]
5410    pub prefetch: ::prost::alloc::vec::Vec<PrefetchQuery>,
5411    /// Query to perform.
5412    /// If missing, returns points ordered by their IDs.
5413    #[prost(message, optional, tag = "2")]
5414    pub query: ::core::option::Option<Query>,
5415    /// Define which vector to use for querying.
5416    /// If missing, the default vector is used.
5417    /// For a `text` query, the payload field whose text index to search.
5418    #[prost(string, optional, tag = "3")]
5419    pub using: ::core::option::Option<::prost::alloc::string::String>,
5420    /// Filter conditions - return only those points that satisfy the specified conditions.
5421    #[prost(message, optional, tag = "4")]
5422    pub filter: ::core::option::Option<Filter>,
5423    /// Search params for when there is no prefetch.
5424    #[prost(message, optional, tag = "5")]
5425    pub params: ::core::option::Option<SearchParams>,
5426    /// Return points with scores better than this threshold.
5427    #[prost(float, optional, tag = "6")]
5428    pub score_threshold: ::core::option::Option<f32>,
5429    /// Max number of points. Default is 10
5430    #[prost(uint64, optional, tag = "7")]
5431    pub limit: ::core::option::Option<u64>,
5432    /// The location to use for IDs lookup.
5433    /// If not specified - use the current collection and the 'using' vector.
5434    #[prost(message, optional, tag = "8")]
5435    pub lookup_from: ::core::option::Option<LookupLocation>,
5436}
5437#[derive(Clone, PartialEq, ::prost::Message)]
5438pub struct QueryPoints {
5439    /// Name of the collection
5440    #[prost(string, tag = "1")]
5441    pub collection_name: ::prost::alloc::string::String,
5442    /// Sub-requests to perform first.
5443    /// If present, the query will be performed on the results of the prefetches.
5444    #[prost(message, repeated, tag = "2")]
5445    pub prefetch: ::prost::alloc::vec::Vec<PrefetchQuery>,
5446    /// Query to perform. If missing, returns points ordered by their IDs.
5447    #[prost(message, optional, tag = "3")]
5448    pub query: ::core::option::Option<Query>,
5449    /// Define which vector to use for querying.
5450    /// If missing, the default vector is used.
5451    /// For a `text` query, the payload field whose text index to search.
5452    #[prost(string, optional, tag = "4")]
5453    pub using: ::core::option::Option<::prost::alloc::string::String>,
5454    /// Filter conditions - return only those points that satisfy the specified conditions.
5455    #[prost(message, optional, tag = "5")]
5456    pub filter: ::core::option::Option<Filter>,
5457    /// Search params for when there is no prefetch.
5458    #[prost(message, optional, tag = "6")]
5459    pub params: ::core::option::Option<SearchParams>,
5460    /// Return points with scores better than this threshold.
5461    #[prost(float, optional, tag = "7")]
5462    pub score_threshold: ::core::option::Option<f32>,
5463    /// Max number of points. Default is 10.
5464    #[prost(uint64, optional, tag = "8")]
5465    pub limit: ::core::option::Option<u64>,
5466    /// Offset of the result. Skip this many points. Default is 0.
5467    #[prost(uint64, optional, tag = "9")]
5468    pub offset: ::core::option::Option<u64>,
5469    /// Options for specifying which vectors to include into the response.
5470    #[prost(message, optional, tag = "10")]
5471    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
5472    /// Options for specifying which payload to include or not.
5473    #[prost(message, optional, tag = "11")]
5474    pub with_payload: ::core::option::Option<WithPayloadSelector>,
5475    /// Options for specifying read consistency guarantees.
5476    #[prost(message, optional, tag = "12")]
5477    pub read_consistency: ::core::option::Option<ReadConsistency>,
5478    /// Specify in which shards to look for the points.
5479    /// If not specified - look in all shards.
5480    #[prost(message, optional, tag = "13")]
5481    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
5482    /// The location to use for IDs lookup.
5483    /// If not specified - use the current collection and the 'using' vector.
5484    #[prost(message, optional, tag = "14")]
5485    pub lookup_from: ::core::option::Option<LookupLocation>,
5486    /// If set, overrides global timeout setting for this request. Unit is seconds.
5487    #[prost(uint64, optional, tag = "15")]
5488    pub timeout: ::core::option::Option<u64>,
5489}
5490#[derive(Clone, PartialEq, ::prost::Message)]
5491pub struct QueryBatchPoints {
5492    #[prost(string, tag = "1")]
5493    pub collection_name: ::prost::alloc::string::String,
5494    #[prost(message, repeated, tag = "2")]
5495    pub query_points: ::prost::alloc::vec::Vec<QueryPoints>,
5496    /// Options for specifying read consistency guarantees
5497    #[prost(message, optional, tag = "3")]
5498    pub read_consistency: ::core::option::Option<ReadConsistency>,
5499    /// If set, overrides global timeout setting for this request. Unit is seconds.
5500    #[prost(uint64, optional, tag = "4")]
5501    pub timeout: ::core::option::Option<u64>,
5502}
5503#[derive(Clone, PartialEq, ::prost::Message)]
5504pub struct QueryPointGroups {
5505    /// Name of the collection
5506    #[prost(string, tag = "1")]
5507    pub collection_name: ::prost::alloc::string::String,
5508    /// Sub-requests to perform first.
5509    /// If present, the query will be performed on the results of the prefetches.
5510    #[prost(message, repeated, tag = "2")]
5511    pub prefetch: ::prost::alloc::vec::Vec<PrefetchQuery>,
5512    /// Query to perform. If missing, returns points ordered by their IDs.
5513    #[prost(message, optional, tag = "3")]
5514    pub query: ::core::option::Option<Query>,
5515    /// Define which vector to use for querying.
5516    /// If missing, the default vector is used.
5517    /// For a `text` query, the payload field whose text index to search.
5518    #[prost(string, optional, tag = "4")]
5519    pub using: ::core::option::Option<::prost::alloc::string::String>,
5520    /// Filter conditions - return only those points that satisfy the specified conditions.
5521    #[prost(message, optional, tag = "5")]
5522    pub filter: ::core::option::Option<Filter>,
5523    /// Search params for when there is no prefetch.
5524    #[prost(message, optional, tag = "6")]
5525    pub params: ::core::option::Option<SearchParams>,
5526    /// Return points with scores better than this threshold.
5527    #[prost(float, optional, tag = "7")]
5528    pub score_threshold: ::core::option::Option<f32>,
5529    /// Options for specifying which payload to include or not
5530    #[prost(message, optional, tag = "8")]
5531    pub with_payload: ::core::option::Option<WithPayloadSelector>,
5532    /// Options for specifying which vectors to include into response
5533    #[prost(message, optional, tag = "9")]
5534    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
5535    /// The location to use for IDs lookup.
5536    /// If not specified - use the current collection and the 'using' vector.
5537    #[prost(message, optional, tag = "10")]
5538    pub lookup_from: ::core::option::Option<LookupLocation>,
5539    /// Max number of points. Default is 3.
5540    #[prost(uint64, optional, tag = "11")]
5541    pub limit: ::core::option::Option<u64>,
5542    /// Maximum amount of points to return per group. Defaults to 10.
5543    #[prost(uint64, optional, tag = "12")]
5544    pub group_size: ::core::option::Option<u64>,
5545    /// Payload field to group by, must be a string or number field.
5546    /// If there are multiple values for the field, all of them will be used.
5547    /// One point can be in multiple groups.
5548    #[prost(string, tag = "13")]
5549    pub group_by: ::prost::alloc::string::String,
5550    /// Options for specifying read consistency guarantees
5551    #[prost(message, optional, tag = "14")]
5552    pub read_consistency: ::core::option::Option<ReadConsistency>,
5553    /// Options for specifying how to use the group id to lookup points in another collection
5554    #[prost(message, optional, tag = "15")]
5555    pub with_lookup: ::core::option::Option<WithLookup>,
5556    /// If set, overrides global timeout setting for this request. Unit is seconds.
5557    #[prost(uint64, optional, tag = "16")]
5558    pub timeout: ::core::option::Option<u64>,
5559    /// Specify in which shards to look for the points, if not specified - look in all shards
5560    #[prost(message, optional, tag = "17")]
5561    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
5562}
5563#[derive(Clone, PartialEq, ::prost::Message)]
5564pub struct FacetCounts {
5565    /// Name of the collection
5566    #[prost(string, tag = "1")]
5567    pub collection_name: ::prost::alloc::string::String,
5568    /// Payload key of the facet
5569    #[prost(string, tag = "2")]
5570    pub key: ::prost::alloc::string::String,
5571    /// Filter conditions - return only those points that satisfy the specified conditions.
5572    #[prost(message, optional, tag = "3")]
5573    pub filter: ::core::option::Option<Filter>,
5574    /// Max number of facets. Default is 10.
5575    #[prost(uint64, optional, tag = "4")]
5576    pub limit: ::core::option::Option<u64>,
5577    /// If true, return exact counts, slower but useful for debugging purposes. Default is false.
5578    #[prost(bool, optional, tag = "5")]
5579    pub exact: ::core::option::Option<bool>,
5580    /// If set, overrides global timeout setting for this request. Unit is seconds.
5581    #[prost(uint64, optional, tag = "6")]
5582    pub timeout: ::core::option::Option<u64>,
5583    /// Options for specifying read consistency guarantees
5584    #[prost(message, optional, tag = "7")]
5585    pub read_consistency: ::core::option::Option<ReadConsistency>,
5586    /// Specify in which shards to look for the points, if not specified - look in all shards
5587    #[prost(message, optional, tag = "8")]
5588    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
5589}
5590#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5591pub struct FacetValue {
5592    #[prost(oneof = "facet_value::Variant", tags = "1, 2, 3")]
5593    pub variant: ::core::option::Option<facet_value::Variant>,
5594}
5595/// Nested message and enum types in `FacetValue`.
5596pub mod facet_value {
5597    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
5598    pub enum Variant {
5599        /// String value from the facet
5600        #[prost(string, tag = "1")]
5601        StringValue(::prost::alloc::string::String),
5602        /// Integer value from the facet
5603        #[prost(int64, tag = "2")]
5604        IntegerValue(i64),
5605        /// Boolean value from the facet
5606        #[prost(bool, tag = "3")]
5607        BoolValue(bool),
5608    }
5609}
5610#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5611pub struct FacetHit {
5612    /// Value from the facet
5613    #[prost(message, optional, tag = "1")]
5614    pub value: ::core::option::Option<FacetValue>,
5615    /// Number of points with this value
5616    #[prost(uint64, tag = "2")]
5617    pub count: u64,
5618}
5619#[derive(Clone, PartialEq, ::prost::Message)]
5620pub struct SearchMatrixPoints {
5621    /// Name of the collection
5622    #[prost(string, tag = "1")]
5623    pub collection_name: ::prost::alloc::string::String,
5624    /// Filter conditions - return only those points that satisfy the specified conditions.
5625    #[prost(message, optional, tag = "2")]
5626    pub filter: ::core::option::Option<Filter>,
5627    /// How many points to select and search within. Default is 10.
5628    #[prost(uint64, optional, tag = "3")]
5629    pub sample: ::core::option::Option<u64>,
5630    /// How many neighbours per sample to find. Default is 3.
5631    #[prost(uint64, optional, tag = "4")]
5632    pub limit: ::core::option::Option<u64>,
5633    /// Define which vector to use for querying. If missing, the default vector is used.
5634    #[prost(string, optional, tag = "5")]
5635    pub using: ::core::option::Option<::prost::alloc::string::String>,
5636    /// If set, overrides global timeout setting for this request. Unit is seconds.
5637    #[prost(uint64, optional, tag = "6")]
5638    pub timeout: ::core::option::Option<u64>,
5639    /// Options for specifying read consistency guarantees
5640    #[prost(message, optional, tag = "7")]
5641    pub read_consistency: ::core::option::Option<ReadConsistency>,
5642    /// Specify in which shards to look for the points, if not specified - look in all shards
5643    #[prost(message, optional, tag = "8")]
5644    pub shard_key_selector: ::core::option::Option<ShardKeySelector>,
5645}
5646#[derive(Clone, PartialEq, ::prost::Message)]
5647pub struct SearchMatrixPairs {
5648    /// List of pairs of points with scores
5649    #[prost(message, repeated, tag = "1")]
5650    pub pairs: ::prost::alloc::vec::Vec<SearchMatrixPair>,
5651}
5652#[derive(Clone, PartialEq, ::prost::Message)]
5653pub struct SearchMatrixPair {
5654    /// first id of the pair
5655    #[prost(message, optional, tag = "1")]
5656    pub a: ::core::option::Option<PointId>,
5657    /// second id of the pair
5658    #[prost(message, optional, tag = "2")]
5659    pub b: ::core::option::Option<PointId>,
5660    /// score of the pair
5661    #[prost(float, tag = "3")]
5662    pub score: f32,
5663}
5664#[derive(Clone, PartialEq, ::prost::Message)]
5665pub struct SearchMatrixOffsets {
5666    /// Row indices of the matrix
5667    #[prost(uint64, repeated, tag = "1")]
5668    pub offsets_row: ::prost::alloc::vec::Vec<u64>,
5669    /// Column indices of the matrix
5670    #[prost(uint64, repeated, tag = "2")]
5671    pub offsets_col: ::prost::alloc::vec::Vec<u64>,
5672    /// Scores associated with matrix coordinates
5673    #[prost(float, repeated, tag = "3")]
5674    pub scores: ::prost::alloc::vec::Vec<f32>,
5675    /// Ids of the points in order
5676    #[prost(message, repeated, tag = "4")]
5677    pub ids: ::prost::alloc::vec::Vec<PointId>,
5678}
5679#[derive(Clone, PartialEq, ::prost::Message)]
5680pub struct PointsUpdateOperation {
5681    #[prost(
5682        oneof = "points_update_operation::Operation",
5683        tags = "1, 2, 3, 4, 5, 6, 7, 8, 9, 10"
5684    )]
5685    pub operation: ::core::option::Option<points_update_operation::Operation>,
5686}
5687/// Nested message and enum types in `PointsUpdateOperation`.
5688pub mod points_update_operation {
5689    #[derive(Clone, PartialEq, ::prost::Message)]
5690    pub struct PointStructList {
5691        #[prost(message, repeated, tag = "1")]
5692        pub points: ::prost::alloc::vec::Vec<super::PointStruct>,
5693        /// Option for custom sharding to specify used shard keys
5694        #[prost(message, optional, tag = "2")]
5695        pub shard_key_selector: ::core::option::Option<super::ShardKeySelector>,
5696        /// Filter to apply when updating existing points. Only points matching this filter will be updated.
5697        /// Points that don't match will keep their current state. New points will be inserted regardless of the filter.
5698        #[prost(message, optional, tag = "3")]
5699        pub update_filter: ::core::option::Option<super::Filter>,
5700        /// Mode of the upsert operation: insert_only, upsert (default), update_only
5701        #[prost(enumeration = "super::UpdateMode", optional, tag = "4")]
5702        pub update_mode: ::core::option::Option<i32>,
5703    }
5704    #[derive(Clone, PartialEq, ::prost::Message)]
5705    pub struct SetPayload {
5706        #[prost(map = "string, message", tag = "1")]
5707        pub payload: ::std::collections::HashMap<
5708            ::prost::alloc::string::String,
5709            super::Value,
5710        >,
5711        /// Affected points
5712        #[prost(message, optional, tag = "2")]
5713        pub points_selector: ::core::option::Option<super::PointsSelector>,
5714        /// Option for custom sharding to specify used shard keys
5715        #[prost(message, optional, tag = "3")]
5716        pub shard_key_selector: ::core::option::Option<super::ShardKeySelector>,
5717        /// Option for indicate property of payload
5718        #[prost(string, optional, tag = "4")]
5719        pub key: ::core::option::Option<::prost::alloc::string::String>,
5720    }
5721    #[derive(Clone, PartialEq, ::prost::Message)]
5722    pub struct OverwritePayload {
5723        #[prost(map = "string, message", tag = "1")]
5724        pub payload: ::std::collections::HashMap<
5725            ::prost::alloc::string::String,
5726            super::Value,
5727        >,
5728        /// Affected points
5729        #[prost(message, optional, tag = "2")]
5730        pub points_selector: ::core::option::Option<super::PointsSelector>,
5731        /// Option for custom sharding to specify used shard keys
5732        #[prost(message, optional, tag = "3")]
5733        pub shard_key_selector: ::core::option::Option<super::ShardKeySelector>,
5734        /// Option for indicate property of payload
5735        #[prost(string, optional, tag = "4")]
5736        pub key: ::core::option::Option<::prost::alloc::string::String>,
5737    }
5738    #[derive(Clone, PartialEq, ::prost::Message)]
5739    pub struct DeletePayload {
5740        #[prost(string, repeated, tag = "1")]
5741        pub keys: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
5742        /// Affected points
5743        #[prost(message, optional, tag = "2")]
5744        pub points_selector: ::core::option::Option<super::PointsSelector>,
5745        /// Option for custom sharding to specify used shard keys
5746        #[prost(message, optional, tag = "3")]
5747        pub shard_key_selector: ::core::option::Option<super::ShardKeySelector>,
5748    }
5749    #[derive(Clone, PartialEq, ::prost::Message)]
5750    pub struct UpdateVectors {
5751        /// List of points and vectors to update
5752        #[prost(message, repeated, tag = "1")]
5753        pub points: ::prost::alloc::vec::Vec<super::PointVectors>,
5754        /// Option for custom sharding to specify used shard keys
5755        #[prost(message, optional, tag = "2")]
5756        pub shard_key_selector: ::core::option::Option<super::ShardKeySelector>,
5757        /// If specified, only points that match this filter will be updated
5758        #[prost(message, optional, tag = "3")]
5759        pub update_filter: ::core::option::Option<super::Filter>,
5760    }
5761    #[derive(Clone, PartialEq, ::prost::Message)]
5762    pub struct DeleteVectors {
5763        /// Affected points
5764        #[prost(message, optional, tag = "1")]
5765        pub points_selector: ::core::option::Option<super::PointsSelector>,
5766        /// List of vector names to delete
5767        #[prost(message, optional, tag = "2")]
5768        pub vectors: ::core::option::Option<super::VectorsSelector>,
5769        /// Option for custom sharding to specify used shard keys
5770        #[prost(message, optional, tag = "3")]
5771        pub shard_key_selector: ::core::option::Option<super::ShardKeySelector>,
5772    }
5773    #[derive(Clone, PartialEq, ::prost::Message)]
5774    pub struct DeletePoints {
5775        /// Affected points
5776        #[prost(message, optional, tag = "1")]
5777        pub points: ::core::option::Option<super::PointsSelector>,
5778        /// Option for custom sharding to specify used shard keys
5779        #[prost(message, optional, tag = "2")]
5780        pub shard_key_selector: ::core::option::Option<super::ShardKeySelector>,
5781    }
5782    #[derive(Clone, PartialEq, ::prost::Message)]
5783    pub struct ClearPayload {
5784        /// Affected points
5785        #[prost(message, optional, tag = "1")]
5786        pub points: ::core::option::Option<super::PointsSelector>,
5787        /// Option for custom sharding to specify used shard keys
5788        #[prost(message, optional, tag = "2")]
5789        pub shard_key_selector: ::core::option::Option<super::ShardKeySelector>,
5790    }
5791    #[derive(Clone, PartialEq, ::prost::Oneof)]
5792    pub enum Operation {
5793        #[prost(message, tag = "1")]
5794        Upsert(PointStructList),
5795        #[deprecated]
5796        #[prost(message, tag = "2")]
5797        DeleteDeprecated(super::PointsSelector),
5798        #[prost(message, tag = "3")]
5799        SetPayload(SetPayload),
5800        #[prost(message, tag = "4")]
5801        OverwritePayload(OverwritePayload),
5802        #[prost(message, tag = "5")]
5803        DeletePayload(DeletePayload),
5804        #[deprecated]
5805        #[prost(message, tag = "6")]
5806        ClearPayloadDeprecated(super::PointsSelector),
5807        #[prost(message, tag = "7")]
5808        UpdateVectors(UpdateVectors),
5809        #[prost(message, tag = "8")]
5810        DeleteVectors(DeleteVectors),
5811        #[prost(message, tag = "9")]
5812        DeletePoints(DeletePoints),
5813        #[prost(message, tag = "10")]
5814        ClearPayload(ClearPayload),
5815    }
5816}
5817#[derive(Clone, PartialEq, ::prost::Message)]
5818pub struct UpdateBatchPoints {
5819    /// name of the collection
5820    #[prost(string, tag = "1")]
5821    pub collection_name: ::prost::alloc::string::String,
5822    /// Wait until the changes have been applied?
5823    #[prost(bool, optional, tag = "2")]
5824    pub wait: ::core::option::Option<bool>,
5825    #[prost(message, repeated, tag = "3")]
5826    pub operations: ::prost::alloc::vec::Vec<PointsUpdateOperation>,
5827    /// Write ordering guarantees
5828    #[prost(message, optional, tag = "4")]
5829    pub ordering: ::core::option::Option<WriteOrdering>,
5830    /// Timeout for the operation in seconds
5831    #[prost(uint64, optional, tag = "5")]
5832    pub timeout: ::core::option::Option<u64>,
5833}
5834#[derive(Clone, PartialEq, ::prost::Message)]
5835pub struct PointsOperationResponse {
5836    #[prost(message, optional, tag = "1")]
5837    pub result: ::core::option::Option<UpdateResult>,
5838    /// Time spent to process
5839    #[prost(double, tag = "2")]
5840    pub time: f64,
5841    #[prost(message, optional, tag = "3")]
5842    pub usage: ::core::option::Option<Usage>,
5843}
5844#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
5845pub struct UpdateResult {
5846    /// Number of operation
5847    #[prost(uint64, optional, tag = "1")]
5848    pub operation_id: ::core::option::Option<u64>,
5849    /// Operation status
5850    #[prost(enumeration = "UpdateStatus", tag = "2")]
5851    pub status: i32,
5852}
5853#[derive(Clone, Copy, PartialEq, ::prost::Message)]
5854pub struct OrderValue {
5855    #[prost(oneof = "order_value::Variant", tags = "1, 2")]
5856    pub variant: ::core::option::Option<order_value::Variant>,
5857}
5858/// Nested message and enum types in `OrderValue`.
5859pub mod order_value {
5860    #[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
5861    pub enum Variant {
5862        #[prost(int64, tag = "1")]
5863        Int(i64),
5864        #[prost(double, tag = "2")]
5865        Float(f64),
5866    }
5867}
5868#[derive(Clone, PartialEq, ::prost::Message)]
5869pub struct ScoredPoint {
5870    /// Point id
5871    #[prost(message, optional, tag = "1")]
5872    pub id: ::core::option::Option<PointId>,
5873    /// Payload
5874    #[prost(map = "string, message", tag = "2")]
5875    pub payload: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
5876    /// Similarity score
5877    #[prost(float, tag = "3")]
5878    pub score: f32,
5879    /// Last update operation applied to this point
5880    #[prost(uint64, tag = "5")]
5881    pub version: u64,
5882    /// Vectors to search
5883    #[prost(message, optional, tag = "6")]
5884    pub vectors: ::core::option::Option<VectorsOutput>,
5885    /// Shard key
5886    #[prost(message, optional, tag = "7")]
5887    pub shard_key: ::core::option::Option<ShardKey>,
5888    /// Order by value
5889    #[prost(message, optional, tag = "8")]
5890    pub order_value: ::core::option::Option<OrderValue>,
5891}
5892#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5893pub struct GroupId {
5894    #[prost(oneof = "group_id::Kind", tags = "1, 2, 3")]
5895    pub kind: ::core::option::Option<group_id::Kind>,
5896}
5897/// Nested message and enum types in `GroupId`.
5898pub mod group_id {
5899    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
5900    pub enum Kind {
5901        /// Represents an unsigned integer value.
5902        #[prost(uint64, tag = "1")]
5903        UnsignedValue(u64),
5904        /// Represents an integer value
5905        #[prost(int64, tag = "2")]
5906        IntegerValue(i64),
5907        /// Represents a string value.
5908        #[prost(string, tag = "3")]
5909        StringValue(::prost::alloc::string::String),
5910    }
5911}
5912#[derive(Clone, PartialEq, ::prost::Message)]
5913pub struct PointGroup {
5914    /// Group id
5915    #[prost(message, optional, tag = "1")]
5916    pub id: ::core::option::Option<GroupId>,
5917    /// Points in the group
5918    #[prost(message, repeated, tag = "2")]
5919    pub hits: ::prost::alloc::vec::Vec<ScoredPoint>,
5920    /// Point(s) from the lookup collection that matches the group id
5921    #[prost(message, optional, tag = "3")]
5922    pub lookup: ::core::option::Option<RetrievedPoint>,
5923}
5924#[derive(Clone, PartialEq, ::prost::Message)]
5925pub struct GroupsResult {
5926    /// Groups
5927    #[prost(message, repeated, tag = "1")]
5928    pub groups: ::prost::alloc::vec::Vec<PointGroup>,
5929}
5930#[derive(Clone, PartialEq, ::prost::Message)]
5931pub struct SearchResponse {
5932    #[prost(message, repeated, tag = "1")]
5933    pub result: ::prost::alloc::vec::Vec<ScoredPoint>,
5934    /// Time spent to process
5935    #[prost(double, tag = "2")]
5936    pub time: f64,
5937    #[prost(message, optional, tag = "3")]
5938    pub usage: ::core::option::Option<Usage>,
5939}
5940#[derive(Clone, PartialEq, ::prost::Message)]
5941pub struct QueryResponse {
5942    #[prost(message, repeated, tag = "1")]
5943    pub result: ::prost::alloc::vec::Vec<ScoredPoint>,
5944    /// Time spent to process
5945    #[prost(double, tag = "2")]
5946    pub time: f64,
5947    #[prost(message, optional, tag = "3")]
5948    pub usage: ::core::option::Option<Usage>,
5949}
5950#[derive(Clone, PartialEq, ::prost::Message)]
5951pub struct QueryBatchResponse {
5952    #[prost(message, repeated, tag = "1")]
5953    pub result: ::prost::alloc::vec::Vec<BatchResult>,
5954    /// Time spent to process
5955    #[prost(double, tag = "2")]
5956    pub time: f64,
5957    #[prost(message, optional, tag = "3")]
5958    pub usage: ::core::option::Option<Usage>,
5959}
5960#[derive(Clone, PartialEq, ::prost::Message)]
5961pub struct QueryGroupsResponse {
5962    #[prost(message, optional, tag = "1")]
5963    pub result: ::core::option::Option<GroupsResult>,
5964    /// Time spent to process
5965    #[prost(double, tag = "2")]
5966    pub time: f64,
5967    #[prost(message, optional, tag = "3")]
5968    pub usage: ::core::option::Option<Usage>,
5969}
5970#[derive(Clone, PartialEq, ::prost::Message)]
5971pub struct BatchResult {
5972    #[prost(message, repeated, tag = "1")]
5973    pub result: ::prost::alloc::vec::Vec<ScoredPoint>,
5974}
5975#[derive(Clone, PartialEq, ::prost::Message)]
5976pub struct SearchBatchResponse {
5977    #[prost(message, repeated, tag = "1")]
5978    pub result: ::prost::alloc::vec::Vec<BatchResult>,
5979    /// Time spent to process
5980    #[prost(double, tag = "2")]
5981    pub time: f64,
5982    #[prost(message, optional, tag = "3")]
5983    pub usage: ::core::option::Option<Usage>,
5984}
5985#[derive(Clone, PartialEq, ::prost::Message)]
5986pub struct SearchGroupsResponse {
5987    #[prost(message, optional, tag = "1")]
5988    pub result: ::core::option::Option<GroupsResult>,
5989    /// Time spent to process
5990    #[prost(double, tag = "2")]
5991    pub time: f64,
5992    #[prost(message, optional, tag = "3")]
5993    pub usage: ::core::option::Option<Usage>,
5994}
5995#[derive(Clone, PartialEq, ::prost::Message)]
5996pub struct CountResponse {
5997    #[prost(message, optional, tag = "1")]
5998    pub result: ::core::option::Option<CountResult>,
5999    /// Time spent to process
6000    #[prost(double, tag = "2")]
6001    pub time: f64,
6002    #[prost(message, optional, tag = "3")]
6003    pub usage: ::core::option::Option<Usage>,
6004}
6005#[derive(Clone, PartialEq, ::prost::Message)]
6006pub struct ScrollResponse {
6007    /// Use this offset for the next query
6008    #[prost(message, optional, tag = "1")]
6009    pub next_page_offset: ::core::option::Option<PointId>,
6010    #[prost(message, repeated, tag = "2")]
6011    pub result: ::prost::alloc::vec::Vec<RetrievedPoint>,
6012    /// Time spent to process
6013    #[prost(double, tag = "3")]
6014    pub time: f64,
6015    #[prost(message, optional, tag = "4")]
6016    pub usage: ::core::option::Option<Usage>,
6017}
6018#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
6019pub struct CountResult {
6020    #[prost(uint64, tag = "1")]
6021    pub count: u64,
6022}
6023#[derive(Clone, PartialEq, ::prost::Message)]
6024pub struct RetrievedPoint {
6025    #[prost(message, optional, tag = "1")]
6026    pub id: ::core::option::Option<PointId>,
6027    #[prost(map = "string, message", tag = "2")]
6028    pub payload: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
6029    #[prost(message, optional, tag = "4")]
6030    pub vectors: ::core::option::Option<VectorsOutput>,
6031    /// Shard key
6032    #[prost(message, optional, tag = "5")]
6033    pub shard_key: ::core::option::Option<ShardKey>,
6034    /// Order-by value
6035    #[prost(message, optional, tag = "6")]
6036    pub order_value: ::core::option::Option<OrderValue>,
6037}
6038#[derive(Clone, PartialEq, ::prost::Message)]
6039pub struct GetResponse {
6040    #[prost(message, repeated, tag = "1")]
6041    pub result: ::prost::alloc::vec::Vec<RetrievedPoint>,
6042    /// Time spent to process
6043    #[prost(double, tag = "2")]
6044    pub time: f64,
6045    #[prost(message, optional, tag = "3")]
6046    pub usage: ::core::option::Option<Usage>,
6047}
6048#[derive(Clone, PartialEq, ::prost::Message)]
6049pub struct RecommendResponse {
6050    #[prost(message, repeated, tag = "1")]
6051    pub result: ::prost::alloc::vec::Vec<ScoredPoint>,
6052    /// Time spent to process
6053    #[prost(double, tag = "2")]
6054    pub time: f64,
6055    #[prost(message, optional, tag = "3")]
6056    pub usage: ::core::option::Option<Usage>,
6057}
6058#[derive(Clone, PartialEq, ::prost::Message)]
6059pub struct RecommendBatchResponse {
6060    #[prost(message, repeated, tag = "1")]
6061    pub result: ::prost::alloc::vec::Vec<BatchResult>,
6062    /// Time spent to process
6063    #[prost(double, tag = "2")]
6064    pub time: f64,
6065    #[prost(message, optional, tag = "3")]
6066    pub usage: ::core::option::Option<Usage>,
6067}
6068#[derive(Clone, PartialEq, ::prost::Message)]
6069pub struct DiscoverResponse {
6070    #[prost(message, repeated, tag = "1")]
6071    pub result: ::prost::alloc::vec::Vec<ScoredPoint>,
6072    /// Time spent to process
6073    #[prost(double, tag = "2")]
6074    pub time: f64,
6075    #[prost(message, optional, tag = "3")]
6076    pub usage: ::core::option::Option<Usage>,
6077}
6078#[derive(Clone, PartialEq, ::prost::Message)]
6079pub struct DiscoverBatchResponse {
6080    #[prost(message, repeated, tag = "1")]
6081    pub result: ::prost::alloc::vec::Vec<BatchResult>,
6082    /// Time spent to process
6083    #[prost(double, tag = "2")]
6084    pub time: f64,
6085    #[prost(message, optional, tag = "3")]
6086    pub usage: ::core::option::Option<Usage>,
6087}
6088#[derive(Clone, PartialEq, ::prost::Message)]
6089pub struct RecommendGroupsResponse {
6090    #[prost(message, optional, tag = "1")]
6091    pub result: ::core::option::Option<GroupsResult>,
6092    /// Time spent to process
6093    #[prost(double, tag = "2")]
6094    pub time: f64,
6095    #[prost(message, optional, tag = "3")]
6096    pub usage: ::core::option::Option<Usage>,
6097}
6098#[derive(Clone, PartialEq, ::prost::Message)]
6099pub struct UpdateBatchResponse {
6100    #[prost(message, repeated, tag = "1")]
6101    pub result: ::prost::alloc::vec::Vec<UpdateResult>,
6102    /// Time spent to process
6103    #[prost(double, tag = "2")]
6104    pub time: f64,
6105    #[prost(message, optional, tag = "3")]
6106    pub usage: ::core::option::Option<Usage>,
6107}
6108#[derive(Clone, PartialEq, ::prost::Message)]
6109pub struct FacetResponse {
6110    #[prost(message, repeated, tag = "1")]
6111    pub hits: ::prost::alloc::vec::Vec<FacetHit>,
6112    /// Time spent to process
6113    #[prost(double, tag = "2")]
6114    pub time: f64,
6115    #[prost(message, optional, tag = "3")]
6116    pub usage: ::core::option::Option<Usage>,
6117}
6118#[derive(Clone, PartialEq, ::prost::Message)]
6119pub struct SearchMatrixPairsResponse {
6120    #[prost(message, optional, tag = "1")]
6121    pub result: ::core::option::Option<SearchMatrixPairs>,
6122    /// Time spent to process
6123    #[prost(double, tag = "2")]
6124    pub time: f64,
6125    #[prost(message, optional, tag = "3")]
6126    pub usage: ::core::option::Option<Usage>,
6127}
6128#[derive(Clone, PartialEq, ::prost::Message)]
6129pub struct SearchMatrixOffsetsResponse {
6130    #[prost(message, optional, tag = "1")]
6131    pub result: ::core::option::Option<SearchMatrixOffsets>,
6132    /// Time spent to process
6133    #[prost(double, tag = "2")]
6134    pub time: f64,
6135    #[prost(message, optional, tag = "3")]
6136    pub usage: ::core::option::Option<Usage>,
6137}
6138#[derive(Clone, PartialEq, ::prost::Message)]
6139pub struct PointsSelector {
6140    #[prost(oneof = "points_selector::PointsSelectorOneOf", tags = "1, 2")]
6141    pub points_selector_one_of: ::core::option::Option<
6142        points_selector::PointsSelectorOneOf,
6143    >,
6144}
6145/// Nested message and enum types in `PointsSelector`.
6146pub mod points_selector {
6147    #[derive(Clone, PartialEq, ::prost::Oneof)]
6148    pub enum PointsSelectorOneOf {
6149        #[prost(message, tag = "1")]
6150        Points(super::PointsIdsList),
6151        #[prost(message, tag = "2")]
6152        Filter(super::Filter),
6153    }
6154}
6155#[derive(Clone, PartialEq, ::prost::Message)]
6156pub struct PointsIdsList {
6157    #[prost(message, repeated, tag = "1")]
6158    pub ids: ::prost::alloc::vec::Vec<PointId>,
6159}
6160#[derive(Clone, PartialEq, ::prost::Message)]
6161pub struct PointStruct {
6162    #[prost(message, optional, tag = "1")]
6163    pub id: ::core::option::Option<PointId>,
6164    #[prost(map = "string, message", tag = "3")]
6165    pub payload: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
6166    #[prost(message, optional, tag = "4")]
6167    pub vectors: ::core::option::Option<Vectors>,
6168}
6169/// ---
6170///
6171/// ## ----------- Measurements collector ----------
6172#[derive(Clone, PartialEq, ::prost::Message)]
6173pub struct Usage {
6174    #[prost(message, optional, tag = "1")]
6175    pub hardware: ::core::option::Option<HardwareUsage>,
6176    #[prost(message, optional, tag = "2")]
6177    pub inference: ::core::option::Option<InferenceUsage>,
6178}
6179#[derive(Clone, PartialEq, ::prost::Message)]
6180pub struct InferenceUsage {
6181    #[prost(map = "string, message", tag = "1")]
6182    pub models: ::std::collections::HashMap<::prost::alloc::string::String, ModelUsage>,
6183}
6184#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
6185pub struct ModelUsage {
6186    #[prost(uint64, tag = "1")]
6187    pub tokens: u64,
6188}
6189#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
6190pub struct HardwareUsage {
6191    #[prost(uint64, tag = "1")]
6192    pub cpu: u64,
6193    #[prost(uint64, tag = "2")]
6194    pub payload_io_read: u64,
6195    #[prost(uint64, tag = "3")]
6196    pub payload_io_write: u64,
6197    #[prost(uint64, tag = "4")]
6198    pub payload_index_io_read: u64,
6199    #[prost(uint64, tag = "5")]
6200    pub payload_index_io_write: u64,
6201    #[prost(uint64, tag = "6")]
6202    pub vector_io_read: u64,
6203    #[prost(uint64, tag = "7")]
6204    pub vector_io_write: u64,
6205}
6206#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
6207#[repr(i32)]
6208pub enum WriteOrderingType {
6209    /// Write operations may be reordered, works faster, default
6210    Weak = 0,
6211    /// Write operations go through dynamically selected leader,
6212    /// may be inconsistent for a short period of time in case of leader change
6213    Medium = 1,
6214    /// Write operations go through the permanent leader, consistent,
6215    /// but may be unavailable if leader is down
6216    Strong = 2,
6217}
6218impl WriteOrderingType {
6219    /// String value of the enum field names used in the ProtoBuf definition.
6220    ///
6221    /// The values are not transformed in any way and thus are considered stable
6222    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
6223    pub fn as_str_name(&self) -> &'static str {
6224        match self {
6225            Self::Weak => "Weak",
6226            Self::Medium => "Medium",
6227            Self::Strong => "Strong",
6228        }
6229    }
6230    /// Creates an enum from field names used in the ProtoBuf definition.
6231    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6232        match value {
6233            "Weak" => Some(Self::Weak),
6234            "Medium" => Some(Self::Medium),
6235            "Strong" => Some(Self::Strong),
6236            _ => None,
6237        }
6238    }
6239}
6240/// Defines the mode of the upsert operation
6241#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
6242#[repr(i32)]
6243pub enum UpdateMode {
6244    /// Default mode - insert new points, update existing points
6245    Upsert = 0,
6246    /// Only insert new points, do not update existing points
6247    InsertOnly = 1,
6248    /// Only update existing points, do not insert new points
6249    UpdateOnly = 2,
6250}
6251impl UpdateMode {
6252    /// String value of the enum field names used in the ProtoBuf definition.
6253    ///
6254    /// The values are not transformed in any way and thus are considered stable
6255    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
6256    pub fn as_str_name(&self) -> &'static str {
6257        match self {
6258            Self::Upsert => "Upsert",
6259            Self::InsertOnly => "InsertOnly",
6260            Self::UpdateOnly => "UpdateOnly",
6261        }
6262    }
6263    /// Creates an enum from field names used in the ProtoBuf definition.
6264    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6265        match value {
6266            "Upsert" => Some(Self::Upsert),
6267            "InsertOnly" => Some(Self::InsertOnly),
6268            "UpdateOnly" => Some(Self::UpdateOnly),
6269            _ => None,
6270        }
6271    }
6272}
6273#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
6274#[repr(i32)]
6275pub enum ReadConsistencyType {
6276    /// Send request to all nodes and return points which are present on all of them
6277    All = 0,
6278    /// Send requests to all nodes and return points which are present on majority of them
6279    Majority = 1,
6280    /// Send requests to half + 1 nodes, return points which are present on all of them
6281    Quorum = 2,
6282}
6283impl ReadConsistencyType {
6284    /// String value of the enum field names used in the ProtoBuf definition.
6285    ///
6286    /// The values are not transformed in any way and thus are considered stable
6287    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
6288    pub fn as_str_name(&self) -> &'static str {
6289        match self {
6290            Self::All => "All",
6291            Self::Majority => "Majority",
6292            Self::Quorum => "Quorum",
6293        }
6294    }
6295    /// Creates an enum from field names used in the ProtoBuf definition.
6296    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6297        match value {
6298            "All" => Some(Self::All),
6299            "Majority" => Some(Self::Majority),
6300            "Quorum" => Some(Self::Quorum),
6301            _ => None,
6302        }
6303    }
6304}
6305#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
6306#[repr(i32)]
6307pub enum FieldType {
6308    Keyword = 0,
6309    Integer = 1,
6310    Float = 2,
6311    Geo = 3,
6312    Text = 4,
6313    Bool = 5,
6314    Datetime = 6,
6315    Uuid = 7,
6316}
6317impl FieldType {
6318    /// String value of the enum field names used in the ProtoBuf definition.
6319    ///
6320    /// The values are not transformed in any way and thus are considered stable
6321    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
6322    pub fn as_str_name(&self) -> &'static str {
6323        match self {
6324            Self::Keyword => "FieldTypeKeyword",
6325            Self::Integer => "FieldTypeInteger",
6326            Self::Float => "FieldTypeFloat",
6327            Self::Geo => "FieldTypeGeo",
6328            Self::Text => "FieldTypeText",
6329            Self::Bool => "FieldTypeBool",
6330            Self::Datetime => "FieldTypeDatetime",
6331            Self::Uuid => "FieldTypeUuid",
6332        }
6333    }
6334    /// Creates an enum from field names used in the ProtoBuf definition.
6335    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6336        match value {
6337            "FieldTypeKeyword" => Some(Self::Keyword),
6338            "FieldTypeInteger" => Some(Self::Integer),
6339            "FieldTypeFloat" => Some(Self::Float),
6340            "FieldTypeGeo" => Some(Self::Geo),
6341            "FieldTypeText" => Some(Self::Text),
6342            "FieldTypeBool" => Some(Self::Bool),
6343            "FieldTypeDatetime" => Some(Self::Datetime),
6344            "FieldTypeUuid" => Some(Self::Uuid),
6345            _ => None,
6346        }
6347    }
6348}
6349#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
6350#[repr(i32)]
6351pub enum Direction {
6352    Asc = 0,
6353    Desc = 1,
6354}
6355impl Direction {
6356    /// String value of the enum field names used in the ProtoBuf definition.
6357    ///
6358    /// The values are not transformed in any way and thus are considered stable
6359    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
6360    pub fn as_str_name(&self) -> &'static str {
6361        match self {
6362            Self::Asc => "Asc",
6363            Self::Desc => "Desc",
6364        }
6365    }
6366    /// Creates an enum from field names used in the ProtoBuf definition.
6367    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6368        match value {
6369            "Asc" => Some(Self::Asc),
6370            "Desc" => Some(Self::Desc),
6371            _ => None,
6372        }
6373    }
6374}
6375/// How to use positive and negative vectors to find the results, default is `AverageVector`.
6376#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
6377#[repr(i32)]
6378pub enum RecommendStrategy {
6379    /// Average positive and negative vectors and create a single query with the formula
6380    /// `query = avg_pos + avg_pos - avg_neg`. Then performs normal search.
6381    AverageVector = 0,
6382    /// Uses custom search objective. Each candidate is compared against all
6383    /// examples, its score is then chosen from the `max(max_pos_score, max_neg_score)`.
6384    /// If the `max_neg_score` is chosen then it is squared and negated.
6385    BestScore = 1,
6386    /// Uses custom search objective. Compares against all inputs, sums all the scores.
6387    /// Scores against positive vectors are added, against negatives are subtracted.
6388    SumScores = 2,
6389}
6390impl RecommendStrategy {
6391    /// String value of the enum field names used in the ProtoBuf definition.
6392    ///
6393    /// The values are not transformed in any way and thus are considered stable
6394    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
6395    pub fn as_str_name(&self) -> &'static str {
6396        match self {
6397            Self::AverageVector => "AverageVector",
6398            Self::BestScore => "BestScore",
6399            Self::SumScores => "SumScores",
6400        }
6401    }
6402    /// Creates an enum from field names used in the ProtoBuf definition.
6403    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6404        match value {
6405            "AverageVector" => Some(Self::AverageVector),
6406            "BestScore" => Some(Self::BestScore),
6407            "SumScores" => Some(Self::SumScores),
6408            _ => None,
6409        }
6410    }
6411}
6412#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
6413#[repr(i32)]
6414pub enum Fusion {
6415    /// Reciprocal Rank Fusion (with default parameters)
6416    Rrf = 0,
6417    /// Distribution-Based Score Fusion
6418    Dbsf = 1,
6419}
6420impl Fusion {
6421    /// String value of the enum field names used in the ProtoBuf definition.
6422    ///
6423    /// The values are not transformed in any way and thus are considered stable
6424    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
6425    pub fn as_str_name(&self) -> &'static str {
6426        match self {
6427            Self::Rrf => "RRF",
6428            Self::Dbsf => "DBSF",
6429        }
6430    }
6431    /// Creates an enum from field names used in the ProtoBuf definition.
6432    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6433        match value {
6434            "RRF" => Some(Self::Rrf),
6435            "DBSF" => Some(Self::Dbsf),
6436            _ => None,
6437        }
6438    }
6439}
6440/// Sample points from the collection
6441///
6442/// Available sampling methods:
6443///
6444/// * `random` - Random sampling
6445#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
6446#[repr(i32)]
6447pub enum Sample {
6448    Random = 0,
6449}
6450impl Sample {
6451    /// String value of the enum field names used in the ProtoBuf definition.
6452    ///
6453    /// The values are not transformed in any way and thus are considered stable
6454    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
6455    pub fn as_str_name(&self) -> &'static str {
6456        match self {
6457            Self::Random => "Random",
6458        }
6459    }
6460    /// Creates an enum from field names used in the ProtoBuf definition.
6461    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6462        match value {
6463            "Random" => Some(Self::Random),
6464            _ => None,
6465        }
6466    }
6467}
6468#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
6469#[repr(i32)]
6470pub enum UpdateStatus {
6471    UnknownUpdateStatus = 0,
6472    /// Update is received, but not processed yet
6473    Acknowledged = 1,
6474    /// Update is applied and ready for search
6475    Completed = 2,
6476    /// Internal: update is rejected due to an outdated clock
6477    ClockRejected = 3,
6478    /// Timeout of awaited operations
6479    WaitTimeout = 4,
6480}
6481impl UpdateStatus {
6482    /// String value of the enum field names used in the ProtoBuf definition.
6483    ///
6484    /// The values are not transformed in any way and thus are considered stable
6485    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
6486    pub fn as_str_name(&self) -> &'static str {
6487        match self {
6488            Self::UnknownUpdateStatus => "UnknownUpdateStatus",
6489            Self::Acknowledged => "Acknowledged",
6490            Self::Completed => "Completed",
6491            Self::ClockRejected => "ClockRejected",
6492            Self::WaitTimeout => "WaitTimeout",
6493        }
6494    }
6495    /// Creates an enum from field names used in the ProtoBuf definition.
6496    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6497        match value {
6498            "UnknownUpdateStatus" => Some(Self::UnknownUpdateStatus),
6499            "Acknowledged" => Some(Self::Acknowledged),
6500            "Completed" => Some(Self::Completed),
6501            "ClockRejected" => Some(Self::ClockRejected),
6502            "WaitTimeout" => Some(Self::WaitTimeout),
6503            _ => None,
6504        }
6505    }
6506}
6507/// Generated client implementations.
6508pub mod points_client {
6509    #![allow(
6510        unused_variables,
6511        dead_code,
6512        missing_docs,
6513        clippy::wildcard_imports,
6514        clippy::let_unit_value,
6515    )]
6516    use tonic::codegen::*;
6517    use tonic::codegen::http::Uri;
6518    #[derive(Debug, Clone)]
6519    pub struct PointsClient<T> {
6520        inner: tonic::client::Grpc<T>,
6521    }
6522    impl PointsClient<tonic::transport::Channel> {
6523        /// Attempt to create a new client by connecting to a given endpoint.
6524        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
6525        where
6526            D: TryInto<tonic::transport::Endpoint>,
6527            D::Error: Into<StdError>,
6528        {
6529            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
6530            Ok(Self::new(conn))
6531        }
6532    }
6533    impl<T> PointsClient<T>
6534    where
6535        T: tonic::client::GrpcService<tonic::body::Body>,
6536        T::Error: Into<StdError>,
6537        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
6538        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
6539    {
6540        pub fn new(inner: T) -> Self {
6541            let inner = tonic::client::Grpc::new(inner);
6542            Self { inner }
6543        }
6544        pub fn with_origin(inner: T, origin: Uri) -> Self {
6545            let inner = tonic::client::Grpc::with_origin(inner, origin);
6546            Self { inner }
6547        }
6548        pub fn with_interceptor<F>(
6549            inner: T,
6550            interceptor: F,
6551        ) -> PointsClient<InterceptedService<T, F>>
6552        where
6553            F: tonic::service::Interceptor,
6554            T::ResponseBody: Default,
6555            T: tonic::codegen::Service<
6556                http::Request<tonic::body::Body>,
6557                Response = http::Response<
6558                    <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
6559                >,
6560            >,
6561            <T as tonic::codegen::Service<
6562                http::Request<tonic::body::Body>,
6563            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
6564        {
6565            PointsClient::new(InterceptedService::new(inner, interceptor))
6566        }
6567        /// Compress requests with the given encoding.
6568        ///
6569        /// This requires the server to support it otherwise it might respond with an
6570        /// error.
6571        #[must_use]
6572        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
6573            self.inner = self.inner.send_compressed(encoding);
6574            self
6575        }
6576        /// Enable decompressing responses.
6577        #[must_use]
6578        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
6579            self.inner = self.inner.accept_compressed(encoding);
6580            self
6581        }
6582        /// Limits the maximum size of a decoded message.
6583        ///
6584        /// Default: `4MB`
6585        #[must_use]
6586        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
6587            self.inner = self.inner.max_decoding_message_size(limit);
6588            self
6589        }
6590        /// Limits the maximum size of an encoded message.
6591        ///
6592        /// Default: `usize::MAX`
6593        #[must_use]
6594        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
6595            self.inner = self.inner.max_encoding_message_size(limit);
6596            self
6597        }
6598        /// Perform insert + updates on points.
6599        /// If a point with a given ID already exists - it will be overwritten.
6600        pub async fn upsert(
6601            &mut self,
6602            request: impl tonic::IntoRequest<super::UpsertPoints>,
6603        ) -> std::result::Result<
6604            tonic::Response<super::PointsOperationResponse>,
6605            tonic::Status,
6606        > {
6607            self.inner
6608                .ready()
6609                .await
6610                .map_err(|e| {
6611                    tonic::Status::unknown(
6612                        format!("Service was not ready: {}", e.into()),
6613                    )
6614                })?;
6615            let codec = tonic_prost::ProstCodec::default();
6616            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/Upsert");
6617            let mut req = request.into_request();
6618            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "Upsert"));
6619            self.inner.unary(req, path, codec).await
6620        }
6621        /// Delete points
6622        pub async fn delete(
6623            &mut self,
6624            request: impl tonic::IntoRequest<super::DeletePoints>,
6625        ) -> std::result::Result<
6626            tonic::Response<super::PointsOperationResponse>,
6627            tonic::Status,
6628        > {
6629            self.inner
6630                .ready()
6631                .await
6632                .map_err(|e| {
6633                    tonic::Status::unknown(
6634                        format!("Service was not ready: {}", e.into()),
6635                    )
6636                })?;
6637            let codec = tonic_prost::ProstCodec::default();
6638            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/Delete");
6639            let mut req = request.into_request();
6640            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "Delete"));
6641            self.inner.unary(req, path, codec).await
6642        }
6643        /// Retrieve points
6644        pub async fn get(
6645            &mut self,
6646            request: impl tonic::IntoRequest<super::GetPoints>,
6647        ) -> std::result::Result<tonic::Response<super::GetResponse>, tonic::Status> {
6648            self.inner
6649                .ready()
6650                .await
6651                .map_err(|e| {
6652                    tonic::Status::unknown(
6653                        format!("Service was not ready: {}", e.into()),
6654                    )
6655                })?;
6656            let codec = tonic_prost::ProstCodec::default();
6657            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/Get");
6658            let mut req = request.into_request();
6659            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "Get"));
6660            self.inner.unary(req, path, codec).await
6661        }
6662        /// Update named vectors for point
6663        pub async fn update_vectors(
6664            &mut self,
6665            request: impl tonic::IntoRequest<super::UpdatePointVectors>,
6666        ) -> std::result::Result<
6667            tonic::Response<super::PointsOperationResponse>,
6668            tonic::Status,
6669        > {
6670            self.inner
6671                .ready()
6672                .await
6673                .map_err(|e| {
6674                    tonic::Status::unknown(
6675                        format!("Service was not ready: {}", e.into()),
6676                    )
6677                })?;
6678            let codec = tonic_prost::ProstCodec::default();
6679            let path = http::uri::PathAndQuery::from_static(
6680                "/qdrant.Points/UpdateVectors",
6681            );
6682            let mut req = request.into_request();
6683            req.extensions_mut()
6684                .insert(GrpcMethod::new("qdrant.Points", "UpdateVectors"));
6685            self.inner.unary(req, path, codec).await
6686        }
6687        /// Delete named vectors for points
6688        pub async fn delete_vectors(
6689            &mut self,
6690            request: impl tonic::IntoRequest<super::DeletePointVectors>,
6691        ) -> std::result::Result<
6692            tonic::Response<super::PointsOperationResponse>,
6693            tonic::Status,
6694        > {
6695            self.inner
6696                .ready()
6697                .await
6698                .map_err(|e| {
6699                    tonic::Status::unknown(
6700                        format!("Service was not ready: {}", e.into()),
6701                    )
6702                })?;
6703            let codec = tonic_prost::ProstCodec::default();
6704            let path = http::uri::PathAndQuery::from_static(
6705                "/qdrant.Points/DeleteVectors",
6706            );
6707            let mut req = request.into_request();
6708            req.extensions_mut()
6709                .insert(GrpcMethod::new("qdrant.Points", "DeleteVectors"));
6710            self.inner.unary(req, path, codec).await
6711        }
6712        /// Set payload for points
6713        pub async fn set_payload(
6714            &mut self,
6715            request: impl tonic::IntoRequest<super::SetPayloadPoints>,
6716        ) -> std::result::Result<
6717            tonic::Response<super::PointsOperationResponse>,
6718            tonic::Status,
6719        > {
6720            self.inner
6721                .ready()
6722                .await
6723                .map_err(|e| {
6724                    tonic::Status::unknown(
6725                        format!("Service was not ready: {}", e.into()),
6726                    )
6727                })?;
6728            let codec = tonic_prost::ProstCodec::default();
6729            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/SetPayload");
6730            let mut req = request.into_request();
6731            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "SetPayload"));
6732            self.inner.unary(req, path, codec).await
6733        }
6734        /// Overwrite payload for points
6735        pub async fn overwrite_payload(
6736            &mut self,
6737            request: impl tonic::IntoRequest<super::SetPayloadPoints>,
6738        ) -> std::result::Result<
6739            tonic::Response<super::PointsOperationResponse>,
6740            tonic::Status,
6741        > {
6742            self.inner
6743                .ready()
6744                .await
6745                .map_err(|e| {
6746                    tonic::Status::unknown(
6747                        format!("Service was not ready: {}", e.into()),
6748                    )
6749                })?;
6750            let codec = tonic_prost::ProstCodec::default();
6751            let path = http::uri::PathAndQuery::from_static(
6752                "/qdrant.Points/OverwritePayload",
6753            );
6754            let mut req = request.into_request();
6755            req.extensions_mut()
6756                .insert(GrpcMethod::new("qdrant.Points", "OverwritePayload"));
6757            self.inner.unary(req, path, codec).await
6758        }
6759        /// Delete specified key payload for points
6760        pub async fn delete_payload(
6761            &mut self,
6762            request: impl tonic::IntoRequest<super::DeletePayloadPoints>,
6763        ) -> std::result::Result<
6764            tonic::Response<super::PointsOperationResponse>,
6765            tonic::Status,
6766        > {
6767            self.inner
6768                .ready()
6769                .await
6770                .map_err(|e| {
6771                    tonic::Status::unknown(
6772                        format!("Service was not ready: {}", e.into()),
6773                    )
6774                })?;
6775            let codec = tonic_prost::ProstCodec::default();
6776            let path = http::uri::PathAndQuery::from_static(
6777                "/qdrant.Points/DeletePayload",
6778            );
6779            let mut req = request.into_request();
6780            req.extensions_mut()
6781                .insert(GrpcMethod::new("qdrant.Points", "DeletePayload"));
6782            self.inner.unary(req, path, codec).await
6783        }
6784        /// Remove all payload for specified points
6785        pub async fn clear_payload(
6786            &mut self,
6787            request: impl tonic::IntoRequest<super::ClearPayloadPoints>,
6788        ) -> std::result::Result<
6789            tonic::Response<super::PointsOperationResponse>,
6790            tonic::Status,
6791        > {
6792            self.inner
6793                .ready()
6794                .await
6795                .map_err(|e| {
6796                    tonic::Status::unknown(
6797                        format!("Service was not ready: {}", e.into()),
6798                    )
6799                })?;
6800            let codec = tonic_prost::ProstCodec::default();
6801            let path = http::uri::PathAndQuery::from_static(
6802                "/qdrant.Points/ClearPayload",
6803            );
6804            let mut req = request.into_request();
6805            req.extensions_mut()
6806                .insert(GrpcMethod::new("qdrant.Points", "ClearPayload"));
6807            self.inner.unary(req, path, codec).await
6808        }
6809        /// Create index for field in collection
6810        pub async fn create_field_index(
6811            &mut self,
6812            request: impl tonic::IntoRequest<super::CreateFieldIndexCollection>,
6813        ) -> std::result::Result<
6814            tonic::Response<super::PointsOperationResponse>,
6815            tonic::Status,
6816        > {
6817            self.inner
6818                .ready()
6819                .await
6820                .map_err(|e| {
6821                    tonic::Status::unknown(
6822                        format!("Service was not ready: {}", e.into()),
6823                    )
6824                })?;
6825            let codec = tonic_prost::ProstCodec::default();
6826            let path = http::uri::PathAndQuery::from_static(
6827                "/qdrant.Points/CreateFieldIndex",
6828            );
6829            let mut req = request.into_request();
6830            req.extensions_mut()
6831                .insert(GrpcMethod::new("qdrant.Points", "CreateFieldIndex"));
6832            self.inner.unary(req, path, codec).await
6833        }
6834        /// Delete field index for collection
6835        pub async fn delete_field_index(
6836            &mut self,
6837            request: impl tonic::IntoRequest<super::DeleteFieldIndexCollection>,
6838        ) -> std::result::Result<
6839            tonic::Response<super::PointsOperationResponse>,
6840            tonic::Status,
6841        > {
6842            self.inner
6843                .ready()
6844                .await
6845                .map_err(|e| {
6846                    tonic::Status::unknown(
6847                        format!("Service was not ready: {}", e.into()),
6848                    )
6849                })?;
6850            let codec = tonic_prost::ProstCodec::default();
6851            let path = http::uri::PathAndQuery::from_static(
6852                "/qdrant.Points/DeleteFieldIndex",
6853            );
6854            let mut req = request.into_request();
6855            req.extensions_mut()
6856                .insert(GrpcMethod::new("qdrant.Points", "DeleteFieldIndex"));
6857            self.inner.unary(req, path, codec).await
6858        }
6859        /// Create a new named vector on the collection
6860        pub async fn create_vector_name(
6861            &mut self,
6862            request: impl tonic::IntoRequest<super::CreateVectorNameRequest>,
6863        ) -> std::result::Result<
6864            tonic::Response<super::PointsOperationResponse>,
6865            tonic::Status,
6866        > {
6867            self.inner
6868                .ready()
6869                .await
6870                .map_err(|e| {
6871                    tonic::Status::unknown(
6872                        format!("Service was not ready: {}", e.into()),
6873                    )
6874                })?;
6875            let codec = tonic_prost::ProstCodec::default();
6876            let path = http::uri::PathAndQuery::from_static(
6877                "/qdrant.Points/CreateVectorName",
6878            );
6879            let mut req = request.into_request();
6880            req.extensions_mut()
6881                .insert(GrpcMethod::new("qdrant.Points", "CreateVectorName"));
6882            self.inner.unary(req, path, codec).await
6883        }
6884        /// Delete a named vector from the collection
6885        pub async fn delete_vector_name(
6886            &mut self,
6887            request: impl tonic::IntoRequest<super::DeleteVectorNameRequest>,
6888        ) -> std::result::Result<
6889            tonic::Response<super::PointsOperationResponse>,
6890            tonic::Status,
6891        > {
6892            self.inner
6893                .ready()
6894                .await
6895                .map_err(|e| {
6896                    tonic::Status::unknown(
6897                        format!("Service was not ready: {}", e.into()),
6898                    )
6899                })?;
6900            let codec = tonic_prost::ProstCodec::default();
6901            let path = http::uri::PathAndQuery::from_static(
6902                "/qdrant.Points/DeleteVectorName",
6903            );
6904            let mut req = request.into_request();
6905            req.extensions_mut()
6906                .insert(GrpcMethod::new("qdrant.Points", "DeleteVectorName"));
6907            self.inner.unary(req, path, codec).await
6908        }
6909        /// Retrieve closest points based on vector similarity and given filtering
6910        /// conditions
6911        ///
6912        /// Deprecated: use `Query` instead.
6913        #[deprecated]
6914        pub async fn search(
6915            &mut self,
6916            request: impl tonic::IntoRequest<super::SearchPoints>,
6917        ) -> std::result::Result<tonic::Response<super::SearchResponse>, tonic::Status> {
6918            self.inner
6919                .ready()
6920                .await
6921                .map_err(|e| {
6922                    tonic::Status::unknown(
6923                        format!("Service was not ready: {}", e.into()),
6924                    )
6925                })?;
6926            let codec = tonic_prost::ProstCodec::default();
6927            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/Search");
6928            let mut req = request.into_request();
6929            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "Search"));
6930            self.inner.unary(req, path, codec).await
6931        }
6932        /// Retrieve closest points based on vector similarity and given filtering
6933        /// conditions
6934        ///
6935        /// Deprecated: use `QueryBatch` instead.
6936        #[deprecated]
6937        pub async fn search_batch(
6938            &mut self,
6939            request: impl tonic::IntoRequest<super::SearchBatchPoints>,
6940        ) -> std::result::Result<
6941            tonic::Response<super::SearchBatchResponse>,
6942            tonic::Status,
6943        > {
6944            self.inner
6945                .ready()
6946                .await
6947                .map_err(|e| {
6948                    tonic::Status::unknown(
6949                        format!("Service was not ready: {}", e.into()),
6950                    )
6951                })?;
6952            let codec = tonic_prost::ProstCodec::default();
6953            let path = http::uri::PathAndQuery::from_static(
6954                "/qdrant.Points/SearchBatch",
6955            );
6956            let mut req = request.into_request();
6957            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "SearchBatch"));
6958            self.inner.unary(req, path, codec).await
6959        }
6960        /// Retrieve closest points based on vector similarity and given filtering
6961        /// conditions, grouped by a given field
6962        ///
6963        /// Deprecated: use `QueryGroups` instead.
6964        #[deprecated]
6965        pub async fn search_groups(
6966            &mut self,
6967            request: impl tonic::IntoRequest<super::SearchPointGroups>,
6968        ) -> std::result::Result<
6969            tonic::Response<super::SearchGroupsResponse>,
6970            tonic::Status,
6971        > {
6972            self.inner
6973                .ready()
6974                .await
6975                .map_err(|e| {
6976                    tonic::Status::unknown(
6977                        format!("Service was not ready: {}", e.into()),
6978                    )
6979                })?;
6980            let codec = tonic_prost::ProstCodec::default();
6981            let path = http::uri::PathAndQuery::from_static(
6982                "/qdrant.Points/SearchGroups",
6983            );
6984            let mut req = request.into_request();
6985            req.extensions_mut()
6986                .insert(GrpcMethod::new("qdrant.Points", "SearchGroups"));
6987            self.inner.unary(req, path, codec).await
6988        }
6989        /// Iterate over all or filtered points
6990        pub async fn scroll(
6991            &mut self,
6992            request: impl tonic::IntoRequest<super::ScrollPoints>,
6993        ) -> std::result::Result<tonic::Response<super::ScrollResponse>, tonic::Status> {
6994            self.inner
6995                .ready()
6996                .await
6997                .map_err(|e| {
6998                    tonic::Status::unknown(
6999                        format!("Service was not ready: {}", e.into()),
7000                    )
7001                })?;
7002            let codec = tonic_prost::ProstCodec::default();
7003            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/Scroll");
7004            let mut req = request.into_request();
7005            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "Scroll"));
7006            self.inner.unary(req, path, codec).await
7007        }
7008        /// Look for the points which are closer to stored positive examples and at
7009        /// the same time further to negative examples.
7010        ///
7011        /// Deprecated: use `Query` with a `recommend` query instead.
7012        #[deprecated]
7013        pub async fn recommend(
7014            &mut self,
7015            request: impl tonic::IntoRequest<super::RecommendPoints>,
7016        ) -> std::result::Result<
7017            tonic::Response<super::RecommendResponse>,
7018            tonic::Status,
7019        > {
7020            self.inner
7021                .ready()
7022                .await
7023                .map_err(|e| {
7024                    tonic::Status::unknown(
7025                        format!("Service was not ready: {}", e.into()),
7026                    )
7027                })?;
7028            let codec = tonic_prost::ProstCodec::default();
7029            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/Recommend");
7030            let mut req = request.into_request();
7031            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "Recommend"));
7032            self.inner.unary(req, path, codec).await
7033        }
7034        /// Look for the points which are closer to stored positive examples and at
7035        /// the same time further to negative examples.
7036        ///
7037        /// Deprecated: use `QueryBatch` with `recommend` queries instead.
7038        #[deprecated]
7039        pub async fn recommend_batch(
7040            &mut self,
7041            request: impl tonic::IntoRequest<super::RecommendBatchPoints>,
7042        ) -> std::result::Result<
7043            tonic::Response<super::RecommendBatchResponse>,
7044            tonic::Status,
7045        > {
7046            self.inner
7047                .ready()
7048                .await
7049                .map_err(|e| {
7050                    tonic::Status::unknown(
7051                        format!("Service was not ready: {}", e.into()),
7052                    )
7053                })?;
7054            let codec = tonic_prost::ProstCodec::default();
7055            let path = http::uri::PathAndQuery::from_static(
7056                "/qdrant.Points/RecommendBatch",
7057            );
7058            let mut req = request.into_request();
7059            req.extensions_mut()
7060                .insert(GrpcMethod::new("qdrant.Points", "RecommendBatch"));
7061            self.inner.unary(req, path, codec).await
7062        }
7063        /// Look for the points which are closer to stored positive examples and at
7064        /// the same time further to negative examples, grouped by a given field
7065        ///
7066        /// Deprecated: use `QueryGroups` with a `recommend` query instead.
7067        #[deprecated]
7068        pub async fn recommend_groups(
7069            &mut self,
7070            request: impl tonic::IntoRequest<super::RecommendPointGroups>,
7071        ) -> std::result::Result<
7072            tonic::Response<super::RecommendGroupsResponse>,
7073            tonic::Status,
7074        > {
7075            self.inner
7076                .ready()
7077                .await
7078                .map_err(|e| {
7079                    tonic::Status::unknown(
7080                        format!("Service was not ready: {}", e.into()),
7081                    )
7082                })?;
7083            let codec = tonic_prost::ProstCodec::default();
7084            let path = http::uri::PathAndQuery::from_static(
7085                "/qdrant.Points/RecommendGroups",
7086            );
7087            let mut req = request.into_request();
7088            req.extensions_mut()
7089                .insert(GrpcMethod::new("qdrant.Points", "RecommendGroups"));
7090            self.inner.unary(req, path, codec).await
7091        }
7092        /// Use context and a target to find the most similar points to the target,
7093        /// constrained by the context.
7094        ///
7095        /// When using only the context (without a target), a special search - called
7096        /// context search - is performed where pairs of points are used to generate a
7097        /// loss that guides the search towards the zone where most positive examples
7098        /// overlap. This means that the score minimizes the scenario of finding a
7099        /// point closer to a negative than to a positive part of a pair.
7100        ///
7101        /// Since the score of a context relates to loss, the maximum score a point
7102        /// can get is 0.0, and it becomes normal that many points can have a score of
7103        /// 0.0.
7104        ///
7105        /// When using target (with or without context), the score behaves a little
7106        /// different: The integer part of the score represents the rank with respect
7107        /// to the context, while the decimal part of the score relates to the
7108        /// distance to the target. The context part of the score for each pair is
7109        /// calculated +1 if the point is closer to a positive than to a negative part
7110        /// of a pair, and -1 otherwise.
7111        ///
7112        /// Deprecated: use `Query` with a `discover` or `context` query instead.
7113        #[deprecated]
7114        pub async fn discover(
7115            &mut self,
7116            request: impl tonic::IntoRequest<super::DiscoverPoints>,
7117        ) -> std::result::Result<
7118            tonic::Response<super::DiscoverResponse>,
7119            tonic::Status,
7120        > {
7121            self.inner
7122                .ready()
7123                .await
7124                .map_err(|e| {
7125                    tonic::Status::unknown(
7126                        format!("Service was not ready: {}", e.into()),
7127                    )
7128                })?;
7129            let codec = tonic_prost::ProstCodec::default();
7130            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/Discover");
7131            let mut req = request.into_request();
7132            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "Discover"));
7133            self.inner.unary(req, path, codec).await
7134        }
7135        /// Batch request points based on { positive, negative } pairs of examples, and/or a target
7136        ///
7137        /// Deprecated: use `QueryBatch` with `discover` or `context` queries instead.
7138        #[deprecated]
7139        pub async fn discover_batch(
7140            &mut self,
7141            request: impl tonic::IntoRequest<super::DiscoverBatchPoints>,
7142        ) -> std::result::Result<
7143            tonic::Response<super::DiscoverBatchResponse>,
7144            tonic::Status,
7145        > {
7146            self.inner
7147                .ready()
7148                .await
7149                .map_err(|e| {
7150                    tonic::Status::unknown(
7151                        format!("Service was not ready: {}", e.into()),
7152                    )
7153                })?;
7154            let codec = tonic_prost::ProstCodec::default();
7155            let path = http::uri::PathAndQuery::from_static(
7156                "/qdrant.Points/DiscoverBatch",
7157            );
7158            let mut req = request.into_request();
7159            req.extensions_mut()
7160                .insert(GrpcMethod::new("qdrant.Points", "DiscoverBatch"));
7161            self.inner.unary(req, path, codec).await
7162        }
7163        /// Count points in collection with given filtering conditions
7164        pub async fn count(
7165            &mut self,
7166            request: impl tonic::IntoRequest<super::CountPoints>,
7167        ) -> std::result::Result<tonic::Response<super::CountResponse>, tonic::Status> {
7168            self.inner
7169                .ready()
7170                .await
7171                .map_err(|e| {
7172                    tonic::Status::unknown(
7173                        format!("Service was not ready: {}", e.into()),
7174                    )
7175                })?;
7176            let codec = tonic_prost::ProstCodec::default();
7177            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/Count");
7178            let mut req = request.into_request();
7179            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "Count"));
7180            self.inner.unary(req, path, codec).await
7181        }
7182        /// Perform multiple update operations in one request
7183        pub async fn update_batch(
7184            &mut self,
7185            request: impl tonic::IntoRequest<super::UpdateBatchPoints>,
7186        ) -> std::result::Result<
7187            tonic::Response<super::UpdateBatchResponse>,
7188            tonic::Status,
7189        > {
7190            self.inner
7191                .ready()
7192                .await
7193                .map_err(|e| {
7194                    tonic::Status::unknown(
7195                        format!("Service was not ready: {}", e.into()),
7196                    )
7197                })?;
7198            let codec = tonic_prost::ProstCodec::default();
7199            let path = http::uri::PathAndQuery::from_static(
7200                "/qdrant.Points/UpdateBatch",
7201            );
7202            let mut req = request.into_request();
7203            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "UpdateBatch"));
7204            self.inner.unary(req, path, codec).await
7205        }
7206        /// Universally query points.
7207        /// This endpoint covers all capabilities of search, recommend, discover, filters.
7208        /// But also enables hybrid and multi-stage queries.
7209        pub async fn query(
7210            &mut self,
7211            request: impl tonic::IntoRequest<super::QueryPoints>,
7212        ) -> std::result::Result<tonic::Response<super::QueryResponse>, tonic::Status> {
7213            self.inner
7214                .ready()
7215                .await
7216                .map_err(|e| {
7217                    tonic::Status::unknown(
7218                        format!("Service was not ready: {}", e.into()),
7219                    )
7220                })?;
7221            let codec = tonic_prost::ProstCodec::default();
7222            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/Query");
7223            let mut req = request.into_request();
7224            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "Query"));
7225            self.inner.unary(req, path, codec).await
7226        }
7227        /// Universally query points in a batch fashion.
7228        /// This endpoint covers all capabilities of search, recommend, discover, filters.
7229        /// But also enables hybrid and multi-stage queries.
7230        pub async fn query_batch(
7231            &mut self,
7232            request: impl tonic::IntoRequest<super::QueryBatchPoints>,
7233        ) -> std::result::Result<
7234            tonic::Response<super::QueryBatchResponse>,
7235            tonic::Status,
7236        > {
7237            self.inner
7238                .ready()
7239                .await
7240                .map_err(|e| {
7241                    tonic::Status::unknown(
7242                        format!("Service was not ready: {}", e.into()),
7243                    )
7244                })?;
7245            let codec = tonic_prost::ProstCodec::default();
7246            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/QueryBatch");
7247            let mut req = request.into_request();
7248            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "QueryBatch"));
7249            self.inner.unary(req, path, codec).await
7250        }
7251        /// Universally query points in a group fashion.
7252        /// This endpoint covers all capabilities of search, recommend, discover, filters.
7253        /// But also enables hybrid and multi-stage queries.
7254        pub async fn query_groups(
7255            &mut self,
7256            request: impl tonic::IntoRequest<super::QueryPointGroups>,
7257        ) -> std::result::Result<
7258            tonic::Response<super::QueryGroupsResponse>,
7259            tonic::Status,
7260        > {
7261            self.inner
7262                .ready()
7263                .await
7264                .map_err(|e| {
7265                    tonic::Status::unknown(
7266                        format!("Service was not ready: {}", e.into()),
7267                    )
7268                })?;
7269            let codec = tonic_prost::ProstCodec::default();
7270            let path = http::uri::PathAndQuery::from_static(
7271                "/qdrant.Points/QueryGroups",
7272            );
7273            let mut req = request.into_request();
7274            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "QueryGroups"));
7275            self.inner.unary(req, path, codec).await
7276        }
7277        /// Perform facet counts.
7278        /// For each value in the field, count the number of points that have this
7279        /// value and match the conditions.
7280        pub async fn facet(
7281            &mut self,
7282            request: impl tonic::IntoRequest<super::FacetCounts>,
7283        ) -> std::result::Result<tonic::Response<super::FacetResponse>, tonic::Status> {
7284            self.inner
7285                .ready()
7286                .await
7287                .map_err(|e| {
7288                    tonic::Status::unknown(
7289                        format!("Service was not ready: {}", e.into()),
7290                    )
7291                })?;
7292            let codec = tonic_prost::ProstCodec::default();
7293            let path = http::uri::PathAndQuery::from_static("/qdrant.Points/Facet");
7294            let mut req = request.into_request();
7295            req.extensions_mut().insert(GrpcMethod::new("qdrant.Points", "Facet"));
7296            self.inner.unary(req, path, codec).await
7297        }
7298        /// Compute distance matrix for sampled points with a pair based output format
7299        pub async fn search_matrix_pairs(
7300            &mut self,
7301            request: impl tonic::IntoRequest<super::SearchMatrixPoints>,
7302        ) -> std::result::Result<
7303            tonic::Response<super::SearchMatrixPairsResponse>,
7304            tonic::Status,
7305        > {
7306            self.inner
7307                .ready()
7308                .await
7309                .map_err(|e| {
7310                    tonic::Status::unknown(
7311                        format!("Service was not ready: {}", e.into()),
7312                    )
7313                })?;
7314            let codec = tonic_prost::ProstCodec::default();
7315            let path = http::uri::PathAndQuery::from_static(
7316                "/qdrant.Points/SearchMatrixPairs",
7317            );
7318            let mut req = request.into_request();
7319            req.extensions_mut()
7320                .insert(GrpcMethod::new("qdrant.Points", "SearchMatrixPairs"));
7321            self.inner.unary(req, path, codec).await
7322        }
7323        /// Compute distance matrix for sampled points with an offset based output format
7324        pub async fn search_matrix_offsets(
7325            &mut self,
7326            request: impl tonic::IntoRequest<super::SearchMatrixPoints>,
7327        ) -> std::result::Result<
7328            tonic::Response<super::SearchMatrixOffsetsResponse>,
7329            tonic::Status,
7330        > {
7331            self.inner
7332                .ready()
7333                .await
7334                .map_err(|e| {
7335                    tonic::Status::unknown(
7336                        format!("Service was not ready: {}", e.into()),
7337                    )
7338                })?;
7339            let codec = tonic_prost::ProstCodec::default();
7340            let path = http::uri::PathAndQuery::from_static(
7341                "/qdrant.Points/SearchMatrixOffsets",
7342            );
7343            let mut req = request.into_request();
7344            req.extensions_mut()
7345                .insert(GrpcMethod::new("qdrant.Points", "SearchMatrixOffsets"));
7346            self.inner.unary(req, path, codec).await
7347        }
7348    }
7349}
7350/// Generated server implementations.
7351pub mod points_server {
7352    #![allow(
7353        unused_variables,
7354        dead_code,
7355        missing_docs,
7356        clippy::wildcard_imports,
7357        clippy::let_unit_value,
7358    )]
7359    use tonic::codegen::*;
7360    /// Generated trait containing gRPC methods that should be implemented for use with PointsServer.
7361    #[async_trait]
7362    pub trait Points: std::marker::Send + std::marker::Sync + 'static {
7363        /// Perform insert + updates on points.
7364        /// If a point with a given ID already exists - it will be overwritten.
7365        async fn upsert(
7366            &self,
7367            request: tonic::Request<super::UpsertPoints>,
7368        ) -> std::result::Result<
7369            tonic::Response<super::PointsOperationResponse>,
7370            tonic::Status,
7371        >;
7372        /// Delete points
7373        async fn delete(
7374            &self,
7375            request: tonic::Request<super::DeletePoints>,
7376        ) -> std::result::Result<
7377            tonic::Response<super::PointsOperationResponse>,
7378            tonic::Status,
7379        >;
7380        /// Retrieve points
7381        async fn get(
7382            &self,
7383            request: tonic::Request<super::GetPoints>,
7384        ) -> std::result::Result<tonic::Response<super::GetResponse>, tonic::Status>;
7385        /// Update named vectors for point
7386        async fn update_vectors(
7387            &self,
7388            request: tonic::Request<super::UpdatePointVectors>,
7389        ) -> std::result::Result<
7390            tonic::Response<super::PointsOperationResponse>,
7391            tonic::Status,
7392        >;
7393        /// Delete named vectors for points
7394        async fn delete_vectors(
7395            &self,
7396            request: tonic::Request<super::DeletePointVectors>,
7397        ) -> std::result::Result<
7398            tonic::Response<super::PointsOperationResponse>,
7399            tonic::Status,
7400        >;
7401        /// Set payload for points
7402        async fn set_payload(
7403            &self,
7404            request: tonic::Request<super::SetPayloadPoints>,
7405        ) -> std::result::Result<
7406            tonic::Response<super::PointsOperationResponse>,
7407            tonic::Status,
7408        >;
7409        /// Overwrite payload for points
7410        async fn overwrite_payload(
7411            &self,
7412            request: tonic::Request<super::SetPayloadPoints>,
7413        ) -> std::result::Result<
7414            tonic::Response<super::PointsOperationResponse>,
7415            tonic::Status,
7416        >;
7417        /// Delete specified key payload for points
7418        async fn delete_payload(
7419            &self,
7420            request: tonic::Request<super::DeletePayloadPoints>,
7421        ) -> std::result::Result<
7422            tonic::Response<super::PointsOperationResponse>,
7423            tonic::Status,
7424        >;
7425        /// Remove all payload for specified points
7426        async fn clear_payload(
7427            &self,
7428            request: tonic::Request<super::ClearPayloadPoints>,
7429        ) -> std::result::Result<
7430            tonic::Response<super::PointsOperationResponse>,
7431            tonic::Status,
7432        >;
7433        /// Create index for field in collection
7434        async fn create_field_index(
7435            &self,
7436            request: tonic::Request<super::CreateFieldIndexCollection>,
7437        ) -> std::result::Result<
7438            tonic::Response<super::PointsOperationResponse>,
7439            tonic::Status,
7440        >;
7441        /// Delete field index for collection
7442        async fn delete_field_index(
7443            &self,
7444            request: tonic::Request<super::DeleteFieldIndexCollection>,
7445        ) -> std::result::Result<
7446            tonic::Response<super::PointsOperationResponse>,
7447            tonic::Status,
7448        >;
7449        /// Create a new named vector on the collection
7450        async fn create_vector_name(
7451            &self,
7452            request: tonic::Request<super::CreateVectorNameRequest>,
7453        ) -> std::result::Result<
7454            tonic::Response<super::PointsOperationResponse>,
7455            tonic::Status,
7456        >;
7457        /// Delete a named vector from the collection
7458        async fn delete_vector_name(
7459            &self,
7460            request: tonic::Request<super::DeleteVectorNameRequest>,
7461        ) -> std::result::Result<
7462            tonic::Response<super::PointsOperationResponse>,
7463            tonic::Status,
7464        >;
7465        /// Retrieve closest points based on vector similarity and given filtering
7466        /// conditions
7467        ///
7468        /// Deprecated: use `Query` instead.
7469        async fn search(
7470            &self,
7471            request: tonic::Request<super::SearchPoints>,
7472        ) -> std::result::Result<tonic::Response<super::SearchResponse>, tonic::Status>;
7473        /// Retrieve closest points based on vector similarity and given filtering
7474        /// conditions
7475        ///
7476        /// Deprecated: use `QueryBatch` instead.
7477        async fn search_batch(
7478            &self,
7479            request: tonic::Request<super::SearchBatchPoints>,
7480        ) -> std::result::Result<
7481            tonic::Response<super::SearchBatchResponse>,
7482            tonic::Status,
7483        >;
7484        /// Retrieve closest points based on vector similarity and given filtering
7485        /// conditions, grouped by a given field
7486        ///
7487        /// Deprecated: use `QueryGroups` instead.
7488        async fn search_groups(
7489            &self,
7490            request: tonic::Request<super::SearchPointGroups>,
7491        ) -> std::result::Result<
7492            tonic::Response<super::SearchGroupsResponse>,
7493            tonic::Status,
7494        >;
7495        /// Iterate over all or filtered points
7496        async fn scroll(
7497            &self,
7498            request: tonic::Request<super::ScrollPoints>,
7499        ) -> std::result::Result<tonic::Response<super::ScrollResponse>, tonic::Status>;
7500        /// Look for the points which are closer to stored positive examples and at
7501        /// the same time further to negative examples.
7502        ///
7503        /// Deprecated: use `Query` with a `recommend` query instead.
7504        async fn recommend(
7505            &self,
7506            request: tonic::Request<super::RecommendPoints>,
7507        ) -> std::result::Result<
7508            tonic::Response<super::RecommendResponse>,
7509            tonic::Status,
7510        >;
7511        /// Look for the points which are closer to stored positive examples and at
7512        /// the same time further to negative examples.
7513        ///
7514        /// Deprecated: use `QueryBatch` with `recommend` queries instead.
7515        async fn recommend_batch(
7516            &self,
7517            request: tonic::Request<super::RecommendBatchPoints>,
7518        ) -> std::result::Result<
7519            tonic::Response<super::RecommendBatchResponse>,
7520            tonic::Status,
7521        >;
7522        /// Look for the points which are closer to stored positive examples and at
7523        /// the same time further to negative examples, grouped by a given field
7524        ///
7525        /// Deprecated: use `QueryGroups` with a `recommend` query instead.
7526        async fn recommend_groups(
7527            &self,
7528            request: tonic::Request<super::RecommendPointGroups>,
7529        ) -> std::result::Result<
7530            tonic::Response<super::RecommendGroupsResponse>,
7531            tonic::Status,
7532        >;
7533        /// Use context and a target to find the most similar points to the target,
7534        /// constrained by the context.
7535        ///
7536        /// When using only the context (without a target), a special search - called
7537        /// context search - is performed where pairs of points are used to generate a
7538        /// loss that guides the search towards the zone where most positive examples
7539        /// overlap. This means that the score minimizes the scenario of finding a
7540        /// point closer to a negative than to a positive part of a pair.
7541        ///
7542        /// Since the score of a context relates to loss, the maximum score a point
7543        /// can get is 0.0, and it becomes normal that many points can have a score of
7544        /// 0.0.
7545        ///
7546        /// When using target (with or without context), the score behaves a little
7547        /// different: The integer part of the score represents the rank with respect
7548        /// to the context, while the decimal part of the score relates to the
7549        /// distance to the target. The context part of the score for each pair is
7550        /// calculated +1 if the point is closer to a positive than to a negative part
7551        /// of a pair, and -1 otherwise.
7552        ///
7553        /// Deprecated: use `Query` with a `discover` or `context` query instead.
7554        async fn discover(
7555            &self,
7556            request: tonic::Request<super::DiscoverPoints>,
7557        ) -> std::result::Result<
7558            tonic::Response<super::DiscoverResponse>,
7559            tonic::Status,
7560        >;
7561        /// Batch request points based on { positive, negative } pairs of examples, and/or a target
7562        ///
7563        /// Deprecated: use `QueryBatch` with `discover` or `context` queries instead.
7564        async fn discover_batch(
7565            &self,
7566            request: tonic::Request<super::DiscoverBatchPoints>,
7567        ) -> std::result::Result<
7568            tonic::Response<super::DiscoverBatchResponse>,
7569            tonic::Status,
7570        >;
7571        /// Count points in collection with given filtering conditions
7572        async fn count(
7573            &self,
7574            request: tonic::Request<super::CountPoints>,
7575        ) -> std::result::Result<tonic::Response<super::CountResponse>, tonic::Status>;
7576        /// Perform multiple update operations in one request
7577        async fn update_batch(
7578            &self,
7579            request: tonic::Request<super::UpdateBatchPoints>,
7580        ) -> std::result::Result<
7581            tonic::Response<super::UpdateBatchResponse>,
7582            tonic::Status,
7583        >;
7584        /// Universally query points.
7585        /// This endpoint covers all capabilities of search, recommend, discover, filters.
7586        /// But also enables hybrid and multi-stage queries.
7587        async fn query(
7588            &self,
7589            request: tonic::Request<super::QueryPoints>,
7590        ) -> std::result::Result<tonic::Response<super::QueryResponse>, tonic::Status>;
7591        /// Universally query points in a batch fashion.
7592        /// This endpoint covers all capabilities of search, recommend, discover, filters.
7593        /// But also enables hybrid and multi-stage queries.
7594        async fn query_batch(
7595            &self,
7596            request: tonic::Request<super::QueryBatchPoints>,
7597        ) -> std::result::Result<
7598            tonic::Response<super::QueryBatchResponse>,
7599            tonic::Status,
7600        >;
7601        /// Universally query points in a group fashion.
7602        /// This endpoint covers all capabilities of search, recommend, discover, filters.
7603        /// But also enables hybrid and multi-stage queries.
7604        async fn query_groups(
7605            &self,
7606            request: tonic::Request<super::QueryPointGroups>,
7607        ) -> std::result::Result<
7608            tonic::Response<super::QueryGroupsResponse>,
7609            tonic::Status,
7610        >;
7611        /// Perform facet counts.
7612        /// For each value in the field, count the number of points that have this
7613        /// value and match the conditions.
7614        async fn facet(
7615            &self,
7616            request: tonic::Request<super::FacetCounts>,
7617        ) -> std::result::Result<tonic::Response<super::FacetResponse>, tonic::Status>;
7618        /// Compute distance matrix for sampled points with a pair based output format
7619        async fn search_matrix_pairs(
7620            &self,
7621            request: tonic::Request<super::SearchMatrixPoints>,
7622        ) -> std::result::Result<
7623            tonic::Response<super::SearchMatrixPairsResponse>,
7624            tonic::Status,
7625        >;
7626        /// Compute distance matrix for sampled points with an offset based output format
7627        async fn search_matrix_offsets(
7628            &self,
7629            request: tonic::Request<super::SearchMatrixPoints>,
7630        ) -> std::result::Result<
7631            tonic::Response<super::SearchMatrixOffsetsResponse>,
7632            tonic::Status,
7633        >;
7634    }
7635    #[derive(Debug)]
7636    pub struct PointsServer<T> {
7637        inner: Arc<T>,
7638        accept_compression_encodings: EnabledCompressionEncodings,
7639        send_compression_encodings: EnabledCompressionEncodings,
7640        max_decoding_message_size: Option<usize>,
7641        max_encoding_message_size: Option<usize>,
7642    }
7643    impl<T> PointsServer<T> {
7644        pub fn new(inner: T) -> Self {
7645            Self::from_arc(Arc::new(inner))
7646        }
7647        pub fn from_arc(inner: Arc<T>) -> Self {
7648            Self {
7649                inner,
7650                accept_compression_encodings: Default::default(),
7651                send_compression_encodings: Default::default(),
7652                max_decoding_message_size: None,
7653                max_encoding_message_size: None,
7654            }
7655        }
7656        pub fn with_interceptor<F>(
7657            inner: T,
7658            interceptor: F,
7659        ) -> InterceptedService<Self, F>
7660        where
7661            F: tonic::service::Interceptor,
7662        {
7663            InterceptedService::new(Self::new(inner), interceptor)
7664        }
7665        /// Enable decompressing requests with the given encoding.
7666        #[must_use]
7667        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7668            self.accept_compression_encodings.enable(encoding);
7669            self
7670        }
7671        /// Compress responses with the given encoding, if the client supports it.
7672        #[must_use]
7673        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7674            self.send_compression_encodings.enable(encoding);
7675            self
7676        }
7677        /// Limits the maximum size of a decoded message.
7678        ///
7679        /// Default: `4MB`
7680        #[must_use]
7681        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7682            self.max_decoding_message_size = Some(limit);
7683            self
7684        }
7685        /// Limits the maximum size of an encoded message.
7686        ///
7687        /// Default: `usize::MAX`
7688        #[must_use]
7689        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7690            self.max_encoding_message_size = Some(limit);
7691            self
7692        }
7693    }
7694    impl<T, B> tonic::codegen::Service<http::Request<B>> for PointsServer<T>
7695    where
7696        T: Points,
7697        B: Body + std::marker::Send + 'static,
7698        B::Error: Into<StdError> + std::marker::Send + 'static,
7699    {
7700        type Response = http::Response<tonic::body::Body>;
7701        type Error = std::convert::Infallible;
7702        type Future = BoxFuture<Self::Response, Self::Error>;
7703        fn poll_ready(
7704            &mut self,
7705            _cx: &mut Context<'_>,
7706        ) -> Poll<std::result::Result<(), Self::Error>> {
7707            Poll::Ready(Ok(()))
7708        }
7709        fn call(&mut self, req: http::Request<B>) -> Self::Future {
7710            match req.uri().path() {
7711                "/qdrant.Points/Upsert" => {
7712                    #[allow(non_camel_case_types)]
7713                    struct UpsertSvc<T: Points>(pub Arc<T>);
7714                    impl<T: Points> tonic::server::UnaryService<super::UpsertPoints>
7715                    for UpsertSvc<T> {
7716                        type Response = super::PointsOperationResponse;
7717                        type Future = BoxFuture<
7718                            tonic::Response<Self::Response>,
7719                            tonic::Status,
7720                        >;
7721                        fn call(
7722                            &mut self,
7723                            request: tonic::Request<super::UpsertPoints>,
7724                        ) -> Self::Future {
7725                            let inner = Arc::clone(&self.0);
7726                            let fut = async move {
7727                                <T as Points>::upsert(&inner, request).await
7728                            };
7729                            Box::pin(fut)
7730                        }
7731                    }
7732                    let accept_compression_encodings = self.accept_compression_encodings;
7733                    let send_compression_encodings = self.send_compression_encodings;
7734                    let max_decoding_message_size = self.max_decoding_message_size;
7735                    let max_encoding_message_size = self.max_encoding_message_size;
7736                    let inner = self.inner.clone();
7737                    let fut = async move {
7738                        let method = UpsertSvc(inner);
7739                        let codec = tonic_prost::ProstCodec::default();
7740                        let mut grpc = tonic::server::Grpc::new(codec)
7741                            .apply_compression_config(
7742                                accept_compression_encodings,
7743                                send_compression_encodings,
7744                            )
7745                            .apply_max_message_size_config(
7746                                max_decoding_message_size,
7747                                max_encoding_message_size,
7748                            );
7749                        let res = grpc.unary(method, req).await;
7750                        Ok(res)
7751                    };
7752                    Box::pin(fut)
7753                }
7754                "/qdrant.Points/Delete" => {
7755                    #[allow(non_camel_case_types)]
7756                    struct DeleteSvc<T: Points>(pub Arc<T>);
7757                    impl<T: Points> tonic::server::UnaryService<super::DeletePoints>
7758                    for DeleteSvc<T> {
7759                        type Response = super::PointsOperationResponse;
7760                        type Future = BoxFuture<
7761                            tonic::Response<Self::Response>,
7762                            tonic::Status,
7763                        >;
7764                        fn call(
7765                            &mut self,
7766                            request: tonic::Request<super::DeletePoints>,
7767                        ) -> Self::Future {
7768                            let inner = Arc::clone(&self.0);
7769                            let fut = async move {
7770                                <T as Points>::delete(&inner, request).await
7771                            };
7772                            Box::pin(fut)
7773                        }
7774                    }
7775                    let accept_compression_encodings = self.accept_compression_encodings;
7776                    let send_compression_encodings = self.send_compression_encodings;
7777                    let max_decoding_message_size = self.max_decoding_message_size;
7778                    let max_encoding_message_size = self.max_encoding_message_size;
7779                    let inner = self.inner.clone();
7780                    let fut = async move {
7781                        let method = DeleteSvc(inner);
7782                        let codec = tonic_prost::ProstCodec::default();
7783                        let mut grpc = tonic::server::Grpc::new(codec)
7784                            .apply_compression_config(
7785                                accept_compression_encodings,
7786                                send_compression_encodings,
7787                            )
7788                            .apply_max_message_size_config(
7789                                max_decoding_message_size,
7790                                max_encoding_message_size,
7791                            );
7792                        let res = grpc.unary(method, req).await;
7793                        Ok(res)
7794                    };
7795                    Box::pin(fut)
7796                }
7797                "/qdrant.Points/Get" => {
7798                    #[allow(non_camel_case_types)]
7799                    struct GetSvc<T: Points>(pub Arc<T>);
7800                    impl<T: Points> tonic::server::UnaryService<super::GetPoints>
7801                    for GetSvc<T> {
7802                        type Response = super::GetResponse;
7803                        type Future = BoxFuture<
7804                            tonic::Response<Self::Response>,
7805                            tonic::Status,
7806                        >;
7807                        fn call(
7808                            &mut self,
7809                            request: tonic::Request<super::GetPoints>,
7810                        ) -> Self::Future {
7811                            let inner = Arc::clone(&self.0);
7812                            let fut = async move {
7813                                <T as Points>::get(&inner, request).await
7814                            };
7815                            Box::pin(fut)
7816                        }
7817                    }
7818                    let accept_compression_encodings = self.accept_compression_encodings;
7819                    let send_compression_encodings = self.send_compression_encodings;
7820                    let max_decoding_message_size = self.max_decoding_message_size;
7821                    let max_encoding_message_size = self.max_encoding_message_size;
7822                    let inner = self.inner.clone();
7823                    let fut = async move {
7824                        let method = GetSvc(inner);
7825                        let codec = tonic_prost::ProstCodec::default();
7826                        let mut grpc = tonic::server::Grpc::new(codec)
7827                            .apply_compression_config(
7828                                accept_compression_encodings,
7829                                send_compression_encodings,
7830                            )
7831                            .apply_max_message_size_config(
7832                                max_decoding_message_size,
7833                                max_encoding_message_size,
7834                            );
7835                        let res = grpc.unary(method, req).await;
7836                        Ok(res)
7837                    };
7838                    Box::pin(fut)
7839                }
7840                "/qdrant.Points/UpdateVectors" => {
7841                    #[allow(non_camel_case_types)]
7842                    struct UpdateVectorsSvc<T: Points>(pub Arc<T>);
7843                    impl<
7844                        T: Points,
7845                    > tonic::server::UnaryService<super::UpdatePointVectors>
7846                    for UpdateVectorsSvc<T> {
7847                        type Response = super::PointsOperationResponse;
7848                        type Future = BoxFuture<
7849                            tonic::Response<Self::Response>,
7850                            tonic::Status,
7851                        >;
7852                        fn call(
7853                            &mut self,
7854                            request: tonic::Request<super::UpdatePointVectors>,
7855                        ) -> Self::Future {
7856                            let inner = Arc::clone(&self.0);
7857                            let fut = async move {
7858                                <T as Points>::update_vectors(&inner, request).await
7859                            };
7860                            Box::pin(fut)
7861                        }
7862                    }
7863                    let accept_compression_encodings = self.accept_compression_encodings;
7864                    let send_compression_encodings = self.send_compression_encodings;
7865                    let max_decoding_message_size = self.max_decoding_message_size;
7866                    let max_encoding_message_size = self.max_encoding_message_size;
7867                    let inner = self.inner.clone();
7868                    let fut = async move {
7869                        let method = UpdateVectorsSvc(inner);
7870                        let codec = tonic_prost::ProstCodec::default();
7871                        let mut grpc = tonic::server::Grpc::new(codec)
7872                            .apply_compression_config(
7873                                accept_compression_encodings,
7874                                send_compression_encodings,
7875                            )
7876                            .apply_max_message_size_config(
7877                                max_decoding_message_size,
7878                                max_encoding_message_size,
7879                            );
7880                        let res = grpc.unary(method, req).await;
7881                        Ok(res)
7882                    };
7883                    Box::pin(fut)
7884                }
7885                "/qdrant.Points/DeleteVectors" => {
7886                    #[allow(non_camel_case_types)]
7887                    struct DeleteVectorsSvc<T: Points>(pub Arc<T>);
7888                    impl<
7889                        T: Points,
7890                    > tonic::server::UnaryService<super::DeletePointVectors>
7891                    for DeleteVectorsSvc<T> {
7892                        type Response = super::PointsOperationResponse;
7893                        type Future = BoxFuture<
7894                            tonic::Response<Self::Response>,
7895                            tonic::Status,
7896                        >;
7897                        fn call(
7898                            &mut self,
7899                            request: tonic::Request<super::DeletePointVectors>,
7900                        ) -> Self::Future {
7901                            let inner = Arc::clone(&self.0);
7902                            let fut = async move {
7903                                <T as Points>::delete_vectors(&inner, request).await
7904                            };
7905                            Box::pin(fut)
7906                        }
7907                    }
7908                    let accept_compression_encodings = self.accept_compression_encodings;
7909                    let send_compression_encodings = self.send_compression_encodings;
7910                    let max_decoding_message_size = self.max_decoding_message_size;
7911                    let max_encoding_message_size = self.max_encoding_message_size;
7912                    let inner = self.inner.clone();
7913                    let fut = async move {
7914                        let method = DeleteVectorsSvc(inner);
7915                        let codec = tonic_prost::ProstCodec::default();
7916                        let mut grpc = tonic::server::Grpc::new(codec)
7917                            .apply_compression_config(
7918                                accept_compression_encodings,
7919                                send_compression_encodings,
7920                            )
7921                            .apply_max_message_size_config(
7922                                max_decoding_message_size,
7923                                max_encoding_message_size,
7924                            );
7925                        let res = grpc.unary(method, req).await;
7926                        Ok(res)
7927                    };
7928                    Box::pin(fut)
7929                }
7930                "/qdrant.Points/SetPayload" => {
7931                    #[allow(non_camel_case_types)]
7932                    struct SetPayloadSvc<T: Points>(pub Arc<T>);
7933                    impl<T: Points> tonic::server::UnaryService<super::SetPayloadPoints>
7934                    for SetPayloadSvc<T> {
7935                        type Response = super::PointsOperationResponse;
7936                        type Future = BoxFuture<
7937                            tonic::Response<Self::Response>,
7938                            tonic::Status,
7939                        >;
7940                        fn call(
7941                            &mut self,
7942                            request: tonic::Request<super::SetPayloadPoints>,
7943                        ) -> Self::Future {
7944                            let inner = Arc::clone(&self.0);
7945                            let fut = async move {
7946                                <T as Points>::set_payload(&inner, request).await
7947                            };
7948                            Box::pin(fut)
7949                        }
7950                    }
7951                    let accept_compression_encodings = self.accept_compression_encodings;
7952                    let send_compression_encodings = self.send_compression_encodings;
7953                    let max_decoding_message_size = self.max_decoding_message_size;
7954                    let max_encoding_message_size = self.max_encoding_message_size;
7955                    let inner = self.inner.clone();
7956                    let fut = async move {
7957                        let method = SetPayloadSvc(inner);
7958                        let codec = tonic_prost::ProstCodec::default();
7959                        let mut grpc = tonic::server::Grpc::new(codec)
7960                            .apply_compression_config(
7961                                accept_compression_encodings,
7962                                send_compression_encodings,
7963                            )
7964                            .apply_max_message_size_config(
7965                                max_decoding_message_size,
7966                                max_encoding_message_size,
7967                            );
7968                        let res = grpc.unary(method, req).await;
7969                        Ok(res)
7970                    };
7971                    Box::pin(fut)
7972                }
7973                "/qdrant.Points/OverwritePayload" => {
7974                    #[allow(non_camel_case_types)]
7975                    struct OverwritePayloadSvc<T: Points>(pub Arc<T>);
7976                    impl<T: Points> tonic::server::UnaryService<super::SetPayloadPoints>
7977                    for OverwritePayloadSvc<T> {
7978                        type Response = super::PointsOperationResponse;
7979                        type Future = BoxFuture<
7980                            tonic::Response<Self::Response>,
7981                            tonic::Status,
7982                        >;
7983                        fn call(
7984                            &mut self,
7985                            request: tonic::Request<super::SetPayloadPoints>,
7986                        ) -> Self::Future {
7987                            let inner = Arc::clone(&self.0);
7988                            let fut = async move {
7989                                <T as Points>::overwrite_payload(&inner, request).await
7990                            };
7991                            Box::pin(fut)
7992                        }
7993                    }
7994                    let accept_compression_encodings = self.accept_compression_encodings;
7995                    let send_compression_encodings = self.send_compression_encodings;
7996                    let max_decoding_message_size = self.max_decoding_message_size;
7997                    let max_encoding_message_size = self.max_encoding_message_size;
7998                    let inner = self.inner.clone();
7999                    let fut = async move {
8000                        let method = OverwritePayloadSvc(inner);
8001                        let codec = tonic_prost::ProstCodec::default();
8002                        let mut grpc = tonic::server::Grpc::new(codec)
8003                            .apply_compression_config(
8004                                accept_compression_encodings,
8005                                send_compression_encodings,
8006                            )
8007                            .apply_max_message_size_config(
8008                                max_decoding_message_size,
8009                                max_encoding_message_size,
8010                            );
8011                        let res = grpc.unary(method, req).await;
8012                        Ok(res)
8013                    };
8014                    Box::pin(fut)
8015                }
8016                "/qdrant.Points/DeletePayload" => {
8017                    #[allow(non_camel_case_types)]
8018                    struct DeletePayloadSvc<T: Points>(pub Arc<T>);
8019                    impl<
8020                        T: Points,
8021                    > tonic::server::UnaryService<super::DeletePayloadPoints>
8022                    for DeletePayloadSvc<T> {
8023                        type Response = super::PointsOperationResponse;
8024                        type Future = BoxFuture<
8025                            tonic::Response<Self::Response>,
8026                            tonic::Status,
8027                        >;
8028                        fn call(
8029                            &mut self,
8030                            request: tonic::Request<super::DeletePayloadPoints>,
8031                        ) -> Self::Future {
8032                            let inner = Arc::clone(&self.0);
8033                            let fut = async move {
8034                                <T as Points>::delete_payload(&inner, request).await
8035                            };
8036                            Box::pin(fut)
8037                        }
8038                    }
8039                    let accept_compression_encodings = self.accept_compression_encodings;
8040                    let send_compression_encodings = self.send_compression_encodings;
8041                    let max_decoding_message_size = self.max_decoding_message_size;
8042                    let max_encoding_message_size = self.max_encoding_message_size;
8043                    let inner = self.inner.clone();
8044                    let fut = async move {
8045                        let method = DeletePayloadSvc(inner);
8046                        let codec = tonic_prost::ProstCodec::default();
8047                        let mut grpc = tonic::server::Grpc::new(codec)
8048                            .apply_compression_config(
8049                                accept_compression_encodings,
8050                                send_compression_encodings,
8051                            )
8052                            .apply_max_message_size_config(
8053                                max_decoding_message_size,
8054                                max_encoding_message_size,
8055                            );
8056                        let res = grpc.unary(method, req).await;
8057                        Ok(res)
8058                    };
8059                    Box::pin(fut)
8060                }
8061                "/qdrant.Points/ClearPayload" => {
8062                    #[allow(non_camel_case_types)]
8063                    struct ClearPayloadSvc<T: Points>(pub Arc<T>);
8064                    impl<
8065                        T: Points,
8066                    > tonic::server::UnaryService<super::ClearPayloadPoints>
8067                    for ClearPayloadSvc<T> {
8068                        type Response = super::PointsOperationResponse;
8069                        type Future = BoxFuture<
8070                            tonic::Response<Self::Response>,
8071                            tonic::Status,
8072                        >;
8073                        fn call(
8074                            &mut self,
8075                            request: tonic::Request<super::ClearPayloadPoints>,
8076                        ) -> Self::Future {
8077                            let inner = Arc::clone(&self.0);
8078                            let fut = async move {
8079                                <T as Points>::clear_payload(&inner, request).await
8080                            };
8081                            Box::pin(fut)
8082                        }
8083                    }
8084                    let accept_compression_encodings = self.accept_compression_encodings;
8085                    let send_compression_encodings = self.send_compression_encodings;
8086                    let max_decoding_message_size = self.max_decoding_message_size;
8087                    let max_encoding_message_size = self.max_encoding_message_size;
8088                    let inner = self.inner.clone();
8089                    let fut = async move {
8090                        let method = ClearPayloadSvc(inner);
8091                        let codec = tonic_prost::ProstCodec::default();
8092                        let mut grpc = tonic::server::Grpc::new(codec)
8093                            .apply_compression_config(
8094                                accept_compression_encodings,
8095                                send_compression_encodings,
8096                            )
8097                            .apply_max_message_size_config(
8098                                max_decoding_message_size,
8099                                max_encoding_message_size,
8100                            );
8101                        let res = grpc.unary(method, req).await;
8102                        Ok(res)
8103                    };
8104                    Box::pin(fut)
8105                }
8106                "/qdrant.Points/CreateFieldIndex" => {
8107                    #[allow(non_camel_case_types)]
8108                    struct CreateFieldIndexSvc<T: Points>(pub Arc<T>);
8109                    impl<
8110                        T: Points,
8111                    > tonic::server::UnaryService<super::CreateFieldIndexCollection>
8112                    for CreateFieldIndexSvc<T> {
8113                        type Response = super::PointsOperationResponse;
8114                        type Future = BoxFuture<
8115                            tonic::Response<Self::Response>,
8116                            tonic::Status,
8117                        >;
8118                        fn call(
8119                            &mut self,
8120                            request: tonic::Request<super::CreateFieldIndexCollection>,
8121                        ) -> Self::Future {
8122                            let inner = Arc::clone(&self.0);
8123                            let fut = async move {
8124                                <T as Points>::create_field_index(&inner, request).await
8125                            };
8126                            Box::pin(fut)
8127                        }
8128                    }
8129                    let accept_compression_encodings = self.accept_compression_encodings;
8130                    let send_compression_encodings = self.send_compression_encodings;
8131                    let max_decoding_message_size = self.max_decoding_message_size;
8132                    let max_encoding_message_size = self.max_encoding_message_size;
8133                    let inner = self.inner.clone();
8134                    let fut = async move {
8135                        let method = CreateFieldIndexSvc(inner);
8136                        let codec = tonic_prost::ProstCodec::default();
8137                        let mut grpc = tonic::server::Grpc::new(codec)
8138                            .apply_compression_config(
8139                                accept_compression_encodings,
8140                                send_compression_encodings,
8141                            )
8142                            .apply_max_message_size_config(
8143                                max_decoding_message_size,
8144                                max_encoding_message_size,
8145                            );
8146                        let res = grpc.unary(method, req).await;
8147                        Ok(res)
8148                    };
8149                    Box::pin(fut)
8150                }
8151                "/qdrant.Points/DeleteFieldIndex" => {
8152                    #[allow(non_camel_case_types)]
8153                    struct DeleteFieldIndexSvc<T: Points>(pub Arc<T>);
8154                    impl<
8155                        T: Points,
8156                    > tonic::server::UnaryService<super::DeleteFieldIndexCollection>
8157                    for DeleteFieldIndexSvc<T> {
8158                        type Response = super::PointsOperationResponse;
8159                        type Future = BoxFuture<
8160                            tonic::Response<Self::Response>,
8161                            tonic::Status,
8162                        >;
8163                        fn call(
8164                            &mut self,
8165                            request: tonic::Request<super::DeleteFieldIndexCollection>,
8166                        ) -> Self::Future {
8167                            let inner = Arc::clone(&self.0);
8168                            let fut = async move {
8169                                <T as Points>::delete_field_index(&inner, request).await
8170                            };
8171                            Box::pin(fut)
8172                        }
8173                    }
8174                    let accept_compression_encodings = self.accept_compression_encodings;
8175                    let send_compression_encodings = self.send_compression_encodings;
8176                    let max_decoding_message_size = self.max_decoding_message_size;
8177                    let max_encoding_message_size = self.max_encoding_message_size;
8178                    let inner = self.inner.clone();
8179                    let fut = async move {
8180                        let method = DeleteFieldIndexSvc(inner);
8181                        let codec = tonic_prost::ProstCodec::default();
8182                        let mut grpc = tonic::server::Grpc::new(codec)
8183                            .apply_compression_config(
8184                                accept_compression_encodings,
8185                                send_compression_encodings,
8186                            )
8187                            .apply_max_message_size_config(
8188                                max_decoding_message_size,
8189                                max_encoding_message_size,
8190                            );
8191                        let res = grpc.unary(method, req).await;
8192                        Ok(res)
8193                    };
8194                    Box::pin(fut)
8195                }
8196                "/qdrant.Points/CreateVectorName" => {
8197                    #[allow(non_camel_case_types)]
8198                    struct CreateVectorNameSvc<T: Points>(pub Arc<T>);
8199                    impl<
8200                        T: Points,
8201                    > tonic::server::UnaryService<super::CreateVectorNameRequest>
8202                    for CreateVectorNameSvc<T> {
8203                        type Response = super::PointsOperationResponse;
8204                        type Future = BoxFuture<
8205                            tonic::Response<Self::Response>,
8206                            tonic::Status,
8207                        >;
8208                        fn call(
8209                            &mut self,
8210                            request: tonic::Request<super::CreateVectorNameRequest>,
8211                        ) -> Self::Future {
8212                            let inner = Arc::clone(&self.0);
8213                            let fut = async move {
8214                                <T as Points>::create_vector_name(&inner, request).await
8215                            };
8216                            Box::pin(fut)
8217                        }
8218                    }
8219                    let accept_compression_encodings = self.accept_compression_encodings;
8220                    let send_compression_encodings = self.send_compression_encodings;
8221                    let max_decoding_message_size = self.max_decoding_message_size;
8222                    let max_encoding_message_size = self.max_encoding_message_size;
8223                    let inner = self.inner.clone();
8224                    let fut = async move {
8225                        let method = CreateVectorNameSvc(inner);
8226                        let codec = tonic_prost::ProstCodec::default();
8227                        let mut grpc = tonic::server::Grpc::new(codec)
8228                            .apply_compression_config(
8229                                accept_compression_encodings,
8230                                send_compression_encodings,
8231                            )
8232                            .apply_max_message_size_config(
8233                                max_decoding_message_size,
8234                                max_encoding_message_size,
8235                            );
8236                        let res = grpc.unary(method, req).await;
8237                        Ok(res)
8238                    };
8239                    Box::pin(fut)
8240                }
8241                "/qdrant.Points/DeleteVectorName" => {
8242                    #[allow(non_camel_case_types)]
8243                    struct DeleteVectorNameSvc<T: Points>(pub Arc<T>);
8244                    impl<
8245                        T: Points,
8246                    > tonic::server::UnaryService<super::DeleteVectorNameRequest>
8247                    for DeleteVectorNameSvc<T> {
8248                        type Response = super::PointsOperationResponse;
8249                        type Future = BoxFuture<
8250                            tonic::Response<Self::Response>,
8251                            tonic::Status,
8252                        >;
8253                        fn call(
8254                            &mut self,
8255                            request: tonic::Request<super::DeleteVectorNameRequest>,
8256                        ) -> Self::Future {
8257                            let inner = Arc::clone(&self.0);
8258                            let fut = async move {
8259                                <T as Points>::delete_vector_name(&inner, request).await
8260                            };
8261                            Box::pin(fut)
8262                        }
8263                    }
8264                    let accept_compression_encodings = self.accept_compression_encodings;
8265                    let send_compression_encodings = self.send_compression_encodings;
8266                    let max_decoding_message_size = self.max_decoding_message_size;
8267                    let max_encoding_message_size = self.max_encoding_message_size;
8268                    let inner = self.inner.clone();
8269                    let fut = async move {
8270                        let method = DeleteVectorNameSvc(inner);
8271                        let codec = tonic_prost::ProstCodec::default();
8272                        let mut grpc = tonic::server::Grpc::new(codec)
8273                            .apply_compression_config(
8274                                accept_compression_encodings,
8275                                send_compression_encodings,
8276                            )
8277                            .apply_max_message_size_config(
8278                                max_decoding_message_size,
8279                                max_encoding_message_size,
8280                            );
8281                        let res = grpc.unary(method, req).await;
8282                        Ok(res)
8283                    };
8284                    Box::pin(fut)
8285                }
8286                "/qdrant.Points/Search" => {
8287                    #[allow(non_camel_case_types)]
8288                    struct SearchSvc<T: Points>(pub Arc<T>);
8289                    impl<T: Points> tonic::server::UnaryService<super::SearchPoints>
8290                    for SearchSvc<T> {
8291                        type Response = super::SearchResponse;
8292                        type Future = BoxFuture<
8293                            tonic::Response<Self::Response>,
8294                            tonic::Status,
8295                        >;
8296                        fn call(
8297                            &mut self,
8298                            request: tonic::Request<super::SearchPoints>,
8299                        ) -> Self::Future {
8300                            let inner = Arc::clone(&self.0);
8301                            let fut = async move {
8302                                <T as Points>::search(&inner, request).await
8303                            };
8304                            Box::pin(fut)
8305                        }
8306                    }
8307                    let accept_compression_encodings = self.accept_compression_encodings;
8308                    let send_compression_encodings = self.send_compression_encodings;
8309                    let max_decoding_message_size = self.max_decoding_message_size;
8310                    let max_encoding_message_size = self.max_encoding_message_size;
8311                    let inner = self.inner.clone();
8312                    let fut = async move {
8313                        let method = SearchSvc(inner);
8314                        let codec = tonic_prost::ProstCodec::default();
8315                        let mut grpc = tonic::server::Grpc::new(codec)
8316                            .apply_compression_config(
8317                                accept_compression_encodings,
8318                                send_compression_encodings,
8319                            )
8320                            .apply_max_message_size_config(
8321                                max_decoding_message_size,
8322                                max_encoding_message_size,
8323                            );
8324                        let res = grpc.unary(method, req).await;
8325                        Ok(res)
8326                    };
8327                    Box::pin(fut)
8328                }
8329                "/qdrant.Points/SearchBatch" => {
8330                    #[allow(non_camel_case_types)]
8331                    struct SearchBatchSvc<T: Points>(pub Arc<T>);
8332                    impl<T: Points> tonic::server::UnaryService<super::SearchBatchPoints>
8333                    for SearchBatchSvc<T> {
8334                        type Response = super::SearchBatchResponse;
8335                        type Future = BoxFuture<
8336                            tonic::Response<Self::Response>,
8337                            tonic::Status,
8338                        >;
8339                        fn call(
8340                            &mut self,
8341                            request: tonic::Request<super::SearchBatchPoints>,
8342                        ) -> Self::Future {
8343                            let inner = Arc::clone(&self.0);
8344                            let fut = async move {
8345                                <T as Points>::search_batch(&inner, request).await
8346                            };
8347                            Box::pin(fut)
8348                        }
8349                    }
8350                    let accept_compression_encodings = self.accept_compression_encodings;
8351                    let send_compression_encodings = self.send_compression_encodings;
8352                    let max_decoding_message_size = self.max_decoding_message_size;
8353                    let max_encoding_message_size = self.max_encoding_message_size;
8354                    let inner = self.inner.clone();
8355                    let fut = async move {
8356                        let method = SearchBatchSvc(inner);
8357                        let codec = tonic_prost::ProstCodec::default();
8358                        let mut grpc = tonic::server::Grpc::new(codec)
8359                            .apply_compression_config(
8360                                accept_compression_encodings,
8361                                send_compression_encodings,
8362                            )
8363                            .apply_max_message_size_config(
8364                                max_decoding_message_size,
8365                                max_encoding_message_size,
8366                            );
8367                        let res = grpc.unary(method, req).await;
8368                        Ok(res)
8369                    };
8370                    Box::pin(fut)
8371                }
8372                "/qdrant.Points/SearchGroups" => {
8373                    #[allow(non_camel_case_types)]
8374                    struct SearchGroupsSvc<T: Points>(pub Arc<T>);
8375                    impl<T: Points> tonic::server::UnaryService<super::SearchPointGroups>
8376                    for SearchGroupsSvc<T> {
8377                        type Response = super::SearchGroupsResponse;
8378                        type Future = BoxFuture<
8379                            tonic::Response<Self::Response>,
8380                            tonic::Status,
8381                        >;
8382                        fn call(
8383                            &mut self,
8384                            request: tonic::Request<super::SearchPointGroups>,
8385                        ) -> Self::Future {
8386                            let inner = Arc::clone(&self.0);
8387                            let fut = async move {
8388                                <T as Points>::search_groups(&inner, request).await
8389                            };
8390                            Box::pin(fut)
8391                        }
8392                    }
8393                    let accept_compression_encodings = self.accept_compression_encodings;
8394                    let send_compression_encodings = self.send_compression_encodings;
8395                    let max_decoding_message_size = self.max_decoding_message_size;
8396                    let max_encoding_message_size = self.max_encoding_message_size;
8397                    let inner = self.inner.clone();
8398                    let fut = async move {
8399                        let method = SearchGroupsSvc(inner);
8400                        let codec = tonic_prost::ProstCodec::default();
8401                        let mut grpc = tonic::server::Grpc::new(codec)
8402                            .apply_compression_config(
8403                                accept_compression_encodings,
8404                                send_compression_encodings,
8405                            )
8406                            .apply_max_message_size_config(
8407                                max_decoding_message_size,
8408                                max_encoding_message_size,
8409                            );
8410                        let res = grpc.unary(method, req).await;
8411                        Ok(res)
8412                    };
8413                    Box::pin(fut)
8414                }
8415                "/qdrant.Points/Scroll" => {
8416                    #[allow(non_camel_case_types)]
8417                    struct ScrollSvc<T: Points>(pub Arc<T>);
8418                    impl<T: Points> tonic::server::UnaryService<super::ScrollPoints>
8419                    for ScrollSvc<T> {
8420                        type Response = super::ScrollResponse;
8421                        type Future = BoxFuture<
8422                            tonic::Response<Self::Response>,
8423                            tonic::Status,
8424                        >;
8425                        fn call(
8426                            &mut self,
8427                            request: tonic::Request<super::ScrollPoints>,
8428                        ) -> Self::Future {
8429                            let inner = Arc::clone(&self.0);
8430                            let fut = async move {
8431                                <T as Points>::scroll(&inner, request).await
8432                            };
8433                            Box::pin(fut)
8434                        }
8435                    }
8436                    let accept_compression_encodings = self.accept_compression_encodings;
8437                    let send_compression_encodings = self.send_compression_encodings;
8438                    let max_decoding_message_size = self.max_decoding_message_size;
8439                    let max_encoding_message_size = self.max_encoding_message_size;
8440                    let inner = self.inner.clone();
8441                    let fut = async move {
8442                        let method = ScrollSvc(inner);
8443                        let codec = tonic_prost::ProstCodec::default();
8444                        let mut grpc = tonic::server::Grpc::new(codec)
8445                            .apply_compression_config(
8446                                accept_compression_encodings,
8447                                send_compression_encodings,
8448                            )
8449                            .apply_max_message_size_config(
8450                                max_decoding_message_size,
8451                                max_encoding_message_size,
8452                            );
8453                        let res = grpc.unary(method, req).await;
8454                        Ok(res)
8455                    };
8456                    Box::pin(fut)
8457                }
8458                "/qdrant.Points/Recommend" => {
8459                    #[allow(non_camel_case_types)]
8460                    struct RecommendSvc<T: Points>(pub Arc<T>);
8461                    impl<T: Points> tonic::server::UnaryService<super::RecommendPoints>
8462                    for RecommendSvc<T> {
8463                        type Response = super::RecommendResponse;
8464                        type Future = BoxFuture<
8465                            tonic::Response<Self::Response>,
8466                            tonic::Status,
8467                        >;
8468                        fn call(
8469                            &mut self,
8470                            request: tonic::Request<super::RecommendPoints>,
8471                        ) -> Self::Future {
8472                            let inner = Arc::clone(&self.0);
8473                            let fut = async move {
8474                                <T as Points>::recommend(&inner, request).await
8475                            };
8476                            Box::pin(fut)
8477                        }
8478                    }
8479                    let accept_compression_encodings = self.accept_compression_encodings;
8480                    let send_compression_encodings = self.send_compression_encodings;
8481                    let max_decoding_message_size = self.max_decoding_message_size;
8482                    let max_encoding_message_size = self.max_encoding_message_size;
8483                    let inner = self.inner.clone();
8484                    let fut = async move {
8485                        let method = RecommendSvc(inner);
8486                        let codec = tonic_prost::ProstCodec::default();
8487                        let mut grpc = tonic::server::Grpc::new(codec)
8488                            .apply_compression_config(
8489                                accept_compression_encodings,
8490                                send_compression_encodings,
8491                            )
8492                            .apply_max_message_size_config(
8493                                max_decoding_message_size,
8494                                max_encoding_message_size,
8495                            );
8496                        let res = grpc.unary(method, req).await;
8497                        Ok(res)
8498                    };
8499                    Box::pin(fut)
8500                }
8501                "/qdrant.Points/RecommendBatch" => {
8502                    #[allow(non_camel_case_types)]
8503                    struct RecommendBatchSvc<T: Points>(pub Arc<T>);
8504                    impl<
8505                        T: Points,
8506                    > tonic::server::UnaryService<super::RecommendBatchPoints>
8507                    for RecommendBatchSvc<T> {
8508                        type Response = super::RecommendBatchResponse;
8509                        type Future = BoxFuture<
8510                            tonic::Response<Self::Response>,
8511                            tonic::Status,
8512                        >;
8513                        fn call(
8514                            &mut self,
8515                            request: tonic::Request<super::RecommendBatchPoints>,
8516                        ) -> Self::Future {
8517                            let inner = Arc::clone(&self.0);
8518                            let fut = async move {
8519                                <T as Points>::recommend_batch(&inner, request).await
8520                            };
8521                            Box::pin(fut)
8522                        }
8523                    }
8524                    let accept_compression_encodings = self.accept_compression_encodings;
8525                    let send_compression_encodings = self.send_compression_encodings;
8526                    let max_decoding_message_size = self.max_decoding_message_size;
8527                    let max_encoding_message_size = self.max_encoding_message_size;
8528                    let inner = self.inner.clone();
8529                    let fut = async move {
8530                        let method = RecommendBatchSvc(inner);
8531                        let codec = tonic_prost::ProstCodec::default();
8532                        let mut grpc = tonic::server::Grpc::new(codec)
8533                            .apply_compression_config(
8534                                accept_compression_encodings,
8535                                send_compression_encodings,
8536                            )
8537                            .apply_max_message_size_config(
8538                                max_decoding_message_size,
8539                                max_encoding_message_size,
8540                            );
8541                        let res = grpc.unary(method, req).await;
8542                        Ok(res)
8543                    };
8544                    Box::pin(fut)
8545                }
8546                "/qdrant.Points/RecommendGroups" => {
8547                    #[allow(non_camel_case_types)]
8548                    struct RecommendGroupsSvc<T: Points>(pub Arc<T>);
8549                    impl<
8550                        T: Points,
8551                    > tonic::server::UnaryService<super::RecommendPointGroups>
8552                    for RecommendGroupsSvc<T> {
8553                        type Response = super::RecommendGroupsResponse;
8554                        type Future = BoxFuture<
8555                            tonic::Response<Self::Response>,
8556                            tonic::Status,
8557                        >;
8558                        fn call(
8559                            &mut self,
8560                            request: tonic::Request<super::RecommendPointGroups>,
8561                        ) -> Self::Future {
8562                            let inner = Arc::clone(&self.0);
8563                            let fut = async move {
8564                                <T as Points>::recommend_groups(&inner, request).await
8565                            };
8566                            Box::pin(fut)
8567                        }
8568                    }
8569                    let accept_compression_encodings = self.accept_compression_encodings;
8570                    let send_compression_encodings = self.send_compression_encodings;
8571                    let max_decoding_message_size = self.max_decoding_message_size;
8572                    let max_encoding_message_size = self.max_encoding_message_size;
8573                    let inner = self.inner.clone();
8574                    let fut = async move {
8575                        let method = RecommendGroupsSvc(inner);
8576                        let codec = tonic_prost::ProstCodec::default();
8577                        let mut grpc = tonic::server::Grpc::new(codec)
8578                            .apply_compression_config(
8579                                accept_compression_encodings,
8580                                send_compression_encodings,
8581                            )
8582                            .apply_max_message_size_config(
8583                                max_decoding_message_size,
8584                                max_encoding_message_size,
8585                            );
8586                        let res = grpc.unary(method, req).await;
8587                        Ok(res)
8588                    };
8589                    Box::pin(fut)
8590                }
8591                "/qdrant.Points/Discover" => {
8592                    #[allow(non_camel_case_types)]
8593                    struct DiscoverSvc<T: Points>(pub Arc<T>);
8594                    impl<T: Points> tonic::server::UnaryService<super::DiscoverPoints>
8595                    for DiscoverSvc<T> {
8596                        type Response = super::DiscoverResponse;
8597                        type Future = BoxFuture<
8598                            tonic::Response<Self::Response>,
8599                            tonic::Status,
8600                        >;
8601                        fn call(
8602                            &mut self,
8603                            request: tonic::Request<super::DiscoverPoints>,
8604                        ) -> Self::Future {
8605                            let inner = Arc::clone(&self.0);
8606                            let fut = async move {
8607                                <T as Points>::discover(&inner, request).await
8608                            };
8609                            Box::pin(fut)
8610                        }
8611                    }
8612                    let accept_compression_encodings = self.accept_compression_encodings;
8613                    let send_compression_encodings = self.send_compression_encodings;
8614                    let max_decoding_message_size = self.max_decoding_message_size;
8615                    let max_encoding_message_size = self.max_encoding_message_size;
8616                    let inner = self.inner.clone();
8617                    let fut = async move {
8618                        let method = DiscoverSvc(inner);
8619                        let codec = tonic_prost::ProstCodec::default();
8620                        let mut grpc = tonic::server::Grpc::new(codec)
8621                            .apply_compression_config(
8622                                accept_compression_encodings,
8623                                send_compression_encodings,
8624                            )
8625                            .apply_max_message_size_config(
8626                                max_decoding_message_size,
8627                                max_encoding_message_size,
8628                            );
8629                        let res = grpc.unary(method, req).await;
8630                        Ok(res)
8631                    };
8632                    Box::pin(fut)
8633                }
8634                "/qdrant.Points/DiscoverBatch" => {
8635                    #[allow(non_camel_case_types)]
8636                    struct DiscoverBatchSvc<T: Points>(pub Arc<T>);
8637                    impl<
8638                        T: Points,
8639                    > tonic::server::UnaryService<super::DiscoverBatchPoints>
8640                    for DiscoverBatchSvc<T> {
8641                        type Response = super::DiscoverBatchResponse;
8642                        type Future = BoxFuture<
8643                            tonic::Response<Self::Response>,
8644                            tonic::Status,
8645                        >;
8646                        fn call(
8647                            &mut self,
8648                            request: tonic::Request<super::DiscoverBatchPoints>,
8649                        ) -> Self::Future {
8650                            let inner = Arc::clone(&self.0);
8651                            let fut = async move {
8652                                <T as Points>::discover_batch(&inner, request).await
8653                            };
8654                            Box::pin(fut)
8655                        }
8656                    }
8657                    let accept_compression_encodings = self.accept_compression_encodings;
8658                    let send_compression_encodings = self.send_compression_encodings;
8659                    let max_decoding_message_size = self.max_decoding_message_size;
8660                    let max_encoding_message_size = self.max_encoding_message_size;
8661                    let inner = self.inner.clone();
8662                    let fut = async move {
8663                        let method = DiscoverBatchSvc(inner);
8664                        let codec = tonic_prost::ProstCodec::default();
8665                        let mut grpc = tonic::server::Grpc::new(codec)
8666                            .apply_compression_config(
8667                                accept_compression_encodings,
8668                                send_compression_encodings,
8669                            )
8670                            .apply_max_message_size_config(
8671                                max_decoding_message_size,
8672                                max_encoding_message_size,
8673                            );
8674                        let res = grpc.unary(method, req).await;
8675                        Ok(res)
8676                    };
8677                    Box::pin(fut)
8678                }
8679                "/qdrant.Points/Count" => {
8680                    #[allow(non_camel_case_types)]
8681                    struct CountSvc<T: Points>(pub Arc<T>);
8682                    impl<T: Points> tonic::server::UnaryService<super::CountPoints>
8683                    for CountSvc<T> {
8684                        type Response = super::CountResponse;
8685                        type Future = BoxFuture<
8686                            tonic::Response<Self::Response>,
8687                            tonic::Status,
8688                        >;
8689                        fn call(
8690                            &mut self,
8691                            request: tonic::Request<super::CountPoints>,
8692                        ) -> Self::Future {
8693                            let inner = Arc::clone(&self.0);
8694                            let fut = async move {
8695                                <T as Points>::count(&inner, request).await
8696                            };
8697                            Box::pin(fut)
8698                        }
8699                    }
8700                    let accept_compression_encodings = self.accept_compression_encodings;
8701                    let send_compression_encodings = self.send_compression_encodings;
8702                    let max_decoding_message_size = self.max_decoding_message_size;
8703                    let max_encoding_message_size = self.max_encoding_message_size;
8704                    let inner = self.inner.clone();
8705                    let fut = async move {
8706                        let method = CountSvc(inner);
8707                        let codec = tonic_prost::ProstCodec::default();
8708                        let mut grpc = tonic::server::Grpc::new(codec)
8709                            .apply_compression_config(
8710                                accept_compression_encodings,
8711                                send_compression_encodings,
8712                            )
8713                            .apply_max_message_size_config(
8714                                max_decoding_message_size,
8715                                max_encoding_message_size,
8716                            );
8717                        let res = grpc.unary(method, req).await;
8718                        Ok(res)
8719                    };
8720                    Box::pin(fut)
8721                }
8722                "/qdrant.Points/UpdateBatch" => {
8723                    #[allow(non_camel_case_types)]
8724                    struct UpdateBatchSvc<T: Points>(pub Arc<T>);
8725                    impl<T: Points> tonic::server::UnaryService<super::UpdateBatchPoints>
8726                    for UpdateBatchSvc<T> {
8727                        type Response = super::UpdateBatchResponse;
8728                        type Future = BoxFuture<
8729                            tonic::Response<Self::Response>,
8730                            tonic::Status,
8731                        >;
8732                        fn call(
8733                            &mut self,
8734                            request: tonic::Request<super::UpdateBatchPoints>,
8735                        ) -> Self::Future {
8736                            let inner = Arc::clone(&self.0);
8737                            let fut = async move {
8738                                <T as Points>::update_batch(&inner, request).await
8739                            };
8740                            Box::pin(fut)
8741                        }
8742                    }
8743                    let accept_compression_encodings = self.accept_compression_encodings;
8744                    let send_compression_encodings = self.send_compression_encodings;
8745                    let max_decoding_message_size = self.max_decoding_message_size;
8746                    let max_encoding_message_size = self.max_encoding_message_size;
8747                    let inner = self.inner.clone();
8748                    let fut = async move {
8749                        let method = UpdateBatchSvc(inner);
8750                        let codec = tonic_prost::ProstCodec::default();
8751                        let mut grpc = tonic::server::Grpc::new(codec)
8752                            .apply_compression_config(
8753                                accept_compression_encodings,
8754                                send_compression_encodings,
8755                            )
8756                            .apply_max_message_size_config(
8757                                max_decoding_message_size,
8758                                max_encoding_message_size,
8759                            );
8760                        let res = grpc.unary(method, req).await;
8761                        Ok(res)
8762                    };
8763                    Box::pin(fut)
8764                }
8765                "/qdrant.Points/Query" => {
8766                    #[allow(non_camel_case_types)]
8767                    struct QuerySvc<T: Points>(pub Arc<T>);
8768                    impl<T: Points> tonic::server::UnaryService<super::QueryPoints>
8769                    for QuerySvc<T> {
8770                        type Response = super::QueryResponse;
8771                        type Future = BoxFuture<
8772                            tonic::Response<Self::Response>,
8773                            tonic::Status,
8774                        >;
8775                        fn call(
8776                            &mut self,
8777                            request: tonic::Request<super::QueryPoints>,
8778                        ) -> Self::Future {
8779                            let inner = Arc::clone(&self.0);
8780                            let fut = async move {
8781                                <T as Points>::query(&inner, request).await
8782                            };
8783                            Box::pin(fut)
8784                        }
8785                    }
8786                    let accept_compression_encodings = self.accept_compression_encodings;
8787                    let send_compression_encodings = self.send_compression_encodings;
8788                    let max_decoding_message_size = self.max_decoding_message_size;
8789                    let max_encoding_message_size = self.max_encoding_message_size;
8790                    let inner = self.inner.clone();
8791                    let fut = async move {
8792                        let method = QuerySvc(inner);
8793                        let codec = tonic_prost::ProstCodec::default();
8794                        let mut grpc = tonic::server::Grpc::new(codec)
8795                            .apply_compression_config(
8796                                accept_compression_encodings,
8797                                send_compression_encodings,
8798                            )
8799                            .apply_max_message_size_config(
8800                                max_decoding_message_size,
8801                                max_encoding_message_size,
8802                            );
8803                        let res = grpc.unary(method, req).await;
8804                        Ok(res)
8805                    };
8806                    Box::pin(fut)
8807                }
8808                "/qdrant.Points/QueryBatch" => {
8809                    #[allow(non_camel_case_types)]
8810                    struct QueryBatchSvc<T: Points>(pub Arc<T>);
8811                    impl<T: Points> tonic::server::UnaryService<super::QueryBatchPoints>
8812                    for QueryBatchSvc<T> {
8813                        type Response = super::QueryBatchResponse;
8814                        type Future = BoxFuture<
8815                            tonic::Response<Self::Response>,
8816                            tonic::Status,
8817                        >;
8818                        fn call(
8819                            &mut self,
8820                            request: tonic::Request<super::QueryBatchPoints>,
8821                        ) -> Self::Future {
8822                            let inner = Arc::clone(&self.0);
8823                            let fut = async move {
8824                                <T as Points>::query_batch(&inner, request).await
8825                            };
8826                            Box::pin(fut)
8827                        }
8828                    }
8829                    let accept_compression_encodings = self.accept_compression_encodings;
8830                    let send_compression_encodings = self.send_compression_encodings;
8831                    let max_decoding_message_size = self.max_decoding_message_size;
8832                    let max_encoding_message_size = self.max_encoding_message_size;
8833                    let inner = self.inner.clone();
8834                    let fut = async move {
8835                        let method = QueryBatchSvc(inner);
8836                        let codec = tonic_prost::ProstCodec::default();
8837                        let mut grpc = tonic::server::Grpc::new(codec)
8838                            .apply_compression_config(
8839                                accept_compression_encodings,
8840                                send_compression_encodings,
8841                            )
8842                            .apply_max_message_size_config(
8843                                max_decoding_message_size,
8844                                max_encoding_message_size,
8845                            );
8846                        let res = grpc.unary(method, req).await;
8847                        Ok(res)
8848                    };
8849                    Box::pin(fut)
8850                }
8851                "/qdrant.Points/QueryGroups" => {
8852                    #[allow(non_camel_case_types)]
8853                    struct QueryGroupsSvc<T: Points>(pub Arc<T>);
8854                    impl<T: Points> tonic::server::UnaryService<super::QueryPointGroups>
8855                    for QueryGroupsSvc<T> {
8856                        type Response = super::QueryGroupsResponse;
8857                        type Future = BoxFuture<
8858                            tonic::Response<Self::Response>,
8859                            tonic::Status,
8860                        >;
8861                        fn call(
8862                            &mut self,
8863                            request: tonic::Request<super::QueryPointGroups>,
8864                        ) -> Self::Future {
8865                            let inner = Arc::clone(&self.0);
8866                            let fut = async move {
8867                                <T as Points>::query_groups(&inner, request).await
8868                            };
8869                            Box::pin(fut)
8870                        }
8871                    }
8872                    let accept_compression_encodings = self.accept_compression_encodings;
8873                    let send_compression_encodings = self.send_compression_encodings;
8874                    let max_decoding_message_size = self.max_decoding_message_size;
8875                    let max_encoding_message_size = self.max_encoding_message_size;
8876                    let inner = self.inner.clone();
8877                    let fut = async move {
8878                        let method = QueryGroupsSvc(inner);
8879                        let codec = tonic_prost::ProstCodec::default();
8880                        let mut grpc = tonic::server::Grpc::new(codec)
8881                            .apply_compression_config(
8882                                accept_compression_encodings,
8883                                send_compression_encodings,
8884                            )
8885                            .apply_max_message_size_config(
8886                                max_decoding_message_size,
8887                                max_encoding_message_size,
8888                            );
8889                        let res = grpc.unary(method, req).await;
8890                        Ok(res)
8891                    };
8892                    Box::pin(fut)
8893                }
8894                "/qdrant.Points/Facet" => {
8895                    #[allow(non_camel_case_types)]
8896                    struct FacetSvc<T: Points>(pub Arc<T>);
8897                    impl<T: Points> tonic::server::UnaryService<super::FacetCounts>
8898                    for FacetSvc<T> {
8899                        type Response = super::FacetResponse;
8900                        type Future = BoxFuture<
8901                            tonic::Response<Self::Response>,
8902                            tonic::Status,
8903                        >;
8904                        fn call(
8905                            &mut self,
8906                            request: tonic::Request<super::FacetCounts>,
8907                        ) -> Self::Future {
8908                            let inner = Arc::clone(&self.0);
8909                            let fut = async move {
8910                                <T as Points>::facet(&inner, request).await
8911                            };
8912                            Box::pin(fut)
8913                        }
8914                    }
8915                    let accept_compression_encodings = self.accept_compression_encodings;
8916                    let send_compression_encodings = self.send_compression_encodings;
8917                    let max_decoding_message_size = self.max_decoding_message_size;
8918                    let max_encoding_message_size = self.max_encoding_message_size;
8919                    let inner = self.inner.clone();
8920                    let fut = async move {
8921                        let method = FacetSvc(inner);
8922                        let codec = tonic_prost::ProstCodec::default();
8923                        let mut grpc = tonic::server::Grpc::new(codec)
8924                            .apply_compression_config(
8925                                accept_compression_encodings,
8926                                send_compression_encodings,
8927                            )
8928                            .apply_max_message_size_config(
8929                                max_decoding_message_size,
8930                                max_encoding_message_size,
8931                            );
8932                        let res = grpc.unary(method, req).await;
8933                        Ok(res)
8934                    };
8935                    Box::pin(fut)
8936                }
8937                "/qdrant.Points/SearchMatrixPairs" => {
8938                    #[allow(non_camel_case_types)]
8939                    struct SearchMatrixPairsSvc<T: Points>(pub Arc<T>);
8940                    impl<
8941                        T: Points,
8942                    > tonic::server::UnaryService<super::SearchMatrixPoints>
8943                    for SearchMatrixPairsSvc<T> {
8944                        type Response = super::SearchMatrixPairsResponse;
8945                        type Future = BoxFuture<
8946                            tonic::Response<Self::Response>,
8947                            tonic::Status,
8948                        >;
8949                        fn call(
8950                            &mut self,
8951                            request: tonic::Request<super::SearchMatrixPoints>,
8952                        ) -> Self::Future {
8953                            let inner = Arc::clone(&self.0);
8954                            let fut = async move {
8955                                <T as Points>::search_matrix_pairs(&inner, request).await
8956                            };
8957                            Box::pin(fut)
8958                        }
8959                    }
8960                    let accept_compression_encodings = self.accept_compression_encodings;
8961                    let send_compression_encodings = self.send_compression_encodings;
8962                    let max_decoding_message_size = self.max_decoding_message_size;
8963                    let max_encoding_message_size = self.max_encoding_message_size;
8964                    let inner = self.inner.clone();
8965                    let fut = async move {
8966                        let method = SearchMatrixPairsSvc(inner);
8967                        let codec = tonic_prost::ProstCodec::default();
8968                        let mut grpc = tonic::server::Grpc::new(codec)
8969                            .apply_compression_config(
8970                                accept_compression_encodings,
8971                                send_compression_encodings,
8972                            )
8973                            .apply_max_message_size_config(
8974                                max_decoding_message_size,
8975                                max_encoding_message_size,
8976                            );
8977                        let res = grpc.unary(method, req).await;
8978                        Ok(res)
8979                    };
8980                    Box::pin(fut)
8981                }
8982                "/qdrant.Points/SearchMatrixOffsets" => {
8983                    #[allow(non_camel_case_types)]
8984                    struct SearchMatrixOffsetsSvc<T: Points>(pub Arc<T>);
8985                    impl<
8986                        T: Points,
8987                    > tonic::server::UnaryService<super::SearchMatrixPoints>
8988                    for SearchMatrixOffsetsSvc<T> {
8989                        type Response = super::SearchMatrixOffsetsResponse;
8990                        type Future = BoxFuture<
8991                            tonic::Response<Self::Response>,
8992                            tonic::Status,
8993                        >;
8994                        fn call(
8995                            &mut self,
8996                            request: tonic::Request<super::SearchMatrixPoints>,
8997                        ) -> Self::Future {
8998                            let inner = Arc::clone(&self.0);
8999                            let fut = async move {
9000                                <T as Points>::search_matrix_offsets(&inner, request).await
9001                            };
9002                            Box::pin(fut)
9003                        }
9004                    }
9005                    let accept_compression_encodings = self.accept_compression_encodings;
9006                    let send_compression_encodings = self.send_compression_encodings;
9007                    let max_decoding_message_size = self.max_decoding_message_size;
9008                    let max_encoding_message_size = self.max_encoding_message_size;
9009                    let inner = self.inner.clone();
9010                    let fut = async move {
9011                        let method = SearchMatrixOffsetsSvc(inner);
9012                        let codec = tonic_prost::ProstCodec::default();
9013                        let mut grpc = tonic::server::Grpc::new(codec)
9014                            .apply_compression_config(
9015                                accept_compression_encodings,
9016                                send_compression_encodings,
9017                            )
9018                            .apply_max_message_size_config(
9019                                max_decoding_message_size,
9020                                max_encoding_message_size,
9021                            );
9022                        let res = grpc.unary(method, req).await;
9023                        Ok(res)
9024                    };
9025                    Box::pin(fut)
9026                }
9027                _ => {
9028                    Box::pin(async move {
9029                        let mut response = http::Response::new(
9030                            tonic::body::Body::default(),
9031                        );
9032                        let headers = response.headers_mut();
9033                        headers
9034                            .insert(
9035                                tonic::Status::GRPC_STATUS,
9036                                (tonic::Code::Unimplemented as i32).into(),
9037                            );
9038                        headers
9039                            .insert(
9040                                http::header::CONTENT_TYPE,
9041                                tonic::metadata::GRPC_CONTENT_TYPE,
9042                            );
9043                        Ok(response)
9044                    })
9045                }
9046            }
9047        }
9048    }
9049    impl<T> Clone for PointsServer<T> {
9050        fn clone(&self) -> Self {
9051            let inner = self.inner.clone();
9052            Self {
9053                inner,
9054                accept_compression_encodings: self.accept_compression_encodings,
9055                send_compression_encodings: self.send_compression_encodings,
9056                max_decoding_message_size: self.max_decoding_message_size,
9057                max_encoding_message_size: self.max_encoding_message_size,
9058            }
9059        }
9060    }
9061    /// Generated gRPC service name
9062    pub const SERVICE_NAME: &str = "qdrant.Points";
9063    impl<T> tonic::server::NamedService for PointsServer<T> {
9064        const NAME: &'static str = SERVICE_NAME;
9065    }
9066}
9067#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
9068pub struct CreateFullSnapshotRequest {}
9069#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
9070pub struct ListFullSnapshotsRequest {}
9071#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
9072pub struct DeleteFullSnapshotRequest {
9073    /// Name of the full snapshot
9074    #[prost(string, tag = "1")]
9075    pub snapshot_name: ::prost::alloc::string::String,
9076}
9077#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
9078pub struct CreateSnapshotRequest {
9079    /// Name of the collection
9080    #[prost(string, tag = "1")]
9081    pub collection_name: ::prost::alloc::string::String,
9082}
9083#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
9084pub struct ListSnapshotsRequest {
9085    /// Name of the collection
9086    #[prost(string, tag = "1")]
9087    pub collection_name: ::prost::alloc::string::String,
9088}
9089#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
9090pub struct DeleteSnapshotRequest {
9091    /// Name of the collection
9092    #[prost(string, tag = "1")]
9093    pub collection_name: ::prost::alloc::string::String,
9094    /// Name of the collection snapshot
9095    #[prost(string, tag = "2")]
9096    pub snapshot_name: ::prost::alloc::string::String,
9097}
9098#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
9099pub struct SnapshotDescription {
9100    /// Name of the snapshot
9101    #[prost(string, tag = "1")]
9102    pub name: ::prost::alloc::string::String,
9103    /// Creation time of the snapshot
9104    #[prost(message, optional, tag = "2")]
9105    pub creation_time: ::core::option::Option<::prost_types::Timestamp>,
9106    /// Size of the snapshot in bytes
9107    #[prost(int64, tag = "3")]
9108    pub size: i64,
9109    /// SHA256 digest of the snapshot file
9110    #[prost(string, optional, tag = "4")]
9111    pub checksum: ::core::option::Option<::prost::alloc::string::String>,
9112}
9113#[derive(Clone, PartialEq, ::prost::Message)]
9114pub struct CreateSnapshotResponse {
9115    #[prost(message, optional, tag = "1")]
9116    pub snapshot_description: ::core::option::Option<SnapshotDescription>,
9117    /// Time spent to process
9118    #[prost(double, tag = "2")]
9119    pub time: f64,
9120}
9121#[derive(Clone, PartialEq, ::prost::Message)]
9122pub struct ListSnapshotsResponse {
9123    #[prost(message, repeated, tag = "1")]
9124    pub snapshot_descriptions: ::prost::alloc::vec::Vec<SnapshotDescription>,
9125    /// Time spent to process
9126    #[prost(double, tag = "2")]
9127    pub time: f64,
9128}
9129#[derive(Clone, Copy, PartialEq, ::prost::Message)]
9130pub struct DeleteSnapshotResponse {
9131    /// Time spent to process
9132    #[prost(double, tag = "1")]
9133    pub time: f64,
9134}
9135/// Generated client implementations.
9136pub mod snapshots_client {
9137    #![allow(
9138        unused_variables,
9139        dead_code,
9140        missing_docs,
9141        clippy::wildcard_imports,
9142        clippy::let_unit_value,
9143    )]
9144    use tonic::codegen::*;
9145    use tonic::codegen::http::Uri;
9146    #[derive(Debug, Clone)]
9147    pub struct SnapshotsClient<T> {
9148        inner: tonic::client::Grpc<T>,
9149    }
9150    impl SnapshotsClient<tonic::transport::Channel> {
9151        /// Attempt to create a new client by connecting to a given endpoint.
9152        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
9153        where
9154            D: TryInto<tonic::transport::Endpoint>,
9155            D::Error: Into<StdError>,
9156        {
9157            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
9158            Ok(Self::new(conn))
9159        }
9160    }
9161    impl<T> SnapshotsClient<T>
9162    where
9163        T: tonic::client::GrpcService<tonic::body::Body>,
9164        T::Error: Into<StdError>,
9165        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
9166        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
9167    {
9168        pub fn new(inner: T) -> Self {
9169            let inner = tonic::client::Grpc::new(inner);
9170            Self { inner }
9171        }
9172        pub fn with_origin(inner: T, origin: Uri) -> Self {
9173            let inner = tonic::client::Grpc::with_origin(inner, origin);
9174            Self { inner }
9175        }
9176        pub fn with_interceptor<F>(
9177            inner: T,
9178            interceptor: F,
9179        ) -> SnapshotsClient<InterceptedService<T, F>>
9180        where
9181            F: tonic::service::Interceptor,
9182            T::ResponseBody: Default,
9183            T: tonic::codegen::Service<
9184                http::Request<tonic::body::Body>,
9185                Response = http::Response<
9186                    <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
9187                >,
9188            >,
9189            <T as tonic::codegen::Service<
9190                http::Request<tonic::body::Body>,
9191            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
9192        {
9193            SnapshotsClient::new(InterceptedService::new(inner, interceptor))
9194        }
9195        /// Compress requests with the given encoding.
9196        ///
9197        /// This requires the server to support it otherwise it might respond with an
9198        /// error.
9199        #[must_use]
9200        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
9201            self.inner = self.inner.send_compressed(encoding);
9202            self
9203        }
9204        /// Enable decompressing responses.
9205        #[must_use]
9206        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
9207            self.inner = self.inner.accept_compressed(encoding);
9208            self
9209        }
9210        /// Limits the maximum size of a decoded message.
9211        ///
9212        /// Default: `4MB`
9213        #[must_use]
9214        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
9215            self.inner = self.inner.max_decoding_message_size(limit);
9216            self
9217        }
9218        /// Limits the maximum size of an encoded message.
9219        ///
9220        /// Default: `usize::MAX`
9221        #[must_use]
9222        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
9223            self.inner = self.inner.max_encoding_message_size(limit);
9224            self
9225        }
9226        /// Create collection snapshot
9227        pub async fn create(
9228            &mut self,
9229            request: impl tonic::IntoRequest<super::CreateSnapshotRequest>,
9230        ) -> std::result::Result<
9231            tonic::Response<super::CreateSnapshotResponse>,
9232            tonic::Status,
9233        > {
9234            self.inner
9235                .ready()
9236                .await
9237                .map_err(|e| {
9238                    tonic::Status::unknown(
9239                        format!("Service was not ready: {}", e.into()),
9240                    )
9241                })?;
9242            let codec = tonic_prost::ProstCodec::default();
9243            let path = http::uri::PathAndQuery::from_static("/qdrant.Snapshots/Create");
9244            let mut req = request.into_request();
9245            req.extensions_mut().insert(GrpcMethod::new("qdrant.Snapshots", "Create"));
9246            self.inner.unary(req, path, codec).await
9247        }
9248        /// List collection snapshots
9249        pub async fn list(
9250            &mut self,
9251            request: impl tonic::IntoRequest<super::ListSnapshotsRequest>,
9252        ) -> std::result::Result<
9253            tonic::Response<super::ListSnapshotsResponse>,
9254            tonic::Status,
9255        > {
9256            self.inner
9257                .ready()
9258                .await
9259                .map_err(|e| {
9260                    tonic::Status::unknown(
9261                        format!("Service was not ready: {}", e.into()),
9262                    )
9263                })?;
9264            let codec = tonic_prost::ProstCodec::default();
9265            let path = http::uri::PathAndQuery::from_static("/qdrant.Snapshots/List");
9266            let mut req = request.into_request();
9267            req.extensions_mut().insert(GrpcMethod::new("qdrant.Snapshots", "List"));
9268            self.inner.unary(req, path, codec).await
9269        }
9270        /// Delete collection snapshot
9271        pub async fn delete(
9272            &mut self,
9273            request: impl tonic::IntoRequest<super::DeleteSnapshotRequest>,
9274        ) -> std::result::Result<
9275            tonic::Response<super::DeleteSnapshotResponse>,
9276            tonic::Status,
9277        > {
9278            self.inner
9279                .ready()
9280                .await
9281                .map_err(|e| {
9282                    tonic::Status::unknown(
9283                        format!("Service was not ready: {}", e.into()),
9284                    )
9285                })?;
9286            let codec = tonic_prost::ProstCodec::default();
9287            let path = http::uri::PathAndQuery::from_static("/qdrant.Snapshots/Delete");
9288            let mut req = request.into_request();
9289            req.extensions_mut().insert(GrpcMethod::new("qdrant.Snapshots", "Delete"));
9290            self.inner.unary(req, path, codec).await
9291        }
9292        /// Create full storage snapshot
9293        pub async fn create_full(
9294            &mut self,
9295            request: impl tonic::IntoRequest<super::CreateFullSnapshotRequest>,
9296        ) -> std::result::Result<
9297            tonic::Response<super::CreateSnapshotResponse>,
9298            tonic::Status,
9299        > {
9300            self.inner
9301                .ready()
9302                .await
9303                .map_err(|e| {
9304                    tonic::Status::unknown(
9305                        format!("Service was not ready: {}", e.into()),
9306                    )
9307                })?;
9308            let codec = tonic_prost::ProstCodec::default();
9309            let path = http::uri::PathAndQuery::from_static(
9310                "/qdrant.Snapshots/CreateFull",
9311            );
9312            let mut req = request.into_request();
9313            req.extensions_mut()
9314                .insert(GrpcMethod::new("qdrant.Snapshots", "CreateFull"));
9315            self.inner.unary(req, path, codec).await
9316        }
9317        /// List full storage snapshots
9318        pub async fn list_full(
9319            &mut self,
9320            request: impl tonic::IntoRequest<super::ListFullSnapshotsRequest>,
9321        ) -> std::result::Result<
9322            tonic::Response<super::ListSnapshotsResponse>,
9323            tonic::Status,
9324        > {
9325            self.inner
9326                .ready()
9327                .await
9328                .map_err(|e| {
9329                    tonic::Status::unknown(
9330                        format!("Service was not ready: {}", e.into()),
9331                    )
9332                })?;
9333            let codec = tonic_prost::ProstCodec::default();
9334            let path = http::uri::PathAndQuery::from_static(
9335                "/qdrant.Snapshots/ListFull",
9336            );
9337            let mut req = request.into_request();
9338            req.extensions_mut().insert(GrpcMethod::new("qdrant.Snapshots", "ListFull"));
9339            self.inner.unary(req, path, codec).await
9340        }
9341        /// Delete full storage snapshot
9342        pub async fn delete_full(
9343            &mut self,
9344            request: impl tonic::IntoRequest<super::DeleteFullSnapshotRequest>,
9345        ) -> std::result::Result<
9346            tonic::Response<super::DeleteSnapshotResponse>,
9347            tonic::Status,
9348        > {
9349            self.inner
9350                .ready()
9351                .await
9352                .map_err(|e| {
9353                    tonic::Status::unknown(
9354                        format!("Service was not ready: {}", e.into()),
9355                    )
9356                })?;
9357            let codec = tonic_prost::ProstCodec::default();
9358            let path = http::uri::PathAndQuery::from_static(
9359                "/qdrant.Snapshots/DeleteFull",
9360            );
9361            let mut req = request.into_request();
9362            req.extensions_mut()
9363                .insert(GrpcMethod::new("qdrant.Snapshots", "DeleteFull"));
9364            self.inner.unary(req, path, codec).await
9365        }
9366    }
9367}
9368/// Generated server implementations.
9369pub mod snapshots_server {
9370    #![allow(
9371        unused_variables,
9372        dead_code,
9373        missing_docs,
9374        clippy::wildcard_imports,
9375        clippy::let_unit_value,
9376    )]
9377    use tonic::codegen::*;
9378    /// Generated trait containing gRPC methods that should be implemented for use with SnapshotsServer.
9379    #[async_trait]
9380    pub trait Snapshots: std::marker::Send + std::marker::Sync + 'static {
9381        /// Create collection snapshot
9382        async fn create(
9383            &self,
9384            request: tonic::Request<super::CreateSnapshotRequest>,
9385        ) -> std::result::Result<
9386            tonic::Response<super::CreateSnapshotResponse>,
9387            tonic::Status,
9388        >;
9389        /// List collection snapshots
9390        async fn list(
9391            &self,
9392            request: tonic::Request<super::ListSnapshotsRequest>,
9393        ) -> std::result::Result<
9394            tonic::Response<super::ListSnapshotsResponse>,
9395            tonic::Status,
9396        >;
9397        /// Delete collection snapshot
9398        async fn delete(
9399            &self,
9400            request: tonic::Request<super::DeleteSnapshotRequest>,
9401        ) -> std::result::Result<
9402            tonic::Response<super::DeleteSnapshotResponse>,
9403            tonic::Status,
9404        >;
9405        /// Create full storage snapshot
9406        async fn create_full(
9407            &self,
9408            request: tonic::Request<super::CreateFullSnapshotRequest>,
9409        ) -> std::result::Result<
9410            tonic::Response<super::CreateSnapshotResponse>,
9411            tonic::Status,
9412        >;
9413        /// List full storage snapshots
9414        async fn list_full(
9415            &self,
9416            request: tonic::Request<super::ListFullSnapshotsRequest>,
9417        ) -> std::result::Result<
9418            tonic::Response<super::ListSnapshotsResponse>,
9419            tonic::Status,
9420        >;
9421        /// Delete full storage snapshot
9422        async fn delete_full(
9423            &self,
9424            request: tonic::Request<super::DeleteFullSnapshotRequest>,
9425        ) -> std::result::Result<
9426            tonic::Response<super::DeleteSnapshotResponse>,
9427            tonic::Status,
9428        >;
9429    }
9430    #[derive(Debug)]
9431    pub struct SnapshotsServer<T> {
9432        inner: Arc<T>,
9433        accept_compression_encodings: EnabledCompressionEncodings,
9434        send_compression_encodings: EnabledCompressionEncodings,
9435        max_decoding_message_size: Option<usize>,
9436        max_encoding_message_size: Option<usize>,
9437    }
9438    impl<T> SnapshotsServer<T> {
9439        pub fn new(inner: T) -> Self {
9440            Self::from_arc(Arc::new(inner))
9441        }
9442        pub fn from_arc(inner: Arc<T>) -> Self {
9443            Self {
9444                inner,
9445                accept_compression_encodings: Default::default(),
9446                send_compression_encodings: Default::default(),
9447                max_decoding_message_size: None,
9448                max_encoding_message_size: None,
9449            }
9450        }
9451        pub fn with_interceptor<F>(
9452            inner: T,
9453            interceptor: F,
9454        ) -> InterceptedService<Self, F>
9455        where
9456            F: tonic::service::Interceptor,
9457        {
9458            InterceptedService::new(Self::new(inner), interceptor)
9459        }
9460        /// Enable decompressing requests with the given encoding.
9461        #[must_use]
9462        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
9463            self.accept_compression_encodings.enable(encoding);
9464            self
9465        }
9466        /// Compress responses with the given encoding, if the client supports it.
9467        #[must_use]
9468        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
9469            self.send_compression_encodings.enable(encoding);
9470            self
9471        }
9472        /// Limits the maximum size of a decoded message.
9473        ///
9474        /// Default: `4MB`
9475        #[must_use]
9476        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
9477            self.max_decoding_message_size = Some(limit);
9478            self
9479        }
9480        /// Limits the maximum size of an encoded message.
9481        ///
9482        /// Default: `usize::MAX`
9483        #[must_use]
9484        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
9485            self.max_encoding_message_size = Some(limit);
9486            self
9487        }
9488    }
9489    impl<T, B> tonic::codegen::Service<http::Request<B>> for SnapshotsServer<T>
9490    where
9491        T: Snapshots,
9492        B: Body + std::marker::Send + 'static,
9493        B::Error: Into<StdError> + std::marker::Send + 'static,
9494    {
9495        type Response = http::Response<tonic::body::Body>;
9496        type Error = std::convert::Infallible;
9497        type Future = BoxFuture<Self::Response, Self::Error>;
9498        fn poll_ready(
9499            &mut self,
9500            _cx: &mut Context<'_>,
9501        ) -> Poll<std::result::Result<(), Self::Error>> {
9502            Poll::Ready(Ok(()))
9503        }
9504        fn call(&mut self, req: http::Request<B>) -> Self::Future {
9505            match req.uri().path() {
9506                "/qdrant.Snapshots/Create" => {
9507                    #[allow(non_camel_case_types)]
9508                    struct CreateSvc<T: Snapshots>(pub Arc<T>);
9509                    impl<
9510                        T: Snapshots,
9511                    > tonic::server::UnaryService<super::CreateSnapshotRequest>
9512                    for CreateSvc<T> {
9513                        type Response = super::CreateSnapshotResponse;
9514                        type Future = BoxFuture<
9515                            tonic::Response<Self::Response>,
9516                            tonic::Status,
9517                        >;
9518                        fn call(
9519                            &mut self,
9520                            request: tonic::Request<super::CreateSnapshotRequest>,
9521                        ) -> Self::Future {
9522                            let inner = Arc::clone(&self.0);
9523                            let fut = async move {
9524                                <T as Snapshots>::create(&inner, request).await
9525                            };
9526                            Box::pin(fut)
9527                        }
9528                    }
9529                    let accept_compression_encodings = self.accept_compression_encodings;
9530                    let send_compression_encodings = self.send_compression_encodings;
9531                    let max_decoding_message_size = self.max_decoding_message_size;
9532                    let max_encoding_message_size = self.max_encoding_message_size;
9533                    let inner = self.inner.clone();
9534                    let fut = async move {
9535                        let method = CreateSvc(inner);
9536                        let codec = tonic_prost::ProstCodec::default();
9537                        let mut grpc = tonic::server::Grpc::new(codec)
9538                            .apply_compression_config(
9539                                accept_compression_encodings,
9540                                send_compression_encodings,
9541                            )
9542                            .apply_max_message_size_config(
9543                                max_decoding_message_size,
9544                                max_encoding_message_size,
9545                            );
9546                        let res = grpc.unary(method, req).await;
9547                        Ok(res)
9548                    };
9549                    Box::pin(fut)
9550                }
9551                "/qdrant.Snapshots/List" => {
9552                    #[allow(non_camel_case_types)]
9553                    struct ListSvc<T: Snapshots>(pub Arc<T>);
9554                    impl<
9555                        T: Snapshots,
9556                    > tonic::server::UnaryService<super::ListSnapshotsRequest>
9557                    for ListSvc<T> {
9558                        type Response = super::ListSnapshotsResponse;
9559                        type Future = BoxFuture<
9560                            tonic::Response<Self::Response>,
9561                            tonic::Status,
9562                        >;
9563                        fn call(
9564                            &mut self,
9565                            request: tonic::Request<super::ListSnapshotsRequest>,
9566                        ) -> Self::Future {
9567                            let inner = Arc::clone(&self.0);
9568                            let fut = async move {
9569                                <T as Snapshots>::list(&inner, request).await
9570                            };
9571                            Box::pin(fut)
9572                        }
9573                    }
9574                    let accept_compression_encodings = self.accept_compression_encodings;
9575                    let send_compression_encodings = self.send_compression_encodings;
9576                    let max_decoding_message_size = self.max_decoding_message_size;
9577                    let max_encoding_message_size = self.max_encoding_message_size;
9578                    let inner = self.inner.clone();
9579                    let fut = async move {
9580                        let method = ListSvc(inner);
9581                        let codec = tonic_prost::ProstCodec::default();
9582                        let mut grpc = tonic::server::Grpc::new(codec)
9583                            .apply_compression_config(
9584                                accept_compression_encodings,
9585                                send_compression_encodings,
9586                            )
9587                            .apply_max_message_size_config(
9588                                max_decoding_message_size,
9589                                max_encoding_message_size,
9590                            );
9591                        let res = grpc.unary(method, req).await;
9592                        Ok(res)
9593                    };
9594                    Box::pin(fut)
9595                }
9596                "/qdrant.Snapshots/Delete" => {
9597                    #[allow(non_camel_case_types)]
9598                    struct DeleteSvc<T: Snapshots>(pub Arc<T>);
9599                    impl<
9600                        T: Snapshots,
9601                    > tonic::server::UnaryService<super::DeleteSnapshotRequest>
9602                    for DeleteSvc<T> {
9603                        type Response = super::DeleteSnapshotResponse;
9604                        type Future = BoxFuture<
9605                            tonic::Response<Self::Response>,
9606                            tonic::Status,
9607                        >;
9608                        fn call(
9609                            &mut self,
9610                            request: tonic::Request<super::DeleteSnapshotRequest>,
9611                        ) -> Self::Future {
9612                            let inner = Arc::clone(&self.0);
9613                            let fut = async move {
9614                                <T as Snapshots>::delete(&inner, request).await
9615                            };
9616                            Box::pin(fut)
9617                        }
9618                    }
9619                    let accept_compression_encodings = self.accept_compression_encodings;
9620                    let send_compression_encodings = self.send_compression_encodings;
9621                    let max_decoding_message_size = self.max_decoding_message_size;
9622                    let max_encoding_message_size = self.max_encoding_message_size;
9623                    let inner = self.inner.clone();
9624                    let fut = async move {
9625                        let method = DeleteSvc(inner);
9626                        let codec = tonic_prost::ProstCodec::default();
9627                        let mut grpc = tonic::server::Grpc::new(codec)
9628                            .apply_compression_config(
9629                                accept_compression_encodings,
9630                                send_compression_encodings,
9631                            )
9632                            .apply_max_message_size_config(
9633                                max_decoding_message_size,
9634                                max_encoding_message_size,
9635                            );
9636                        let res = grpc.unary(method, req).await;
9637                        Ok(res)
9638                    };
9639                    Box::pin(fut)
9640                }
9641                "/qdrant.Snapshots/CreateFull" => {
9642                    #[allow(non_camel_case_types)]
9643                    struct CreateFullSvc<T: Snapshots>(pub Arc<T>);
9644                    impl<
9645                        T: Snapshots,
9646                    > tonic::server::UnaryService<super::CreateFullSnapshotRequest>
9647                    for CreateFullSvc<T> {
9648                        type Response = super::CreateSnapshotResponse;
9649                        type Future = BoxFuture<
9650                            tonic::Response<Self::Response>,
9651                            tonic::Status,
9652                        >;
9653                        fn call(
9654                            &mut self,
9655                            request: tonic::Request<super::CreateFullSnapshotRequest>,
9656                        ) -> Self::Future {
9657                            let inner = Arc::clone(&self.0);
9658                            let fut = async move {
9659                                <T as Snapshots>::create_full(&inner, request).await
9660                            };
9661                            Box::pin(fut)
9662                        }
9663                    }
9664                    let accept_compression_encodings = self.accept_compression_encodings;
9665                    let send_compression_encodings = self.send_compression_encodings;
9666                    let max_decoding_message_size = self.max_decoding_message_size;
9667                    let max_encoding_message_size = self.max_encoding_message_size;
9668                    let inner = self.inner.clone();
9669                    let fut = async move {
9670                        let method = CreateFullSvc(inner);
9671                        let codec = tonic_prost::ProstCodec::default();
9672                        let mut grpc = tonic::server::Grpc::new(codec)
9673                            .apply_compression_config(
9674                                accept_compression_encodings,
9675                                send_compression_encodings,
9676                            )
9677                            .apply_max_message_size_config(
9678                                max_decoding_message_size,
9679                                max_encoding_message_size,
9680                            );
9681                        let res = grpc.unary(method, req).await;
9682                        Ok(res)
9683                    };
9684                    Box::pin(fut)
9685                }
9686                "/qdrant.Snapshots/ListFull" => {
9687                    #[allow(non_camel_case_types)]
9688                    struct ListFullSvc<T: Snapshots>(pub Arc<T>);
9689                    impl<
9690                        T: Snapshots,
9691                    > tonic::server::UnaryService<super::ListFullSnapshotsRequest>
9692                    for ListFullSvc<T> {
9693                        type Response = super::ListSnapshotsResponse;
9694                        type Future = BoxFuture<
9695                            tonic::Response<Self::Response>,
9696                            tonic::Status,
9697                        >;
9698                        fn call(
9699                            &mut self,
9700                            request: tonic::Request<super::ListFullSnapshotsRequest>,
9701                        ) -> Self::Future {
9702                            let inner = Arc::clone(&self.0);
9703                            let fut = async move {
9704                                <T as Snapshots>::list_full(&inner, request).await
9705                            };
9706                            Box::pin(fut)
9707                        }
9708                    }
9709                    let accept_compression_encodings = self.accept_compression_encodings;
9710                    let send_compression_encodings = self.send_compression_encodings;
9711                    let max_decoding_message_size = self.max_decoding_message_size;
9712                    let max_encoding_message_size = self.max_encoding_message_size;
9713                    let inner = self.inner.clone();
9714                    let fut = async move {
9715                        let method = ListFullSvc(inner);
9716                        let codec = tonic_prost::ProstCodec::default();
9717                        let mut grpc = tonic::server::Grpc::new(codec)
9718                            .apply_compression_config(
9719                                accept_compression_encodings,
9720                                send_compression_encodings,
9721                            )
9722                            .apply_max_message_size_config(
9723                                max_decoding_message_size,
9724                                max_encoding_message_size,
9725                            );
9726                        let res = grpc.unary(method, req).await;
9727                        Ok(res)
9728                    };
9729                    Box::pin(fut)
9730                }
9731                "/qdrant.Snapshots/DeleteFull" => {
9732                    #[allow(non_camel_case_types)]
9733                    struct DeleteFullSvc<T: Snapshots>(pub Arc<T>);
9734                    impl<
9735                        T: Snapshots,
9736                    > tonic::server::UnaryService<super::DeleteFullSnapshotRequest>
9737                    for DeleteFullSvc<T> {
9738                        type Response = super::DeleteSnapshotResponse;
9739                        type Future = BoxFuture<
9740                            tonic::Response<Self::Response>,
9741                            tonic::Status,
9742                        >;
9743                        fn call(
9744                            &mut self,
9745                            request: tonic::Request<super::DeleteFullSnapshotRequest>,
9746                        ) -> Self::Future {
9747                            let inner = Arc::clone(&self.0);
9748                            let fut = async move {
9749                                <T as Snapshots>::delete_full(&inner, request).await
9750                            };
9751                            Box::pin(fut)
9752                        }
9753                    }
9754                    let accept_compression_encodings = self.accept_compression_encodings;
9755                    let send_compression_encodings = self.send_compression_encodings;
9756                    let max_decoding_message_size = self.max_decoding_message_size;
9757                    let max_encoding_message_size = self.max_encoding_message_size;
9758                    let inner = self.inner.clone();
9759                    let fut = async move {
9760                        let method = DeleteFullSvc(inner);
9761                        let codec = tonic_prost::ProstCodec::default();
9762                        let mut grpc = tonic::server::Grpc::new(codec)
9763                            .apply_compression_config(
9764                                accept_compression_encodings,
9765                                send_compression_encodings,
9766                            )
9767                            .apply_max_message_size_config(
9768                                max_decoding_message_size,
9769                                max_encoding_message_size,
9770                            );
9771                        let res = grpc.unary(method, req).await;
9772                        Ok(res)
9773                    };
9774                    Box::pin(fut)
9775                }
9776                _ => {
9777                    Box::pin(async move {
9778                        let mut response = http::Response::new(
9779                            tonic::body::Body::default(),
9780                        );
9781                        let headers = response.headers_mut();
9782                        headers
9783                            .insert(
9784                                tonic::Status::GRPC_STATUS,
9785                                (tonic::Code::Unimplemented as i32).into(),
9786                            );
9787                        headers
9788                            .insert(
9789                                http::header::CONTENT_TYPE,
9790                                tonic::metadata::GRPC_CONTENT_TYPE,
9791                            );
9792                        Ok(response)
9793                    })
9794                }
9795            }
9796        }
9797    }
9798    impl<T> Clone for SnapshotsServer<T> {
9799        fn clone(&self) -> Self {
9800            let inner = self.inner.clone();
9801            Self {
9802                inner,
9803                accept_compression_encodings: self.accept_compression_encodings,
9804                send_compression_encodings: self.send_compression_encodings,
9805                max_decoding_message_size: self.max_decoding_message_size,
9806                max_encoding_message_size: self.max_encoding_message_size,
9807            }
9808        }
9809    }
9810    /// Generated gRPC service name
9811    pub const SERVICE_NAME: &str = "qdrant.Snapshots";
9812    impl<T> tonic::server::NamedService for SnapshotsServer<T> {
9813        const NAME: &'static str = SERVICE_NAME;
9814    }
9815}
9816#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
9817pub struct HealthCheckRequest {}
9818#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
9819pub struct HealthCheckReply {
9820    #[prost(string, tag = "1")]
9821    pub title: ::prost::alloc::string::String,
9822    #[prost(string, tag = "2")]
9823    pub version: ::prost::alloc::string::String,
9824    #[prost(string, optional, tag = "3")]
9825    pub commit: ::core::option::Option<::prost::alloc::string::String>,
9826}
9827/// Generated client implementations.
9828pub mod qdrant_client {
9829    #![allow(
9830        unused_variables,
9831        dead_code,
9832        missing_docs,
9833        clippy::wildcard_imports,
9834        clippy::let_unit_value,
9835    )]
9836    use tonic::codegen::*;
9837    use tonic::codegen::http::Uri;
9838    #[derive(Debug, Clone)]
9839    pub struct QdrantClient<T> {
9840        inner: tonic::client::Grpc<T>,
9841    }
9842    impl QdrantClient<tonic::transport::Channel> {
9843        /// Attempt to create a new client by connecting to a given endpoint.
9844        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
9845        where
9846            D: TryInto<tonic::transport::Endpoint>,
9847            D::Error: Into<StdError>,
9848        {
9849            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
9850            Ok(Self::new(conn))
9851        }
9852    }
9853    impl<T> QdrantClient<T>
9854    where
9855        T: tonic::client::GrpcService<tonic::body::Body>,
9856        T::Error: Into<StdError>,
9857        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
9858        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
9859    {
9860        pub fn new(inner: T) -> Self {
9861            let inner = tonic::client::Grpc::new(inner);
9862            Self { inner }
9863        }
9864        pub fn with_origin(inner: T, origin: Uri) -> Self {
9865            let inner = tonic::client::Grpc::with_origin(inner, origin);
9866            Self { inner }
9867        }
9868        pub fn with_interceptor<F>(
9869            inner: T,
9870            interceptor: F,
9871        ) -> QdrantClient<InterceptedService<T, F>>
9872        where
9873            F: tonic::service::Interceptor,
9874            T::ResponseBody: Default,
9875            T: tonic::codegen::Service<
9876                http::Request<tonic::body::Body>,
9877                Response = http::Response<
9878                    <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
9879                >,
9880            >,
9881            <T as tonic::codegen::Service<
9882                http::Request<tonic::body::Body>,
9883            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
9884        {
9885            QdrantClient::new(InterceptedService::new(inner, interceptor))
9886        }
9887        /// Compress requests with the given encoding.
9888        ///
9889        /// This requires the server to support it otherwise it might respond with an
9890        /// error.
9891        #[must_use]
9892        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
9893            self.inner = self.inner.send_compressed(encoding);
9894            self
9895        }
9896        /// Enable decompressing responses.
9897        #[must_use]
9898        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
9899            self.inner = self.inner.accept_compressed(encoding);
9900            self
9901        }
9902        /// Limits the maximum size of a decoded message.
9903        ///
9904        /// Default: `4MB`
9905        #[must_use]
9906        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
9907            self.inner = self.inner.max_decoding_message_size(limit);
9908            self
9909        }
9910        /// Limits the maximum size of an encoded message.
9911        ///
9912        /// Default: `usize::MAX`
9913        #[must_use]
9914        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
9915            self.inner = self.inner.max_encoding_message_size(limit);
9916            self
9917        }
9918        pub async fn health_check(
9919            &mut self,
9920            request: impl tonic::IntoRequest<super::HealthCheckRequest>,
9921        ) -> std::result::Result<
9922            tonic::Response<super::HealthCheckReply>,
9923            tonic::Status,
9924        > {
9925            self.inner
9926                .ready()
9927                .await
9928                .map_err(|e| {
9929                    tonic::Status::unknown(
9930                        format!("Service was not ready: {}", e.into()),
9931                    )
9932                })?;
9933            let codec = tonic_prost::ProstCodec::default();
9934            let path = http::uri::PathAndQuery::from_static(
9935                "/qdrant.Qdrant/HealthCheck",
9936            );
9937            let mut req = request.into_request();
9938            req.extensions_mut().insert(GrpcMethod::new("qdrant.Qdrant", "HealthCheck"));
9939            self.inner.unary(req, path, codec).await
9940        }
9941    }
9942}
9943/// Generated server implementations.
9944pub mod qdrant_server {
9945    #![allow(
9946        unused_variables,
9947        dead_code,
9948        missing_docs,
9949        clippy::wildcard_imports,
9950        clippy::let_unit_value,
9951    )]
9952    use tonic::codegen::*;
9953    /// Generated trait containing gRPC methods that should be implemented for use with QdrantServer.
9954    #[async_trait]
9955    pub trait Qdrant: std::marker::Send + std::marker::Sync + 'static {
9956        async fn health_check(
9957            &self,
9958            request: tonic::Request<super::HealthCheckRequest>,
9959        ) -> std::result::Result<
9960            tonic::Response<super::HealthCheckReply>,
9961            tonic::Status,
9962        >;
9963    }
9964    #[derive(Debug)]
9965    pub struct QdrantServer<T> {
9966        inner: Arc<T>,
9967        accept_compression_encodings: EnabledCompressionEncodings,
9968        send_compression_encodings: EnabledCompressionEncodings,
9969        max_decoding_message_size: Option<usize>,
9970        max_encoding_message_size: Option<usize>,
9971    }
9972    impl<T> QdrantServer<T> {
9973        pub fn new(inner: T) -> Self {
9974            Self::from_arc(Arc::new(inner))
9975        }
9976        pub fn from_arc(inner: Arc<T>) -> Self {
9977            Self {
9978                inner,
9979                accept_compression_encodings: Default::default(),
9980                send_compression_encodings: Default::default(),
9981                max_decoding_message_size: None,
9982                max_encoding_message_size: None,
9983            }
9984        }
9985        pub fn with_interceptor<F>(
9986            inner: T,
9987            interceptor: F,
9988        ) -> InterceptedService<Self, F>
9989        where
9990            F: tonic::service::Interceptor,
9991        {
9992            InterceptedService::new(Self::new(inner), interceptor)
9993        }
9994        /// Enable decompressing requests with the given encoding.
9995        #[must_use]
9996        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
9997            self.accept_compression_encodings.enable(encoding);
9998            self
9999        }
10000        /// Compress responses with the given encoding, if the client supports it.
10001        #[must_use]
10002        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
10003            self.send_compression_encodings.enable(encoding);
10004            self
10005        }
10006        /// Limits the maximum size of a decoded message.
10007        ///
10008        /// Default: `4MB`
10009        #[must_use]
10010        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
10011            self.max_decoding_message_size = Some(limit);
10012            self
10013        }
10014        /// Limits the maximum size of an encoded message.
10015        ///
10016        /// Default: `usize::MAX`
10017        #[must_use]
10018        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
10019            self.max_encoding_message_size = Some(limit);
10020            self
10021        }
10022    }
10023    impl<T, B> tonic::codegen::Service<http::Request<B>> for QdrantServer<T>
10024    where
10025        T: Qdrant,
10026        B: Body + std::marker::Send + 'static,
10027        B::Error: Into<StdError> + std::marker::Send + 'static,
10028    {
10029        type Response = http::Response<tonic::body::Body>;
10030        type Error = std::convert::Infallible;
10031        type Future = BoxFuture<Self::Response, Self::Error>;
10032        fn poll_ready(
10033            &mut self,
10034            _cx: &mut Context<'_>,
10035        ) -> Poll<std::result::Result<(), Self::Error>> {
10036            Poll::Ready(Ok(()))
10037        }
10038        fn call(&mut self, req: http::Request<B>) -> Self::Future {
10039            match req.uri().path() {
10040                "/qdrant.Qdrant/HealthCheck" => {
10041                    #[allow(non_camel_case_types)]
10042                    struct HealthCheckSvc<T: Qdrant>(pub Arc<T>);
10043                    impl<
10044                        T: Qdrant,
10045                    > tonic::server::UnaryService<super::HealthCheckRequest>
10046                    for HealthCheckSvc<T> {
10047                        type Response = super::HealthCheckReply;
10048                        type Future = BoxFuture<
10049                            tonic::Response<Self::Response>,
10050                            tonic::Status,
10051                        >;
10052                        fn call(
10053                            &mut self,
10054                            request: tonic::Request<super::HealthCheckRequest>,
10055                        ) -> Self::Future {
10056                            let inner = Arc::clone(&self.0);
10057                            let fut = async move {
10058                                <T as Qdrant>::health_check(&inner, request).await
10059                            };
10060                            Box::pin(fut)
10061                        }
10062                    }
10063                    let accept_compression_encodings = self.accept_compression_encodings;
10064                    let send_compression_encodings = self.send_compression_encodings;
10065                    let max_decoding_message_size = self.max_decoding_message_size;
10066                    let max_encoding_message_size = self.max_encoding_message_size;
10067                    let inner = self.inner.clone();
10068                    let fut = async move {
10069                        let method = HealthCheckSvc(inner);
10070                        let codec = tonic_prost::ProstCodec::default();
10071                        let mut grpc = tonic::server::Grpc::new(codec)
10072                            .apply_compression_config(
10073                                accept_compression_encodings,
10074                                send_compression_encodings,
10075                            )
10076                            .apply_max_message_size_config(
10077                                max_decoding_message_size,
10078                                max_encoding_message_size,
10079                            );
10080                        let res = grpc.unary(method, req).await;
10081                        Ok(res)
10082                    };
10083                    Box::pin(fut)
10084                }
10085                _ => {
10086                    Box::pin(async move {
10087                        let mut response = http::Response::new(
10088                            tonic::body::Body::default(),
10089                        );
10090                        let headers = response.headers_mut();
10091                        headers
10092                            .insert(
10093                                tonic::Status::GRPC_STATUS,
10094                                (tonic::Code::Unimplemented as i32).into(),
10095                            );
10096                        headers
10097                            .insert(
10098                                http::header::CONTENT_TYPE,
10099                                tonic::metadata::GRPC_CONTENT_TYPE,
10100                            );
10101                        Ok(response)
10102                    })
10103                }
10104            }
10105        }
10106    }
10107    impl<T> Clone for QdrantServer<T> {
10108        fn clone(&self) -> Self {
10109            let inner = self.inner.clone();
10110            Self {
10111                inner,
10112                accept_compression_encodings: self.accept_compression_encodings,
10113                send_compression_encodings: self.send_compression_encodings,
10114                max_decoding_message_size: self.max_decoding_message_size,
10115                max_encoding_message_size: self.max_encoding_message_size,
10116            }
10117        }
10118    }
10119    /// Generated gRPC service name
10120    pub const SERVICE_NAME: &str = "qdrant.Qdrant";
10121    impl<T> tonic::server::NamedService for QdrantServer<T> {
10122        const NAME: &'static str = SERVICE_NAME;
10123    }
10124}
10125pub use crate::manual_builder::*;
10126pub use crate::builder_types::*;
10127pub use crate::qdrant_client::builders::*;
10128pub use crate::builders::*;
10129pub use prost_types::Timestamp;