In https://thenewstack.io/exploring-chroma-the-open-source-vector-database-for-llms/, we explored Chroma as a vector database to store and retrieve embeddings. We will replace that function with a query to search the collection stored in Chroma.

Now that we have the text that’s constructed from the dataset let’s convert it into word embeddings and store it in Chroma.

In the above step, we are pointing Chroma to use OpenAI embeddings by passing the OpenAI API Key and the embedding model.

This tutorial demonstrates how to leverage a Vector database like Chroma to implement Retrieval Augmented Generation (RAG) to enhance the prompt with additional context.

Related Articles