Arch Desai
Arch Desai

Reputation: 331

langchain vectordb.similarity_search_with_relevance_scores() gives different top results with different value of k

I am using ChromaDB as vector DB and using similarity_search_with_relevance_scores to fetch relevant documents.

if I use k=20 and k=5 in vectordb.similarity_search_with_relevance_scores(query, k) the top 5 documents in case of k=20 do not match with 5 documents fetched when k=5. I agree that relevance score do not match due to normalization but why fetched documents are different?

Upvotes: 0

Views: 379

Answers (0)

Related Questions