@mixedbread/sdk 0.1.0-alpha.8
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/CHANGELOG.md +210 -0
- package/LICENSE +201 -0
- package/README.md +360 -0
- package/_shims/MultipartBody.d.ts +9 -0
- package/_shims/MultipartBody.d.ts.map +1 -0
- package/_shims/MultipartBody.js +16 -0
- package/_shims/MultipartBody.js.map +1 -0
- package/_shims/MultipartBody.mjs +12 -0
- package/_shims/MultipartBody.mjs.map +1 -0
- package/_shims/README.md +46 -0
- package/_shims/auto/runtime-bun.d.ts +5 -0
- package/_shims/auto/runtime-bun.d.ts.map +1 -0
- package/_shims/auto/runtime-bun.js +21 -0
- package/_shims/auto/runtime-bun.js.map +1 -0
- package/_shims/auto/runtime-bun.mjs +2 -0
- package/_shims/auto/runtime-bun.mjs.map +1 -0
- package/_shims/auto/runtime-node.d.ts +5 -0
- package/_shims/auto/runtime-node.d.ts.map +1 -0
- package/_shims/auto/runtime-node.js +21 -0
- package/_shims/auto/runtime-node.js.map +1 -0
- package/_shims/auto/runtime-node.mjs +2 -0
- package/_shims/auto/runtime-node.mjs.map +1 -0
- package/_shims/auto/runtime.d.ts +5 -0
- package/_shims/auto/runtime.d.ts.map +1 -0
- package/_shims/auto/runtime.js +21 -0
- package/_shims/auto/runtime.js.map +1 -0
- package/_shims/auto/runtime.mjs +2 -0
- package/_shims/auto/runtime.mjs.map +1 -0
- package/_shims/auto/types-node.d.ts +5 -0
- package/_shims/auto/types-node.d.ts.map +1 -0
- package/_shims/auto/types-node.js +21 -0
- package/_shims/auto/types-node.js.map +1 -0
- package/_shims/auto/types-node.mjs +2 -0
- package/_shims/auto/types-node.mjs.map +1 -0
- package/_shims/auto/types.d.ts +101 -0
- package/_shims/auto/types.js +3 -0
- package/_shims/auto/types.mjs +3 -0
- package/_shims/bun-runtime.d.ts +6 -0
- package/_shims/bun-runtime.d.ts.map +1 -0
- package/_shims/bun-runtime.js +14 -0
- package/_shims/bun-runtime.js.map +1 -0
- package/_shims/bun-runtime.mjs +10 -0
- package/_shims/bun-runtime.mjs.map +1 -0
- package/_shims/index.d.ts +81 -0
- package/_shims/index.js +13 -0
- package/_shims/index.mjs +7 -0
- package/_shims/manual-types.d.ts +12 -0
- package/_shims/manual-types.js +3 -0
- package/_shims/manual-types.mjs +3 -0
- package/_shims/node-runtime.d.ts +3 -0
- package/_shims/node-runtime.d.ts.map +1 -0
- package/_shims/node-runtime.js +89 -0
- package/_shims/node-runtime.js.map +1 -0
- package/_shims/node-runtime.mjs +56 -0
- package/_shims/node-runtime.mjs.map +1 -0
- package/_shims/node-types.d.ts +42 -0
- package/_shims/node-types.js +3 -0
- package/_shims/node-types.mjs +3 -0
- package/_shims/registry.d.ts +37 -0
- package/_shims/registry.d.ts.map +1 -0
- package/_shims/registry.js +41 -0
- package/_shims/registry.js.map +1 -0
- package/_shims/registry.mjs +37 -0
- package/_shims/registry.mjs.map +1 -0
- package/_shims/web-runtime.d.ts +5 -0
- package/_shims/web-runtime.d.ts.map +1 -0
- package/_shims/web-runtime.js +78 -0
- package/_shims/web-runtime.js.map +1 -0
- package/_shims/web-runtime.mjs +71 -0
- package/_shims/web-runtime.mjs.map +1 -0
- package/_shims/web-types.d.ts +83 -0
- package/_shims/web-types.js +3 -0
- package/_shims/web-types.mjs +3 -0
- package/core.d.ts +241 -0
- package/core.d.ts.map +1 -0
- package/core.js +914 -0
- package/core.js.map +1 -0
- package/core.mjs +882 -0
- package/core.mjs.map +1 -0
- package/error.d.ts +47 -0
- package/error.d.ts.map +1 -0
- package/error.js +113 -0
- package/error.js.map +1 -0
- package/error.mjs +97 -0
- package/error.mjs.map +1 -0
- package/index.d.mts +148 -0
- package/index.d.ts +148 -0
- package/index.d.ts.map +1 -0
- package/index.js +151 -0
- package/index.js.map +1 -0
- package/index.mjs +108 -0
- package/index.mjs.map +1 -0
- package/lib/polling.d.ts +48 -0
- package/lib/polling.d.ts.map +1 -0
- package/lib/polling.js +75 -0
- package/lib/polling.js.map +1 -0
- package/lib/polling.mjs +71 -0
- package/lib/polling.mjs.map +1 -0
- package/package.json +124 -0
- package/pagination.d.ts +30 -0
- package/pagination.d.ts.map +1 -0
- package/pagination.js +45 -0
- package/pagination.js.map +1 -0
- package/pagination.mjs +41 -0
- package/pagination.mjs.map +1 -0
- package/resource.d.ts +6 -0
- package/resource.d.ts.map +1 -0
- package/resource.js +11 -0
- package/resource.js.map +1 -0
- package/resource.mjs +7 -0
- package/resource.mjs.map +1 -0
- package/resources/extractions/content.d.ts +35 -0
- package/resources/extractions/content.d.ts.map +1 -0
- package/resources/extractions/content.js +19 -0
- package/resources/extractions/content.js.map +1 -0
- package/resources/extractions/content.mjs +15 -0
- package/resources/extractions/content.mjs.map +1 -0
- package/resources/extractions/extractions.d.ts +18 -0
- package/resources/extractions/extractions.d.ts.map +1 -0
- package/resources/extractions/extractions.js +47 -0
- package/resources/extractions/extractions.js.map +1 -0
- package/resources/extractions/extractions.mjs +20 -0
- package/resources/extractions/extractions.mjs.map +1 -0
- package/resources/extractions/index.d.ts +5 -0
- package/resources/extractions/index.d.ts.map +1 -0
- package/resources/extractions/index.js +13 -0
- package/resources/extractions/index.js.map +1 -0
- package/resources/extractions/index.mjs +6 -0
- package/resources/extractions/index.mjs.map +1 -0
- package/resources/extractions/jobs.d.ts +44 -0
- package/resources/extractions/jobs.d.ts.map +1 -0
- package/resources/extractions/jobs.js +29 -0
- package/resources/extractions/jobs.js.map +1 -0
- package/resources/extractions/jobs.mjs +25 -0
- package/resources/extractions/jobs.mjs.map +1 -0
- package/resources/extractions/schema.d.ts +85 -0
- package/resources/extractions/schema.d.ts.map +1 -0
- package/resources/extractions/schema.js +39 -0
- package/resources/extractions/schema.js.map +1 -0
- package/resources/extractions/schema.mjs +35 -0
- package/resources/extractions/schema.mjs.map +1 -0
- package/resources/files.d.ts +125 -0
- package/resources/files.d.ts.map +1 -0
- package/resources/files.js +99 -0
- package/resources/files.js.map +1 -0
- package/resources/files.mjs +71 -0
- package/resources/files.mjs.map +1 -0
- package/resources/index.d.ts +7 -0
- package/resources/index.d.ts.map +1 -0
- package/resources/index.js +30 -0
- package/resources/index.js.map +1 -0
- package/resources/index.mjs +7 -0
- package/resources/index.mjs.map +1 -0
- package/resources/parsing/index.d.ts +3 -0
- package/resources/parsing/index.d.ts.map +1 -0
- package/resources/parsing/index.js +10 -0
- package/resources/parsing/index.js.map +1 -0
- package/resources/parsing/index.mjs +4 -0
- package/resources/parsing/index.mjs.map +1 -0
- package/resources/parsing/jobs.d.ts +278 -0
- package/resources/parsing/jobs.d.ts.map +1 -0
- package/resources/parsing/jobs.js +147 -0
- package/resources/parsing/jobs.js.map +1 -0
- package/resources/parsing/jobs.mjs +119 -0
- package/resources/parsing/jobs.mjs.map +1 -0
- package/resources/parsing/parsing.d.ts +10 -0
- package/resources/parsing/parsing.d.ts.map +1 -0
- package/resources/parsing/parsing.js +40 -0
- package/resources/parsing/parsing.js.map +1 -0
- package/resources/parsing/parsing.mjs +13 -0
- package/resources/parsing/parsing.mjs.map +1 -0
- package/resources/shared.d.ts +35 -0
- package/resources/shared.d.ts.map +1 -0
- package/resources/shared.js +4 -0
- package/resources/shared.js.map +1 -0
- package/resources/shared.mjs +3 -0
- package/resources/shared.mjs.map +1 -0
- package/resources/top-level.d.ts +11 -0
- package/resources/top-level.d.ts.map +1 -0
- package/resources/top-level.js +4 -0
- package/resources/top-level.js.map +1 -0
- package/resources/top-level.mjs +3 -0
- package/resources/top-level.mjs.map +1 -0
- package/resources/vector-stores/files.d.ts +280 -0
- package/resources/vector-stores/files.d.ts.map +1 -0
- package/resources/vector-stores/files.js +167 -0
- package/resources/vector-stores/files.js.map +1 -0
- package/resources/vector-stores/files.mjs +139 -0
- package/resources/vector-stores/files.mjs.map +1 -0
- package/resources/vector-stores/index.d.ts +3 -0
- package/resources/vector-stores/index.d.ts.map +1 -0
- package/resources/vector-stores/index.js +11 -0
- package/resources/vector-stores/index.js.map +1 -0
- package/resources/vector-stores/index.mjs +4 -0
- package/resources/vector-stores/index.mjs.map +1 -0
- package/resources/vector-stores/vector-stores.d.ts +400 -0
- package/resources/vector-stores/vector-stores.d.ts.map +1 -0
- package/resources/vector-stores/vector-stores.js +121 -0
- package/resources/vector-stores/vector-stores.js.map +1 -0
- package/resources/vector-stores/vector-stores.mjs +93 -0
- package/resources/vector-stores/vector-stores.mjs.map +1 -0
- package/shims/node.d.ts +30 -0
- package/shims/node.d.ts.map +1 -0
- package/shims/node.js +31 -0
- package/shims/node.js.map +1 -0
- package/shims/node.mjs +5 -0
- package/shims/node.mjs.map +1 -0
- package/shims/web.d.ts +26 -0
- package/shims/web.d.ts.map +1 -0
- package/shims/web.js +31 -0
- package/shims/web.js.map +1 -0
- package/shims/web.mjs +5 -0
- package/shims/web.mjs.map +1 -0
- package/src/_shims/MultipartBody.ts +9 -0
- package/src/_shims/README.md +46 -0
- package/src/_shims/auto/runtime-bun.ts +4 -0
- package/src/_shims/auto/runtime-node.ts +4 -0
- package/src/_shims/auto/runtime.ts +4 -0
- package/src/_shims/auto/types-node.ts +4 -0
- package/src/_shims/auto/types.d.ts +101 -0
- package/src/_shims/auto/types.js +3 -0
- package/src/_shims/auto/types.mjs +3 -0
- package/src/_shims/bun-runtime.ts +14 -0
- package/src/_shims/index.d.ts +81 -0
- package/src/_shims/index.js +13 -0
- package/src/_shims/index.mjs +7 -0
- package/src/_shims/manual-types.d.ts +12 -0
- package/src/_shims/manual-types.js +3 -0
- package/src/_shims/manual-types.mjs +3 -0
- package/src/_shims/node-runtime.ts +81 -0
- package/src/_shims/node-types.d.ts +42 -0
- package/src/_shims/node-types.js +3 -0
- package/src/_shims/node-types.mjs +3 -0
- package/src/_shims/registry.ts +67 -0
- package/src/_shims/web-runtime.ts +103 -0
- package/src/_shims/web-types.d.ts +83 -0
- package/src/_shims/web-types.js +3 -0
- package/src/_shims/web-types.mjs +3 -0
- package/src/core.ts +1208 -0
- package/src/error.ts +130 -0
- package/src/index.ts +294 -0
- package/src/lib/.keep +4 -0
- package/src/lib/polling.ts +115 -0
- package/src/pagination.ts +82 -0
- package/src/resource.ts +11 -0
- package/src/resources/extractions/content.ts +43 -0
- package/src/resources/extractions/extractions.ts +47 -0
- package/src/resources/extractions/index.ts +14 -0
- package/src/resources/extractions/jobs.ts +55 -0
- package/src/resources/extractions/schema.ts +111 -0
- package/src/resources/files.ts +181 -0
- package/src/resources/index.ts +32 -0
- package/src/resources/parsing/index.ts +12 -0
- package/src/resources/parsing/jobs.ts +438 -0
- package/src/resources/parsing/parsing.ts +32 -0
- package/src/resources/shared.ts +41 -0
- package/src/resources/top-level.ts +14 -0
- package/src/resources/vector-stores/files.ts +434 -0
- package/src/resources/vector-stores/index.ts +30 -0
- package/src/resources/vector-stores/vector-stores.ts +561 -0
- package/src/shims/node.ts +50 -0
- package/src/shims/web.ts +50 -0
- package/src/tsconfig.json +11 -0
- package/src/uploads.ts +255 -0
- package/src/version.ts +1 -0
- package/uploads.d.ts +75 -0
- package/uploads.d.ts.map +1 -0
- package/uploads.js +171 -0
- package/uploads.js.map +1 -0
- package/uploads.mjs +158 -0
- package/uploads.mjs.map +1 -0
- package/version.d.ts +2 -0
- package/version.d.ts.map +1 -0
- package/version.js +5 -0
- package/version.js.map +1 -0
- package/version.mjs +2 -0
- package/version.mjs.map +1 -0
@@ -0,0 +1,139 @@
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
2
|
+
import { APIResource } from "../../resource.mjs";
|
3
|
+
import { isRequestOptions } from "../../core.mjs";
|
4
|
+
import { LimitOffset } from "../../pagination.mjs";
|
5
|
+
import * as polling from "../../lib/polling.mjs";
|
6
|
+
export class Files extends APIResource {
|
7
|
+
/**
|
8
|
+
* Upload a new file to a vector store for indexing.
|
9
|
+
*
|
10
|
+
* Args: vector_store_id: The ID of the vector store to upload to file: The file to
|
11
|
+
* upload and index
|
12
|
+
*
|
13
|
+
* Returns: VectorStoreFile: Details of the uploaded and indexed file
|
14
|
+
*/
|
15
|
+
create(vectorStoreId, body, options) {
|
16
|
+
return this._client.post(`/v1/vector_stores/${vectorStoreId}/files`, { body, ...options });
|
17
|
+
}
|
18
|
+
/**
|
19
|
+
* Get details of a specific file in a vector store.
|
20
|
+
*
|
21
|
+
* Args: vector_store_id: The ID of the vector store file_id: The ID of the file
|
22
|
+
*
|
23
|
+
* Returns: VectorStoreFile: Details of the vector store file
|
24
|
+
*/
|
25
|
+
retrieve(vectorStoreId, fileId, options) {
|
26
|
+
return this._client.get(`/v1/vector_stores/${vectorStoreId}/files/${fileId}`, options);
|
27
|
+
}
|
28
|
+
list(vectorStoreId, query = {}, options) {
|
29
|
+
if (isRequestOptions(query)) {
|
30
|
+
return this.list(vectorStoreId, {}, query);
|
31
|
+
}
|
32
|
+
return this._client.getAPIList(`/v1/vector_stores/${vectorStoreId}/files`, VectorStoreFilesLimitOffset, {
|
33
|
+
query,
|
34
|
+
...options,
|
35
|
+
});
|
36
|
+
}
|
37
|
+
/**
|
38
|
+
* Delete a file from a vector store.
|
39
|
+
*
|
40
|
+
* Args: vector_store_id: The ID of the vector store file_id: The ID of the file to
|
41
|
+
* delete
|
42
|
+
*
|
43
|
+
* Returns: VectorStoreFileDeleted: The deleted file
|
44
|
+
*/
|
45
|
+
delete(vectorStoreId, fileId, options) {
|
46
|
+
return this._client.delete(`/v1/vector_stores/${vectorStoreId}/files/${fileId}`, options);
|
47
|
+
}
|
48
|
+
/**
|
49
|
+
* Perform semantic search across complete vector store files.
|
50
|
+
*
|
51
|
+
* This endpoint searches through vector store files using semantic similarity
|
52
|
+
* matching. Unlike chunk search, it returns complete matching files rather than
|
53
|
+
* individual chunks. Supports complex search queries with filters and returns
|
54
|
+
* relevance-scored results.
|
55
|
+
*
|
56
|
+
* Args: search_params: Search configuration including: - query text or
|
57
|
+
* embeddings - metadata filters - pagination parameters - sorting preferences
|
58
|
+
* \_state: API state dependency \_ctx: Service context dependency
|
59
|
+
*
|
60
|
+
* Returns: VectorStoreSearchFileResponse containing: - List of matched files with
|
61
|
+
* relevance scores - Pagination details including total result count
|
62
|
+
*
|
63
|
+
* Raises: HTTPException (400): If search parameters are invalid HTTPException
|
64
|
+
* (404): If no vector stores are found to search
|
65
|
+
*/
|
66
|
+
search(body, options) {
|
67
|
+
return this._client.post('/v1/vector_stores/files/search', { body, ...options });
|
68
|
+
}
|
69
|
+
/**
|
70
|
+
* Poll for a file's processing status until it reaches a terminal state.
|
71
|
+
*
|
72
|
+
* @param vectorStoreId - The ID of the vector store
|
73
|
+
* @param fileId - The ID of the file to poll
|
74
|
+
* @param pollIntervalMs - The interval between polls in milliseconds (default: 500)
|
75
|
+
* @param pollTimeoutMs - The maximum time to poll for in milliseconds (default: no timeout)
|
76
|
+
* @param options - Additional request options
|
77
|
+
* @returns The file object once it reaches a terminal state
|
78
|
+
*/
|
79
|
+
async poll(vectorStoreId, fileId, pollIntervalMs, pollTimeoutMs, options) {
|
80
|
+
const pollingIntervalMs = pollIntervalMs || 500;
|
81
|
+
const pollingTimeoutMs = pollTimeoutMs;
|
82
|
+
return polling.poll({
|
83
|
+
fn: () => this.retrieve(vectorStoreId, fileId, options),
|
84
|
+
condition: (result) => result.status === 'completed' || result.status === 'failed' || result.status === 'error',
|
85
|
+
intervalSeconds: pollingIntervalMs / 1000,
|
86
|
+
...(pollingTimeoutMs && { timeoutSeconds: pollingTimeoutMs / 1000 }),
|
87
|
+
});
|
88
|
+
}
|
89
|
+
/**
|
90
|
+
* Create a file in a vector store and wait for it to be processed.
|
91
|
+
*
|
92
|
+
* @param vectorStoreId - The ID of the vector store to upload to
|
93
|
+
* @param body - The file creation parameters
|
94
|
+
* @param pollIntervalMs - The interval between polls in milliseconds (default: 500)
|
95
|
+
* @param pollTimeoutMs - The maximum time to poll for in milliseconds (default: no timeout)
|
96
|
+
* @param options - Additional request options
|
97
|
+
* @returns The file object once it reaches a terminal state
|
98
|
+
*/
|
99
|
+
async createAndPoll(vectorStoreId, body, pollIntervalMs, pollTimeoutMs, options) {
|
100
|
+
const file = await this.create(vectorStoreId, body, options);
|
101
|
+
return this.poll(vectorStoreId, file.id, pollIntervalMs, pollTimeoutMs, options);
|
102
|
+
}
|
103
|
+
/**
|
104
|
+
* Upload a file to the files API and then create a file in a vector store.
|
105
|
+
* Note the file will be asynchronously processed.
|
106
|
+
*
|
107
|
+
* @param vectorStoreId - The ID of the vector store to add the file to
|
108
|
+
* @param file - The file to upload
|
109
|
+
* @param body - Additional parameters for the vector store file
|
110
|
+
* @param options - Additional request options
|
111
|
+
* @returns The created vector store file
|
112
|
+
*/
|
113
|
+
async upload(vectorStoreId, file, body, options) {
|
114
|
+
const fileUploadResponse = await this._client.files.create({ file }, options);
|
115
|
+
return this.create(vectorStoreId, {
|
116
|
+
file_id: fileUploadResponse.id,
|
117
|
+
...body,
|
118
|
+
}, options);
|
119
|
+
}
|
120
|
+
/**
|
121
|
+
* Upload a file to files API, create a file in a vector store, and poll until processing is complete.
|
122
|
+
*
|
123
|
+
* @param vectorStoreId - The ID of the vector store to add the file to
|
124
|
+
* @param file - The file to upload
|
125
|
+
* @param body - Additional parameters for the vector store file
|
126
|
+
* @param pollIntervalMs - The interval between polls in milliseconds (default: 500)
|
127
|
+
* @param pollTimeoutMs - The maximum time to poll for in milliseconds (default: no timeout)
|
128
|
+
* @param options - Additional request options
|
129
|
+
* @returns The vector store file object once it reaches a terminal state
|
130
|
+
*/
|
131
|
+
async uploadAndPoll(vectorStoreId, file, body, pollIntervalMs, pollTimeoutMs, options) {
|
132
|
+
const vectorStoreFile = await this.upload(vectorStoreId, file, body, options);
|
133
|
+
return this.poll(vectorStoreId, vectorStoreFile.id, pollIntervalMs, pollTimeoutMs, options);
|
134
|
+
}
|
135
|
+
}
|
136
|
+
export class VectorStoreFilesLimitOffset extends LimitOffset {
|
137
|
+
}
|
138
|
+
Files.VectorStoreFilesLimitOffset = VectorStoreFilesLimitOffset;
|
139
|
+
//# sourceMappingURL=files.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version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AE,IAAI,EAAE,EAAE,OAAO,CAAC,CAAC;QAE9E,OAAO,IAAI,CAAC,MAAM,CAChB,aAAa,EACb;YACE,OAAO,EAAE,kBAAkB,CAAC,EAAE;YAC9B,GAAG,IAAI;SACR,EACD,OAAO,CACR,CAAC;IACJ,CAAC;IAED;;;;;;;;;;OAUG;IACH,KAAK,CAAC,aAAa,CACjB,aAAqB,EACrB,IAAgB,EAChB,IAAwC,EACxC,cAAuB,EACvB,aAAsB,EACtB,OAA6B;QAE7B,MAAM,eAAe,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,aAAa,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;QAC9E,OAAO,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,eAAe,CAAC,EAAE,EAAE,cAAc,EAAE,aAAa,EAAE,OAAO,CAAC,CAAC;IAC9F,CAAC;CACF;AAED,MAAM,OAAO,2BAA4B,SAAQ,WAA4B;CAAG;AA8MhF,KAAK,CAAC,2BAA2B,GAAG,2BAA2B,CAAC"}
|
@@ -0,0 +1,3 @@
|
|
1
|
+
export { VectorStoreFilesLimitOffset, Files, type ScoredVectorStoreFile, type VectorStoreFile, type FileDeleteResponse, type FileSearchResponse, type FileCreateParams, type FileListParams, type FileSearchParams, } from "./files.js";
|
2
|
+
export { VectorStoresLimitOffset, VectorStores, type ExpiresAfter, type FileCounts, type ScoredVectorStoreChunk, type VectorStore, type VectorStoreSearchOptions, type VectorStoreDeleteResponse, type VectorStoreQuestionAnsweringResponse, type VectorStoreSearchResponse, type VectorStoreCreateParams, type VectorStoreUpdateParams, type VectorStoreListParams, type VectorStoreQuestionAnsweringParams, type VectorStoreSearchParams, } from "./vector-stores.js";
|
3
|
+
//# sourceMappingURL=index.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/vector-stores/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,2BAA2B,EAC3B,KAAK,EACL,KAAK,qBAAqB,EAC1B,KAAK,eAAe,EACpB,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,gBAAgB,GACtB,MAAM,SAAS,CAAC;AACjB,OAAO,EACL,uBAAuB,EACvB,YAAY,EACZ,KAAK,YAAY,EACjB,KAAK,UAAU,EACf,KAAK,sBAAsB,EAC3B,KAAK,WAAW,EAChB,KAAK,wBAAwB,EAC7B,KAAK,yBAAyB,EAC9B,KAAK,oCAAoC,EACzC,KAAK,yBAAyB,EAC9B,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC5B,KAAK,qBAAqB,EAC1B,KAAK,kCAAkC,EACvC,KAAK,uBAAuB,GAC7B,MAAM,iBAAiB,CAAC"}
|
@@ -0,0 +1,11 @@
|
|
1
|
+
"use strict";
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
4
|
+
exports.VectorStores = exports.VectorStoresLimitOffset = exports.Files = exports.VectorStoreFilesLimitOffset = void 0;
|
5
|
+
var files_1 = require("./files.js");
|
6
|
+
Object.defineProperty(exports, "VectorStoreFilesLimitOffset", { enumerable: true, get: function () { return files_1.VectorStoreFilesLimitOffset; } });
|
7
|
+
Object.defineProperty(exports, "Files", { enumerable: true, get: function () { return files_1.Files; } });
|
8
|
+
var vector_stores_1 = require("./vector-stores.js");
|
9
|
+
Object.defineProperty(exports, "VectorStoresLimitOffset", { enumerable: true, get: function () { return vector_stores_1.VectorStoresLimitOffset; } });
|
10
|
+
Object.defineProperty(exports, "VectorStores", { enumerable: true, get: function () { return vector_stores_1.VectorStores; } });
|
11
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/vector-stores/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,oCAUiB;AATf,oHAAA,2BAA2B,OAAA;AAC3B,8FAAA,KAAK,OAAA;AASP,oDAgByB;AAfvB,wHAAA,uBAAuB,OAAA;AACvB,6GAAA,YAAY,OAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/vector-stores/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,2BAA2B,EAC3B,KAAK,GAQN;OACM,EACL,uBAAuB,EACvB,YAAY,GAcb"}
|
@@ -0,0 +1,400 @@
|
|
1
|
+
import { APIResource } from "../../resource.js";
|
2
|
+
import * as Core from "../../core.js";
|
3
|
+
import * as Shared from "../shared.js";
|
4
|
+
import * as FilesAPI from "./files.js";
|
5
|
+
import { FileCreateParams, FileDeleteResponse, FileListParams, FileSearchParams, FileSearchResponse, Files, ScoredVectorStoreFile, VectorStoreFile, VectorStoreFilesLimitOffset } from "./files.js";
|
6
|
+
import { LimitOffset, type LimitOffsetParams } from "../../pagination.js";
|
7
|
+
export declare class VectorStores extends APIResource {
|
8
|
+
files: FilesAPI.Files;
|
9
|
+
/**
|
10
|
+
* Create a new vector store.
|
11
|
+
*
|
12
|
+
* Args: vector_store_create: VectorStoreCreate object containing the name,
|
13
|
+
* description, and metadata.
|
14
|
+
*
|
15
|
+
* Returns: VectorStore: The response containing the created vector store details.
|
16
|
+
*/
|
17
|
+
create(body: VectorStoreCreateParams, options?: Core.RequestOptions): Core.APIPromise<VectorStore>;
|
18
|
+
/**
|
19
|
+
* Get a vector store by ID.
|
20
|
+
*
|
21
|
+
* Args: vector_store_id: The ID of the vector store to retrieve.
|
22
|
+
*
|
23
|
+
* Returns: VectorStore: The response containing the vector store details.
|
24
|
+
*/
|
25
|
+
retrieve(vectorStoreId: string, options?: Core.RequestOptions): Core.APIPromise<VectorStore>;
|
26
|
+
/**
|
27
|
+
* Update a vector store by ID.
|
28
|
+
*
|
29
|
+
* Args: vector_store_id: The ID of the vector store to update.
|
30
|
+
* vector_store_update: VectorStoreCreate object containing the name, description,
|
31
|
+
* and metadata.
|
32
|
+
*
|
33
|
+
* Returns: VectorStore: The response containing the updated vector store details.
|
34
|
+
*/
|
35
|
+
update(vectorStoreId: string, body: VectorStoreUpdateParams, options?: Core.RequestOptions): Core.APIPromise<VectorStore>;
|
36
|
+
/**
|
37
|
+
* List all vector stores.
|
38
|
+
*
|
39
|
+
* Args: pagination: The pagination options.
|
40
|
+
*
|
41
|
+
* Returns: VectorStoreListResponse: The list of vector stores.
|
42
|
+
*/
|
43
|
+
list(query?: VectorStoreListParams, options?: Core.RequestOptions): Core.PagePromise<VectorStoresLimitOffset, VectorStore>;
|
44
|
+
list(options?: Core.RequestOptions): Core.PagePromise<VectorStoresLimitOffset, VectorStore>;
|
45
|
+
/**
|
46
|
+
* Delete a vector store by ID.
|
47
|
+
*
|
48
|
+
* Args: vector_store_id: The ID of the vector store to delete.
|
49
|
+
*
|
50
|
+
* Returns: VectorStore: The response containing the deleted vector store details.
|
51
|
+
*/
|
52
|
+
delete(vectorStoreId: string, options?: Core.RequestOptions): Core.APIPromise<VectorStoreDeleteResponse>;
|
53
|
+
/**
|
54
|
+
* Question answering
|
55
|
+
*/
|
56
|
+
questionAnswering(body: VectorStoreQuestionAnsweringParams, options?: Core.RequestOptions): Core.APIPromise<unknown>;
|
57
|
+
/**
|
58
|
+
* Perform semantic search across vector store chunks.
|
59
|
+
*
|
60
|
+
* This endpoint searches through vector store chunks using semantic similarity
|
61
|
+
* matching. It supports complex search queries with filters and returns
|
62
|
+
* relevance-scored results.
|
63
|
+
*
|
64
|
+
* Args: search_params: Search configuration including: - query text or
|
65
|
+
* embeddings - metadata filters - pagination parameters - sorting preferences
|
66
|
+
* \_state: API state dependency \_ctx: Service context dependency
|
67
|
+
*
|
68
|
+
* Returns: VectorStoreSearchChunkResponse containing: - List of matched chunks
|
69
|
+
* with relevance scores - Pagination details including total result count
|
70
|
+
*
|
71
|
+
* Raises: HTTPException (400): If search parameters are invalid HTTPException
|
72
|
+
* (404): If no vector stores are found to search
|
73
|
+
*/
|
74
|
+
search(body: VectorStoreSearchParams, options?: Core.RequestOptions): Core.APIPromise<VectorStoreSearchResponse>;
|
75
|
+
}
|
76
|
+
export declare class VectorStoresLimitOffset extends LimitOffset<VectorStore> {
|
77
|
+
}
|
78
|
+
/**
|
79
|
+
* Represents an expiration policy for a vector store.
|
80
|
+
*/
|
81
|
+
export interface ExpiresAfter {
|
82
|
+
/**
|
83
|
+
* Anchor date for the expiration policy
|
84
|
+
*/
|
85
|
+
anchor?: 'last_active_at';
|
86
|
+
/**
|
87
|
+
* Number of days after which the vector store expires
|
88
|
+
*/
|
89
|
+
days?: number;
|
90
|
+
}
|
91
|
+
/**
|
92
|
+
* Tracks counts of files in different states within a vector store.
|
93
|
+
*/
|
94
|
+
export interface FileCounts {
|
95
|
+
/**
|
96
|
+
* Number of files currently being processed
|
97
|
+
*/
|
98
|
+
in_progress?: number;
|
99
|
+
/**
|
100
|
+
* Number of files whose processing was cancelled
|
101
|
+
*/
|
102
|
+
cancelled?: number;
|
103
|
+
/**
|
104
|
+
* Number of successfully processed files
|
105
|
+
*/
|
106
|
+
completed?: number;
|
107
|
+
/**
|
108
|
+
* Number of files that failed processing
|
109
|
+
*/
|
110
|
+
failed?: number;
|
111
|
+
/**
|
112
|
+
* Total number of files
|
113
|
+
*/
|
114
|
+
total?: number;
|
115
|
+
}
|
116
|
+
export interface ScoredVectorStoreChunk {
|
117
|
+
/**
|
118
|
+
* position of the chunk in a file
|
119
|
+
*/
|
120
|
+
position: number;
|
121
|
+
/**
|
122
|
+
* value of the chunk
|
123
|
+
*/
|
124
|
+
value?: string | ScoredVectorStoreChunk.ImageURLInput | ScoredVectorStoreChunk.TextInput | Record<string, unknown> | null;
|
125
|
+
/**
|
126
|
+
* content of the chunk
|
127
|
+
*/
|
128
|
+
content?: string | null;
|
129
|
+
/**
|
130
|
+
* score of the chunk
|
131
|
+
*/
|
132
|
+
score: number;
|
133
|
+
/**
|
134
|
+
* file id
|
135
|
+
*/
|
136
|
+
file_id: string;
|
137
|
+
/**
|
138
|
+
* vector store id
|
139
|
+
*/
|
140
|
+
vector_store_id: string;
|
141
|
+
/**
|
142
|
+
* file metadata
|
143
|
+
*/
|
144
|
+
metadata?: unknown;
|
145
|
+
}
|
146
|
+
export declare namespace ScoredVectorStoreChunk {
|
147
|
+
/**
|
148
|
+
* Model for image input validation.
|
149
|
+
*/
|
150
|
+
interface ImageURLInput {
|
151
|
+
/**
|
152
|
+
* Input type identifier
|
153
|
+
*/
|
154
|
+
type?: 'image_url';
|
155
|
+
/**
|
156
|
+
* The image input specification.
|
157
|
+
*/
|
158
|
+
image: ImageURLInput.Image;
|
159
|
+
}
|
160
|
+
namespace ImageURLInput {
|
161
|
+
/**
|
162
|
+
* The image input specification.
|
163
|
+
*/
|
164
|
+
interface Image {
|
165
|
+
/**
|
166
|
+
* The image URL. Can be either a URL or a Data URI.
|
167
|
+
*/
|
168
|
+
url: string;
|
169
|
+
}
|
170
|
+
}
|
171
|
+
/**
|
172
|
+
* Model for text input validation.
|
173
|
+
*
|
174
|
+
* Attributes: type: Input type identifier, always "text" text: The actual text
|
175
|
+
* content, with length and whitespace constraints
|
176
|
+
*/
|
177
|
+
interface TextInput {
|
178
|
+
/**
|
179
|
+
* Input type identifier
|
180
|
+
*/
|
181
|
+
type?: 'text';
|
182
|
+
/**
|
183
|
+
* Text content to process
|
184
|
+
*/
|
185
|
+
text: string;
|
186
|
+
}
|
187
|
+
}
|
188
|
+
/**
|
189
|
+
* Model representing a vector store with its metadata and timestamps.
|
190
|
+
*/
|
191
|
+
export interface VectorStore {
|
192
|
+
/**
|
193
|
+
* Unique identifier for the vector store
|
194
|
+
*/
|
195
|
+
id: string;
|
196
|
+
/**
|
197
|
+
* Name of the vector store
|
198
|
+
*/
|
199
|
+
name: string;
|
200
|
+
/**
|
201
|
+
* Detailed description of the vector store's purpose and contents
|
202
|
+
*/
|
203
|
+
description?: string | null;
|
204
|
+
/**
|
205
|
+
* Additional metadata associated with the vector store
|
206
|
+
*/
|
207
|
+
metadata?: unknown;
|
208
|
+
/**
|
209
|
+
* Counts of files in different states
|
210
|
+
*/
|
211
|
+
file_counts?: FileCounts;
|
212
|
+
/**
|
213
|
+
* Represents an expiration policy for a vector store.
|
214
|
+
*/
|
215
|
+
expires_after?: ExpiresAfter | null;
|
216
|
+
/**
|
217
|
+
* Processing status of the vector store
|
218
|
+
*/
|
219
|
+
status?: 'expired' | 'in_progress' | 'completed';
|
220
|
+
/**
|
221
|
+
* Timestamp when the vector store was created
|
222
|
+
*/
|
223
|
+
created_at: string;
|
224
|
+
/**
|
225
|
+
* Timestamp when the vector store was last updated
|
226
|
+
*/
|
227
|
+
updated_at: string;
|
228
|
+
/**
|
229
|
+
* Timestamp when the vector store was last used
|
230
|
+
*/
|
231
|
+
last_active_at?: string | null;
|
232
|
+
/**
|
233
|
+
* Optional expiration timestamp for the vector store
|
234
|
+
*/
|
235
|
+
expires_at?: string | null;
|
236
|
+
/**
|
237
|
+
* Type of the object
|
238
|
+
*/
|
239
|
+
object?: 'vector_store';
|
240
|
+
}
|
241
|
+
/**
|
242
|
+
* Options for configuring vector store searches.
|
243
|
+
*/
|
244
|
+
export interface VectorStoreSearchOptions {
|
245
|
+
/**
|
246
|
+
* Whether to return file metadata
|
247
|
+
*/
|
248
|
+
return_metadata?: boolean;
|
249
|
+
/**
|
250
|
+
* Whether to return matching text chunks
|
251
|
+
*/
|
252
|
+
return_chunks?: boolean;
|
253
|
+
/**
|
254
|
+
* Minimum similarity score threshold
|
255
|
+
*/
|
256
|
+
score_threshold?: number;
|
257
|
+
/**
|
258
|
+
* Whether to rewrite the query
|
259
|
+
*/
|
260
|
+
rewrite_query?: boolean;
|
261
|
+
}
|
262
|
+
/**
|
263
|
+
* Response model for vector store deletion.
|
264
|
+
*/
|
265
|
+
export interface VectorStoreDeleteResponse {
|
266
|
+
/**
|
267
|
+
* ID of the deleted vector store
|
268
|
+
*/
|
269
|
+
id: string;
|
270
|
+
/**
|
271
|
+
* Whether the deletion was successful
|
272
|
+
*/
|
273
|
+
deleted: boolean;
|
274
|
+
/**
|
275
|
+
* Type of the deleted object
|
276
|
+
*/
|
277
|
+
object?: 'vector_store';
|
278
|
+
}
|
279
|
+
export type VectorStoreQuestionAnsweringResponse = unknown;
|
280
|
+
export interface VectorStoreSearchResponse {
|
281
|
+
/**
|
282
|
+
* The object type of the response
|
283
|
+
*/
|
284
|
+
object?: 'list';
|
285
|
+
/**
|
286
|
+
* The list of scored vector store file chunks
|
287
|
+
*/
|
288
|
+
data: Array<ScoredVectorStoreChunk>;
|
289
|
+
}
|
290
|
+
export interface VectorStoreCreateParams {
|
291
|
+
/**
|
292
|
+
* Name for the new vector store
|
293
|
+
*/
|
294
|
+
name?: string | null;
|
295
|
+
/**
|
296
|
+
* Description of the vector store
|
297
|
+
*/
|
298
|
+
description?: string | null;
|
299
|
+
/**
|
300
|
+
* Represents an expiration policy for a vector store.
|
301
|
+
*/
|
302
|
+
expires_after?: ExpiresAfter | null;
|
303
|
+
/**
|
304
|
+
* Optional metadata key-value pairs
|
305
|
+
*/
|
306
|
+
metadata?: unknown;
|
307
|
+
/**
|
308
|
+
* Optional list of file IDs
|
309
|
+
*/
|
310
|
+
file_ids?: Array<string> | null;
|
311
|
+
}
|
312
|
+
export interface VectorStoreUpdateParams {
|
313
|
+
/**
|
314
|
+
* New name for the vector store
|
315
|
+
*/
|
316
|
+
name?: string | null;
|
317
|
+
/**
|
318
|
+
* New description
|
319
|
+
*/
|
320
|
+
description?: string | null;
|
321
|
+
/**
|
322
|
+
* Represents an expiration policy for a vector store.
|
323
|
+
*/
|
324
|
+
expires_after?: ExpiresAfter | null;
|
325
|
+
/**
|
326
|
+
* Optional metadata key-value pairs
|
327
|
+
*/
|
328
|
+
metadata?: unknown;
|
329
|
+
}
|
330
|
+
export interface VectorStoreListParams extends LimitOffsetParams {
|
331
|
+
}
|
332
|
+
export interface VectorStoreQuestionAnsweringParams {
|
333
|
+
/**
|
334
|
+
* Question to answer. If not provided, the question will be extracted from the
|
335
|
+
* passed messages.
|
336
|
+
*/
|
337
|
+
query?: string;
|
338
|
+
/**
|
339
|
+
* IDs of vector stores to search
|
340
|
+
*/
|
341
|
+
vector_store_ids: Array<string>;
|
342
|
+
/**
|
343
|
+
* Number of results to return
|
344
|
+
*/
|
345
|
+
top_k?: number;
|
346
|
+
/**
|
347
|
+
* Optional filter conditions
|
348
|
+
*/
|
349
|
+
filters?: Shared.SearchFilter | Shared.SearchFilterCondition | Array<Shared.SearchFilter | Shared.SearchFilterCondition> | null;
|
350
|
+
/**
|
351
|
+
* Search configuration options
|
352
|
+
*/
|
353
|
+
search_options?: VectorStoreSearchOptions;
|
354
|
+
/**
|
355
|
+
* Whether to stream the answer
|
356
|
+
*/
|
357
|
+
stream?: boolean;
|
358
|
+
/**
|
359
|
+
* Question answering configuration options
|
360
|
+
*/
|
361
|
+
qa_options?: VectorStoreQuestionAnsweringParams.QaOptions;
|
362
|
+
}
|
363
|
+
export declare namespace VectorStoreQuestionAnsweringParams {
|
364
|
+
/**
|
365
|
+
* Question answering configuration options
|
366
|
+
*/
|
367
|
+
interface QaOptions {
|
368
|
+
/**
|
369
|
+
* Whether to use citations
|
370
|
+
*/
|
371
|
+
cite?: boolean;
|
372
|
+
}
|
373
|
+
}
|
374
|
+
export interface VectorStoreSearchParams {
|
375
|
+
/**
|
376
|
+
* Search query text
|
377
|
+
*/
|
378
|
+
query: string;
|
379
|
+
/**
|
380
|
+
* IDs of vector stores to search
|
381
|
+
*/
|
382
|
+
vector_store_ids: Array<string>;
|
383
|
+
/**
|
384
|
+
* Number of results to return
|
385
|
+
*/
|
386
|
+
top_k?: number;
|
387
|
+
/**
|
388
|
+
* Optional filter conditions
|
389
|
+
*/
|
390
|
+
filters?: Shared.SearchFilter | Shared.SearchFilterCondition | Array<Shared.SearchFilter | Shared.SearchFilterCondition> | null;
|
391
|
+
/**
|
392
|
+
* Search configuration options
|
393
|
+
*/
|
394
|
+
search_options?: VectorStoreSearchOptions;
|
395
|
+
}
|
396
|
+
export declare namespace VectorStores {
|
397
|
+
export { type ExpiresAfter as ExpiresAfter, type FileCounts as FileCounts, type ScoredVectorStoreChunk as ScoredVectorStoreChunk, type VectorStore as VectorStore, type VectorStoreSearchOptions as VectorStoreSearchOptions, type VectorStoreDeleteResponse as VectorStoreDeleteResponse, type VectorStoreQuestionAnsweringResponse as VectorStoreQuestionAnsweringResponse, type VectorStoreSearchResponse as VectorStoreSearchResponse, VectorStoresLimitOffset as VectorStoresLimitOffset, type VectorStoreCreateParams as VectorStoreCreateParams, type VectorStoreUpdateParams as VectorStoreUpdateParams, type VectorStoreListParams as VectorStoreListParams, type VectorStoreQuestionAnsweringParams as VectorStoreQuestionAnsweringParams, type VectorStoreSearchParams as VectorStoreSearchParams, };
|
398
|
+
export { Files as Files, type ScoredVectorStoreFile as ScoredVectorStoreFile, type VectorStoreFile as VectorStoreFile, type FileDeleteResponse as FileDeleteResponse, type FileSearchResponse as FileSearchResponse, VectorStoreFilesLimitOffset as VectorStoreFilesLimitOffset, type FileCreateParams as FileCreateParams, type FileListParams as FileListParams, type FileSearchParams as FileSearchParams, };
|
399
|
+
}
|
400
|
+
//# sourceMappingURL=vector-stores.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"vector-stores.d.ts","sourceRoot":"","sources":["../../src/resources/vector-stores/vector-stores.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,OAAO,KAAK,IAAI,MAAM,YAAY,CAAC;AACnC,OAAO,KAAK,MAAM,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,QAAQ,MAAM,SAAS,CAAC;AACpC,OAAO,EACL,gBAAgB,EAChB,kBAAkB,EAClB,cAAc,EACd,gBAAgB,EAChB,kBAAkB,EAClB,KAAK,EACL,qBAAqB,EACrB,eAAe,EACf,2BAA2B,EAC5B,MAAM,SAAS,CAAC;AACjB,OA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