Filtering restricts results by attributes such as tenant, product, date or permission group.
Post-filtering runs the vector search first and then removes non-matching results: simple, but you may end up with fewer than k (even zero) results if most top hits are filtered out.
Pre-filtering (or filtered search inside the index) applies the constraint during search, which guarantees k matching results but can slow HNSW traversal sharply under very selective filters, so many systems switch to brute force over the filtered subset when the filter is very selective.
Index frequently used filter fields and test tail latency with selective filters.
Loading…