@mixedbread/sdk 0.29.0 → 0.30.0

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.
Files changed (31) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/bin/cli +4 -10
  3. package/package.json +1 -1
  4. package/resources/data-sources/connectors.d.mts +4 -4
  5. package/resources/data-sources/connectors.d.mts.map +1 -1
  6. package/resources/data-sources/connectors.d.ts +4 -4
  7. package/resources/data-sources/connectors.d.ts.map +1 -1
  8. package/resources/vector-stores/files.d.mts +313 -264
  9. package/resources/vector-stores/files.d.mts.map +1 -1
  10. package/resources/vector-stores/files.d.ts +313 -264
  11. package/resources/vector-stores/files.d.ts.map +1 -1
  12. package/resources/vector-stores/files.js +10 -35
  13. package/resources/vector-stores/files.js.map +1 -1
  14. package/resources/vector-stores/files.mjs +10 -35
  15. package/resources/vector-stores/files.mjs.map +1 -1
  16. package/resources/vector-stores/vector-stores.d.mts +593 -275
  17. package/resources/vector-stores/vector-stores.d.mts.map +1 -1
  18. package/resources/vector-stores/vector-stores.d.ts +593 -275
  19. package/resources/vector-stores/vector-stores.d.ts.map +1 -1
  20. package/resources/vector-stores/vector-stores.js +15 -41
  21. package/resources/vector-stores/vector-stores.js.map +1 -1
  22. package/resources/vector-stores/vector-stores.mjs +15 -41
  23. package/resources/vector-stores/vector-stores.mjs.map +1 -1
  24. package/src/resources/data-sources/connectors.ts +4 -4
  25. package/src/resources/vector-stores/files.ts +356 -439
  26. package/src/resources/vector-stores/vector-stores.ts +693 -453
  27. package/src/version.ts +1 -1
  28. package/version.d.mts +1 -1
  29. package/version.d.ts +1 -1
  30. package/version.js +1 -1
  31. package/version.mjs +1 -1
@@ -27,36 +27,27 @@ export class VectorStores extends APIResource {
27
27
  files: FilesAPI.Files = new FilesAPI.Files(this._client);
28
28
 
29
29
  /**
30
- * Create a new vector store.
30
+ * DEPRECATED: Use POST /stores instead
31
31
  *
32
- * Args: vector_store_create: VectorStoreCreate object containing the name,
33
- * description, and metadata.
34
- *
35
- * Returns: VectorStore: The response containing the created vector store details.
32
+ * @deprecated
36
33
  */
37
34
  create(body: VectorStoreCreateParams, options?: RequestOptions): APIPromise<VectorStore> {
38
35
  return this._client.post('/v1/vector_stores', { body, ...options });
39
36
  }
40
37
 
41
38
  /**
42
- * Get a vector store by ID or name.
43
- *
44
- * Args: vector_store_identifier: The ID or name of the vector store to retrieve.
39
+ * DEPRECATED: Use GET /stores/{store_identifier} instead
45
40
  *
46
- * Returns: VectorStore: The response containing the vector store details.
41
+ * @deprecated
47
42
  */
48
43
  retrieve(vectorStoreIdentifier: string, options?: RequestOptions): APIPromise<VectorStore> {
49
44
  return this._client.get(path`/v1/vector_stores/${vectorStoreIdentifier}`, options);
50
45
  }
51
46
 
52
47
  /**
53
- * Update a vector store by ID or name.
48
+ * DEPRECATED: Use PUT /stores/{store_identifier} instead
54
49
  *
55
- * Args: vector_store_identifier: The ID or name of the vector store to update.
56
- * vector_store_update: VectorStoreCreate object containing the name, description,
57
- * and metadata.
58
- *
59
- * Returns: VectorStore: The response containing the updated vector store details.
50
+ * @deprecated
60
51
  */
61
52
  update(
62
53
  vectorStoreIdentifier: string,
@@ -67,12 +58,9 @@ export class VectorStores extends APIResource {
67
58
  }
68
59
 
69
60
  /**
70
- * List all vector stores with optional search.
71
- *
72
- * Args: options: The pagination options including limit, cursor, and optional
73
- * search query (q)
61
+ * DEPRECATED: Use GET /stores instead
74
62
  *
75
- * Returns: VectorStoreListResponse: The list of vector stores
63
+ * @deprecated
76
64
  */
77
65
  list(
78
66
  query: VectorStoreListParams | null | undefined = {},
@@ -82,18 +70,18 @@ export class VectorStores extends APIResource {
82
70
  }
83
71
 
84
72
  /**
85
- * Delete a vector store by ID or name.
73
+ * DEPRECATED: Use DELETE /stores/{store_identifier} instead
86
74
  *
87
- * Args: vector_store_identifier: The ID or name of the vector store to delete.
88
- *
89
- * Returns: VectorStore: The response containing the deleted vector store details.
75
+ * @deprecated
90
76
  */
91
77
  delete(vectorStoreIdentifier: string, options?: RequestOptions): APIPromise<VectorStoreDeleteResponse> {
92
78
  return this._client.delete(path`/v1/vector_stores/${vectorStoreIdentifier}`, options);
93
79
  }
94
80
 
95
81
  /**
96
- * Question answering
82
+ * DEPRECATED: Use POST /stores/question-answering instead
83
+ *
84
+ * @deprecated
97
85
  */
98
86
  questionAnswering(
99
87
  body: VectorStoreQuestionAnsweringParams,
@@ -103,23 +91,9 @@ export class VectorStores extends APIResource {
103
91
  }
104
92
 
105
93
  /**
106
- * Perform semantic search across vector store chunks.
107
- *
108
- * This endpoint searches through vector store chunks using semantic similarity
109
- * matching. It supports complex search queries with filters and returns
110
- * relevance-scored results.
111
- *
112
- * Args: search_params: Search configuration including: - query text or
113
- * embeddings - vector_store_ids: List of vector stores to search - file_ids:
114
- * Optional list of file IDs to filter chunks by (or tuple of list and condition
115
- * operator) - metadata filters - pagination parameters - sorting preferences
116
- * \_state: API state dependency \_ctx: Service context dependency
94
+ * DEPRECATED: Use POST /stores/search instead
117
95
  *
118
- * Returns: VectorStoreSearchChunkResponse containing: - List of matched chunks
119
- * with relevance scores - Pagination details including total result count
120
- *
121
- * Raises: HTTPException (400): If search parameters are invalid HTTPException
122
- * (404): If no vector stores are found to search
96
+ * @deprecated
123
97
  */
124
98
  search(body: VectorStoreSearchParams, options?: RequestOptions): APIPromise<VectorStoreSearchResponse> {
125
99
  return this._client.post('/v1/vector_stores/search', { body, ...options });
@@ -129,7 +103,7 @@ export class VectorStores extends APIResource {
129
103
  export type VectorStoresCursor = Cursor<VectorStore>;
130
104
 
131
105
  /**
132
- * Represents an expiration policy for a vector store.
106
+ * Represents an expiration policy for a store.
133
107
  */
134
108
  export interface ExpiresAfter {
135
109
  /**
@@ -138,7 +112,7 @@ export interface ExpiresAfter {
138
112
  anchor?: 'last_active_at';
139
113
 
140
114
  /**
141
- * Number of days after which the vector store expires
115
+ * Number of days after which the store expires
142
116
  */
143
117
  days?: number;
144
118
  }
@@ -157,13 +131,7 @@ export interface ScoredAudioURLInputChunk {
157
131
  /**
158
132
  * metadata of the chunk
159
133
  */
160
- generated_metadata?:
161
- | ScoredAudioURLInputChunk.MarkdownChunkGeneratedMetadata
162
- | ScoredAudioURLInputChunk.TextChunkGeneratedMetadata
163
- | ScoredAudioURLInputChunk.PdfChunkGeneratedMetadata
164
- | ScoredAudioURLInputChunk.CodeChunkGeneratedMetadata
165
- | ScoredAudioURLInputChunk.AudioChunkGeneratedMetadata
166
- | null;
134
+ generated_metadata?: { [key: string]: unknown } | null;
167
135
 
168
136
  /**
169
137
  * model used for this chunk
@@ -186,9 +154,9 @@ export interface ScoredAudioURLInputChunk {
186
154
  filename: string;
187
155
 
188
156
  /**
189
- * vector store id
157
+ * store id
190
158
  */
191
- vector_store_id: string;
159
+ store_id: string;
192
160
 
193
161
  /**
194
162
  * file metadata
@@ -222,96 +190,6 @@ export interface ScoredAudioURLInputChunk {
222
190
  }
223
191
 
224
192
  export namespace ScoredAudioURLInputChunk {
225
- export interface MarkdownChunkGeneratedMetadata {
226
- type?: 'markdown';
227
-
228
- file_type?: 'text/markdown';
229
-
230
- language: string;
231
-
232
- word_count: number;
233
-
234
- file_size: number;
235
-
236
- chunk_headings?: Array<MarkdownChunkGeneratedMetadata.ChunkHeading>;
237
-
238
- heading_context?: Array<MarkdownChunkGeneratedMetadata.HeadingContext>;
239
-
240
- [k: string]: unknown;
241
- }
242
-
243
- export namespace MarkdownChunkGeneratedMetadata {
244
- export interface ChunkHeading {
245
- level: number;
246
-
247
- text: string;
248
- }
249
-
250
- export interface HeadingContext {
251
- level: number;
252
-
253
- text: string;
254
- }
255
- }
256
-
257
- export interface TextChunkGeneratedMetadata {
258
- type?: 'text';
259
-
260
- file_type?: 'text/plain';
261
-
262
- language: string;
263
-
264
- word_count: number;
265
-
266
- file_size: number;
267
-
268
- [k: string]: unknown;
269
- }
270
-
271
- export interface PdfChunkGeneratedMetadata {
272
- type?: 'pdf';
273
-
274
- file_type?: 'application/pdf';
275
-
276
- total_pages: number;
277
-
278
- total_size: number;
279
-
280
- [k: string]: unknown;
281
- }
282
-
283
- export interface CodeChunkGeneratedMetadata {
284
- type?: 'code';
285
-
286
- file_type: string;
287
-
288
- language: string;
289
-
290
- word_count: number;
291
-
292
- file_size: number;
293
-
294
- [k: string]: unknown;
295
- }
296
-
297
- export interface AudioChunkGeneratedMetadata {
298
- type?: 'audio';
299
-
300
- file_type: string;
301
-
302
- file_size: number;
303
-
304
- total_duration_seconds: number;
305
-
306
- sample_rate: number;
307
-
308
- channels: number;
309
-
310
- audio_format: number;
311
-
312
- [k: string]: unknown;
313
- }
314
-
315
193
  /**
316
194
  * The audio input specification.
317
195
  */
@@ -337,13 +215,7 @@ export interface ScoredImageURLInputChunk {
337
215
  /**
338
216
  * metadata of the chunk
339
217
  */
340
- generated_metadata?:
341
- | ScoredImageURLInputChunk.MarkdownChunkGeneratedMetadata
342
- | ScoredImageURLInputChunk.TextChunkGeneratedMetadata
343
- | ScoredImageURLInputChunk.PdfChunkGeneratedMetadata
344
- | ScoredImageURLInputChunk.CodeChunkGeneratedMetadata
345
- | ScoredImageURLInputChunk.AudioChunkGeneratedMetadata
346
- | null;
218
+ generated_metadata?: { [key: string]: unknown } | null;
347
219
 
348
220
  /**
349
221
  * model used for this chunk
@@ -366,9 +238,9 @@ export interface ScoredImageURLInputChunk {
366
238
  filename: string;
367
239
 
368
240
  /**
369
- * vector store id
241
+ * store id
370
242
  */
371
- vector_store_id: string;
243
+ store_id: string;
372
244
 
373
245
  /**
374
246
  * file metadata
@@ -397,96 +269,6 @@ export interface ScoredImageURLInputChunk {
397
269
  }
398
270
 
399
271
  export namespace ScoredImageURLInputChunk {
400
- export interface MarkdownChunkGeneratedMetadata {
401
- type?: 'markdown';
402
-
403
- file_type?: 'text/markdown';
404
-
405
- language: string;
406
-
407
- word_count: number;
408
-
409
- file_size: number;
410
-
411
- chunk_headings?: Array<MarkdownChunkGeneratedMetadata.ChunkHeading>;
412
-
413
- heading_context?: Array<MarkdownChunkGeneratedMetadata.HeadingContext>;
414
-
415
- [k: string]: unknown;
416
- }
417
-
418
- export namespace MarkdownChunkGeneratedMetadata {
419
- export interface ChunkHeading {
420
- level: number;
421
-
422
- text: string;
423
- }
424
-
425
- export interface HeadingContext {
426
- level: number;
427
-
428
- text: string;
429
- }
430
- }
431
-
432
- export interface TextChunkGeneratedMetadata {
433
- type?: 'text';
434
-
435
- file_type?: 'text/plain';
436
-
437
- language: string;
438
-
439
- word_count: number;
440
-
441
- file_size: number;
442
-
443
- [k: string]: unknown;
444
- }
445
-
446
- export interface PdfChunkGeneratedMetadata {
447
- type?: 'pdf';
448
-
449
- file_type?: 'application/pdf';
450
-
451
- total_pages: number;
452
-
453
- total_size: number;
454
-
455
- [k: string]: unknown;
456
- }
457
-
458
- export interface CodeChunkGeneratedMetadata {
459
- type?: 'code';
460
-
461
- file_type: string;
462
-
463
- language: string;
464
-
465
- word_count: number;
466
-
467
- file_size: number;
468
-
469
- [k: string]: unknown;
470
- }
471
-
472
- export interface AudioChunkGeneratedMetadata {
473
- type?: 'audio';
474
-
475
- file_type: string;
476
-
477
- file_size: number;
478
-
479
- total_duration_seconds: number;
480
-
481
- sample_rate: number;
482
-
483
- channels: number;
484
-
485
- audio_format: number;
486
-
487
- [k: string]: unknown;
488
- }
489
-
490
272
  /**
491
273
  * The image input specification.
492
274
  */
@@ -517,13 +299,7 @@ export interface ScoredTextInputChunk {
517
299
  /**
518
300
  * metadata of the chunk
519
301
  */
520
- generated_metadata?:
521
- | ScoredTextInputChunk.MarkdownChunkGeneratedMetadata
522
- | ScoredTextInputChunk.TextChunkGeneratedMetadata
523
- | ScoredTextInputChunk.PdfChunkGeneratedMetadata
524
- | ScoredTextInputChunk.CodeChunkGeneratedMetadata
525
- | ScoredTextInputChunk.AudioChunkGeneratedMetadata
526
- | null;
302
+ generated_metadata?: { [key: string]: unknown } | null;
527
303
 
528
304
  /**
529
305
  * model used for this chunk
@@ -546,9 +322,9 @@ export interface ScoredTextInputChunk {
546
322
  filename: string;
547
323
 
548
324
  /**
549
- * vector store id
325
+ * store id
550
326
  */
551
- vector_store_id: string;
327
+ store_id: string;
552
328
 
553
329
  /**
554
330
  * file metadata
@@ -571,98 +347,6 @@ export interface ScoredTextInputChunk {
571
347
  text: string;
572
348
  }
573
349
 
574
- export namespace ScoredTextInputChunk {
575
- export interface MarkdownChunkGeneratedMetadata {
576
- type?: 'markdown';
577
-
578
- file_type?: 'text/markdown';
579
-
580
- language: string;
581
-
582
- word_count: number;
583
-
584
- file_size: number;
585
-
586
- chunk_headings?: Array<MarkdownChunkGeneratedMetadata.ChunkHeading>;
587
-
588
- heading_context?: Array<MarkdownChunkGeneratedMetadata.HeadingContext>;
589
-
590
- [k: string]: unknown;
591
- }
592
-
593
- export namespace MarkdownChunkGeneratedMetadata {
594
- export interface ChunkHeading {
595
- level: number;
596
-
597
- text: string;
598
- }
599
-
600
- export interface HeadingContext {
601
- level: number;
602
-
603
- text: string;
604
- }
605
- }
606
-
607
- export interface TextChunkGeneratedMetadata {
608
- type?: 'text';
609
-
610
- file_type?: 'text/plain';
611
-
612
- language: string;
613
-
614
- word_count: number;
615
-
616
- file_size: number;
617
-
618
- [k: string]: unknown;
619
- }
620
-
621
- export interface PdfChunkGeneratedMetadata {
622
- type?: 'pdf';
623
-
624
- file_type?: 'application/pdf';
625
-
626
- total_pages: number;
627
-
628
- total_size: number;
629
-
630
- [k: string]: unknown;
631
- }
632
-
633
- export interface CodeChunkGeneratedMetadata {
634
- type?: 'code';
635
-
636
- file_type: string;
637
-
638
- language: string;
639
-
640
- word_count: number;
641
-
642
- file_size: number;
643
-
644
- [k: string]: unknown;
645
- }
646
-
647
- export interface AudioChunkGeneratedMetadata {
648
- type?: 'audio';
649
-
650
- file_type: string;
651
-
652
- file_size: number;
653
-
654
- total_duration_seconds: number;
655
-
656
- sample_rate: number;
657
-
658
- channels: number;
659
-
660
- audio_format: number;
661
-
662
- [k: string]: unknown;
663
- }
664
- }
665
-
666
350
  export interface ScoredVideoURLInputChunk {
667
351
  /**
668
352
  * position of the chunk in a file
@@ -677,13 +361,7 @@ export interface ScoredVideoURLInputChunk {
677
361
  /**
678
362
  * metadata of the chunk
679
363
  */
680
- generated_metadata?:
681
- | ScoredVideoURLInputChunk.MarkdownChunkGeneratedMetadata
682
- | ScoredVideoURLInputChunk.TextChunkGeneratedMetadata
683
- | ScoredVideoURLInputChunk.PdfChunkGeneratedMetadata
684
- | ScoredVideoURLInputChunk.CodeChunkGeneratedMetadata
685
- | ScoredVideoURLInputChunk.AudioChunkGeneratedMetadata
686
- | null;
364
+ generated_metadata?: { [key: string]: unknown } | null;
687
365
 
688
366
  /**
689
367
  * model used for this chunk
@@ -706,9 +384,9 @@ export interface ScoredVideoURLInputChunk {
706
384
  filename: string;
707
385
 
708
386
  /**
709
- * vector store id
387
+ * store id
710
388
  */
711
- vector_store_id: string;
389
+ store_id: string;
712
390
 
713
391
  /**
714
392
  * file metadata
@@ -737,96 +415,6 @@ export interface ScoredVideoURLInputChunk {
737
415
  }
738
416
 
739
417
  export namespace ScoredVideoURLInputChunk {
740
- export interface MarkdownChunkGeneratedMetadata {
741
- type?: 'markdown';
742
-
743
- file_type?: 'text/markdown';
744
-
745
- language: string;
746
-
747
- word_count: number;
748
-
749
- file_size: number;
750
-
751
- chunk_headings?: Array<MarkdownChunkGeneratedMetadata.ChunkHeading>;
752
-
753
- heading_context?: Array<MarkdownChunkGeneratedMetadata.HeadingContext>;
754
-
755
- [k: string]: unknown;
756
- }
757
-
758
- export namespace MarkdownChunkGeneratedMetadata {
759
- export interface ChunkHeading {
760
- level: number;
761
-
762
- text: string;
763
- }
764
-
765
- export interface HeadingContext {
766
- level: number;
767
-
768
- text: string;
769
- }
770
- }
771
-
772
- export interface TextChunkGeneratedMetadata {
773
- type?: 'text';
774
-
775
- file_type?: 'text/plain';
776
-
777
- language: string;
778
-
779
- word_count: number;
780
-
781
- file_size: number;
782
-
783
- [k: string]: unknown;
784
- }
785
-
786
- export interface PdfChunkGeneratedMetadata {
787
- type?: 'pdf';
788
-
789
- file_type?: 'application/pdf';
790
-
791
- total_pages: number;
792
-
793
- total_size: number;
794
-
795
- [k: string]: unknown;
796
- }
797
-
798
- export interface CodeChunkGeneratedMetadata {
799
- type?: 'code';
800
-
801
- file_type: string;
802
-
803
- language: string;
804
-
805
- word_count: number;
806
-
807
- file_size: number;
808
-
809
- [k: string]: unknown;
810
- }
811
-
812
- export interface AudioChunkGeneratedMetadata {
813
- type?: 'audio';
814
-
815
- file_type: string;
816
-
817
- file_size: number;
818
-
819
- total_duration_seconds: number;
820
-
821
- sample_rate: number;
822
-
823
- channels: number;
824
-
825
- audio_format: number;
826
-
827
- [k: string]: unknown;
828
- }
829
-
830
418
  /**
831
419
  * The video input specification.
832
420
  */
@@ -873,7 +461,7 @@ export interface VectorStore {
873
461
  file_counts?: VectorStore.FileCounts;
874
462
 
875
463
  /**
876
- * Represents an expiration policy for a vector store.
464
+ * Represents an expiration policy for a store.
877
465
  */
878
466
  expires_after?: ExpiresAfter | null;
879
467
 
@@ -1013,22 +601,674 @@ export interface VectorStoreQuestionAnsweringResponse {
1013
601
  * Source documents used to generate the answer
1014
602
  */
1015
603
  sources?: Array<
1016
- ScoredTextInputChunk | ScoredImageURLInputChunk | ScoredAudioURLInputChunk | ScoredVideoURLInputChunk
604
+ | VectorStoreQuestionAnsweringResponse.MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredTextInputChunk
605
+ | VectorStoreQuestionAnsweringResponse.MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredImageURLInputChunk
606
+ | VectorStoreQuestionAnsweringResponse.MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredAudioURLInputChunk
607
+ | VectorStoreQuestionAnsweringResponse.MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredVideoURLInputChunk
1017
608
  >;
1018
609
  }
1019
610
 
1020
- export interface VectorStoreSearchResponse {
611
+ export namespace VectorStoreQuestionAnsweringResponse {
1021
612
  /**
1022
- * The object type of the response
613
+ * Scored text chunk for deprecated API.
1023
614
  */
1024
- object?: 'list';
615
+ export interface MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredTextInputChunk {
616
+ /**
617
+ * position of the chunk in a file
618
+ */
619
+ chunk_index: number;
620
+
621
+ /**
622
+ * mime type of the chunk
623
+ */
624
+ mime_type?: string;
625
+
626
+ /**
627
+ * metadata of the chunk
628
+ */
629
+ generated_metadata?: { [key: string]: unknown } | null;
630
+
631
+ /**
632
+ * model used for this chunk
633
+ */
634
+ model?: string | null;
635
+
636
+ /**
637
+ * score of the chunk
638
+ */
639
+ score: number;
640
+
641
+ /**
642
+ * file id
643
+ */
644
+ file_id: string;
645
+
646
+ /**
647
+ * filename
648
+ */
649
+ filename: string;
650
+
651
+ /**
652
+ * store id
653
+ */
654
+ vector_store_id: string;
655
+
656
+ /**
657
+ * file metadata
658
+ */
659
+ metadata?: unknown;
660
+
661
+ /**
662
+ * Input type identifier
663
+ */
664
+ type?: 'text';
665
+
666
+ /**
667
+ * The offset of the text in the file relative to the start of the file.
668
+ */
669
+ offset?: number;
670
+
671
+ /**
672
+ * Text content to process
673
+ */
674
+ text: string;
675
+ }
1025
676
 
1026
677
  /**
1027
- * The list of scored vector store file chunks
678
+ * Scored image chunk for deprecated API.
1028
679
  */
1029
- data: Array<
1030
- ScoredTextInputChunk | ScoredImageURLInputChunk | ScoredAudioURLInputChunk | ScoredVideoURLInputChunk
1031
- >;
680
+ export interface MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredImageURLInputChunk {
681
+ /**
682
+ * position of the chunk in a file
683
+ */
684
+ chunk_index: number;
685
+
686
+ /**
687
+ * mime type of the chunk
688
+ */
689
+ mime_type?: string;
690
+
691
+ /**
692
+ * metadata of the chunk
693
+ */
694
+ generated_metadata?: { [key: string]: unknown } | null;
695
+
696
+ /**
697
+ * model used for this chunk
698
+ */
699
+ model?: string | null;
700
+
701
+ /**
702
+ * score of the chunk
703
+ */
704
+ score: number;
705
+
706
+ /**
707
+ * file id
708
+ */
709
+ file_id: string;
710
+
711
+ /**
712
+ * filename
713
+ */
714
+ filename: string;
715
+
716
+ /**
717
+ * store id
718
+ */
719
+ vector_store_id: string;
720
+
721
+ /**
722
+ * file metadata
723
+ */
724
+ metadata?: unknown;
725
+
726
+ /**
727
+ * Input type identifier
728
+ */
729
+ type?: 'image_url';
730
+
731
+ /**
732
+ * ocr text of the image
733
+ */
734
+ ocr_text?: string | null;
735
+
736
+ /**
737
+ * summary of the image
738
+ */
739
+ summary?: string | null;
740
+
741
+ /**
742
+ * The image input specification.
743
+ */
744
+ image_url: MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredImageURLInputChunk.ImageURL;
745
+ }
746
+
747
+ export namespace MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredImageURLInputChunk {
748
+ /**
749
+ * The image input specification.
750
+ */
751
+ export interface ImageURL {
752
+ /**
753
+ * The image URL. Can be either a URL or a Data URI.
754
+ */
755
+ url: string;
756
+
757
+ /**
758
+ * The image format/mimetype
759
+ */
760
+ format?: string;
761
+ }
762
+ }
763
+
764
+ /**
765
+ * Scored audio chunk for deprecated API.
766
+ */
767
+ export interface MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredAudioURLInputChunk {
768
+ /**
769
+ * position of the chunk in a file
770
+ */
771
+ chunk_index: number;
772
+
773
+ /**
774
+ * mime type of the chunk
775
+ */
776
+ mime_type?: string;
777
+
778
+ /**
779
+ * metadata of the chunk
780
+ */
781
+ generated_metadata?: { [key: string]: unknown } | null;
782
+
783
+ /**
784
+ * model used for this chunk
785
+ */
786
+ model?: string | null;
787
+
788
+ /**
789
+ * score of the chunk
790
+ */
791
+ score: number;
792
+
793
+ /**
794
+ * file id
795
+ */
796
+ file_id: string;
797
+
798
+ /**
799
+ * filename
800
+ */
801
+ filename: string;
802
+
803
+ /**
804
+ * store id
805
+ */
806
+ vector_store_id: string;
807
+
808
+ /**
809
+ * file metadata
810
+ */
811
+ metadata?: unknown;
812
+
813
+ /**
814
+ * Input type identifier
815
+ */
816
+ type?: 'audio_url';
817
+
818
+ /**
819
+ * speech recognition (sr) text of the audio
820
+ */
821
+ transcription?: string | null;
822
+
823
+ /**
824
+ * summary of the audio
825
+ */
826
+ summary?: string | null;
827
+
828
+ /**
829
+ * The audio input specification.
830
+ */
831
+ audio_url: MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredAudioURLInputChunk.AudioURL;
832
+
833
+ /**
834
+ * The sampling rate of the audio.
835
+ */
836
+ sampling_rate: number;
837
+ }
838
+
839
+ export namespace MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredAudioURLInputChunk {
840
+ /**
841
+ * The audio input specification.
842
+ */
843
+ export interface AudioURL {
844
+ /**
845
+ * The audio URL. Can be either a URL or a Data URI.
846
+ */
847
+ url: string;
848
+ }
849
+ }
850
+
851
+ /**
852
+ * Scored video chunk for deprecated API.
853
+ */
854
+ export interface MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredVideoURLInputChunk {
855
+ /**
856
+ * position of the chunk in a file
857
+ */
858
+ chunk_index: number;
859
+
860
+ /**
861
+ * mime type of the chunk
862
+ */
863
+ mime_type?: string;
864
+
865
+ /**
866
+ * metadata of the chunk
867
+ */
868
+ generated_metadata?: { [key: string]: unknown } | null;
869
+
870
+ /**
871
+ * model used for this chunk
872
+ */
873
+ model?: string | null;
874
+
875
+ /**
876
+ * score of the chunk
877
+ */
878
+ score: number;
879
+
880
+ /**
881
+ * file id
882
+ */
883
+ file_id: string;
884
+
885
+ /**
886
+ * filename
887
+ */
888
+ filename: string;
889
+
890
+ /**
891
+ * store id
892
+ */
893
+ vector_store_id: string;
894
+
895
+ /**
896
+ * file metadata
897
+ */
898
+ metadata?: unknown;
899
+
900
+ /**
901
+ * Input type identifier
902
+ */
903
+ type?: 'video_url';
904
+
905
+ /**
906
+ * speech recognition (sr) text of the video
907
+ */
908
+ transcription?: string | null;
909
+
910
+ /**
911
+ * summary of the video
912
+ */
913
+ summary?: string | null;
914
+
915
+ /**
916
+ * The video input specification.
917
+ */
918
+ video_url: MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredVideoURLInputChunk.VideoURL;
919
+ }
920
+
921
+ export namespace MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredVideoURLInputChunk {
922
+ /**
923
+ * The video input specification.
924
+ */
925
+ export interface VideoURL {
926
+ /**
927
+ * The video URL. Can be either a URL or a Data URI.
928
+ */
929
+ url: string;
930
+ }
931
+ }
932
+ }
933
+
934
+ export interface VectorStoreSearchResponse {
935
+ /**
936
+ * The object type of the response
937
+ */
938
+ object?: 'list';
939
+
940
+ /**
941
+ * The list of scored vector store file chunks
942
+ */
943
+ data: Array<
944
+ | VectorStoreSearchResponse.MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredTextInputChunk
945
+ | VectorStoreSearchResponse.MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredImageURLInputChunk
946
+ | VectorStoreSearchResponse.MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredAudioURLInputChunk
947
+ | VectorStoreSearchResponse.MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredVideoURLInputChunk
948
+ >;
949
+ }
950
+
951
+ export namespace VectorStoreSearchResponse {
952
+ /**
953
+ * Scored text chunk for deprecated API.
954
+ */
955
+ export interface MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredTextInputChunk {
956
+ /**
957
+ * position of the chunk in a file
958
+ */
959
+ chunk_index: number;
960
+
961
+ /**
962
+ * mime type of the chunk
963
+ */
964
+ mime_type?: string;
965
+
966
+ /**
967
+ * metadata of the chunk
968
+ */
969
+ generated_metadata?: { [key: string]: unknown } | null;
970
+
971
+ /**
972
+ * model used for this chunk
973
+ */
974
+ model?: string | null;
975
+
976
+ /**
977
+ * score of the chunk
978
+ */
979
+ score: number;
980
+
981
+ /**
982
+ * file id
983
+ */
984
+ file_id: string;
985
+
986
+ /**
987
+ * filename
988
+ */
989
+ filename: string;
990
+
991
+ /**
992
+ * store id
993
+ */
994
+ vector_store_id: string;
995
+
996
+ /**
997
+ * file metadata
998
+ */
999
+ metadata?: unknown;
1000
+
1001
+ /**
1002
+ * Input type identifier
1003
+ */
1004
+ type?: 'text';
1005
+
1006
+ /**
1007
+ * The offset of the text in the file relative to the start of the file.
1008
+ */
1009
+ offset?: number;
1010
+
1011
+ /**
1012
+ * Text content to process
1013
+ */
1014
+ text: string;
1015
+ }
1016
+
1017
+ /**
1018
+ * Scored image chunk for deprecated API.
1019
+ */
1020
+ export interface MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredImageURLInputChunk {
1021
+ /**
1022
+ * position of the chunk in a file
1023
+ */
1024
+ chunk_index: number;
1025
+
1026
+ /**
1027
+ * mime type of the chunk
1028
+ */
1029
+ mime_type?: string;
1030
+
1031
+ /**
1032
+ * metadata of the chunk
1033
+ */
1034
+ generated_metadata?: { [key: string]: unknown } | null;
1035
+
1036
+ /**
1037
+ * model used for this chunk
1038
+ */
1039
+ model?: string | null;
1040
+
1041
+ /**
1042
+ * score of the chunk
1043
+ */
1044
+ score: number;
1045
+
1046
+ /**
1047
+ * file id
1048
+ */
1049
+ file_id: string;
1050
+
1051
+ /**
1052
+ * filename
1053
+ */
1054
+ filename: string;
1055
+
1056
+ /**
1057
+ * store id
1058
+ */
1059
+ vector_store_id: string;
1060
+
1061
+ /**
1062
+ * file metadata
1063
+ */
1064
+ metadata?: unknown;
1065
+
1066
+ /**
1067
+ * Input type identifier
1068
+ */
1069
+ type?: 'image_url';
1070
+
1071
+ /**
1072
+ * ocr text of the image
1073
+ */
1074
+ ocr_text?: string | null;
1075
+
1076
+ /**
1077
+ * summary of the image
1078
+ */
1079
+ summary?: string | null;
1080
+
1081
+ /**
1082
+ * The image input specification.
1083
+ */
1084
+ image_url: MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredImageURLInputChunk.ImageURL;
1085
+ }
1086
+
1087
+ export namespace MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredImageURLInputChunk {
1088
+ /**
1089
+ * The image input specification.
1090
+ */
1091
+ export interface ImageURL {
1092
+ /**
1093
+ * The image URL. Can be either a URL or a Data URI.
1094
+ */
1095
+ url: string;
1096
+
1097
+ /**
1098
+ * The image format/mimetype
1099
+ */
1100
+ format?: string;
1101
+ }
1102
+ }
1103
+
1104
+ /**
1105
+ * Scored audio chunk for deprecated API.
1106
+ */
1107
+ export interface MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredAudioURLInputChunk {
1108
+ /**
1109
+ * position of the chunk in a file
1110
+ */
1111
+ chunk_index: number;
1112
+
1113
+ /**
1114
+ * mime type of the chunk
1115
+ */
1116
+ mime_type?: string;
1117
+
1118
+ /**
1119
+ * metadata of the chunk
1120
+ */
1121
+ generated_metadata?: { [key: string]: unknown } | null;
1122
+
1123
+ /**
1124
+ * model used for this chunk
1125
+ */
1126
+ model?: string | null;
1127
+
1128
+ /**
1129
+ * score of the chunk
1130
+ */
1131
+ score: number;
1132
+
1133
+ /**
1134
+ * file id
1135
+ */
1136
+ file_id: string;
1137
+
1138
+ /**
1139
+ * filename
1140
+ */
1141
+ filename: string;
1142
+
1143
+ /**
1144
+ * store id
1145
+ */
1146
+ vector_store_id: string;
1147
+
1148
+ /**
1149
+ * file metadata
1150
+ */
1151
+ metadata?: unknown;
1152
+
1153
+ /**
1154
+ * Input type identifier
1155
+ */
1156
+ type?: 'audio_url';
1157
+
1158
+ /**
1159
+ * speech recognition (sr) text of the audio
1160
+ */
1161
+ transcription?: string | null;
1162
+
1163
+ /**
1164
+ * summary of the audio
1165
+ */
1166
+ summary?: string | null;
1167
+
1168
+ /**
1169
+ * The audio input specification.
1170
+ */
1171
+ audio_url: MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredAudioURLInputChunk.AudioURL;
1172
+
1173
+ /**
1174
+ * The sampling rate of the audio.
1175
+ */
1176
+ sampling_rate: number;
1177
+ }
1178
+
1179
+ export namespace MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredAudioURLInputChunk {
1180
+ /**
1181
+ * The audio input specification.
1182
+ */
1183
+ export interface AudioURL {
1184
+ /**
1185
+ * The audio URL. Can be either a URL or a Data URI.
1186
+ */
1187
+ url: string;
1188
+ }
1189
+ }
1190
+
1191
+ /**
1192
+ * Scored video chunk for deprecated API.
1193
+ */
1194
+ export interface MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredVideoURLInputChunk {
1195
+ /**
1196
+ * position of the chunk in a file
1197
+ */
1198
+ chunk_index: number;
1199
+
1200
+ /**
1201
+ * mime type of the chunk
1202
+ */
1203
+ mime_type?: string;
1204
+
1205
+ /**
1206
+ * metadata of the chunk
1207
+ */
1208
+ generated_metadata?: { [key: string]: unknown } | null;
1209
+
1210
+ /**
1211
+ * model used for this chunk
1212
+ */
1213
+ model?: string | null;
1214
+
1215
+ /**
1216
+ * score of the chunk
1217
+ */
1218
+ score: number;
1219
+
1220
+ /**
1221
+ * file id
1222
+ */
1223
+ file_id: string;
1224
+
1225
+ /**
1226
+ * filename
1227
+ */
1228
+ filename: string;
1229
+
1230
+ /**
1231
+ * store id
1232
+ */
1233
+ vector_store_id: string;
1234
+
1235
+ /**
1236
+ * file metadata
1237
+ */
1238
+ metadata?: unknown;
1239
+
1240
+ /**
1241
+ * Input type identifier
1242
+ */
1243
+ type?: 'video_url';
1244
+
1245
+ /**
1246
+ * speech recognition (sr) text of the video
1247
+ */
1248
+ transcription?: string | null;
1249
+
1250
+ /**
1251
+ * summary of the video
1252
+ */
1253
+ summary?: string | null;
1254
+
1255
+ /**
1256
+ * The video input specification.
1257
+ */
1258
+ video_url: MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredVideoURLInputChunk.VideoURL;
1259
+ }
1260
+
1261
+ export namespace MxbaiOmniAPIRoutesV1DeprecatedVectorStoresModelsScoredVideoURLInputChunk {
1262
+ /**
1263
+ * The video input specification.
1264
+ */
1265
+ export interface VideoURL {
1266
+ /**
1267
+ * The video URL. Can be either a URL or a Data URI.
1268
+ */
1269
+ url: string;
1270
+ }
1271
+ }
1032
1272
  }
1033
1273
 
1034
1274
  export interface VectorStoreCreateParams {
@@ -1048,7 +1288,7 @@ export interface VectorStoreCreateParams {
1048
1288
  is_public?: boolean;
1049
1289
 
1050
1290
  /**
1051
- * Represents an expiration policy for a vector store.
1291
+ * Represents an expiration policy for a store.
1052
1292
  */
1053
1293
  expires_after?: ExpiresAfter | null;
1054
1294
 
@@ -1065,7 +1305,7 @@ export interface VectorStoreCreateParams {
1065
1305
 
1066
1306
  export interface VectorStoreUpdateParams {
1067
1307
  /**
1068
- * New name for the vector store
1308
+ * New name for the store
1069
1309
  */
1070
1310
  name?: string | null;
1071
1311
 
@@ -1080,7 +1320,7 @@ export interface VectorStoreUpdateParams {
1080
1320
  is_public?: boolean | null;
1081
1321
 
1082
1322
  /**
1083
- * Represents an expiration policy for a vector store.
1323
+ * Represents an expiration policy for a store.
1084
1324
  */
1085
1325
  expires_after?: ExpiresAfter | null;
1086
1326