Share via


SqliteServiceCollectionExtensions.AddSqliteVectorStoreRecordCollection Method

Definition

Overloads

AddSqliteVectorStoreRecordCollection<TKey,TRecord>(IServiceCollection, String, SqliteVectorStoreRecordCollectionOptions<TRecord>, String)

Register a SQLite Microsoft.Extensions.VectorData.IVectorStoreRecordCollection`2 and Microsoft.Extensions.VectorData.IVectorizedSearch`1 with the specified service ID and where the SQLite SqliteConnection is retrieved from the dependency injection container. In this case vector search extension loading should be handled manually.

AddSqliteVectorStoreRecordCollection<TKey,TRecord>(IServiceCollection, String, String, SqliteVectorStoreRecordCollectionOptions<TRecord>, String)

Register a SQLite Microsoft.Extensions.VectorData.IVectorStoreRecordCollection`2 and Microsoft.Extensions.VectorData.IVectorizedSearch`1 with the specified service ID. SqliteConnection instance will be initialized, connection will be opened and vector search extension with be loaded.

AddSqliteVectorStoreRecordCollection<TKey,TRecord>(IServiceCollection, String, SqliteVectorStoreRecordCollectionOptions<TRecord>, String)

Register a SQLite Microsoft.Extensions.VectorData.IVectorStoreRecordCollection`2 and Microsoft.Extensions.VectorData.IVectorizedSearch`1 with the specified service ID and where the SQLite SqliteConnection is retrieved from the dependency injection container. In this case vector search extension loading should be handled manually.

public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddSqliteVectorStoreRecordCollection<TKey,TRecord>(this Microsoft.Extensions.DependencyInjection.IServiceCollection services, string collectionName, Microsoft.SemanticKernel.Connectors.Sqlite.SqliteVectorStoreRecordCollectionOptions<TRecord>? options = default, string? serviceId = default);
static member AddSqliteVectorStoreRecordCollection : Microsoft.Extensions.DependencyInjection.IServiceCollection * string * Microsoft.SemanticKernel.Connectors.Sqlite.SqliteVectorStoreRecordCollectionOptions<'Record> * string -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddSqliteVectorStoreRecordCollection(Of TKey, TRecord) (services As IServiceCollection, collectionName As String, Optional options As SqliteVectorStoreRecordCollectionOptions(Of TRecord) = Nothing, Optional serviceId As String = Nothing) As IServiceCollection

Type Parameters

TKey

The type of the key.

TRecord

The type of the record.

Parameters

services
IServiceCollection

The IServiceCollection to register the Microsoft.Extensions.VectorData.IVectorStoreRecordCollection`2 on.

collectionName
String

The name of the collection.

options
SqliteVectorStoreRecordCollectionOptions<TRecord>

Optional options to further configure the Microsoft.Extensions.VectorData.IVectorStoreRecordCollection`2.

serviceId
String

An optional service id to use as the service key.

Returns

Service collection.

Applies to

AddSqliteVectorStoreRecordCollection<TKey,TRecord>(IServiceCollection, String, String, SqliteVectorStoreRecordCollectionOptions<TRecord>, String)

Register a SQLite Microsoft.Extensions.VectorData.IVectorStoreRecordCollection`2 and Microsoft.Extensions.VectorData.IVectorizedSearch`1 with the specified service ID. SqliteConnection instance will be initialized, connection will be opened and vector search extension with be loaded.

public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddSqliteVectorStoreRecordCollection<TKey,TRecord>(this Microsoft.Extensions.DependencyInjection.IServiceCollection services, string collectionName, string connectionString, Microsoft.SemanticKernel.Connectors.Sqlite.SqliteVectorStoreRecordCollectionOptions<TRecord>? options = default, string? serviceId = default);
static member AddSqliteVectorStoreRecordCollection : Microsoft.Extensions.DependencyInjection.IServiceCollection * string * string * Microsoft.SemanticKernel.Connectors.Sqlite.SqliteVectorStoreRecordCollectionOptions<'Record> * string -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddSqliteVectorStoreRecordCollection(Of TKey, TRecord) (services As IServiceCollection, collectionName As String, connectionString As String, Optional options As SqliteVectorStoreRecordCollectionOptions(Of TRecord) = Nothing, Optional serviceId As String = Nothing) As IServiceCollection

Type Parameters

TKey

The type of the key.

TRecord

The type of the record.

Parameters

services
IServiceCollection

The IServiceCollection to register the Microsoft.Extensions.VectorData.IVectorStoreRecordCollection`2 on.

collectionName
String

The name of the collection.

connectionString
String

Connection string for SqliteConnection.

options
SqliteVectorStoreRecordCollectionOptions<TRecord>

Optional options to further configure the Microsoft.Extensions.VectorData.IVectorStoreRecordCollection`2.

serviceId
String

An optional service id to use as the service key.

Returns

Service collection.

Applies to