SharpVector icon indicating copy to clipboard operation
SharpVector copied to clipboard

Providing embeddings instead of text

Open Pragmateek opened this issue 2 months ago • 0 comments

Is there a way to provide embeddings instead of text (AddText[Async])?

I'm using OpenAI embeddings, I've seen OpenAIMemoryVectorDatabase, but if I understand correctly it requests embedding for each text, and indeed it is sluggish as I have to handle hundreds of elements. Instead I'd like to leverage OpenAI API EmbeddingClient.GenerateEmbeddingsAsync which allows to pass a bulk of texts once.

For sure it should be faster, and maybe cheaper.

What are your thoughts?

Thanks 🙂

Pragmateek avatar Nov 30 '25 20:11 Pragmateek