VectorStores
interface VectorStores
Vector stores are used to store files for use by the file_search tool.
Inheritors
Functions
Link copied to clipboard
abstract suspend fun cancel(vectorStoreId: VectorStoreId, batchId: BatchId, requestOptions: RequestOptions? = null): FilesBatch?
Cancel a vector store file batch. This attempts to cancel the processing of files in this batch as soon as possible.
Link copied to clipboard
abstract suspend fun createVectorStore(request: VectorStoreRequest? = null, requestOptions: RequestOptions? = null): VectorStore
Create a new vector store.
Link copied to clipboard
abstract suspend fun createVectorStoreFile(id: VectorStoreId, request: VectorStoreFileRequest, requestOptions: RequestOptions? = null): VectorStoreFile
Create a vector store file by attaching a File to a vector store.
Link copied to clipboard
abstract suspend fun createVectorStoreFilesBatch(id: VectorStoreId, request: FileBatchRequest, requestOptions: RequestOptions? = null): FilesBatch
Create a batch of vector store files.
Link copied to clipboard
Delete a vector store.
abstract suspend fun delete(id: VectorStoreId, fileId: FileId, requestOptions: RequestOptions? = null): Boolean
Delete a vector store file. This will remove the file from the vector store, but the file itself will not be deleted. To delete the file, OpenAI.delete(fileId).
Link copied to clipboard
abstract suspend fun updateVectorStore(id: VectorStoreId, request: VectorStoreRequest, requestOptions: RequestOptions? = null): VectorStore
Update a vector store.
Link copied to clipboard
abstract suspend fun vectorStore(id: VectorStoreId, requestOptions: RequestOptions? = null): VectorStore?
Retrieve a vector store.
Link copied to clipboard
abstract suspend fun vectorStoreFileBatch(vectorStoreId: VectorStoreId, batchId: BatchId, requestOptions: RequestOptions? = null): FilesBatch?
Retrieves a vector store file batch.
Link copied to clipboard
abstract suspend fun vectorStoreFiles(id: VectorStoreId, limit: Int? = null, order: SortOrder? = null, after: VectorStoreId? = null, before: VectorStoreId? = null, filter: Status? = null, requestOptions: RequestOptions? = null): List<VectorStoreFile>
Returns a list of vector store files.
Link copied to clipboard
abstract suspend fun vectorStoreFilesBatches(vectorStoreId: VectorStoreId, batchId: BatchId, limit: Int? = null, order: SortOrder? = null, after: VectorStoreId? = null, before: VectorStoreId? = null, filter: Status? = null, requestOptions: RequestOptions? = null): List<VectorStoreFile>
Returns a list of vector store files in a batch.
Link copied to clipboard
abstract suspend fun vectorStores(limit: Int? = null, order: SortOrder? = null, after: VectorStoreId? = null, before: VectorStoreId? = null, requestOptions: RequestOptions? = null): List<VectorStore>
List all vector stores.