Best practices for using vector stores for followup questions of returned lists

I’m trying to create a “simple” chat with documents solution. I’m basically trying to create a chatbot which can respond to these questions and followups.

First prompt: Give me a list of [xxx] activities
This works. The relevant vector store retrieval is pulling the relevant information and giving me a list of activities.

Second prompt: Give me more details about 2.
This fails because the vector store retrieval is trying to search for “2”, which does not exist in the text.

I wondered what are the best practices to handle the second prompt?

Personally, I ask the model to look at the conversation so far, and to provide me with a search term that would best provide an accurate retrieval from a vector database, that way you are always getting the best search term at any stage.

1 Like

How would you change the retriever query in langchain?