How do you use the SqliteVectorStore in Semantic Kernel?
I have managed to get some basic RAG working with semantic kernel in C#, by creating a VectorStoreTextSearch
object based on an InMemoryVectorStoreRecordCollection
inside a InMemoryVectorStore
and creating a KernelPlugin
using CreateWithGetTextSearchResults
and adding it to kernel.Plugins
.
However, I now want to do this with Sqlite.
I created and opened a connection to Sqlite with:
SqliteConnection sqliteConnection = new SqliteConnection(
new SqliteConnectionStringBuilder()
{
DataSource = "SqliteDB.db"
}.ToString()
);
sqliteConnection.Open();
This create "SqliteDB.db" at bin\Debug\net9.0 of my C# project.
I then had (as a toy example):
IVectorStore vectorStore = new SqliteVectorStore(sqliteConnection);
`IVectorStoreRecordCollection