@mixedbread/sdk 0.9.3 → 0.10.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 (171) hide show
  1. package/CHANGELOG.md +29 -0
  2. package/README.md +21 -0
  3. package/client.d.mts +9 -10
  4. package/client.d.mts.map +1 -1
  5. package/client.d.ts +9 -10
  6. package/client.d.ts.map +1 -1
  7. package/client.js +3 -15
  8. package/client.js.map +1 -1
  9. package/client.mjs +3 -15
  10. package/client.mjs.map +1 -1
  11. package/core/pagination.d.mts +29 -0
  12. package/core/pagination.d.mts.map +1 -1
  13. package/core/pagination.d.ts +29 -0
  14. package/core/pagination.d.ts.map +1 -1
  15. package/core/pagination.js +31 -1
  16. package/core/pagination.js.map +1 -1
  17. package/core/pagination.mjs +29 -0
  18. package/core/pagination.mjs.map +1 -1
  19. package/internal/qs/formats.d.mts +7 -0
  20. package/internal/qs/formats.d.mts.map +1 -0
  21. package/internal/qs/formats.d.ts +7 -0
  22. package/internal/qs/formats.d.ts.map +1 -0
  23. package/internal/qs/formats.js +13 -0
  24. package/internal/qs/formats.js.map +1 -0
  25. package/internal/qs/formats.mjs +9 -0
  26. package/internal/qs/formats.mjs.map +1 -0
  27. package/internal/qs/index.d.mts +10 -0
  28. package/internal/qs/index.d.mts.map +1 -0
  29. package/internal/qs/index.d.ts +10 -0
  30. package/internal/qs/index.d.ts.map +1 -0
  31. package/internal/qs/index.js +14 -0
  32. package/internal/qs/index.js.map +1 -0
  33. package/internal/qs/index.mjs +10 -0
  34. package/internal/qs/index.mjs.map +1 -0
  35. package/internal/qs/stringify.d.mts +3 -0
  36. package/internal/qs/stringify.d.mts.map +1 -0
  37. package/internal/qs/stringify.d.ts +3 -0
  38. package/internal/qs/stringify.d.ts.map +1 -0
  39. package/internal/qs/stringify.js +277 -0
  40. package/internal/qs/stringify.js.map +1 -0
  41. package/internal/qs/stringify.mjs +274 -0
  42. package/internal/qs/stringify.mjs.map +1 -0
  43. package/internal/qs/types.d.mts +57 -0
  44. package/internal/qs/types.d.mts.map +1 -0
  45. package/internal/qs/types.d.ts +57 -0
  46. package/internal/qs/types.d.ts.map +1 -0
  47. package/internal/qs/types.js +3 -0
  48. package/internal/qs/types.js.map +1 -0
  49. package/internal/qs/types.mjs +2 -0
  50. package/internal/qs/types.mjs.map +1 -0
  51. package/internal/qs/utils.d.mts +15 -0
  52. package/internal/qs/utils.d.mts.map +1 -0
  53. package/internal/qs/utils.d.ts +15 -0
  54. package/internal/qs/utils.d.ts.map +1 -0
  55. package/internal/qs/utils.js +230 -0
  56. package/internal/qs/utils.js.map +1 -0
  57. package/internal/qs/utils.mjs +217 -0
  58. package/internal/qs/utils.mjs.map +1 -0
  59. package/package.json +5 -2
  60. package/resources/data-sources/connectors.d.mts +11 -7
  61. package/resources/data-sources/connectors.d.mts.map +1 -1
  62. package/resources/data-sources/connectors.d.ts +11 -7
  63. package/resources/data-sources/connectors.d.ts.map +1 -1
  64. package/resources/data-sources/connectors.js +1 -1
  65. package/resources/data-sources/connectors.js.map +1 -1
  66. package/resources/data-sources/connectors.mjs +2 -2
  67. package/resources/data-sources/connectors.mjs.map +1 -1
  68. package/resources/data-sources/data-sources.d.mts +10 -8
  69. package/resources/data-sources/data-sources.d.mts.map +1 -1
  70. package/resources/data-sources/data-sources.d.ts +10 -8
  71. package/resources/data-sources/data-sources.d.ts.map +1 -1
  72. package/resources/data-sources/data-sources.js +1 -1
  73. package/resources/data-sources/data-sources.js.map +1 -1
  74. package/resources/data-sources/data-sources.mjs +2 -2
  75. package/resources/data-sources/data-sources.mjs.map +1 -1
  76. package/resources/data-sources/index.d.mts +2 -2
  77. package/resources/data-sources/index.d.mts.map +1 -1
  78. package/resources/data-sources/index.d.ts +2 -2
  79. package/resources/data-sources/index.d.ts.map +1 -1
  80. package/resources/extractions/content.d.mts +6 -2
  81. package/resources/extractions/content.d.mts.map +1 -1
  82. package/resources/extractions/content.d.ts +6 -2
  83. package/resources/extractions/content.d.ts.map +1 -1
  84. package/resources/extractions/jobs.d.mts +9 -3
  85. package/resources/extractions/jobs.d.mts.map +1 -1
  86. package/resources/extractions/jobs.d.ts +9 -3
  87. package/resources/extractions/jobs.d.ts.map +1 -1
  88. package/resources/extractions/schema.d.mts +15 -5
  89. package/resources/extractions/schema.d.mts.map +1 -1
  90. package/resources/extractions/schema.d.ts +15 -5
  91. package/resources/extractions/schema.d.ts.map +1 -1
  92. package/resources/files.d.mts +5 -5
  93. package/resources/files.d.mts.map +1 -1
  94. package/resources/files.d.ts +5 -5
  95. package/resources/files.d.ts.map +1 -1
  96. package/resources/files.js +1 -1
  97. package/resources/files.js.map +1 -1
  98. package/resources/files.mjs +2 -2
  99. package/resources/files.mjs.map +1 -1
  100. package/resources/index.d.mts +3 -3
  101. package/resources/index.d.mts.map +1 -1
  102. package/resources/index.d.ts +3 -3
  103. package/resources/index.d.ts.map +1 -1
  104. package/resources/parsing/index.d.mts +1 -1
  105. package/resources/parsing/index.d.mts.map +1 -1
  106. package/resources/parsing/index.d.ts +1 -1
  107. package/resources/parsing/index.d.ts.map +1 -1
  108. package/resources/parsing/jobs.d.mts +5 -5
  109. package/resources/parsing/jobs.d.mts.map +1 -1
  110. package/resources/parsing/jobs.d.ts +5 -5
  111. package/resources/parsing/jobs.d.ts.map +1 -1
  112. package/resources/parsing/jobs.js +1 -1
  113. package/resources/parsing/jobs.js.map +1 -1
  114. package/resources/parsing/jobs.mjs +2 -2
  115. package/resources/parsing/jobs.mjs.map +1 -1
  116. package/resources/parsing/parsing.d.mts +2 -2
  117. package/resources/parsing/parsing.d.mts.map +1 -1
  118. package/resources/parsing/parsing.d.ts +2 -2
  119. package/resources/parsing/parsing.d.ts.map +1 -1
  120. package/resources/vector-stores/files.d.mts +9 -5
  121. package/resources/vector-stores/files.d.mts.map +1 -1
  122. package/resources/vector-stores/files.d.ts +9 -5
  123. package/resources/vector-stores/files.d.ts.map +1 -1
  124. package/resources/vector-stores/files.js +1 -1
  125. package/resources/vector-stores/files.js.map +1 -1
  126. package/resources/vector-stores/files.mjs +2 -2
  127. package/resources/vector-stores/files.mjs.map +1 -1
  128. package/resources/vector-stores/index.d.mts +2 -2
  129. package/resources/vector-stores/index.d.mts.map +1 -1
  130. package/resources/vector-stores/index.d.ts +2 -2
  131. package/resources/vector-stores/index.d.ts.map +1 -1
  132. package/resources/vector-stores/vector-stores.d.mts +31 -7
  133. package/resources/vector-stores/vector-stores.d.mts.map +1 -1
  134. package/resources/vector-stores/vector-stores.d.ts +31 -7
  135. package/resources/vector-stores/vector-stores.d.ts.map +1 -1
  136. package/resources/vector-stores/vector-stores.js +1 -1
  137. package/resources/vector-stores/vector-stores.js.map +1 -1
  138. package/resources/vector-stores/vector-stores.mjs +2 -2
  139. package/resources/vector-stores/vector-stores.mjs.map +1 -1
  140. package/src/client.ts +19 -24
  141. package/src/core/pagination.ts +76 -0
  142. package/src/internal/qs/LICENSE.md +13 -0
  143. package/src/internal/qs/README.md +3 -0
  144. package/src/internal/qs/formats.ts +10 -0
  145. package/src/internal/qs/index.ts +13 -0
  146. package/src/internal/qs/stringify.ts +385 -0
  147. package/src/internal/qs/types.ts +71 -0
  148. package/src/internal/qs/utils.ts +265 -0
  149. package/src/resources/data-sources/connectors.ts +8 -8
  150. package/src/resources/data-sources/data-sources.ts +9 -9
  151. package/src/resources/data-sources/index.ts +2 -2
  152. package/src/resources/extractions/content.ts +2 -2
  153. package/src/resources/extractions/jobs.ts +3 -3
  154. package/src/resources/extractions/schema.ts +5 -5
  155. package/src/resources/files.ts +6 -6
  156. package/src/resources/index.ts +3 -3
  157. package/src/resources/parsing/index.ts +1 -1
  158. package/src/resources/parsing/jobs.ts +6 -6
  159. package/src/resources/parsing/parsing.ts +2 -2
  160. package/src/resources/vector-stores/files.ts +11 -6
  161. package/src/resources/vector-stores/index.ts +2 -2
  162. package/src/resources/vector-stores/vector-stores.ts +28 -8
  163. package/src/version.ts +1 -1
  164. package/version.d.mts +1 -1
  165. package/version.d.mts.map +1 -1
  166. package/version.d.ts +1 -1
  167. package/version.d.ts.map +1 -1
  168. package/version.js +1 -1
  169. package/version.js.map +1 -1
  170. package/version.mjs +1 -1
  171. package/version.mjs.map +1 -1
@@ -5,7 +5,7 @@ import * as FilesAPI from './files';
5
5
  import * as Shared from '../shared';
6
6
  import * as VectorStoresAPI from './vector-stores';
7
7
  import { APIPromise } from '../../core/api-promise';
8
- import { LimitOffset, type LimitOffsetParams, PagePromise } from '../../core/pagination';
8
+ import { Cursor, type CursorParams, PagePromise } from '../../core/pagination';
9
9
  import { RequestOptions } from '../../internal/request-options';
10
10
  import * as polling from '../../lib/polling';
11
11
  import { Uploadable } from '../../uploads';
@@ -57,10 +57,10 @@ export class Files extends APIResource {
57
57
  vectorStoreIdentifier: string,
58
58
  query: FileListParams | null | undefined = {},
59
59
  options?: RequestOptions,
60
- ): PagePromise<VectorStoreFilesLimitOffset, VectorStoreFile> {
60
+ ): PagePromise<VectorStoreFilesCursor, VectorStoreFile> {
61
61
  return this._client.getAPIList(
62
62
  path`/v1/vector_stores/${vectorStoreIdentifier}/files`,
63
- LimitOffset<VectorStoreFile>,
63
+ Cursor<VectorStoreFile>,
64
64
  { query, ...options },
65
65
  );
66
66
  }
@@ -202,7 +202,7 @@ export class Files extends APIResource {
202
202
  }
203
203
  }
204
204
 
205
- export type VectorStoreFilesLimitOffset = LimitOffset<VectorStoreFile>;
205
+ export type VectorStoreFilesCursor = Cursor<VectorStoreFile>;
206
206
 
207
207
  /**
208
208
  * Represents a reranking configuration.
@@ -425,7 +425,12 @@ export interface FileRetrieveParams {
425
425
  vector_store_identifier: string;
426
426
  }
427
427
 
428
- export interface FileListParams extends LimitOffsetParams {}
428
+ export interface FileListParams extends CursorParams {
429
+ /**
430
+ * Status to filter by
431
+ */
432
+ statuses?: Array<VectorStoreFileStatus> | null;
433
+ }
429
434
 
430
435
  export interface FileDeleteParams {
431
436
  /**
@@ -520,7 +525,7 @@ export declare namespace Files {
520
525
  type VectorStoreFile as VectorStoreFile,
521
526
  type FileDeleteResponse as FileDeleteResponse,
522
527
  type FileSearchResponse as FileSearchResponse,
523
- type VectorStoreFilesLimitOffset as VectorStoreFilesLimitOffset,
528
+ type VectorStoreFilesCursor as VectorStoreFilesCursor,
524
529
  type FileCreateParams as FileCreateParams,
525
530
  type FileRetrieveParams as FileRetrieveParams,
526
531
  type FileListParams as FileListParams,
@@ -13,7 +13,7 @@ export {
13
13
  type FileListParams,
14
14
  type FileDeleteParams,
15
15
  type FileSearchParams,
16
- type VectorStoreFilesLimitOffset,
16
+ type VectorStoreFilesCursor,
17
17
  } from './files';
18
18
  export {
19
19
  VectorStores,
@@ -32,5 +32,5 @@ export {
32
32
  type VectorStoreListParams,
33
33
  type VectorStoreQuestionAnsweringParams,
34
34
  type VectorStoreSearchParams,
35
- type VectorStoresLimitOffset,
35
+ type VectorStoresCursor,
36
36
  } from './vector-stores';
@@ -16,10 +16,10 @@ import {
16
16
  ScoredVectorStoreFile,
17
17
  VectorStoreFile,
18
18
  VectorStoreFileStatus,
19
- VectorStoreFilesLimitOffset,
19
+ VectorStoreFilesCursor,
20
20
  } from './files';
21
21
  import { APIPromise } from '../../core/api-promise';
22
- import { LimitOffset, type LimitOffsetParams, PagePromise } from '../../core/pagination';
22
+ import { Cursor, type CursorParams, PagePromise } from '../../core/pagination';
23
23
  import { RequestOptions } from '../../internal/request-options';
24
24
  import { path } from '../../internal/utils/path';
25
25
 
@@ -77,8 +77,8 @@ export class VectorStores extends APIResource {
77
77
  list(
78
78
  query: VectorStoreListParams | null | undefined = {},
79
79
  options?: RequestOptions,
80
- ): PagePromise<VectorStoresLimitOffset, VectorStore> {
81
- return this._client.getAPIList('/v1/vector_stores', LimitOffset<VectorStore>, { query, ...options });
80
+ ): PagePromise<VectorStoresCursor, VectorStore> {
81
+ return this._client.getAPIList('/v1/vector_stores', Cursor<VectorStore>, { query, ...options });
82
82
  }
83
83
 
84
84
  /**
@@ -126,7 +126,7 @@ export class VectorStores extends APIResource {
126
126
  }
127
127
  }
128
128
 
129
- export type VectorStoresLimitOffset = LimitOffset<VectorStore>;
129
+ export type VectorStoresCursor = Cursor<VectorStore>;
130
130
 
131
131
  /**
132
132
  * Represents an expiration policy for a vector store.
@@ -154,6 +154,11 @@ export interface ScoredAudioURLInputChunk {
154
154
  */
155
155
  mime_type?: string;
156
156
 
157
+ /**
158
+ * metadata of the chunk
159
+ */
160
+ generated_metadata?: { [key: string]: unknown } | null;
161
+
157
162
  /**
158
163
  * model used for this chunk
159
164
  */
@@ -228,6 +233,11 @@ export interface ScoredImageURLInputChunk {
228
233
  */
229
234
  mime_type?: string;
230
235
 
236
+ /**
237
+ * metadata of the chunk
238
+ */
239
+ generated_metadata?: { [key: string]: unknown } | null;
240
+
231
241
  /**
232
242
  * model used for this chunk
233
243
  */
@@ -307,6 +317,11 @@ export interface ScoredTextInputChunk {
307
317
  */
308
318
  mime_type?: string;
309
319
 
320
+ /**
321
+ * metadata of the chunk
322
+ */
323
+ generated_metadata?: { [key: string]: unknown } | null;
324
+
310
325
  /**
311
326
  * model used for this chunk
312
327
  */
@@ -359,6 +374,11 @@ export interface ScoredVideoURLInputChunk {
359
374
  */
360
375
  mime_type?: string;
361
376
 
377
+ /**
378
+ * metadata of the chunk
379
+ */
380
+ generated_metadata?: { [key: string]: unknown } | null;
381
+
362
382
  /**
363
383
  * model used for this chunk
364
384
  */
@@ -669,7 +689,7 @@ export interface VectorStoreUpdateParams {
669
689
  metadata?: unknown;
670
690
  }
671
691
 
672
- export interface VectorStoreListParams extends LimitOffsetParams {
692
+ export interface VectorStoreListParams extends CursorParams {
673
693
  /**
674
694
  * Search query for fuzzy matching over name and description fields
675
695
  */
@@ -800,7 +820,7 @@ export declare namespace VectorStores {
800
820
  type VectorStoreDeleteResponse as VectorStoreDeleteResponse,
801
821
  type VectorStoreQuestionAnsweringResponse as VectorStoreQuestionAnsweringResponse,
802
822
  type VectorStoreSearchResponse as VectorStoreSearchResponse,
803
- type VectorStoresLimitOffset as VectorStoresLimitOffset,
823
+ type VectorStoresCursor as VectorStoresCursor,
804
824
  type VectorStoreCreateParams as VectorStoreCreateParams,
805
825
  type VectorStoreUpdateParams as VectorStoreUpdateParams,
806
826
  type VectorStoreListParams as VectorStoreListParams,
@@ -816,7 +836,7 @@ export declare namespace VectorStores {
816
836
  type VectorStoreFile as VectorStoreFile,
817
837
  type FileDeleteResponse as FileDeleteResponse,
818
838
  type FileSearchResponse as FileSearchResponse,
819
- type VectorStoreFilesLimitOffset as VectorStoreFilesLimitOffset,
839
+ type VectorStoreFilesCursor as VectorStoreFilesCursor,
820
840
  type FileCreateParams as FileCreateParams,
821
841
  type FileRetrieveParams as FileRetrieveParams,
822
842
  type FileListParams as FileListParams,
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.9.3'; // x-release-please-version
1
+ export const VERSION = '0.10.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.9.3";
1
+ export declare const VERSION = "0.10.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.mts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"version.d.mts","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,UAAU,CAAC"}
1
+ {"version":3,"file":"version.d.mts","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,WAAW,CAAC"}
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.9.3";
1
+ export declare const VERSION = "0.10.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,UAAU,CAAC"}
1
+ {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,WAAW,CAAC"}
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.9.3'; // x-release-please-version
4
+ exports.VERSION = '0.10.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"version.js","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG,OAAO,CAAC,CAAC,2BAA2B"}
1
+ {"version":3,"file":"version.js","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG,QAAQ,CAAC,CAAC,2BAA2B"}
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.9.3'; // x-release-please-version
1
+ export const VERSION = '0.10.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map
package/version.mjs.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"version.mjs","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,OAAO,GAAG,OAAO,CAAC,CAAC,2BAA2B"}
1
+ {"version":3,"file":"version.mjs","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,OAAO,GAAG,QAAQ,CAAC,CAAC,2BAA2B"}