Share via


VectorStore Class

Definition

Represents a vector store which contains collections of records.

public ref class VectorStore abstract : IDisposable
public abstract class VectorStore : IDisposable
type VectorStore = class
    interface IDisposable
Public MustInherit Class VectorStore
Implements IDisposable
Inheritance
VectorStore
Implements

Remarks

This type can be used with collections of any schema type, but requires you to provide schema information when getting a collection.

Unless otherwise documented, implementations of this abstract base class can be expected to be thread-safe, and can be used concurrently from multiple threads.

Constructors

VectorStore()

Methods

CollectionExistsAsync(String, CancellationToken)

Checks if the collection exists in the vector store.

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

Dispose(Boolean)

Disposes the VectorStore and releases any resources it holds.

EnsureCollectionDeletedAsync(String, CancellationToken)

Deletes the collection from the vector store.

GetCollection<TKey,TRecord>(String, VectorStoreCollectionDefinition)

Gets a collection from the vector store.

GetDynamicCollection(String, VectorStoreCollectionDefinition)

Gets a collection from the vector store, using dynamic mapping; the record type is represented as a Dictionary<TKey,TValue>.

GetService(Type, Object)

Asks the VectorStore for an object of the specified type serviceType.

ListCollectionNamesAsync(CancellationToken)

Retrieves the names of all the collections in the vector store.

Extension Methods

GetRequiredService<TRecord>(VectorStore, Type, Object)

Asks the VectorStore for an object of the specified type serviceType and throw an exception if one isn't available.

Applies to