Skip to main content

Vector Indices

VectorIndex API | Available Vector Indices | Examples

Using vector indices to store and retrieve objects is a common pattern when working with language models. One important use case is retrieval augmented generation.

ModelFusion provides a VectorIndex interface that can be implemented by different vector databases. This allows you to use the same code to query different vector databases, e.g. Pinecone or an in-memory vector store. It is parameterized with a subtype of TextChunk.