AI engineering glossary · RAG vector search
What is post-filtering?
Post-filtering: Running the nearest-neighbour search first and then discarding results that fail the metadata condition. It is simple, but a strict filter can leave fewer than the requested number of results, since many top hits get thrown away.
Post-filtering: an example
The search returns 10 hits, but only 2 pass the language = 'hi' filter, so the user sees 2 results.
Related terms
More RAG vector search terms
- Pre-filtering
- Product quantisation
- Proposition indexing
- Query decomposition
- Query expansion
- Query rewriting
- RAG evaluation
- Ragas
Where you learn it
Post-filtering is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.