@loams/client 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +78 -2
- package/dist/app.d.ts +149 -0
- package/dist/app.js +317 -0
- package/dist/builders/filter.d.ts +96 -0
- package/dist/builders/filter.js +190 -0
- package/dist/builders/schema.d.ts +50 -0
- package/dist/builders/schema.js +92 -0
- package/dist/builders/search.d.ts +159 -0
- package/dist/builders/search.js +307 -0
- package/dist/gen/facade.d.ts +267 -2
- package/dist/gen/facade.js +194 -0
- package/dist/handle.d.ts +67 -0
- package/dist/handle.js +107 -0
- package/dist/index.d.ts +12 -5
- package/dist/index.js +12 -3
- package/dist/loams.d.ts +77 -2
- package/dist/loams.js +84 -6
- package/dist/runtime/batch.d.ts +29 -0
- package/dist/runtime/batch.js +95 -0
- package/dist/runtime/call.d.ts +63 -9
- package/dist/runtime/call.js +243 -41
- package/dist/runtime/consistency.d.ts +65 -11
- package/dist/runtime/consistency.js +212 -46
- package/dist/runtime/errors.d.ts +29 -2
- package/dist/runtime/errors.js +26 -0
- package/dist/runtime/pagination.js +8 -2
- package/dist/runtime/subscribe.d.ts +37 -0
- package/dist/runtime/subscribe.js +128 -0
- package/dist/vendor/proto/collection-v1.d.ts +3 -0
- package/dist/vendor/proto/collection-v1.js +7 -0
- package/dist/vendor/proto/gen/loams/collection/v1/collection_pb.d.ts +1610 -0
- package/dist/vendor/proto/gen/loams/collection/v1/collection_pb.js +399 -0
- package/dist/vendor/proto/gen/loams/collection/v1/document_pb.d.ts +1054 -0
- package/dist/vendor/proto/gen/loams/collection/v1/document_pb.js +327 -0
- package/dist/vendor/proto/gen/loams/collection/v1/query_pb.d.ts +2101 -0
- package/dist/vendor/proto/gen/loams/collection/v1/query_pb.js +608 -0
- package/dist/vendor/proto/gen/loams/graph/v1/graph_pb.d.ts +2299 -0
- package/dist/vendor/proto/gen/loams/graph/v1/graph_pb.js +596 -0
- package/dist/vendor/proto/gen/loams/operations/v1/operations_pb.d.ts +399 -0
- package/dist/vendor/proto/gen/loams/operations/v1/operations_pb.js +118 -0
- package/dist/vendor/proto/gen/loams/sql/v1/sql_pb.d.ts +182 -0
- package/dist/vendor/proto/gen/loams/sql/v1/sql_pb.js +72 -0
- package/dist/vendor/proto/gen/loams/stream/v1/stream_pb.d.ts +688 -0
- package/dist/vendor/proto/gen/loams/stream/v1/stream_pb.js +180 -0
- package/package.json +2 -2
|
@@ -0,0 +1,2101 @@
|
|
|
1
|
+
import type { GenEnum, GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv2";
|
|
2
|
+
import type { Empty, Value } from "@bufbuild/protobuf/wkt";
|
|
3
|
+
import type { Consistency, DocumentId } from "./document_pb.js";
|
|
4
|
+
import type { JsonObject, Message } from "@bufbuild/protobuf";
|
|
5
|
+
/**
|
|
6
|
+
* Describes the file loams/collection/v1/query.proto.
|
|
7
|
+
*/
|
|
8
|
+
export declare const file_loams_collection_v1_query: GenFile;
|
|
9
|
+
/**
|
|
10
|
+
* @generated from message loams.collection.v1.SearchRequest
|
|
11
|
+
*/
|
|
12
|
+
export type SearchRequest = Message<"loams.collection.v1.SearchRequest"> & {
|
|
13
|
+
/**
|
|
14
|
+
* @generated from field: string namespace = 1;
|
|
15
|
+
*/
|
|
16
|
+
namespace: string;
|
|
17
|
+
/**
|
|
18
|
+
* A collection name or an alias. The alias of `from` is this field's other
|
|
19
|
+
* name; a request that sets both names one collection, and `collection`
|
|
20
|
+
* wins.
|
|
21
|
+
*
|
|
22
|
+
* @generated from field: string collection = 2;
|
|
23
|
+
*/
|
|
24
|
+
collection: string;
|
|
25
|
+
/**
|
|
26
|
+
* How fresh the read must be. Absent is `FRESHNESS_STRONG`, the same default
|
|
27
|
+
* the REST route reads, and the `loams-consistency-token` request header
|
|
28
|
+
* still merges into it by the same rule.
|
|
29
|
+
*
|
|
30
|
+
* @generated from field: loams.collection.v1.Consistency consistency = 3;
|
|
31
|
+
*/
|
|
32
|
+
consistency?: Consistency | undefined;
|
|
33
|
+
/**
|
|
34
|
+
* The sources of ranked candidates. Empty with a `filter` is a filter-only
|
|
35
|
+
* query; empty with neither matches nothing.
|
|
36
|
+
*
|
|
37
|
+
* @generated from field: repeated loams.collection.v1.Retriever retrievers = 4;
|
|
38
|
+
*/
|
|
39
|
+
retrievers: Retriever[];
|
|
40
|
+
/**
|
|
41
|
+
* How the ranked lists are combined. Absent is the engine's own combination,
|
|
42
|
+
* which is RRF.
|
|
43
|
+
*
|
|
44
|
+
* @generated from field: loams.collection.v1.Fusion fusion = 5;
|
|
45
|
+
*/
|
|
46
|
+
fusion?: Fusion | undefined;
|
|
47
|
+
/**
|
|
48
|
+
* The filter every retriever's candidates must match.
|
|
49
|
+
*
|
|
50
|
+
* @generated from field: loams.collection.v1.Query filter = 6;
|
|
51
|
+
*/
|
|
52
|
+
filter?: Query | undefined;
|
|
53
|
+
/**
|
|
54
|
+
* The effective sort; the primary key ascending always breaks ties (Ruling
|
|
55
|
+
* 10).
|
|
56
|
+
*
|
|
57
|
+
* @generated from field: repeated loams.collection.v1.SortKey sort = 7;
|
|
58
|
+
*/
|
|
59
|
+
sort: SortKey[];
|
|
60
|
+
/**
|
|
61
|
+
* How many hits to skip before the window. `offset` is the IR's, and it is
|
|
62
|
+
* capped by the engine's own limits.
|
|
63
|
+
*
|
|
64
|
+
* @generated from field: uint32 offset = 8;
|
|
65
|
+
*/
|
|
66
|
+
offset: number;
|
|
67
|
+
/**
|
|
68
|
+
* The window size; absent is 10, the IR's default. `optional`, so an
|
|
69
|
+
* explicit `0` is a window of nothing rather than the default.
|
|
70
|
+
*
|
|
71
|
+
* @generated from field: optional uint32 limit = 9;
|
|
72
|
+
*/
|
|
73
|
+
limit?: number | undefined;
|
|
74
|
+
/**
|
|
75
|
+
* The sort values of the last hit of the previous page, for a deep page
|
|
76
|
+
* jump. Each is the IR's own JSON: `null`, a bool, a number, a string or
|
|
77
|
+
* `{"uuid": "…"}`.
|
|
78
|
+
*
|
|
79
|
+
* @generated from field: repeated google.protobuf.Value search_after = 10;
|
|
80
|
+
*/
|
|
81
|
+
searchAfter: Value[];
|
|
82
|
+
/**
|
|
83
|
+
* Hits scoring below this are dropped. `optional`, so `0` is a threshold and
|
|
84
|
+
* not an absent one.
|
|
85
|
+
*
|
|
86
|
+
* @generated from field: optional float score_threshold = 11;
|
|
87
|
+
*/
|
|
88
|
+
scoreThreshold?: number | undefined;
|
|
89
|
+
/**
|
|
90
|
+
* What to return of each hit, as the REST route's projection JSON
|
|
91
|
+
* (`{"source": "all" | "none" | {"include": [], "exclude": []},
|
|
92
|
+
* "vectors": [], "fields": []}`). Absent is everything, and `id` and
|
|
93
|
+
* `_score` are answered whatever it says.
|
|
94
|
+
*
|
|
95
|
+
* @generated from field: google.protobuf.Struct select = 12;
|
|
96
|
+
*/
|
|
97
|
+
select?: JsonObject | undefined;
|
|
98
|
+
/**
|
|
99
|
+
* An ES aggregation request, carried verbatim as Tantivy's own
|
|
100
|
+
* `Aggregations` JSON owns it.
|
|
101
|
+
*
|
|
102
|
+
* @generated from field: google.protobuf.Value aggregations = 13;
|
|
103
|
+
*/
|
|
104
|
+
aggregations?: Value | undefined;
|
|
105
|
+
/**
|
|
106
|
+
* Text fields to highlight, and how.
|
|
107
|
+
*
|
|
108
|
+
* @generated from field: loams.collection.v1.Highlight highlight = 14;
|
|
109
|
+
*/
|
|
110
|
+
highlight?: Highlight | undefined;
|
|
111
|
+
/**
|
|
112
|
+
* Groups the hits by a field value instead of answering a flat page.
|
|
113
|
+
*
|
|
114
|
+
* @generated from field: loams.collection.v1.GroupBy group_by = 15;
|
|
115
|
+
*/
|
|
116
|
+
groupBy?: GroupBy | undefined;
|
|
117
|
+
/**
|
|
118
|
+
* Whether and how far to count the matches. A `Value` and not a message,
|
|
119
|
+
* for the reason the header gives.
|
|
120
|
+
*
|
|
121
|
+
* @generated from field: google.protobuf.Value track_total_hits = 16;
|
|
122
|
+
*/
|
|
123
|
+
trackTotalHits?: Value | undefined;
|
|
124
|
+
/**
|
|
125
|
+
* **Deprecated; always `invalid_argument`.** `rerank_spec` carries the
|
|
126
|
+
* stage (GR1 Task 20). The field stays so a body carrying it is refused
|
|
127
|
+
* rather than silently dropped.
|
|
128
|
+
*
|
|
129
|
+
* @generated from field: google.protobuf.Struct rerank = 17 [deprecated = true];
|
|
130
|
+
* @deprecated
|
|
131
|
+
*/
|
|
132
|
+
rerank?: JsonObject | undefined;
|
|
133
|
+
/**
|
|
134
|
+
* **Deprecated; always `invalid_argument`.** `expand_spec` carries the
|
|
135
|
+
* stage; see `rerank`.
|
|
136
|
+
*
|
|
137
|
+
* @generated from field: google.protobuf.Struct expand = 18 [deprecated = true];
|
|
138
|
+
* @deprecated
|
|
139
|
+
*/
|
|
140
|
+
expand?: JsonObject | undefined;
|
|
141
|
+
/**
|
|
142
|
+
* Design §05 §4's `from`, verbatim: `"collections.<name>"` or `"<name>"`.
|
|
143
|
+
* An alias of `collection` (see the header).
|
|
144
|
+
*
|
|
145
|
+
* @generated from field: string from = 19;
|
|
146
|
+
*/
|
|
147
|
+
from: string;
|
|
148
|
+
/**
|
|
149
|
+
* Design §05 §4's `retrieve`, verbatim, same element shape. An alias of
|
|
150
|
+
* `retrievers`.
|
|
151
|
+
*
|
|
152
|
+
* @generated from field: repeated loams.collection.v1.Retriever retrieve = 20;
|
|
153
|
+
*/
|
|
154
|
+
retrieve: Retriever[];
|
|
155
|
+
/**
|
|
156
|
+
* Design §05 §4's `fuse`, verbatim: `{"method": "rrf", "k": 60}`. A `Struct`
|
|
157
|
+
* for the reason the header gives, and an alias of `fusion`.
|
|
158
|
+
*
|
|
159
|
+
* @generated from field: google.protobuf.Struct fuse = 21;
|
|
160
|
+
*/
|
|
161
|
+
fuse?: JsonObject | undefined;
|
|
162
|
+
/**
|
|
163
|
+
* Walks a Loams Graph graph from the top hits (design §07 §5.2, GR1 Task
|
|
164
|
+
* 20). Needs the server's `graph` feature.
|
|
165
|
+
*
|
|
166
|
+
* @generated from field: loams.collection.v1.ExpandSpec expand_spec = 22;
|
|
167
|
+
*/
|
|
168
|
+
expandSpec?: ExpandSpec | undefined;
|
|
169
|
+
/**
|
|
170
|
+
* Re-scores the final candidates, seeds and neighbors (§07 §5.2).
|
|
171
|
+
*
|
|
172
|
+
* @generated from field: loams.collection.v1.RerankSpec rerank_spec = 23;
|
|
173
|
+
*/
|
|
174
|
+
rerankSpec?: RerankSpec | undefined;
|
|
175
|
+
};
|
|
176
|
+
/**
|
|
177
|
+
* Describes the message loams.collection.v1.SearchRequest.
|
|
178
|
+
* Use `create(SearchRequestSchema)` to create a new message.
|
|
179
|
+
*/
|
|
180
|
+
export declare const SearchRequestSchema: GenMessage<SearchRequest>;
|
|
181
|
+
/**
|
|
182
|
+
* One source of ranked candidates. A proto oneof, so the JSON is the REST
|
|
183
|
+
* route's `{"vector": {…}}` / `{"text": {…}}` / `{"fused": {…}}` /
|
|
184
|
+
* `{"rescore": {…}}` / `{"sparse": {…}}` unchanged, and a retriever that is
|
|
185
|
+
* none of the five is `invalid_argument`.
|
|
186
|
+
*
|
|
187
|
+
* @generated from message loams.collection.v1.Retriever
|
|
188
|
+
*/
|
|
189
|
+
export type Retriever = Message<"loams.collection.v1.Retriever"> & {
|
|
190
|
+
/**
|
|
191
|
+
* @generated from oneof loams.collection.v1.Retriever.retriever
|
|
192
|
+
*/
|
|
193
|
+
retriever: {
|
|
194
|
+
/**
|
|
195
|
+
* @generated from field: loams.collection.v1.VectorQuery vector = 1;
|
|
196
|
+
*/
|
|
197
|
+
value: VectorQuery;
|
|
198
|
+
case: "vector";
|
|
199
|
+
} | {
|
|
200
|
+
/**
|
|
201
|
+
* @generated from field: loams.collection.v1.TextQuery text = 2;
|
|
202
|
+
*/
|
|
203
|
+
value: TextQuery;
|
|
204
|
+
case: "text";
|
|
205
|
+
} | {
|
|
206
|
+
/**
|
|
207
|
+
* Runs its own inputs and fuses them, which makes it a subtree of
|
|
208
|
+
* retrievers rather than one stage.
|
|
209
|
+
*
|
|
210
|
+
* @generated from field: loams.collection.v1.FusedQuery fused = 3;
|
|
211
|
+
*/
|
|
212
|
+
value: FusedQuery;
|
|
213
|
+
case: "fused";
|
|
214
|
+
} | {
|
|
215
|
+
/**
|
|
216
|
+
* Re-ranks an input's candidates against a second vector.
|
|
217
|
+
*
|
|
218
|
+
* @generated from field: loams.collection.v1.RescoreQuery rescore = 4;
|
|
219
|
+
*/
|
|
220
|
+
value: RescoreQuery;
|
|
221
|
+
case: "rescore";
|
|
222
|
+
} | {
|
|
223
|
+
/**
|
|
224
|
+
* Exact sparse-vector search (overview A29).
|
|
225
|
+
*
|
|
226
|
+
* @generated from field: loams.collection.v1.SparseQuery sparse = 5;
|
|
227
|
+
*/
|
|
228
|
+
value: SparseQuery;
|
|
229
|
+
case: "sparse";
|
|
230
|
+
} | {
|
|
231
|
+
case: undefined;
|
|
232
|
+
value?: undefined;
|
|
233
|
+
};
|
|
234
|
+
};
|
|
235
|
+
/**
|
|
236
|
+
* Describes the message loams.collection.v1.Retriever.
|
|
237
|
+
* Use `create(RetrieverSchema)` to create a new message.
|
|
238
|
+
*/
|
|
239
|
+
export declare const RetrieverSchema: GenMessage<Retriever>;
|
|
240
|
+
/**
|
|
241
|
+
* @generated from message loams.collection.v1.VectorQuery
|
|
242
|
+
*/
|
|
243
|
+
export type VectorQuery = Message<"loams.collection.v1.VectorQuery"> & {
|
|
244
|
+
/**
|
|
245
|
+
* The dense vector column to search.
|
|
246
|
+
*
|
|
247
|
+
* @generated from field: string field = 1;
|
|
248
|
+
*/
|
|
249
|
+
field: string;
|
|
250
|
+
/**
|
|
251
|
+
* The query vector, as `[1.0, 0.0, 0.0]`.
|
|
252
|
+
*
|
|
253
|
+
* @generated from field: repeated float query = 2;
|
|
254
|
+
*/
|
|
255
|
+
query: number[];
|
|
256
|
+
/**
|
|
257
|
+
* How many candidates this retriever contributes before fusion.
|
|
258
|
+
*
|
|
259
|
+
* @generated from field: uint32 k = 3;
|
|
260
|
+
*/
|
|
261
|
+
k: number;
|
|
262
|
+
/**
|
|
263
|
+
* @generated from field: loams.collection.v1.AnnParams params = 4;
|
|
264
|
+
*/
|
|
265
|
+
params?: AnnParams | undefined;
|
|
266
|
+
/**
|
|
267
|
+
* Narrows this retriever's candidates, over and above the request's
|
|
268
|
+
* `filter`.
|
|
269
|
+
*
|
|
270
|
+
* @generated from field: loams.collection.v1.Query filter = 5;
|
|
271
|
+
*/
|
|
272
|
+
filter?: Query | undefined;
|
|
273
|
+
};
|
|
274
|
+
/**
|
|
275
|
+
* Describes the message loams.collection.v1.VectorQuery.
|
|
276
|
+
* Use `create(VectorQuerySchema)` to create a new message.
|
|
277
|
+
*/
|
|
278
|
+
export declare const VectorQuerySchema: GenMessage<VectorQuery>;
|
|
279
|
+
/**
|
|
280
|
+
* @generated from message loams.collection.v1.TextQuery
|
|
281
|
+
*/
|
|
282
|
+
export type TextQuery = Message<"loams.collection.v1.TextQuery"> & {
|
|
283
|
+
/**
|
|
284
|
+
* The query over the collection's text fields.
|
|
285
|
+
*
|
|
286
|
+
* @generated from field: loams.collection.v1.Query query = 1;
|
|
287
|
+
*/
|
|
288
|
+
query?: Query | undefined;
|
|
289
|
+
/**
|
|
290
|
+
* @generated from field: uint32 k = 2;
|
|
291
|
+
*/
|
|
292
|
+
k: number;
|
|
293
|
+
};
|
|
294
|
+
/**
|
|
295
|
+
* Describes the message loams.collection.v1.TextQuery.
|
|
296
|
+
* Use `create(TextQuerySchema)` to create a new message.
|
|
297
|
+
*/
|
|
298
|
+
export declare const TextQuerySchema: GenMessage<TextQuery>;
|
|
299
|
+
/**
|
|
300
|
+
* @generated from message loams.collection.v1.FusedQuery
|
|
301
|
+
*/
|
|
302
|
+
export type FusedQuery = Message<"loams.collection.v1.FusedQuery"> & {
|
|
303
|
+
/**
|
|
304
|
+
* @generated from field: repeated loams.collection.v1.Retriever inputs = 1;
|
|
305
|
+
*/
|
|
306
|
+
inputs: Retriever[];
|
|
307
|
+
/**
|
|
308
|
+
* @generated from field: loams.collection.v1.Fusion fusion = 2;
|
|
309
|
+
*/
|
|
310
|
+
fusion?: Fusion | undefined;
|
|
311
|
+
/**
|
|
312
|
+
* @generated from field: uint32 k = 3;
|
|
313
|
+
*/
|
|
314
|
+
k: number;
|
|
315
|
+
};
|
|
316
|
+
/**
|
|
317
|
+
* Describes the message loams.collection.v1.FusedQuery.
|
|
318
|
+
* Use `create(FusedQuerySchema)` to create a new message.
|
|
319
|
+
*/
|
|
320
|
+
export declare const FusedQuerySchema: GenMessage<FusedQuery>;
|
|
321
|
+
/**
|
|
322
|
+
* @generated from message loams.collection.v1.RescoreQuery
|
|
323
|
+
*/
|
|
324
|
+
export type RescoreQuery = Message<"loams.collection.v1.RescoreQuery"> & {
|
|
325
|
+
/**
|
|
326
|
+
* The retriever whose candidates are re-ranked.
|
|
327
|
+
*
|
|
328
|
+
* @generated from field: loams.collection.v1.Retriever input = 1;
|
|
329
|
+
*/
|
|
330
|
+
input?: Retriever | undefined;
|
|
331
|
+
/**
|
|
332
|
+
* The vector column to re-score against.
|
|
333
|
+
*
|
|
334
|
+
* @generated from field: string field = 2;
|
|
335
|
+
*/
|
|
336
|
+
field: string;
|
|
337
|
+
/**
|
|
338
|
+
* @generated from field: repeated float query = 3;
|
|
339
|
+
*/
|
|
340
|
+
query: number[];
|
|
341
|
+
/**
|
|
342
|
+
* @generated from field: uint32 k = 4;
|
|
343
|
+
*/
|
|
344
|
+
k: number;
|
|
345
|
+
};
|
|
346
|
+
/**
|
|
347
|
+
* Describes the message loams.collection.v1.RescoreQuery.
|
|
348
|
+
* Use `create(RescoreQuerySchema)` to create a new message.
|
|
349
|
+
*/
|
|
350
|
+
export declare const RescoreQuerySchema: GenMessage<RescoreQuery>;
|
|
351
|
+
/**
|
|
352
|
+
* @generated from message loams.collection.v1.SparseQuery
|
|
353
|
+
*/
|
|
354
|
+
export type SparseQuery = Message<"loams.collection.v1.SparseQuery"> & {
|
|
355
|
+
/**
|
|
356
|
+
* The sparse vector column to search.
|
|
357
|
+
*
|
|
358
|
+
* @generated from field: string field = 1;
|
|
359
|
+
*/
|
|
360
|
+
field: string;
|
|
361
|
+
/**
|
|
362
|
+
* The query vector, as the sparse vector's own JSON:
|
|
363
|
+
* `{"indices": [5], "values": [1.0]}`.
|
|
364
|
+
*
|
|
365
|
+
* @generated from field: google.protobuf.Struct query = 2;
|
|
366
|
+
*/
|
|
367
|
+
query?: JsonObject | undefined;
|
|
368
|
+
/**
|
|
369
|
+
* @generated from field: uint32 k = 3;
|
|
370
|
+
*/
|
|
371
|
+
k: number;
|
|
372
|
+
/**
|
|
373
|
+
* @generated from field: loams.collection.v1.Query filter = 4;
|
|
374
|
+
*/
|
|
375
|
+
filter?: Query | undefined;
|
|
376
|
+
/**
|
|
377
|
+
* @generated from field: loams.collection.v1.SparseParams params = 5;
|
|
378
|
+
*/
|
|
379
|
+
params?: SparseParams | undefined;
|
|
380
|
+
};
|
|
381
|
+
/**
|
|
382
|
+
* Describes the message loams.collection.v1.SparseQuery.
|
|
383
|
+
* Use `create(SparseQuerySchema)` to create a new message.
|
|
384
|
+
*/
|
|
385
|
+
export declare const SparseQuerySchema: GenMessage<SparseQuery>;
|
|
386
|
+
/**
|
|
387
|
+
* The parameters of a dense-vector retriever. Every field absent is the
|
|
388
|
+
* engine's default, which is why they are `optional` rather than sent as
|
|
389
|
+
* zeroes.
|
|
390
|
+
*
|
|
391
|
+
* @generated from message loams.collection.v1.AnnParams
|
|
392
|
+
*/
|
|
393
|
+
export type AnnParams = Message<"loams.collection.v1.AnnParams"> & {
|
|
394
|
+
/**
|
|
395
|
+
* Search the whole index exactly instead of approximately. This is not a
|
|
396
|
+
* free read.
|
|
397
|
+
*
|
|
398
|
+
* @generated from field: bool exact = 1;
|
|
399
|
+
*/
|
|
400
|
+
exact: boolean;
|
|
401
|
+
/**
|
|
402
|
+
* HNSW layers probed.
|
|
403
|
+
*
|
|
404
|
+
* @generated from field: optional uint32 nprobes = 2;
|
|
405
|
+
*/
|
|
406
|
+
nprobes?: number | undefined;
|
|
407
|
+
/**
|
|
408
|
+
* Candidates the approximate pass re-ranks exactly.
|
|
409
|
+
*
|
|
410
|
+
* @generated from field: optional uint32 refine_factor = 3;
|
|
411
|
+
*/
|
|
412
|
+
refineFactor?: number | undefined;
|
|
413
|
+
/**
|
|
414
|
+
* The approximate search's beam width.
|
|
415
|
+
*
|
|
416
|
+
* @generated from field: optional uint32 ef = 4;
|
|
417
|
+
*/
|
|
418
|
+
ef?: number | undefined;
|
|
419
|
+
/**
|
|
420
|
+
* Fractions of each candidate's cells to visit (multi-vector).
|
|
421
|
+
*
|
|
422
|
+
* @generated from field: optional float oversampling = 5;
|
|
423
|
+
*/
|
|
424
|
+
oversampling?: number | undefined;
|
|
425
|
+
/**
|
|
426
|
+
* A metric override — `cosine`, `dot`, `euclid` or `manhattan` — as the REST
|
|
427
|
+
* route spells it; only with `exact`. A string rather than an enum so the
|
|
428
|
+
* REST spelling survives verbatim (the same call `ScanColumn.distance`
|
|
429
|
+
* makes).
|
|
430
|
+
*
|
|
431
|
+
* @generated from field: string distance = 6;
|
|
432
|
+
*/
|
|
433
|
+
distance: string;
|
|
434
|
+
};
|
|
435
|
+
/**
|
|
436
|
+
* Describes the message loams.collection.v1.AnnParams.
|
|
437
|
+
* Use `create(AnnParamsSchema)` to create a new message.
|
|
438
|
+
*/
|
|
439
|
+
export declare const AnnParamsSchema: GenMessage<AnnParams>;
|
|
440
|
+
/**
|
|
441
|
+
* The parameters of a sparse retriever.
|
|
442
|
+
*
|
|
443
|
+
* @generated from message loams.collection.v1.SparseParams
|
|
444
|
+
*/
|
|
445
|
+
export type SparseParams = Message<"loams.collection.v1.SparseParams"> & {
|
|
446
|
+
/**
|
|
447
|
+
* The rows the IDF statistics count. Absent is every live row.
|
|
448
|
+
*
|
|
449
|
+
* @generated from field: loams.collection.v1.Query idf_corpus = 1;
|
|
450
|
+
*/
|
|
451
|
+
idfCorpus?: Query | undefined;
|
|
452
|
+
};
|
|
453
|
+
/**
|
|
454
|
+
* Describes the message loams.collection.v1.SparseParams.
|
|
455
|
+
* Use `create(SparseParamsSchema)` to create a new message.
|
|
456
|
+
*/
|
|
457
|
+
export declare const SparseParamsSchema: GenMessage<SparseParams>;
|
|
458
|
+
/**
|
|
459
|
+
* How ranked lists are combined (overview §6.6, Rulings 4 and 5). A proto
|
|
460
|
+
* oneof, so the JSON is the IR's `{"rrf": {"k": 60}}` / `{"dbsf": {}}` /
|
|
461
|
+
* `{"weightedSum": {"weights": [0.5, 0.5]}}` — `dbsf` is a unit arm and so is an
|
|
462
|
+
* empty message, because the REST spelling `"dbsf"` has no oneof form.
|
|
463
|
+
*
|
|
464
|
+
* @generated from message loams.collection.v1.Fusion
|
|
465
|
+
*/
|
|
466
|
+
export type Fusion = Message<"loams.collection.v1.Fusion"> & {
|
|
467
|
+
/**
|
|
468
|
+
* @generated from oneof loams.collection.v1.Fusion.fusion
|
|
469
|
+
*/
|
|
470
|
+
fusion: {
|
|
471
|
+
/**
|
|
472
|
+
* @generated from field: loams.collection.v1.Rrf rrf = 1;
|
|
473
|
+
*/
|
|
474
|
+
value: Rrf;
|
|
475
|
+
case: "rrf";
|
|
476
|
+
} | {
|
|
477
|
+
/**
|
|
478
|
+
* Distance-based score fusion, with the engine's own parameters.
|
|
479
|
+
*
|
|
480
|
+
* @generated from field: google.protobuf.Empty dbsf = 2;
|
|
481
|
+
*/
|
|
482
|
+
value: Empty;
|
|
483
|
+
case: "dbsf";
|
|
484
|
+
} | {
|
|
485
|
+
/**
|
|
486
|
+
* @generated from field: loams.collection.v1.WeightedSum weighted_sum = 3;
|
|
487
|
+
*/
|
|
488
|
+
value: WeightedSum;
|
|
489
|
+
case: "weightedSum";
|
|
490
|
+
} | {
|
|
491
|
+
case: undefined;
|
|
492
|
+
value?: undefined;
|
|
493
|
+
};
|
|
494
|
+
};
|
|
495
|
+
/**
|
|
496
|
+
* Describes the message loams.collection.v1.Fusion.
|
|
497
|
+
* Use `create(FusionSchema)` to create a new message.
|
|
498
|
+
*/
|
|
499
|
+
export declare const FusionSchema: GenMessage<Fusion>;
|
|
500
|
+
/**
|
|
501
|
+
* @generated from message loams.collection.v1.Rrf
|
|
502
|
+
*/
|
|
503
|
+
export type Rrf = Message<"loams.collection.v1.Rrf"> & {
|
|
504
|
+
/**
|
|
505
|
+
* The RRF constant; absent is 60, the IR's default, so `optional` rather
|
|
506
|
+
* than a `0` the engine would have to read as "no smoothing at all".
|
|
507
|
+
*
|
|
508
|
+
* @generated from field: optional uint32 k = 1;
|
|
509
|
+
*/
|
|
510
|
+
k?: number | undefined;
|
|
511
|
+
};
|
|
512
|
+
/**
|
|
513
|
+
* Describes the message loams.collection.v1.Rrf.
|
|
514
|
+
* Use `create(RrfSchema)` to create a new message.
|
|
515
|
+
*/
|
|
516
|
+
export declare const RrfSchema: GenMessage<Rrf>;
|
|
517
|
+
/**
|
|
518
|
+
* @generated from message loams.collection.v1.WeightedSum
|
|
519
|
+
*/
|
|
520
|
+
export type WeightedSum = Message<"loams.collection.v1.WeightedSum"> & {
|
|
521
|
+
/**
|
|
522
|
+
* One weight per input retriever, in the order the retrievers are given.
|
|
523
|
+
*
|
|
524
|
+
* @generated from field: repeated float weights = 1;
|
|
525
|
+
*/
|
|
526
|
+
weights: number[];
|
|
527
|
+
};
|
|
528
|
+
/**
|
|
529
|
+
* Describes the message loams.collection.v1.WeightedSum.
|
|
530
|
+
* Use `create(WeightedSumSchema)` to create a new message.
|
|
531
|
+
*/
|
|
532
|
+
export declare const WeightedSumSchema: GenMessage<WeightedSum>;
|
|
533
|
+
/**
|
|
534
|
+
* A query over the collection's fields: a filter, a text retriever's query, or
|
|
535
|
+
* a sparse retriever's IDF corpus. A proto oneof, so the JSON is the IR's own
|
|
536
|
+
* externally-tagged spelling with the one difference proto3 JSON forces: a unit
|
|
537
|
+
* arm is `{"matchAll": {}}` rather than `"match_all"`, and the arms with an
|
|
538
|
+
* underscore in them are `lowerCamelCase` (`matchPhrase`, `multiMatch`,
|
|
539
|
+
* `valuesCount`, `isNull`, `isEmpty`, `queryString`, `constantScore`,
|
|
540
|
+
* `weightedSum` — see the header).
|
|
541
|
+
*
|
|
542
|
+
* @generated from message loams.collection.v1.Query
|
|
543
|
+
*/
|
|
544
|
+
export type Query = Message<"loams.collection.v1.Query"> & {
|
|
545
|
+
/**
|
|
546
|
+
* @generated from oneof loams.collection.v1.Query.query
|
|
547
|
+
*/
|
|
548
|
+
query: {
|
|
549
|
+
/**
|
|
550
|
+
* Every document.
|
|
551
|
+
*
|
|
552
|
+
* @generated from field: google.protobuf.Empty match_all = 1;
|
|
553
|
+
*/
|
|
554
|
+
value: Empty;
|
|
555
|
+
case: "matchAll";
|
|
556
|
+
} | {
|
|
557
|
+
/**
|
|
558
|
+
* No document.
|
|
559
|
+
*
|
|
560
|
+
* @generated from field: google.protobuf.Empty match_none = 2;
|
|
561
|
+
*/
|
|
562
|
+
value: Empty;
|
|
563
|
+
case: "matchNone";
|
|
564
|
+
} | {
|
|
565
|
+
/**
|
|
566
|
+
* @generated from field: loams.collection.v1.MatchQuery match = 3;
|
|
567
|
+
*/
|
|
568
|
+
value: MatchQuery;
|
|
569
|
+
case: "match";
|
|
570
|
+
} | {
|
|
571
|
+
/**
|
|
572
|
+
* @generated from field: loams.collection.v1.MatchPhraseQuery match_phrase = 4;
|
|
573
|
+
*/
|
|
574
|
+
value: MatchPhraseQuery;
|
|
575
|
+
case: "matchPhrase";
|
|
576
|
+
} | {
|
|
577
|
+
/**
|
|
578
|
+
* @generated from field: loams.collection.v1.MultiMatchQuery multi_match = 5;
|
|
579
|
+
*/
|
|
580
|
+
value: MultiMatchQuery;
|
|
581
|
+
case: "multiMatch";
|
|
582
|
+
} | {
|
|
583
|
+
/**
|
|
584
|
+
* The field equals one value.
|
|
585
|
+
*
|
|
586
|
+
* @generated from field: loams.collection.v1.TermQuery term = 6;
|
|
587
|
+
*/
|
|
588
|
+
value: TermQuery;
|
|
589
|
+
case: "term";
|
|
590
|
+
} | {
|
|
591
|
+
/**
|
|
592
|
+
* The field equals any of these values.
|
|
593
|
+
*
|
|
594
|
+
* @generated from field: loams.collection.v1.TermsQuery terms = 7;
|
|
595
|
+
*/
|
|
596
|
+
value: TermsQuery;
|
|
597
|
+
case: "terms";
|
|
598
|
+
} | {
|
|
599
|
+
/**
|
|
600
|
+
* @generated from field: loams.collection.v1.RangeQuery range = 8;
|
|
601
|
+
*/
|
|
602
|
+
value: RangeQuery;
|
|
603
|
+
case: "range";
|
|
604
|
+
} | {
|
|
605
|
+
/**
|
|
606
|
+
* The field is present, whatever its value.
|
|
607
|
+
*
|
|
608
|
+
* @generated from field: loams.collection.v1.FieldQuery exists = 9;
|
|
609
|
+
*/
|
|
610
|
+
value: FieldQuery;
|
|
611
|
+
case: "exists";
|
|
612
|
+
} | {
|
|
613
|
+
/**
|
|
614
|
+
* @generated from field: loams.collection.v1.FieldQuery is_null = 10;
|
|
615
|
+
*/
|
|
616
|
+
value: FieldQuery;
|
|
617
|
+
case: "isNull";
|
|
618
|
+
} | {
|
|
619
|
+
/**
|
|
620
|
+
* @generated from field: loams.collection.v1.FieldQuery is_empty = 11;
|
|
621
|
+
*/
|
|
622
|
+
value: FieldQuery;
|
|
623
|
+
case: "isEmpty";
|
|
624
|
+
} | {
|
|
625
|
+
/**
|
|
626
|
+
* @generated from field: loams.collection.v1.ValuesCountQuery values_count = 12;
|
|
627
|
+
*/
|
|
628
|
+
value: ValuesCountQuery;
|
|
629
|
+
case: "valuesCount";
|
|
630
|
+
} | {
|
|
631
|
+
/**
|
|
632
|
+
* @generated from field: loams.collection.v1.PrefixQuery prefix = 13;
|
|
633
|
+
*/
|
|
634
|
+
value: PrefixQuery;
|
|
635
|
+
case: "prefix";
|
|
636
|
+
} | {
|
|
637
|
+
/**
|
|
638
|
+
* @generated from field: loams.collection.v1.WildcardQuery wildcard = 14;
|
|
639
|
+
*/
|
|
640
|
+
value: WildcardQuery;
|
|
641
|
+
case: "wildcard";
|
|
642
|
+
} | {
|
|
643
|
+
/**
|
|
644
|
+
* @generated from field: loams.collection.v1.FuzzyQuery fuzzy = 15;
|
|
645
|
+
*/
|
|
646
|
+
value: FuzzyQuery;
|
|
647
|
+
case: "fuzzy";
|
|
648
|
+
} | {
|
|
649
|
+
/**
|
|
650
|
+
* @generated from field: loams.collection.v1.QueryStringQuery query_string = 17;
|
|
651
|
+
*/
|
|
652
|
+
value: QueryStringQuery;
|
|
653
|
+
case: "queryString";
|
|
654
|
+
} | {
|
|
655
|
+
/**
|
|
656
|
+
* @generated from field: loams.collection.v1.BoolQuery bool = 18;
|
|
657
|
+
*/
|
|
658
|
+
value: BoolQuery;
|
|
659
|
+
case: "bool";
|
|
660
|
+
} | {
|
|
661
|
+
/**
|
|
662
|
+
* @generated from field: loams.collection.v1.BoostQuery boost = 19;
|
|
663
|
+
*/
|
|
664
|
+
value: BoostQuery;
|
|
665
|
+
case: "boost";
|
|
666
|
+
} | {
|
|
667
|
+
/**
|
|
668
|
+
* @generated from field: loams.collection.v1.ConstantScoreQuery constant_score = 20;
|
|
669
|
+
*/
|
|
670
|
+
value: ConstantScoreQuery;
|
|
671
|
+
case: "constantScore";
|
|
672
|
+
} | {
|
|
673
|
+
case: undefined;
|
|
674
|
+
value?: undefined;
|
|
675
|
+
};
|
|
676
|
+
/**
|
|
677
|
+
* The documents with these ids, and no others.
|
|
678
|
+
*
|
|
679
|
+
* **Not a oneof arm**, and the reason is a wire spelling rather than a
|
|
680
|
+
* modelling preference: a proto3 JSON oneof arm is always `{"arm": {…}}`, and
|
|
681
|
+
* the value here is a **list**, so an arm could only be spelled
|
|
682
|
+
* `{"ids": {"ids": [1, 2]}}` — a wrapper around one field that no IR has and a
|
|
683
|
+
* caller would have to learn separately. As a plain field the list sits exactly
|
|
684
|
+
* where the REST IR puts it: `{"ids": [1, {"uuid": "…"}]}`, which is
|
|
685
|
+
* `{"ids": [{"uint": "1"}, {"uuid": "…"}]}` in proto3 JSON.
|
|
686
|
+
*
|
|
687
|
+
* So `Query` is a oneof **plus** this field, and a request that sets both is
|
|
688
|
+
* `invalid_argument` rather than letting one silently win: two keys naming two
|
|
689
|
+
* different filters is a request that cannot be answered. That refusal is the
|
|
690
|
+
* handler's, not the codec's, and it names the field.
|
|
691
|
+
*
|
|
692
|
+
* Each element is a `google.protobuf.Value`, not a `DocumentId`, because a
|
|
693
|
+
* `repeated` field cannot be a oneof arm in protobuf at all, and because the
|
|
694
|
+
* `DocumentId` shape `{"uint": "1"}` **is** a `Value` — a one-key struct whose
|
|
695
|
+
* values are strings, so a `u64::MAX` id stays exact and `{"uuid": "…"}` keeps
|
|
696
|
+
* the REST spelling verbatim. The handler reads each back through the same
|
|
697
|
+
* `loams_query::json::pk::from_json` `GetDocumentsRequest.ids` goes through, so
|
|
698
|
+
* the three arms and their refusals are the document RPCs'. A whole number
|
|
699
|
+
* (`{"uint": 1}` or a bare `1`, exact up to 2^53) is a `uint` id too, and a
|
|
700
|
+
* bare string is a `string` id, as the REST route spells them.
|
|
701
|
+
*
|
|
702
|
+
* @generated from field: repeated google.protobuf.Value ids = 16;
|
|
703
|
+
*/
|
|
704
|
+
ids: Value[];
|
|
705
|
+
};
|
|
706
|
+
/**
|
|
707
|
+
* Describes the message loams.collection.v1.Query.
|
|
708
|
+
* Use `create(QuerySchema)` to create a new message.
|
|
709
|
+
*/
|
|
710
|
+
export declare const QuerySchema: GenMessage<Query>;
|
|
711
|
+
/**
|
|
712
|
+
* @generated from message loams.collection.v1.MatchQuery
|
|
713
|
+
*/
|
|
714
|
+
export type MatchQuery = Message<"loams.collection.v1.MatchQuery"> & {
|
|
715
|
+
/**
|
|
716
|
+
* @generated from field: string field = 1;
|
|
717
|
+
*/
|
|
718
|
+
field: string;
|
|
719
|
+
/**
|
|
720
|
+
* @generated from field: string text = 2;
|
|
721
|
+
*/
|
|
722
|
+
text: string;
|
|
723
|
+
/**
|
|
724
|
+
* Whether every term must match: `or` or `and`, absent being `or`.
|
|
725
|
+
*
|
|
726
|
+
* A **string**, not the `BoolOperator` enum, and this is the one enum-shaped
|
|
727
|
+
* field in the file that is not one: the IR's spelling is `"or"` / `"and"`
|
|
728
|
+
* and that is what §05 §4's example body and the native REST route both
|
|
729
|
+
* write, so an enum here would have the codec refuse `"operator": "or"` as an
|
|
730
|
+
* unknown variant *before a handler runs* — a refusal with no reason and no
|
|
731
|
+
* field. A string keeps the REST spelling verbatim, which is the same call
|
|
732
|
+
* `Patch.mode` and `ScanColumn.role` make for the same reason; `or` and `and`
|
|
733
|
+
* are the accepted values and anything else is `invalid_argument`.
|
|
734
|
+
*
|
|
735
|
+
* @generated from field: string operator = 3;
|
|
736
|
+
*/
|
|
737
|
+
operator: string;
|
|
738
|
+
/**
|
|
739
|
+
* How many of the terms must match, as the IR's own string form (`"2"`,
|
|
740
|
+
* `"75%"`).
|
|
741
|
+
*
|
|
742
|
+
* @generated from field: optional string minimum_should_match = 4;
|
|
743
|
+
*/
|
|
744
|
+
minimumShouldMatch?: string | undefined;
|
|
745
|
+
/**
|
|
746
|
+
* @generated from field: loams.collection.v1.Fuzziness fuzziness = 5;
|
|
747
|
+
*/
|
|
748
|
+
fuzziness?: Fuzziness | undefined;
|
|
749
|
+
/**
|
|
750
|
+
* The analyzer to run, over the field's own.
|
|
751
|
+
*
|
|
752
|
+
* @generated from field: string analyzer = 6;
|
|
753
|
+
*/
|
|
754
|
+
analyzer: string;
|
|
755
|
+
};
|
|
756
|
+
/**
|
|
757
|
+
* Describes the message loams.collection.v1.MatchQuery.
|
|
758
|
+
* Use `create(MatchQuerySchema)` to create a new message.
|
|
759
|
+
*/
|
|
760
|
+
export declare const MatchQuerySchema: GenMessage<MatchQuery>;
|
|
761
|
+
/**
|
|
762
|
+
* @generated from message loams.collection.v1.MatchPhraseQuery
|
|
763
|
+
*/
|
|
764
|
+
export type MatchPhraseQuery = Message<"loams.collection.v1.MatchPhraseQuery"> & {
|
|
765
|
+
/**
|
|
766
|
+
* @generated from field: string field = 1;
|
|
767
|
+
*/
|
|
768
|
+
field: string;
|
|
769
|
+
/**
|
|
770
|
+
* @generated from field: string text = 2;
|
|
771
|
+
*/
|
|
772
|
+
text: string;
|
|
773
|
+
/**
|
|
774
|
+
* How far apart the terms may be and still match, in positions.
|
|
775
|
+
*
|
|
776
|
+
* @generated from field: uint32 slop = 3;
|
|
777
|
+
*/
|
|
778
|
+
slop: number;
|
|
779
|
+
};
|
|
780
|
+
/**
|
|
781
|
+
* Describes the message loams.collection.v1.MatchPhraseQuery.
|
|
782
|
+
* Use `create(MatchPhraseQuerySchema)` to create a new message.
|
|
783
|
+
*/
|
|
784
|
+
export declare const MatchPhraseQuerySchema: GenMessage<MatchPhraseQuery>;
|
|
785
|
+
/**
|
|
786
|
+
* @generated from message loams.collection.v1.MultiMatchQuery
|
|
787
|
+
*/
|
|
788
|
+
export type MultiMatchQuery = Message<"loams.collection.v1.MultiMatchQuery"> & {
|
|
789
|
+
/**
|
|
790
|
+
* The fields to search, each with its boost. None is every indexed text
|
|
791
|
+
* field at boost 1, as Elasticsearch's `index.query.default_field` of `*`.
|
|
792
|
+
*
|
|
793
|
+
* @generated from field: repeated loams.collection.v1.MultiMatchField fields = 1;
|
|
794
|
+
*/
|
|
795
|
+
fields: MultiMatchField[];
|
|
796
|
+
/**
|
|
797
|
+
* @generated from field: string text = 2;
|
|
798
|
+
*/
|
|
799
|
+
text: string;
|
|
800
|
+
/**
|
|
801
|
+
* How the fields are combined; absent is `MULTI_MATCH_KIND_BEST_FIELDS`.
|
|
802
|
+
*
|
|
803
|
+
* @generated from field: loams.collection.v1.MultiMatchKind kind = 3;
|
|
804
|
+
*/
|
|
805
|
+
kind: MultiMatchKind;
|
|
806
|
+
/**
|
|
807
|
+
* @generated from field: loams.collection.v1.BoolOperator operator = 4;
|
|
808
|
+
*/
|
|
809
|
+
operator: BoolOperator;
|
|
810
|
+
/**
|
|
811
|
+
* How much a best-fields match counts against a most-fields one; absent is
|
|
812
|
+
* the engine's own.
|
|
813
|
+
*
|
|
814
|
+
* @generated from field: optional float tie_breaker = 5;
|
|
815
|
+
*/
|
|
816
|
+
tieBreaker?: number | undefined;
|
|
817
|
+
};
|
|
818
|
+
/**
|
|
819
|
+
* Describes the message loams.collection.v1.MultiMatchQuery.
|
|
820
|
+
* Use `create(MultiMatchQuerySchema)` to create a new message.
|
|
821
|
+
*/
|
|
822
|
+
export declare const MultiMatchQuerySchema: GenMessage<MultiMatchQuery>;
|
|
823
|
+
/**
|
|
824
|
+
* @generated from message loams.collection.v1.MultiMatchField
|
|
825
|
+
*/
|
|
826
|
+
export type MultiMatchField = Message<"loams.collection.v1.MultiMatchField"> & {
|
|
827
|
+
/**
|
|
828
|
+
* @generated from field: string field = 1;
|
|
829
|
+
*/
|
|
830
|
+
field: string;
|
|
831
|
+
/**
|
|
832
|
+
* Absent (0) is 1, as a bare field name is in Elasticsearch.
|
|
833
|
+
*
|
|
834
|
+
* @generated from field: float boost = 2;
|
|
835
|
+
*/
|
|
836
|
+
boost: number;
|
|
837
|
+
};
|
|
838
|
+
/**
|
|
839
|
+
* Describes the message loams.collection.v1.MultiMatchField.
|
|
840
|
+
* Use `create(MultiMatchFieldSchema)` to create a new message.
|
|
841
|
+
*/
|
|
842
|
+
export declare const MultiMatchFieldSchema: GenMessage<MultiMatchField>;
|
|
843
|
+
/**
|
|
844
|
+
* @generated from message loams.collection.v1.TermQuery
|
|
845
|
+
*/
|
|
846
|
+
export type TermQuery = Message<"loams.collection.v1.TermQuery"> & {
|
|
847
|
+
/**
|
|
848
|
+
* @generated from field: string field = 1;
|
|
849
|
+
*/
|
|
850
|
+
field: string;
|
|
851
|
+
/**
|
|
852
|
+
* The value, as the IR's own JSON: a string, a bool, a number or
|
|
853
|
+
* `{"date": "<RFC 3339>"}` (Ruling 9).
|
|
854
|
+
*
|
|
855
|
+
* @generated from field: google.protobuf.Value value = 2;
|
|
856
|
+
*/
|
|
857
|
+
value?: Value | undefined;
|
|
858
|
+
};
|
|
859
|
+
/**
|
|
860
|
+
* Describes the message loams.collection.v1.TermQuery.
|
|
861
|
+
* Use `create(TermQuerySchema)` to create a new message.
|
|
862
|
+
*/
|
|
863
|
+
export declare const TermQuerySchema: GenMessage<TermQuery>;
|
|
864
|
+
/**
|
|
865
|
+
* @generated from message loams.collection.v1.TermsQuery
|
|
866
|
+
*/
|
|
867
|
+
export type TermsQuery = Message<"loams.collection.v1.TermsQuery"> & {
|
|
868
|
+
/**
|
|
869
|
+
* @generated from field: string field = 1;
|
|
870
|
+
*/
|
|
871
|
+
field: string;
|
|
872
|
+
/**
|
|
873
|
+
* @generated from field: repeated google.protobuf.Value values = 2;
|
|
874
|
+
*/
|
|
875
|
+
values: Value[];
|
|
876
|
+
};
|
|
877
|
+
/**
|
|
878
|
+
* Describes the message loams.collection.v1.TermsQuery.
|
|
879
|
+
* Use `create(TermsQuerySchema)` to create a new message.
|
|
880
|
+
*/
|
|
881
|
+
export declare const TermsQuerySchema: GenMessage<TermsQuery>;
|
|
882
|
+
/**
|
|
883
|
+
* @generated from message loams.collection.v1.RangeQuery
|
|
884
|
+
*/
|
|
885
|
+
export type RangeQuery = Message<"loams.collection.v1.RangeQuery"> & {
|
|
886
|
+
/**
|
|
887
|
+
* @generated from field: string field = 1;
|
|
888
|
+
*/
|
|
889
|
+
field: string;
|
|
890
|
+
/**
|
|
891
|
+
* The bounds, each a value of the field's own kind and each optional: an
|
|
892
|
+
* absent bound is unbounded on that side. `gt`/`gte` and `lt`/`lte` both set
|
|
893
|
+
* is `invalid_argument`.
|
|
894
|
+
*
|
|
895
|
+
* @generated from field: google.protobuf.Value gt = 2;
|
|
896
|
+
*/
|
|
897
|
+
gt?: Value | undefined;
|
|
898
|
+
/**
|
|
899
|
+
* @generated from field: google.protobuf.Value gte = 3;
|
|
900
|
+
*/
|
|
901
|
+
gte?: Value | undefined;
|
|
902
|
+
/**
|
|
903
|
+
* @generated from field: google.protobuf.Value lt = 4;
|
|
904
|
+
*/
|
|
905
|
+
lt?: Value | undefined;
|
|
906
|
+
/**
|
|
907
|
+
* @generated from field: google.protobuf.Value lte = 5;
|
|
908
|
+
*/
|
|
909
|
+
lte?: Value | undefined;
|
|
910
|
+
};
|
|
911
|
+
/**
|
|
912
|
+
* Describes the message loams.collection.v1.RangeQuery.
|
|
913
|
+
* Use `create(RangeQuerySchema)` to create a new message.
|
|
914
|
+
*/
|
|
915
|
+
export declare const RangeQuerySchema: GenMessage<RangeQuery>;
|
|
916
|
+
/**
|
|
917
|
+
* `exists`, `is_null` and `is_empty`: one message, because a caller asks the
|
|
918
|
+
* same question of a field in each case.
|
|
919
|
+
*
|
|
920
|
+
* @generated from message loams.collection.v1.FieldQuery
|
|
921
|
+
*/
|
|
922
|
+
export type FieldQuery = Message<"loams.collection.v1.FieldQuery"> & {
|
|
923
|
+
/**
|
|
924
|
+
* @generated from field: string field = 1;
|
|
925
|
+
*/
|
|
926
|
+
field: string;
|
|
927
|
+
};
|
|
928
|
+
/**
|
|
929
|
+
* Describes the message loams.collection.v1.FieldQuery.
|
|
930
|
+
* Use `create(FieldQuerySchema)` to create a new message.
|
|
931
|
+
*/
|
|
932
|
+
export declare const FieldQuerySchema: GenMessage<FieldQuery>;
|
|
933
|
+
/**
|
|
934
|
+
* How many values a field's array (or token) column holds.
|
|
935
|
+
*
|
|
936
|
+
* @generated from message loams.collection.v1.ValuesCountQuery
|
|
937
|
+
*/
|
|
938
|
+
export type ValuesCountQuery = Message<"loams.collection.v1.ValuesCountQuery"> & {
|
|
939
|
+
/**
|
|
940
|
+
* @generated from field: string field = 1;
|
|
941
|
+
*/
|
|
942
|
+
field: string;
|
|
943
|
+
/**
|
|
944
|
+
* @generated from field: optional uint64 gt = 2;
|
|
945
|
+
*/
|
|
946
|
+
gt?: bigint | undefined;
|
|
947
|
+
/**
|
|
948
|
+
* @generated from field: optional uint64 gte = 3;
|
|
949
|
+
*/
|
|
950
|
+
gte?: bigint | undefined;
|
|
951
|
+
/**
|
|
952
|
+
* @generated from field: optional uint64 lt = 4;
|
|
953
|
+
*/
|
|
954
|
+
lt?: bigint | undefined;
|
|
955
|
+
/**
|
|
956
|
+
* @generated from field: optional uint64 lte = 5;
|
|
957
|
+
*/
|
|
958
|
+
lte?: bigint | undefined;
|
|
959
|
+
};
|
|
960
|
+
/**
|
|
961
|
+
* Describes the message loams.collection.v1.ValuesCountQuery.
|
|
962
|
+
* Use `create(ValuesCountQuerySchema)` to create a new message.
|
|
963
|
+
*/
|
|
964
|
+
export declare const ValuesCountQuerySchema: GenMessage<ValuesCountQuery>;
|
|
965
|
+
/**
|
|
966
|
+
* @generated from message loams.collection.v1.PrefixQuery
|
|
967
|
+
*/
|
|
968
|
+
export type PrefixQuery = Message<"loams.collection.v1.PrefixQuery"> & {
|
|
969
|
+
/**
|
|
970
|
+
* @generated from field: string field = 1;
|
|
971
|
+
*/
|
|
972
|
+
field: string;
|
|
973
|
+
/**
|
|
974
|
+
* @generated from field: string value = 2;
|
|
975
|
+
*/
|
|
976
|
+
value: string;
|
|
977
|
+
};
|
|
978
|
+
/**
|
|
979
|
+
* Describes the message loams.collection.v1.PrefixQuery.
|
|
980
|
+
* Use `create(PrefixQuerySchema)` to create a new message.
|
|
981
|
+
*/
|
|
982
|
+
export declare const PrefixQuerySchema: GenMessage<PrefixQuery>;
|
|
983
|
+
/**
|
|
984
|
+
* @generated from message loams.collection.v1.WildcardQuery
|
|
985
|
+
*/
|
|
986
|
+
export type WildcardQuery = Message<"loams.collection.v1.WildcardQuery"> & {
|
|
987
|
+
/**
|
|
988
|
+
* @generated from field: string field = 1;
|
|
989
|
+
*/
|
|
990
|
+
field: string;
|
|
991
|
+
/**
|
|
992
|
+
* With `*` and `?`, as the REST route spells it.
|
|
993
|
+
*
|
|
994
|
+
* @generated from field: string pattern = 2;
|
|
995
|
+
*/
|
|
996
|
+
pattern: string;
|
|
997
|
+
};
|
|
998
|
+
/**
|
|
999
|
+
* Describes the message loams.collection.v1.WildcardQuery.
|
|
1000
|
+
* Use `create(WildcardQuerySchema)` to create a new message.
|
|
1001
|
+
*/
|
|
1002
|
+
export declare const WildcardQuerySchema: GenMessage<WildcardQuery>;
|
|
1003
|
+
/**
|
|
1004
|
+
* @generated from message loams.collection.v1.FuzzyQuery
|
|
1005
|
+
*/
|
|
1006
|
+
export type FuzzyQuery = Message<"loams.collection.v1.FuzzyQuery"> & {
|
|
1007
|
+
/**
|
|
1008
|
+
* @generated from field: string field = 1;
|
|
1009
|
+
*/
|
|
1010
|
+
field: string;
|
|
1011
|
+
/**
|
|
1012
|
+
* @generated from field: string value = 2;
|
|
1013
|
+
*/
|
|
1014
|
+
value: string;
|
|
1015
|
+
/**
|
|
1016
|
+
* @generated from field: loams.collection.v1.Fuzziness fuzziness = 3;
|
|
1017
|
+
*/
|
|
1018
|
+
fuzziness?: Fuzziness | undefined;
|
|
1019
|
+
};
|
|
1020
|
+
/**
|
|
1021
|
+
* Describes the message loams.collection.v1.FuzzyQuery.
|
|
1022
|
+
* Use `create(FuzzyQuerySchema)` to create a new message.
|
|
1023
|
+
*/
|
|
1024
|
+
export declare const FuzzyQuerySchema: GenMessage<FuzzyQuery>;
|
|
1025
|
+
/**
|
|
1026
|
+
* @generated from message loams.collection.v1.QueryStringQuery
|
|
1027
|
+
*/
|
|
1028
|
+
export type QueryStringQuery = Message<"loams.collection.v1.QueryStringQuery"> & {
|
|
1029
|
+
/**
|
|
1030
|
+
* The Lucene query language, as the REST route's `query_string` takes it.
|
|
1031
|
+
*
|
|
1032
|
+
* @generated from field: string query = 1;
|
|
1033
|
+
*/
|
|
1034
|
+
query: string;
|
|
1035
|
+
/**
|
|
1036
|
+
* The fields to search when the query names none. None is every indexed
|
|
1037
|
+
* text field, as Elasticsearch's `index.query.default_field` of `*`.
|
|
1038
|
+
*
|
|
1039
|
+
* @generated from field: repeated string default_fields = 2;
|
|
1040
|
+
*/
|
|
1041
|
+
defaultFields: string[];
|
|
1042
|
+
/**
|
|
1043
|
+
* @generated from field: loams.collection.v1.BoolOperator default_operator = 3;
|
|
1044
|
+
*/
|
|
1045
|
+
defaultOperator: BoolOperator;
|
|
1046
|
+
};
|
|
1047
|
+
/**
|
|
1048
|
+
* Describes the message loams.collection.v1.QueryStringQuery.
|
|
1049
|
+
* Use `create(QueryStringQuerySchema)` to create a new message.
|
|
1050
|
+
*/
|
|
1051
|
+
export declare const QueryStringQuerySchema: GenMessage<QueryStringQuery>;
|
|
1052
|
+
/**
|
|
1053
|
+
* @generated from message loams.collection.v1.BoolQuery
|
|
1054
|
+
*/
|
|
1055
|
+
export type BoolQuery = Message<"loams.collection.v1.BoolQuery"> & {
|
|
1056
|
+
/**
|
|
1057
|
+
* Every one of these must match.
|
|
1058
|
+
*
|
|
1059
|
+
* @generated from field: repeated loams.collection.v1.Query must = 1;
|
|
1060
|
+
*/
|
|
1061
|
+
must: Query[];
|
|
1062
|
+
/**
|
|
1063
|
+
* At least `minimum_should_match` of these must match, and scoring is their
|
|
1064
|
+
* sum.
|
|
1065
|
+
*
|
|
1066
|
+
* @generated from field: repeated loams.collection.v1.Query should = 2;
|
|
1067
|
+
*/
|
|
1068
|
+
should: Query[];
|
|
1069
|
+
/**
|
|
1070
|
+
* None of these may match.
|
|
1071
|
+
*
|
|
1072
|
+
* @generated from field: repeated loams.collection.v1.Query must_not = 3;
|
|
1073
|
+
*/
|
|
1074
|
+
mustNot: Query[];
|
|
1075
|
+
/**
|
|
1076
|
+
* These must match and do not score.
|
|
1077
|
+
*
|
|
1078
|
+
* @generated from field: repeated loams.collection.v1.Query filter = 4;
|
|
1079
|
+
*/
|
|
1080
|
+
filter: Query[];
|
|
1081
|
+
/**
|
|
1082
|
+
* @generated from field: optional string minimum_should_match = 5;
|
|
1083
|
+
*/
|
|
1084
|
+
minimumShouldMatch?: string | undefined;
|
|
1085
|
+
};
|
|
1086
|
+
/**
|
|
1087
|
+
* Describes the message loams.collection.v1.BoolQuery.
|
|
1088
|
+
* Use `create(BoolQuerySchema)` to create a new message.
|
|
1089
|
+
*/
|
|
1090
|
+
export declare const BoolQuerySchema: GenMessage<BoolQuery>;
|
|
1091
|
+
/**
|
|
1092
|
+
* @generated from message loams.collection.v1.BoostQuery
|
|
1093
|
+
*/
|
|
1094
|
+
export type BoostQuery = Message<"loams.collection.v1.BoostQuery"> & {
|
|
1095
|
+
/**
|
|
1096
|
+
* The query whose score is multiplied.
|
|
1097
|
+
*
|
|
1098
|
+
* @generated from field: loams.collection.v1.Query query = 1;
|
|
1099
|
+
*/
|
|
1100
|
+
query?: Query | undefined;
|
|
1101
|
+
/**
|
|
1102
|
+
* @generated from field: float boost = 2;
|
|
1103
|
+
*/
|
|
1104
|
+
boost: number;
|
|
1105
|
+
};
|
|
1106
|
+
/**
|
|
1107
|
+
* Describes the message loams.collection.v1.BoostQuery.
|
|
1108
|
+
* Use `create(BoostQuerySchema)` to create a new message.
|
|
1109
|
+
*/
|
|
1110
|
+
export declare const BoostQuerySchema: GenMessage<BoostQuery>;
|
|
1111
|
+
/**
|
|
1112
|
+
* @generated from message loams.collection.v1.ConstantScoreQuery
|
|
1113
|
+
*/
|
|
1114
|
+
export type ConstantScoreQuery = Message<"loams.collection.v1.ConstantScoreQuery"> & {
|
|
1115
|
+
/**
|
|
1116
|
+
* The query that decides membership; its own score is discarded.
|
|
1117
|
+
*
|
|
1118
|
+
* @generated from field: loams.collection.v1.Query query = 1;
|
|
1119
|
+
*/
|
|
1120
|
+
query?: Query | undefined;
|
|
1121
|
+
/**
|
|
1122
|
+
* The score every match is given.
|
|
1123
|
+
*
|
|
1124
|
+
* @generated from field: float score = 2;
|
|
1125
|
+
*/
|
|
1126
|
+
score: number;
|
|
1127
|
+
};
|
|
1128
|
+
/**
|
|
1129
|
+
* Describes the message loams.collection.v1.ConstantScoreQuery.
|
|
1130
|
+
* Use `create(ConstantScoreQuerySchema)` to create a new message.
|
|
1131
|
+
*/
|
|
1132
|
+
export declare const ConstantScoreQuerySchema: GenMessage<ConstantScoreQuery>;
|
|
1133
|
+
/**
|
|
1134
|
+
* How far a fuzzy match may edit. A oneof, so the REST spellings `"auto"` and
|
|
1135
|
+
* an integer 0–2 become `{"auto": {}}` and `{"edits": 1}` — a bare string has
|
|
1136
|
+
* no oneof form, the same reason `match_all` is an empty message.
|
|
1137
|
+
*
|
|
1138
|
+
* @generated from message loams.collection.v1.Fuzziness
|
|
1139
|
+
*/
|
|
1140
|
+
export type Fuzziness = Message<"loams.collection.v1.Fuzziness"> & {
|
|
1141
|
+
/**
|
|
1142
|
+
* @generated from oneof loams.collection.v1.Fuzziness.fuzziness
|
|
1143
|
+
*/
|
|
1144
|
+
fuzziness: {
|
|
1145
|
+
/**
|
|
1146
|
+
* The engine picks from the term's length.
|
|
1147
|
+
*
|
|
1148
|
+
* @generated from field: google.protobuf.Empty auto = 1;
|
|
1149
|
+
*/
|
|
1150
|
+
value: Empty;
|
|
1151
|
+
case: "auto";
|
|
1152
|
+
} | {
|
|
1153
|
+
/**
|
|
1154
|
+
* An exact number of edits, 0 to 2.
|
|
1155
|
+
*
|
|
1156
|
+
* @generated from field: uint32 edits = 2;
|
|
1157
|
+
*/
|
|
1158
|
+
value: number;
|
|
1159
|
+
case: "edits";
|
|
1160
|
+
} | {
|
|
1161
|
+
case: undefined;
|
|
1162
|
+
value?: undefined;
|
|
1163
|
+
};
|
|
1164
|
+
};
|
|
1165
|
+
/**
|
|
1166
|
+
* Describes the message loams.collection.v1.Fuzziness.
|
|
1167
|
+
* Use `create(FuzzinessSchema)` to create a new message.
|
|
1168
|
+
*/
|
|
1169
|
+
export declare const FuzzinessSchema: GenMessage<Fuzziness>;
|
|
1170
|
+
/**
|
|
1171
|
+
* One key of the effective sort; the primary key ascending always breaks ties
|
|
1172
|
+
* (Ruling 10). A proto oneof, so the JSON is `{"score": {"order": …}}` /
|
|
1173
|
+
* `{"pk": {"order": …}}` / `{"field": {"field": …, "order": …,
|
|
1174
|
+
* "missing": …}}` — the same shape the IR's serde produces, and
|
|
1175
|
+
* `{"pk": {}}` remains a valid way to say "primary key, ascending".
|
|
1176
|
+
*
|
|
1177
|
+
* @generated from message loams.collection.v1.SortKey
|
|
1178
|
+
*/
|
|
1179
|
+
export type SortKey = Message<"loams.collection.v1.SortKey"> & {
|
|
1180
|
+
/**
|
|
1181
|
+
* @generated from oneof loams.collection.v1.SortKey.key
|
|
1182
|
+
*/
|
|
1183
|
+
key: {
|
|
1184
|
+
/**
|
|
1185
|
+
* @generated from field: loams.collection.v1.ScoreSort score = 1;
|
|
1186
|
+
*/
|
|
1187
|
+
value: ScoreSort;
|
|
1188
|
+
case: "score";
|
|
1189
|
+
} | {
|
|
1190
|
+
/**
|
|
1191
|
+
* @generated from field: loams.collection.v1.PrimaryKeySort pk = 2;
|
|
1192
|
+
*/
|
|
1193
|
+
value: PrimaryKeySort;
|
|
1194
|
+
case: "pk";
|
|
1195
|
+
} | {
|
|
1196
|
+
/**
|
|
1197
|
+
* @generated from field: loams.collection.v1.FieldSort field = 3;
|
|
1198
|
+
*/
|
|
1199
|
+
value: FieldSort;
|
|
1200
|
+
case: "field";
|
|
1201
|
+
} | {
|
|
1202
|
+
case: undefined;
|
|
1203
|
+
value?: undefined;
|
|
1204
|
+
};
|
|
1205
|
+
};
|
|
1206
|
+
/**
|
|
1207
|
+
* Describes the message loams.collection.v1.SortKey.
|
|
1208
|
+
* Use `create(SortKeySchema)` to create a new message.
|
|
1209
|
+
*/
|
|
1210
|
+
export declare const SortKeySchema: GenMessage<SortKey>;
|
|
1211
|
+
/**
|
|
1212
|
+
* @generated from message loams.collection.v1.ScoreSort
|
|
1213
|
+
*/
|
|
1214
|
+
export type ScoreSort = Message<"loams.collection.v1.ScoreSort"> & {
|
|
1215
|
+
/**
|
|
1216
|
+
* Absent is descending, which is what sorting by score means.
|
|
1217
|
+
*
|
|
1218
|
+
* @generated from field: loams.collection.v1.SortOrder order = 1;
|
|
1219
|
+
*/
|
|
1220
|
+
order: SortOrder;
|
|
1221
|
+
};
|
|
1222
|
+
/**
|
|
1223
|
+
* Describes the message loams.collection.v1.ScoreSort.
|
|
1224
|
+
* Use `create(ScoreSortSchema)` to create a new message.
|
|
1225
|
+
*/
|
|
1226
|
+
export declare const ScoreSortSchema: GenMessage<ScoreSort>;
|
|
1227
|
+
/**
|
|
1228
|
+
* @generated from message loams.collection.v1.PrimaryKeySort
|
|
1229
|
+
*/
|
|
1230
|
+
export type PrimaryKeySort = Message<"loams.collection.v1.PrimaryKeySort"> & {
|
|
1231
|
+
/**
|
|
1232
|
+
* Absent is ascending.
|
|
1233
|
+
*
|
|
1234
|
+
* @generated from field: loams.collection.v1.SortOrder order = 1;
|
|
1235
|
+
*/
|
|
1236
|
+
order: SortOrder;
|
|
1237
|
+
};
|
|
1238
|
+
/**
|
|
1239
|
+
* Describes the message loams.collection.v1.PrimaryKeySort.
|
|
1240
|
+
* Use `create(PrimaryKeySortSchema)` to create a new message.
|
|
1241
|
+
*/
|
|
1242
|
+
export declare const PrimaryKeySortSchema: GenMessage<PrimaryKeySort>;
|
|
1243
|
+
/**
|
|
1244
|
+
* @generated from message loams.collection.v1.FieldSort
|
|
1245
|
+
*/
|
|
1246
|
+
export type FieldSort = Message<"loams.collection.v1.FieldSort"> & {
|
|
1247
|
+
/**
|
|
1248
|
+
* @generated from field: string field = 1;
|
|
1249
|
+
*/
|
|
1250
|
+
field: string;
|
|
1251
|
+
/**
|
|
1252
|
+
* Absent is ascending.
|
|
1253
|
+
*
|
|
1254
|
+
* @generated from field: loams.collection.v1.SortOrder order = 2;
|
|
1255
|
+
*/
|
|
1256
|
+
order: SortOrder;
|
|
1257
|
+
/**
|
|
1258
|
+
* Where a document without the field sorts. Absent is last.
|
|
1259
|
+
*
|
|
1260
|
+
* @generated from field: loams.collection.v1.MissingOrder missing = 3;
|
|
1261
|
+
*/
|
|
1262
|
+
missing: MissingOrder;
|
|
1263
|
+
};
|
|
1264
|
+
/**
|
|
1265
|
+
* Describes the message loams.collection.v1.FieldSort.
|
|
1266
|
+
* Use `create(FieldSortSchema)` to create a new message.
|
|
1267
|
+
*/
|
|
1268
|
+
export declare const FieldSortSchema: GenMessage<FieldSort>;
|
|
1269
|
+
/**
|
|
1270
|
+
* Highlighting of text fields (ES `highlight`).
|
|
1271
|
+
*
|
|
1272
|
+
* @generated from message loams.collection.v1.Highlight
|
|
1273
|
+
*/
|
|
1274
|
+
export type Highlight = Message<"loams.collection.v1.Highlight"> & {
|
|
1275
|
+
/**
|
|
1276
|
+
* @generated from field: repeated loams.collection.v1.HighlightField fields = 1;
|
|
1277
|
+
*/
|
|
1278
|
+
fields: HighlightField[];
|
|
1279
|
+
};
|
|
1280
|
+
/**
|
|
1281
|
+
* Describes the message loams.collection.v1.Highlight.
|
|
1282
|
+
* Use `create(HighlightSchema)` to create a new message.
|
|
1283
|
+
*/
|
|
1284
|
+
export declare const HighlightSchema: GenMessage<Highlight>;
|
|
1285
|
+
/**
|
|
1286
|
+
* @generated from message loams.collection.v1.HighlightField
|
|
1287
|
+
*/
|
|
1288
|
+
export type HighlightField = Message<"loams.collection.v1.HighlightField"> & {
|
|
1289
|
+
/**
|
|
1290
|
+
* @generated from field: string field = 1;
|
|
1291
|
+
*/
|
|
1292
|
+
field: string;
|
|
1293
|
+
/**
|
|
1294
|
+
* What wraps a matched term. Absent is the IR's `<em>` / `</em>`, which is
|
|
1295
|
+
* why both are `optional`: proto3 cannot tell an absent string from `""`,
|
|
1296
|
+
* and `""` is a legitimate tag.
|
|
1297
|
+
*
|
|
1298
|
+
* @generated from field: optional string pre_tag = 2;
|
|
1299
|
+
*/
|
|
1300
|
+
preTag?: string | undefined;
|
|
1301
|
+
/**
|
|
1302
|
+
* @generated from field: optional string post_tag = 3;
|
|
1303
|
+
*/
|
|
1304
|
+
postTag?: string | undefined;
|
|
1305
|
+
/**
|
|
1306
|
+
* The size of one fragment in characters; absent is the IR's 100.
|
|
1307
|
+
*
|
|
1308
|
+
* @generated from field: optional uint32 fragment_size = 4;
|
|
1309
|
+
*/
|
|
1310
|
+
fragmentSize?: number | undefined;
|
|
1311
|
+
/**
|
|
1312
|
+
* How many fragments of the field to answer; absent is the IR's 5.
|
|
1313
|
+
*
|
|
1314
|
+
* @generated from field: optional uint32 number_of_fragments = 5;
|
|
1315
|
+
*/
|
|
1316
|
+
numberOfFragments?: number | undefined;
|
|
1317
|
+
};
|
|
1318
|
+
/**
|
|
1319
|
+
* Describes the message loams.collection.v1.HighlightField.
|
|
1320
|
+
* Use `create(HighlightFieldSchema)` to create a new message.
|
|
1321
|
+
*/
|
|
1322
|
+
export declare const HighlightFieldSchema: GenMessage<HighlightField>;
|
|
1323
|
+
/**
|
|
1324
|
+
* Groups hits by a field value (Qdrant's `group_by`).
|
|
1325
|
+
*
|
|
1326
|
+
* @generated from message loams.collection.v1.GroupBy
|
|
1327
|
+
*/
|
|
1328
|
+
export type GroupBy = Message<"loams.collection.v1.GroupBy"> & {
|
|
1329
|
+
/**
|
|
1330
|
+
* @generated from field: string field = 1;
|
|
1331
|
+
*/
|
|
1332
|
+
field: string;
|
|
1333
|
+
/**
|
|
1334
|
+
* How many hits of a group to answer; absent is the IR's 3.
|
|
1335
|
+
*
|
|
1336
|
+
* @generated from field: optional uint32 group_size = 2;
|
|
1337
|
+
*/
|
|
1338
|
+
groupSize?: number | undefined;
|
|
1339
|
+
/**
|
|
1340
|
+
* How many groups to answer; absent is the IR's 10.
|
|
1341
|
+
*
|
|
1342
|
+
* @generated from field: optional uint32 limit = 3;
|
|
1343
|
+
*/
|
|
1344
|
+
limit?: number | undefined;
|
|
1345
|
+
};
|
|
1346
|
+
/**
|
|
1347
|
+
* Describes the message loams.collection.v1.GroupBy.
|
|
1348
|
+
* Use `create(GroupBySchema)` to create a new message.
|
|
1349
|
+
*/
|
|
1350
|
+
export declare const GroupBySchema: GenMessage<GroupBy>;
|
|
1351
|
+
/**
|
|
1352
|
+
* @generated from message loams.collection.v1.SearchResponse
|
|
1353
|
+
*/
|
|
1354
|
+
export type SearchResponse = Message<"loams.collection.v1.SearchResponse"> & {
|
|
1355
|
+
/**
|
|
1356
|
+
* The hits, in the effective order. Absent when there are none, which is
|
|
1357
|
+
* proto3 JSON's spelling of an empty list.
|
|
1358
|
+
*
|
|
1359
|
+
* @generated from field: repeated loams.collection.v1.Hit hits = 1;
|
|
1360
|
+
*/
|
|
1361
|
+
hits: Hit[];
|
|
1362
|
+
/**
|
|
1363
|
+
* How many documents matched. Absent unless `track_total_hits` asked for a
|
|
1364
|
+
* count, because counting is not free.
|
|
1365
|
+
*
|
|
1366
|
+
* @generated from field: loams.collection.v1.TotalHits total = 2;
|
|
1367
|
+
*/
|
|
1368
|
+
total?: TotalHits | undefined;
|
|
1369
|
+
/**
|
|
1370
|
+
* The aggregations, as Tantivy's own JSON answers them.
|
|
1371
|
+
*
|
|
1372
|
+
* @generated from field: google.protobuf.Value aggregations = 3;
|
|
1373
|
+
*/
|
|
1374
|
+
aggregations?: Value | undefined;
|
|
1375
|
+
/**
|
|
1376
|
+
* The groups, when the request asked to group.
|
|
1377
|
+
*
|
|
1378
|
+
* @generated from field: repeated loams.collection.v1.HitGroup groups = 4;
|
|
1379
|
+
*/
|
|
1380
|
+
groups: HitGroup[];
|
|
1381
|
+
/**
|
|
1382
|
+
* The state the read saw (overview §6.5), and a `consistency.at_least` that
|
|
1383
|
+
* reads this state again. The same value is the `loams-consistency-token`
|
|
1384
|
+
* response header.
|
|
1385
|
+
*
|
|
1386
|
+
* @generated from field: string read_token = 5;
|
|
1387
|
+
*/
|
|
1388
|
+
readToken: string;
|
|
1389
|
+
/**
|
|
1390
|
+
* The hot structures the read used — `hnsw`, `splits` — in the REST route's
|
|
1391
|
+
* spelling and in declaration order, and **absent when it used none**. The
|
|
1392
|
+
* same list is the `loams-hot-used` response header, which answers `none`
|
|
1393
|
+
* where this answers nothing at all: the header is always there, this field
|
|
1394
|
+
* is only there when there is something in it.
|
|
1395
|
+
*
|
|
1396
|
+
* @generated from field: repeated string hot_used = 6;
|
|
1397
|
+
*/
|
|
1398
|
+
hotUsed: string[];
|
|
1399
|
+
/**
|
|
1400
|
+
* The design's per-answer `performance` block (§05 §4). Nothing computes it
|
|
1401
|
+
* yet, on either surface, so it is declared here and never answered: the
|
|
1402
|
+
* field names the contract this answer will meet rather than reporting one
|
|
1403
|
+
* this build does not measure. A REST answer has no such key today, and
|
|
1404
|
+
* adding it to one surface only is exactly what this package's equality test
|
|
1405
|
+
* exists to prevent.
|
|
1406
|
+
*
|
|
1407
|
+
* @generated from field: google.protobuf.Struct performance = 7;
|
|
1408
|
+
*/
|
|
1409
|
+
performance?: JsonObject | undefined;
|
|
1410
|
+
/**
|
|
1411
|
+
* What the expansion did, when the request expanded (GR1 Task 20).
|
|
1412
|
+
*
|
|
1413
|
+
* @generated from field: loams.collection.v1.ExpandStats expand = 8;
|
|
1414
|
+
*/
|
|
1415
|
+
expand?: ExpandStats | undefined;
|
|
1416
|
+
};
|
|
1417
|
+
/**
|
|
1418
|
+
* Describes the message loams.collection.v1.SearchResponse.
|
|
1419
|
+
* Use `create(SearchResponseSchema)` to create a new message.
|
|
1420
|
+
*/
|
|
1421
|
+
export declare const SearchResponseSchema: GenMessage<SearchResponse>;
|
|
1422
|
+
/**
|
|
1423
|
+
* One hit.
|
|
1424
|
+
*
|
|
1425
|
+
* @generated from message loams.collection.v1.Hit
|
|
1426
|
+
*/
|
|
1427
|
+
export type Hit = Message<"loams.collection.v1.Hit"> & {
|
|
1428
|
+
/**
|
|
1429
|
+
* The document's id, as the `DocumentId` oneof `Document.id` already uses,
|
|
1430
|
+
* for Task 3's reason: a `u64::MAX` id must not come back through a
|
|
1431
|
+
* `double`.
|
|
1432
|
+
*
|
|
1433
|
+
* @generated from field: loams.collection.v1.DocumentId pk = 1;
|
|
1434
|
+
*/
|
|
1435
|
+
pk?: DocumentId | undefined;
|
|
1436
|
+
/**
|
|
1437
|
+
* Absent at zero, which proto3 JSON spells the same way the REST route
|
|
1438
|
+
* writes `0.0`: a filter-only answer scores nothing.
|
|
1439
|
+
*
|
|
1440
|
+
* @generated from field: float score = 2;
|
|
1441
|
+
*/
|
|
1442
|
+
score: number;
|
|
1443
|
+
/**
|
|
1444
|
+
* The values this hit sorts by, in `sort`'s order, so a caller can resume
|
|
1445
|
+
* from it with `search_after`.
|
|
1446
|
+
*
|
|
1447
|
+
* @generated from field: repeated google.protobuf.Value sort_values = 3;
|
|
1448
|
+
*/
|
|
1449
|
+
sortValues: Value[];
|
|
1450
|
+
/**
|
|
1451
|
+
* Absent when the projection leaves the source out, rather than an empty
|
|
1452
|
+
* object: "no source" and "an empty source" are different answers.
|
|
1453
|
+
*
|
|
1454
|
+
* @generated from field: google.protobuf.Struct source = 4;
|
|
1455
|
+
*/
|
|
1456
|
+
source?: JsonObject | undefined;
|
|
1457
|
+
/**
|
|
1458
|
+
* Dense vectors by name, as the REST route's JSON (`[1.0, 0.0, 0.0]`).
|
|
1459
|
+
*
|
|
1460
|
+
* @generated from field: map<string, google.protobuf.Value> vectors = 5;
|
|
1461
|
+
*/
|
|
1462
|
+
vectors: {
|
|
1463
|
+
[key: string]: Value;
|
|
1464
|
+
};
|
|
1465
|
+
/**
|
|
1466
|
+
* Sparse vectors by name, as the REST route's JSON
|
|
1467
|
+
* (`{"indices": [1], "values": [1.0]}`), with `indices` ascending.
|
|
1468
|
+
*
|
|
1469
|
+
* @generated from field: map<string, google.protobuf.Struct> sparse_vectors = 6;
|
|
1470
|
+
*/
|
|
1471
|
+
sparseVectors: {
|
|
1472
|
+
[key: string]: JsonObject;
|
|
1473
|
+
};
|
|
1474
|
+
/**
|
|
1475
|
+
* The fragments per field, when `highlight` asked for them. A `Value`
|
|
1476
|
+
* because it is a list of strings, which proto3 JSON spells as a `Value`'s
|
|
1477
|
+
* list.
|
|
1478
|
+
*
|
|
1479
|
+
* @generated from field: map<string, google.protobuf.Value> highlight = 7;
|
|
1480
|
+
*/
|
|
1481
|
+
highlight: {
|
|
1482
|
+
[key: string]: Value;
|
|
1483
|
+
};
|
|
1484
|
+
/**
|
|
1485
|
+
* The typed field values per name, as the REST route's JSON (Ruling 9).
|
|
1486
|
+
*
|
|
1487
|
+
* @generated from field: map<string, google.protobuf.Value> fields = 8;
|
|
1488
|
+
*/
|
|
1489
|
+
fields: {
|
|
1490
|
+
[key: string]: Value;
|
|
1491
|
+
};
|
|
1492
|
+
/**
|
|
1493
|
+
* The vertices an expansion reached from this hit (`EXPAND_OUTPUT_NESTED`).
|
|
1494
|
+
*
|
|
1495
|
+
* @generated from field: repeated loams.collection.v1.Neighbor neighbors = 9;
|
|
1496
|
+
*/
|
|
1497
|
+
neighbors: Neighbor[];
|
|
1498
|
+
/**
|
|
1499
|
+
* What the hit is in the graph (`EXPAND_OUTPUT_FLAT`).
|
|
1500
|
+
*
|
|
1501
|
+
* @generated from field: loams.collection.v1.GraphHit graph = 10;
|
|
1502
|
+
*/
|
|
1503
|
+
graph?: GraphHit | undefined;
|
|
1504
|
+
};
|
|
1505
|
+
/**
|
|
1506
|
+
* Describes the message loams.collection.v1.Hit.
|
|
1507
|
+
* Use `create(HitSchema)` to create a new message.
|
|
1508
|
+
*/
|
|
1509
|
+
export declare const HitSchema: GenMessage<Hit>;
|
|
1510
|
+
/**
|
|
1511
|
+
* The `expand` stage (design §07 §5.2): the top `seeds` hits seed a walk of
|
|
1512
|
+
* a graph. Zero takes each number's default.
|
|
1513
|
+
*
|
|
1514
|
+
* @generated from message loams.collection.v1.ExpandSpec
|
|
1515
|
+
*/
|
|
1516
|
+
export type ExpandSpec = Message<"loams.collection.v1.ExpandSpec"> & {
|
|
1517
|
+
/**
|
|
1518
|
+
* The graph, in the request's namespace.
|
|
1519
|
+
*
|
|
1520
|
+
* @generated from field: string graph = 1;
|
|
1521
|
+
*/
|
|
1522
|
+
graph: string;
|
|
1523
|
+
/**
|
|
1524
|
+
* The hit's source field holding the seed vertex's key; empty: the hit's id.
|
|
1525
|
+
*
|
|
1526
|
+
* @generated from field: string from_field = 2;
|
|
1527
|
+
*/
|
|
1528
|
+
fromField: string;
|
|
1529
|
+
/**
|
|
1530
|
+
* The seeds' vertex label; empty: any label.
|
|
1531
|
+
*
|
|
1532
|
+
* @generated from field: string seed_label = 3;
|
|
1533
|
+
*/
|
|
1534
|
+
seedLabel: string;
|
|
1535
|
+
/**
|
|
1536
|
+
* How many top hits seed the walk; 0 is 10.
|
|
1537
|
+
*
|
|
1538
|
+
* @generated from field: uint32 seeds = 4;
|
|
1539
|
+
*/
|
|
1540
|
+
seeds: number;
|
|
1541
|
+
/**
|
|
1542
|
+
* 1 or 2; 0 is 1.
|
|
1543
|
+
*
|
|
1544
|
+
* @generated from field: uint32 hops = 5;
|
|
1545
|
+
*/
|
|
1546
|
+
hops: number;
|
|
1547
|
+
/**
|
|
1548
|
+
* Unspecified is out.
|
|
1549
|
+
*
|
|
1550
|
+
* @generated from field: loams.collection.v1.ExpandDirection direction = 6;
|
|
1551
|
+
*/
|
|
1552
|
+
direction: ExpandDirection;
|
|
1553
|
+
/**
|
|
1554
|
+
* Edge types walked; empty walks every type.
|
|
1555
|
+
*
|
|
1556
|
+
* @generated from field: repeated string edge_types = 7;
|
|
1557
|
+
*/
|
|
1558
|
+
edgeTypes: string[];
|
|
1559
|
+
/**
|
|
1560
|
+
* Over the edges' properties (the structured subset of `Query`).
|
|
1561
|
+
*
|
|
1562
|
+
* @generated from field: loams.collection.v1.Query edge_filter = 8;
|
|
1563
|
+
*/
|
|
1564
|
+
edgeFilter?: Query | undefined;
|
|
1565
|
+
/**
|
|
1566
|
+
* Over the reached vertices' properties.
|
|
1567
|
+
*
|
|
1568
|
+
* @generated from field: loams.collection.v1.Query vertex_filter = 9;
|
|
1569
|
+
*/
|
|
1570
|
+
vertexFilter?: Query | undefined;
|
|
1571
|
+
/**
|
|
1572
|
+
* Neighbors per seed; 0 is 50.
|
|
1573
|
+
*
|
|
1574
|
+
* @generated from field: uint32 limit_per_seed = 10;
|
|
1575
|
+
*/
|
|
1576
|
+
limitPerSeed: number;
|
|
1577
|
+
/**
|
|
1578
|
+
* Neighbors in all; 0 is 100.
|
|
1579
|
+
*
|
|
1580
|
+
* @generated from field: uint32 limit = 11;
|
|
1581
|
+
*/
|
|
1582
|
+
limit: number;
|
|
1583
|
+
/**
|
|
1584
|
+
* The neighbors' document fields, as `select` spells a projection; absent
|
|
1585
|
+
* fetches none.
|
|
1586
|
+
*
|
|
1587
|
+
* @generated from field: google.protobuf.Struct select = 12;
|
|
1588
|
+
*/
|
|
1589
|
+
select?: JsonObject | undefined;
|
|
1590
|
+
/**
|
|
1591
|
+
* Unspecified is nested.
|
|
1592
|
+
*
|
|
1593
|
+
* @generated from field: loams.collection.v1.ExpandOutput output = 13;
|
|
1594
|
+
*/
|
|
1595
|
+
output: ExpandOutput;
|
|
1596
|
+
/**
|
|
1597
|
+
* A `loams.graph.v1` consistency token: the walk sees at least its writes.
|
|
1598
|
+
*
|
|
1599
|
+
* @generated from field: string consistency_token = 14;
|
|
1600
|
+
*/
|
|
1601
|
+
consistencyToken: string;
|
|
1602
|
+
};
|
|
1603
|
+
/**
|
|
1604
|
+
* Describes the message loams.collection.v1.ExpandSpec.
|
|
1605
|
+
* Use `create(ExpandSpecSchema)` to create a new message.
|
|
1606
|
+
*/
|
|
1607
|
+
export declare const ExpandSpecSchema: GenMessage<ExpandSpec>;
|
|
1608
|
+
/**
|
|
1609
|
+
* The `rerank` stage (design §07 §5.2).
|
|
1610
|
+
*
|
|
1611
|
+
* @generated from message loams.collection.v1.RerankSpec
|
|
1612
|
+
*/
|
|
1613
|
+
export type RerankSpec = Message<"loams.collection.v1.RerankSpec"> & {
|
|
1614
|
+
/**
|
|
1615
|
+
* @generated from oneof loams.collection.v1.RerankSpec.method
|
|
1616
|
+
*/
|
|
1617
|
+
method: {
|
|
1618
|
+
/**
|
|
1619
|
+
* A neighbor scores the most, over its seeds, of seed score × decay^hop.
|
|
1620
|
+
*
|
|
1621
|
+
* @generated from field: loams.collection.v1.InheritRerank inherit = 1;
|
|
1622
|
+
*/
|
|
1623
|
+
value: InheritRerank;
|
|
1624
|
+
case: "inherit";
|
|
1625
|
+
} | {
|
|
1626
|
+
/**
|
|
1627
|
+
* The cosine similarity of each candidate's vector to a query vector.
|
|
1628
|
+
*
|
|
1629
|
+
* @generated from field: loams.collection.v1.VectorRerank vector = 2;
|
|
1630
|
+
*/
|
|
1631
|
+
value: VectorRerank;
|
|
1632
|
+
case: "vector";
|
|
1633
|
+
} | {
|
|
1634
|
+
/**
|
|
1635
|
+
* An external reranker: off on every server (§05 §4), always refused.
|
|
1636
|
+
*
|
|
1637
|
+
* @generated from field: loams.collection.v1.ModelRerank model = 3;
|
|
1638
|
+
*/
|
|
1639
|
+
value: ModelRerank;
|
|
1640
|
+
case: "model";
|
|
1641
|
+
} | {
|
|
1642
|
+
case: undefined;
|
|
1643
|
+
value?: undefined;
|
|
1644
|
+
};
|
|
1645
|
+
};
|
|
1646
|
+
/**
|
|
1647
|
+
* Describes the message loams.collection.v1.RerankSpec.
|
|
1648
|
+
* Use `create(RerankSpecSchema)` to create a new message.
|
|
1649
|
+
*/
|
|
1650
|
+
export declare const RerankSpecSchema: GenMessage<RerankSpec>;
|
|
1651
|
+
/**
|
|
1652
|
+
* See `RerankSpec.inherit`.
|
|
1653
|
+
*
|
|
1654
|
+
* @generated from message loams.collection.v1.InheritRerank
|
|
1655
|
+
*/
|
|
1656
|
+
export type InheritRerank = Message<"loams.collection.v1.InheritRerank"> & {
|
|
1657
|
+
/**
|
|
1658
|
+
* 0 to 1; absent is 0.5.
|
|
1659
|
+
*
|
|
1660
|
+
* @generated from field: optional float decay = 1;
|
|
1661
|
+
*/
|
|
1662
|
+
decay?: number | undefined;
|
|
1663
|
+
};
|
|
1664
|
+
/**
|
|
1665
|
+
* Describes the message loams.collection.v1.InheritRerank.
|
|
1666
|
+
* Use `create(InheritRerankSchema)` to create a new message.
|
|
1667
|
+
*/
|
|
1668
|
+
export declare const InheritRerankSchema: GenMessage<InheritRerank>;
|
|
1669
|
+
/**
|
|
1670
|
+
* See `RerankSpec.vector`.
|
|
1671
|
+
*
|
|
1672
|
+
* @generated from message loams.collection.v1.VectorRerank
|
|
1673
|
+
*/
|
|
1674
|
+
export type VectorRerank = Message<"loams.collection.v1.VectorRerank"> & {
|
|
1675
|
+
/**
|
|
1676
|
+
* A dense vector field of the candidates' collections.
|
|
1677
|
+
*
|
|
1678
|
+
* @generated from field: string field = 1;
|
|
1679
|
+
*/
|
|
1680
|
+
field: string;
|
|
1681
|
+
/**
|
|
1682
|
+
* @generated from field: repeated float query = 2;
|
|
1683
|
+
*/
|
|
1684
|
+
query: number[];
|
|
1685
|
+
};
|
|
1686
|
+
/**
|
|
1687
|
+
* Describes the message loams.collection.v1.VectorRerank.
|
|
1688
|
+
* Use `create(VectorRerankSchema)` to create a new message.
|
|
1689
|
+
*/
|
|
1690
|
+
export declare const VectorRerankSchema: GenMessage<VectorRerank>;
|
|
1691
|
+
/**
|
|
1692
|
+
* See `RerankSpec.model`.
|
|
1693
|
+
*
|
|
1694
|
+
* @generated from message loams.collection.v1.ModelRerank
|
|
1695
|
+
*/
|
|
1696
|
+
export type ModelRerank = Message<"loams.collection.v1.ModelRerank"> & {
|
|
1697
|
+
/**
|
|
1698
|
+
* @generated from field: string endpoint = 1;
|
|
1699
|
+
*/
|
|
1700
|
+
endpoint: string;
|
|
1701
|
+
/**
|
|
1702
|
+
* @generated from field: string text_field = 2;
|
|
1703
|
+
*/
|
|
1704
|
+
textField: string;
|
|
1705
|
+
/**
|
|
1706
|
+
* @generated from field: string query = 3;
|
|
1707
|
+
*/
|
|
1708
|
+
query: string;
|
|
1709
|
+
/**
|
|
1710
|
+
* @generated from field: uint32 top_n = 4;
|
|
1711
|
+
*/
|
|
1712
|
+
topN: number;
|
|
1713
|
+
};
|
|
1714
|
+
/**
|
|
1715
|
+
* Describes the message loams.collection.v1.ModelRerank.
|
|
1716
|
+
* Use `create(ModelRerankSchema)` to create a new message.
|
|
1717
|
+
*/
|
|
1718
|
+
export declare const ModelRerankSchema: GenMessage<ModelRerank>;
|
|
1719
|
+
/**
|
|
1720
|
+
* A vertex an expansion reached.
|
|
1721
|
+
*
|
|
1722
|
+
* @generated from message loams.collection.v1.Neighbor
|
|
1723
|
+
*/
|
|
1724
|
+
export type Neighbor = Message<"loams.collection.v1.Neighbor"> & {
|
|
1725
|
+
/**
|
|
1726
|
+
* @generated from field: string label = 1;
|
|
1727
|
+
*/
|
|
1728
|
+
label: string;
|
|
1729
|
+
/**
|
|
1730
|
+
* Its key: its document's id when a link wrote it.
|
|
1731
|
+
*
|
|
1732
|
+
* @generated from field: loams.collection.v1.DocumentId key = 2;
|
|
1733
|
+
*/
|
|
1734
|
+
key?: DocumentId | undefined;
|
|
1735
|
+
/**
|
|
1736
|
+
* @generated from field: uint32 hop = 3;
|
|
1737
|
+
*/
|
|
1738
|
+
hop: number;
|
|
1739
|
+
/**
|
|
1740
|
+
* The vertex it was reached from: the seed for hop 1.
|
|
1741
|
+
*
|
|
1742
|
+
* @generated from field: loams.collection.v1.DocumentId via = 4;
|
|
1743
|
+
*/
|
|
1744
|
+
via?: DocumentId | undefined;
|
|
1745
|
+
/**
|
|
1746
|
+
* @generated from field: string edge_type = 5;
|
|
1747
|
+
*/
|
|
1748
|
+
edgeType: string;
|
|
1749
|
+
/**
|
|
1750
|
+
* The edge's key (its document's id).
|
|
1751
|
+
*
|
|
1752
|
+
* @generated from field: loams.collection.v1.DocumentId edge = 6;
|
|
1753
|
+
*/
|
|
1754
|
+
edge?: DocumentId | undefined;
|
|
1755
|
+
/**
|
|
1756
|
+
* @generated from field: float score = 7;
|
|
1757
|
+
*/
|
|
1758
|
+
score: number;
|
|
1759
|
+
/**
|
|
1760
|
+
* The vertex's collection, when a collection link wrote it.
|
|
1761
|
+
*
|
|
1762
|
+
* @generated from field: string collection = 8;
|
|
1763
|
+
*/
|
|
1764
|
+
collection: string;
|
|
1765
|
+
/**
|
|
1766
|
+
* Its document, when `ExpandSpec.select` asked for one.
|
|
1767
|
+
*
|
|
1768
|
+
* @generated from field: google.protobuf.Struct source = 9;
|
|
1769
|
+
*/
|
|
1770
|
+
source?: JsonObject | undefined;
|
|
1771
|
+
};
|
|
1772
|
+
/**
|
|
1773
|
+
* Describes the message loams.collection.v1.Neighbor.
|
|
1774
|
+
* Use `create(NeighborSchema)` to create a new message.
|
|
1775
|
+
*/
|
|
1776
|
+
export declare const NeighborSchema: GenMessage<Neighbor>;
|
|
1777
|
+
/**
|
|
1778
|
+
* What a flat answer's hit is in the graph.
|
|
1779
|
+
*
|
|
1780
|
+
* @generated from message loams.collection.v1.GraphHit
|
|
1781
|
+
*/
|
|
1782
|
+
export type GraphHit = Message<"loams.collection.v1.GraphHit"> & {
|
|
1783
|
+
/**
|
|
1784
|
+
* @generated from field: string label = 1;
|
|
1785
|
+
*/
|
|
1786
|
+
label: string;
|
|
1787
|
+
/**
|
|
1788
|
+
* 0 for a seed.
|
|
1789
|
+
*
|
|
1790
|
+
* @generated from field: uint32 hop = 2;
|
|
1791
|
+
*/
|
|
1792
|
+
hop: number;
|
|
1793
|
+
/**
|
|
1794
|
+
* The seeds it was reached from.
|
|
1795
|
+
*
|
|
1796
|
+
* @generated from field: repeated loams.collection.v1.DocumentId seeds = 3;
|
|
1797
|
+
*/
|
|
1798
|
+
seeds: DocumentId[];
|
|
1799
|
+
/**
|
|
1800
|
+
* @generated from field: string collection = 4;
|
|
1801
|
+
*/
|
|
1802
|
+
collection: string;
|
|
1803
|
+
};
|
|
1804
|
+
/**
|
|
1805
|
+
* Describes the message loams.collection.v1.GraphHit.
|
|
1806
|
+
* Use `create(GraphHitSchema)` to create a new message.
|
|
1807
|
+
*/
|
|
1808
|
+
export declare const GraphHitSchema: GenMessage<GraphHit>;
|
|
1809
|
+
/**
|
|
1810
|
+
* What an expansion did.
|
|
1811
|
+
*
|
|
1812
|
+
* @generated from message loams.collection.v1.ExpandStats
|
|
1813
|
+
*/
|
|
1814
|
+
export type ExpandStats = Message<"loams.collection.v1.ExpandStats"> & {
|
|
1815
|
+
/**
|
|
1816
|
+
* @generated from field: uint64 seeds = 1;
|
|
1817
|
+
*/
|
|
1818
|
+
seeds: bigint;
|
|
1819
|
+
/**
|
|
1820
|
+
* Seeds with no key or no vertex.
|
|
1821
|
+
*
|
|
1822
|
+
* @generated from field: uint64 seeds_skipped = 2;
|
|
1823
|
+
*/
|
|
1824
|
+
seedsSkipped: bigint;
|
|
1825
|
+
/**
|
|
1826
|
+
* @generated from field: uint64 neighbors = 3;
|
|
1827
|
+
*/
|
|
1828
|
+
neighbors: bigint;
|
|
1829
|
+
/**
|
|
1830
|
+
* The graph state the walk read.
|
|
1831
|
+
*
|
|
1832
|
+
* @generated from field: string graph_token = 4;
|
|
1833
|
+
*/
|
|
1834
|
+
graphToken: string;
|
|
1835
|
+
};
|
|
1836
|
+
/**
|
|
1837
|
+
* Describes the message loams.collection.v1.ExpandStats.
|
|
1838
|
+
* Use `create(ExpandStatsSchema)` to create a new message.
|
|
1839
|
+
*/
|
|
1840
|
+
export declare const ExpandStatsSchema: GenMessage<ExpandStats>;
|
|
1841
|
+
/**
|
|
1842
|
+
* One group of a grouped search.
|
|
1843
|
+
*
|
|
1844
|
+
* @generated from message loams.collection.v1.HitGroup
|
|
1845
|
+
*/
|
|
1846
|
+
export type HitGroup = Message<"loams.collection.v1.HitGroup"> & {
|
|
1847
|
+
/**
|
|
1848
|
+
* The field value the group is, in the IR's own JSON.
|
|
1849
|
+
*
|
|
1850
|
+
* @generated from field: google.protobuf.Value key = 1;
|
|
1851
|
+
*/
|
|
1852
|
+
key?: Value | undefined;
|
|
1853
|
+
/**
|
|
1854
|
+
* @generated from field: repeated loams.collection.v1.Hit hits = 2;
|
|
1855
|
+
*/
|
|
1856
|
+
hits: Hit[];
|
|
1857
|
+
};
|
|
1858
|
+
/**
|
|
1859
|
+
* Describes the message loams.collection.v1.HitGroup.
|
|
1860
|
+
* Use `create(HitGroupSchema)` to create a new message.
|
|
1861
|
+
*/
|
|
1862
|
+
export declare const HitGroupSchema: GenMessage<HitGroup>;
|
|
1863
|
+
/**
|
|
1864
|
+
* How many documents matched, and whether the count is exact.
|
|
1865
|
+
*
|
|
1866
|
+
* @generated from message loams.collection.v1.TotalHits
|
|
1867
|
+
*/
|
|
1868
|
+
export type TotalHits = Message<"loams.collection.v1.TotalHits"> & {
|
|
1869
|
+
/**
|
|
1870
|
+
* The count. `optional` and always set: a count of zero is a count, and
|
|
1871
|
+
* proto3 JSON omitting it would read as "unanswered".
|
|
1872
|
+
*
|
|
1873
|
+
* @generated from field: optional uint64 value = 1;
|
|
1874
|
+
*/
|
|
1875
|
+
value?: bigint | undefined;
|
|
1876
|
+
/**
|
|
1877
|
+
* `TOTAL_RELATION_EQ` when `value` is the whole count and
|
|
1878
|
+
* `TOTAL_RELATION_GTE` when it is a floor (`track_total_hits` capped at
|
|
1879
|
+
* `up_to`).
|
|
1880
|
+
*
|
|
1881
|
+
* @generated from field: loams.collection.v1.TotalRelation relation = 2;
|
|
1882
|
+
*/
|
|
1883
|
+
relation: TotalRelation;
|
|
1884
|
+
};
|
|
1885
|
+
/**
|
|
1886
|
+
* Describes the message loams.collection.v1.TotalHits.
|
|
1887
|
+
* Use `create(TotalHitsSchema)` to create a new message.
|
|
1888
|
+
*/
|
|
1889
|
+
export declare const TotalHitsSchema: GenMessage<TotalHits>;
|
|
1890
|
+
/**
|
|
1891
|
+
* `or` / `and`, as the IR spells them.
|
|
1892
|
+
*
|
|
1893
|
+
* Declared for the two fields whose operator the IR spells differently from the
|
|
1894
|
+
* fields above: `MultiMatchQuery.operator` and
|
|
1895
|
+
* `QueryStringQuery.default_operator`, which keep this enum and therefore
|
|
1896
|
+
* answer (and are sent) `BOOL_OPERATOR_OR` / `BOOL_OPERATOR_AND`.
|
|
1897
|
+
*
|
|
1898
|
+
* @generated from enum loams.collection.v1.BoolOperator
|
|
1899
|
+
*/
|
|
1900
|
+
export declare enum BoolOperator {
|
|
1901
|
+
/**
|
|
1902
|
+
* `or`, which is the IR's default for every operator that defaults.
|
|
1903
|
+
*
|
|
1904
|
+
* @generated from enum value: BOOL_OPERATOR_UNSPECIFIED = 0;
|
|
1905
|
+
*/
|
|
1906
|
+
UNSPECIFIED = 0,
|
|
1907
|
+
/**
|
|
1908
|
+
* @generated from enum value: BOOL_OPERATOR_OR = 1;
|
|
1909
|
+
*/
|
|
1910
|
+
OR = 1,
|
|
1911
|
+
/**
|
|
1912
|
+
* @generated from enum value: BOOL_OPERATOR_AND = 2;
|
|
1913
|
+
*/
|
|
1914
|
+
AND = 2
|
|
1915
|
+
}
|
|
1916
|
+
/**
|
|
1917
|
+
* Describes the enum loams.collection.v1.BoolOperator.
|
|
1918
|
+
*/
|
|
1919
|
+
export declare const BoolOperatorSchema: GenEnum<BoolOperator>;
|
|
1920
|
+
/**
|
|
1921
|
+
* @generated from enum loams.collection.v1.MultiMatchKind
|
|
1922
|
+
*/
|
|
1923
|
+
export declare enum MultiMatchKind {
|
|
1924
|
+
/**
|
|
1925
|
+
* `best_fields`, the IR's default.
|
|
1926
|
+
*
|
|
1927
|
+
* @generated from enum value: MULTI_MATCH_KIND_UNSPECIFIED = 0;
|
|
1928
|
+
*/
|
|
1929
|
+
UNSPECIFIED = 0,
|
|
1930
|
+
/**
|
|
1931
|
+
* @generated from enum value: MULTI_MATCH_KIND_BEST_FIELDS = 1;
|
|
1932
|
+
*/
|
|
1933
|
+
BEST_FIELDS = 1,
|
|
1934
|
+
/**
|
|
1935
|
+
* @generated from enum value: MULTI_MATCH_KIND_MOST_FIELDS = 2;
|
|
1936
|
+
*/
|
|
1937
|
+
MOST_FIELDS = 2,
|
|
1938
|
+
/**
|
|
1939
|
+
* @generated from enum value: MULTI_MATCH_KIND_CROSS_FIELDS = 3;
|
|
1940
|
+
*/
|
|
1941
|
+
CROSS_FIELDS = 3,
|
|
1942
|
+
/**
|
|
1943
|
+
* @generated from enum value: MULTI_MATCH_KIND_PHRASE = 4;
|
|
1944
|
+
*/
|
|
1945
|
+
PHRASE = 4,
|
|
1946
|
+
/**
|
|
1947
|
+
* @generated from enum value: MULTI_MATCH_KIND_PHRASE_PREFIX = 5;
|
|
1948
|
+
*/
|
|
1949
|
+
PHRASE_PREFIX = 5
|
|
1950
|
+
}
|
|
1951
|
+
/**
|
|
1952
|
+
* Describes the enum loams.collection.v1.MultiMatchKind.
|
|
1953
|
+
*/
|
|
1954
|
+
export declare const MultiMatchKindSchema: GenEnum<MultiMatchKind>;
|
|
1955
|
+
/**
|
|
1956
|
+
* @generated from enum loams.collection.v1.SortOrder
|
|
1957
|
+
*/
|
|
1958
|
+
export declare enum SortOrder {
|
|
1959
|
+
/**
|
|
1960
|
+
* Ascending for a key and a field, descending for a score; each is the IR's
|
|
1961
|
+
* default for that key.
|
|
1962
|
+
*
|
|
1963
|
+
* @generated from enum value: SORT_ORDER_UNSPECIFIED = 0;
|
|
1964
|
+
*/
|
|
1965
|
+
UNSPECIFIED = 0,
|
|
1966
|
+
/**
|
|
1967
|
+
* @generated from enum value: SORT_ORDER_ASC = 1;
|
|
1968
|
+
*/
|
|
1969
|
+
ASC = 1,
|
|
1970
|
+
/**
|
|
1971
|
+
* @generated from enum value: SORT_ORDER_DESC = 2;
|
|
1972
|
+
*/
|
|
1973
|
+
DESC = 2
|
|
1974
|
+
}
|
|
1975
|
+
/**
|
|
1976
|
+
* Describes the enum loams.collection.v1.SortOrder.
|
|
1977
|
+
*/
|
|
1978
|
+
export declare const SortOrderSchema: GenEnum<SortOrder>;
|
|
1979
|
+
/**
|
|
1980
|
+
* @generated from enum loams.collection.v1.MissingOrder
|
|
1981
|
+
*/
|
|
1982
|
+
export declare enum MissingOrder {
|
|
1983
|
+
/**
|
|
1984
|
+
* Last, which is the IR's default.
|
|
1985
|
+
*
|
|
1986
|
+
* @generated from enum value: MISSING_ORDER_UNSPECIFIED = 0;
|
|
1987
|
+
*/
|
|
1988
|
+
UNSPECIFIED = 0,
|
|
1989
|
+
/**
|
|
1990
|
+
* @generated from enum value: MISSING_ORDER_FIRST = 1;
|
|
1991
|
+
*/
|
|
1992
|
+
FIRST = 1,
|
|
1993
|
+
/**
|
|
1994
|
+
* @generated from enum value: MISSING_ORDER_LAST = 2;
|
|
1995
|
+
*/
|
|
1996
|
+
LAST = 2
|
|
1997
|
+
}
|
|
1998
|
+
/**
|
|
1999
|
+
* Describes the enum loams.collection.v1.MissingOrder.
|
|
2000
|
+
*/
|
|
2001
|
+
export declare const MissingOrderSchema: GenEnum<MissingOrder>;
|
|
2002
|
+
/**
|
|
2003
|
+
* Which way an expansion walks the edges.
|
|
2004
|
+
*
|
|
2005
|
+
* @generated from enum loams.collection.v1.ExpandDirection
|
|
2006
|
+
*/
|
|
2007
|
+
export declare enum ExpandDirection {
|
|
2008
|
+
/**
|
|
2009
|
+
* @generated from enum value: EXPAND_DIRECTION_UNSPECIFIED = 0;
|
|
2010
|
+
*/
|
|
2011
|
+
UNSPECIFIED = 0,
|
|
2012
|
+
/**
|
|
2013
|
+
* @generated from enum value: EXPAND_DIRECTION_OUT = 1;
|
|
2014
|
+
*/
|
|
2015
|
+
OUT = 1,
|
|
2016
|
+
/**
|
|
2017
|
+
* @generated from enum value: EXPAND_DIRECTION_IN = 2;
|
|
2018
|
+
*/
|
|
2019
|
+
IN = 2,
|
|
2020
|
+
/**
|
|
2021
|
+
* @generated from enum value: EXPAND_DIRECTION_BOTH = 3;
|
|
2022
|
+
*/
|
|
2023
|
+
BOTH = 3
|
|
2024
|
+
}
|
|
2025
|
+
/**
|
|
2026
|
+
* Describes the enum loams.collection.v1.ExpandDirection.
|
|
2027
|
+
*/
|
|
2028
|
+
export declare const ExpandDirectionSchema: GenEnum<ExpandDirection>;
|
|
2029
|
+
/**
|
|
2030
|
+
* How the neighbors come back.
|
|
2031
|
+
*
|
|
2032
|
+
* @generated from enum loams.collection.v1.ExpandOutput
|
|
2033
|
+
*/
|
|
2034
|
+
export declare enum ExpandOutput {
|
|
2035
|
+
/**
|
|
2036
|
+
* @generated from enum value: EXPAND_OUTPUT_UNSPECIFIED = 0;
|
|
2037
|
+
*/
|
|
2038
|
+
UNSPECIFIED = 0,
|
|
2039
|
+
/**
|
|
2040
|
+
* Under each seed hit, in `Hit.neighbors`.
|
|
2041
|
+
*
|
|
2042
|
+
* @generated from enum value: EXPAND_OUTPUT_NESTED = 1;
|
|
2043
|
+
*/
|
|
2044
|
+
NESTED = 1,
|
|
2045
|
+
/**
|
|
2046
|
+
* Seeds and neighbors in one ranked list, each neighbor a hit with
|
|
2047
|
+
* `Hit.graph`.
|
|
2048
|
+
*
|
|
2049
|
+
* @generated from enum value: EXPAND_OUTPUT_FLAT = 2;
|
|
2050
|
+
*/
|
|
2051
|
+
FLAT = 2
|
|
2052
|
+
}
|
|
2053
|
+
/**
|
|
2054
|
+
* Describes the enum loams.collection.v1.ExpandOutput.
|
|
2055
|
+
*/
|
|
2056
|
+
export declare const ExpandOutputSchema: GenEnum<ExpandOutput>;
|
|
2057
|
+
/**
|
|
2058
|
+
* @generated from enum loams.collection.v1.TotalRelation
|
|
2059
|
+
*/
|
|
2060
|
+
export declare enum TotalRelation {
|
|
2061
|
+
/**
|
|
2062
|
+
* @generated from enum value: TOTAL_RELATION_UNSPECIFIED = 0;
|
|
2063
|
+
*/
|
|
2064
|
+
UNSPECIFIED = 0,
|
|
2065
|
+
/**
|
|
2066
|
+
* `eq`: the count is exact.
|
|
2067
|
+
*
|
|
2068
|
+
* @generated from enum value: TOTAL_RELATION_EQ = 1;
|
|
2069
|
+
*/
|
|
2070
|
+
EQ = 1,
|
|
2071
|
+
/**
|
|
2072
|
+
* `gte`: at least this many matched.
|
|
2073
|
+
*
|
|
2074
|
+
* @generated from enum value: TOTAL_RELATION_GTE = 2;
|
|
2075
|
+
*/
|
|
2076
|
+
GTE = 2
|
|
2077
|
+
}
|
|
2078
|
+
/**
|
|
2079
|
+
* Describes the enum loams.collection.v1.TotalRelation.
|
|
2080
|
+
*/
|
|
2081
|
+
export declare const TotalRelationSchema: GenEnum<TotalRelation>;
|
|
2082
|
+
/**
|
|
2083
|
+
* @generated from service loams.collection.v1.QueryService
|
|
2084
|
+
*/
|
|
2085
|
+
export declare const QueryService: GenService<{
|
|
2086
|
+
/**
|
|
2087
|
+
* One search over one collection. The whole IR is this request: the
|
|
2088
|
+
* retrievers to run, how to fuse them, the filter, the sort and the window.
|
|
2089
|
+
*
|
|
2090
|
+
* It is `NO_SIDE_EFFECTS` — it reads and counts — so an SDK may retry it
|
|
2091
|
+
* after a lost answer. It is still a `POST`, because a search is not free and
|
|
2092
|
+
* the request is a body.
|
|
2093
|
+
*
|
|
2094
|
+
* @generated from rpc loams.collection.v1.QueryService.Search
|
|
2095
|
+
*/
|
|
2096
|
+
search: {
|
|
2097
|
+
methodKind: "unary";
|
|
2098
|
+
input: typeof SearchRequestSchema;
|
|
2099
|
+
output: typeof SearchResponseSchema;
|
|
2100
|
+
};
|
|
2101
|
+
}>;
|