Agent skill · data analytics · davila7

faiss

Facebook's library for efficient similarity search and clustering of dense vectors. Supports billions of vectors, GPU acceleration, and various index types (Flat, IVF, HNSW). Use for fast k-NN search, large-scale vector retrieval, or when you need pure similarity search without metadata. Best for high-performance applications.

Why this skill is useful

Provides domain-specific knowledge on efficient similarity search techniques and GPU acceleration that the AI wouldn't reliably generate on its own.

What it needs

Requires faiss-cpu, faiss-gpu, numpy installed locally. About 3k tokens when loaded. Last updated 2026-08-06. 30,138 stars on the source repository.

What this skill does

FAISS - Efficient Similarity Search Facebook AI's library for billion-scale vector similarity search. When to use FAISS Use FAISS when: Need fast similarity search on large vector datasets (millions/billions) GPU acceleration required Pure vector similarity (no metadata filtering needed) High throughput, low latency critical Offline/batch processing of embeddings Metrics: 31,700+ GitHub stars Meta/Facebook AI Research Handles billions of vectors C++ with Python bindings Use alternatives instead: Chroma/Pinecone: Need metadata filtering Weaviate: Need full database features Annoy: Simpler, fewer features Quick start Installation Basic usage Index types 1. Flat (exact search) 2. IVF (inverted file) - Fast approximate 3. HNSW (Hierarchical NSW) - Best quality/speed 4. Product Quantization - Memory efficient Save and load GPU acceleration LangChain integration LlamaIndex integration Best practices 1. Choose right index type - Flat for <10K, IVF for 10K-1M, HNSW for quality 2. Normalize for cosine - Use IndexFlatIP with normalized vectors 3. Use GPU for large datasets - 10-100× faster 4. Save trained indices - Training is expensive 5. Tune nprobe/efsearch - Balance speed/accuracy 6. Monitor memory - PQ for large datasets 7. Batch queries - Better GPU utilization Performance Index Type Build Time Search Time Memory Accuracy ------------ ------------ ------------- -------- ---------- Flat Fast Slow High 100% IVF Medium Fast Medium 95-99% HNSW Slow Fastest High 99% PQ Medium Fast Low 90-95% Resources GitHub: https://github.com/facebookresearch/faiss ⭐ 31,700+ Wiki: https://github.com/facebookresearch/faiss/wiki License: MIT

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills davila7/rag-faiss

View the source on GitHub

Browse the @skills marketplace