
10/27/2025 · Jack Li
What this post added
This post provides a deep dive into the Inverted File (IVF) vector index, a core component for Approximate Nearest Neighbor (ANN) search in vector databases. It explains the IVF index's architecture, including clustering, centroids, and inverted lists. It details the index building process involving K-means clustering, vector assignment, and optional compression techniques like Scalar Quantization (SQ8) and Product Quantization (PQ). The post also outlines the search process, emphasizing the role of nprobe in balancing recall and latency. Practical advice is given on choosing nlist and tuning nprobe for different scales and performance requirements, along with a comparison of IVF variants (IVF_FLAT, IVF_PQ, IVF_SQ8).