Tired of Poor RAG Results?
If you are tired of poor RAG results then follow these steps, a coffee break concepts Vol 2
The most important thing to improve your RAG output is to improve your search.
Retrieval (Often called L1)
Goal of this step is to quickly find all the documents from the index that satisfy the search criteria -possibly across millions or billions of documents.
Ranking(Often called L2)
Takes a subset of the top L1 results and computes higher quality relevance scores to reorder the result set. The L2 can improve the L1’s ranking because it applies more computational power to each result.
But which one should you use?
Hybrid Search with semantic ranker outperforms every other search.
Wait, how to write your query for vector search?
But which one would work and which one won’t?
Hybrid search + semantic ranking consistently outperforms any type of search.
Your Document Chunking strategy matters
Number of tokens per vector & Chunk boundary
Summary
- Hybrid Search with semantic ranker outperforms every other search
- There are multiple styles of writing your query, always benchmark your query type against your dataset
- Its always preferred to vectorize your chunk instead of complete document
- Higher chunk size results in lower recall — it is important to check what chunk size works on your dataset
- Overlapping chunks helps improve understanding the context
Comment below on which topic you want to understand next in this “Coffee Break Concepts” series and we will include those topics in the upcoming weeks.
50% off on LLM Interview Questions And Answers Course
- 100+ Interview Questions & Answers: Interview questions from leading tech giants like Google, Microsoft, Meta, and other Fortune 500 companies.
- Realtime case studies
- 100+ Self-Assessment Questions & Real case studies
- Regular Updates & Community Support
- Certification
As a special offer, we are providing a 50% discount using the coupon code below.
Course Coupon: LLM50
Coupon explanation: 30th June 2024