RAG and Retrieval
Build search and retrieval for AI applications.
Choose the piece you need, from document parsing and vector storage to reranking and full retrieval pipelines. Match integrations to the rest of your stack.
20 resources
-
qdrant/qdrant
A vector database for similarity search with structured filtering and multiple representations per point.
qdrant · Local server or managed service.- Compatibility
- Docker, Python, REST, gRPC
- Components
- Vector database, Metadata filtering, Hybrid retrieval
Setup notes
Use named vectors to keep dense embeddings and sparse features associated with the same chunk ID. Filter on fields such as collection, language, or tenant when the same service indexes multiple sources.
Run Qdrant locally in its official Docker container and connect through its REST or gRPC API. Choose collection dimensions to match the embedding model, and save the original chunk text or its document pointer alongside the vector.
-
Milvus Vector Database
An open-source vector database with configurable indexes and scalar fields for filtering retrieval.
Milvus Project · Local library or server. Managed options are separate.- Compatibility
- Python, Docker, PyMilvus
- Components
- Vector database, Metadata filtering, Vector indexes
-
Weaviate Vector Database
A vector database that can combine embedding similarity, keyword relevance, and property filters.
Weaviate · Local server or managed service. Some vectorizer integrations require credentials.- Compatibility
- Docker, Python, REST, GraphQL
- Components
- Vector database, Keyword search, Hybrid retrieval
-
Chroma
An embedding store with a local Python client, collections, and document metadata filters.
Chroma · Local Python client or server.- Compatibility
- Python, JavaScript, Docker
- Components
- Vector store, Metadata filtering, Embedding storage
-
LanceDB
An embedded vector database for storing, filtering, and retrieving chunks from application data.
LanceDB · Local embedded database or managed service.- Compatibility
- Python, TypeScript, Rust
- Components
- Embedded vector store, Full-text search, Hybrid retrieval
-
pgvector for PostgreSQL
A PostgreSQL extension that adds vector columns, similarity operators, and approximate search indexes.
pgvector contributors · Local PostgreSQL extension. Requires a PostgreSQL installation that supports the extension.- Compatibility
- PostgreSQL, SQL
- Components
- Vector database extension, SQL filtering, Approximate nearest neighbors
-
faiss-cpu
A library for exact and approximate nearest-neighbor search over dense numeric vectors.
Meta AI Research · Local C++ or Python library. CPU and supported GPU builds are available.- Compatibility
- Python, C++, CPU, GPU
- Components
- Vector indexing, Approximate nearest neighbors, Embedding search
Setup notes
Use a simple flat index as the correctness baseline before choosing an approximate index. Keep the passage text and application metadata in a separate store keyed by your FAISS IDs.
Benchmark recall at a fixed top-k, query latency, and index memory on the same embeddings. Choose a distance and normalization strategy that matches the embedding model and use it throughout the comparison.
-
Vespa
A search platform with tensor fields, lexical retrieval, and configurable multi-stage ranking.
Vespa · Local deployment or managed service.- Compatibility
- Docker, REST, Vespa schemas
- Components
- Search engine, Tensor ranking, Hybrid retrieval
-
Haystack
A Python framework for assembling document indexing, retrieval, reranking, and answer pipelines.
deepset · Local Python package. Hosted model and search integrations can require credentials.- Compatibility
- Python, Local inference, Hosted integrations
- Components
- RAG pipeline, Document indexing, Retrieval orchestration
-
LlamaIndex
A Python framework for loading data, creating document nodes, indexing them, and composing retrieval queries.
LlamaIndex · Local Python framework. Provider integrations can require credentials.- Compatibility
- Python, Local inference, Hosted integrations
- Components
- Document ingestion, RAG pipeline, Retrieval orchestration
-
docling
A document conversion toolkit that preserves structure such as sections, reading order, and tables.
docling-project · Local Python toolkit. Initial model assets may need downloading.- Compatibility
- Python, PDF, Office documents
- Components
- Document parsing, OCR, Table extraction, Chunk preparation
Setup notes
Convert a small representative set first and inspect reading order, headings, and tables. These structures can become chunk boundaries or metadata used to reconstruct citations.
Run Docling locally and keep source references as you export Markdown or structured output. OCR and conversion settings can affect both runtime and the extraction quality of scanned pages.
-
unstructured
A Python document-processing library that partitions supported files into labeled content elements.
unstructured-io · Local Python library. Some file types require additional system packages.- Compatibility
- Python, PDF, HTML, Office documents
- Components
- Document parsing, Element extraction, Chunk preparation
Setup notes
Preserve element type and page metadata during partitioning so the index can retain document context. Compare outputs on PDFs that contain tables, multi-column layouts, and scanned pages before processing the full collection.
Choose a local partitioning strategy according to document complexity and installed dependencies. Save chunk IDs and source locations before sending the prepared text to a vector store.
-
sentence-transformers
A Python library for local text embeddings, semantic retrieval, and cross-encoder reranking.
huggingface · Local Python inference. Model weights may need downloading.- Compatibility
- Python, PyTorch, Hugging Face models
- Components
- Embeddings, Cross-encoder reranking, Semantic retrieval
Setup notes
Use a bi-encoder to search a corpus efficiently, then apply a cross-encoder only to the candidate passages. The second stage scores each query and passage together.
Keep the first-stage candidate cutoff fixed while comparing rerankers. Measure the ranking improvement and latency separately, and check the selected model license before deployment.
-
flashrank
A Python reranking library with compact models for reordering passages from an existing retriever.
Prithivi Da · Local Python inference. Initial model files may need downloading.- Compatibility
- Python, ONNX
- Components
- Passage reranking, Local model inference
Setup notes
Run the first-stage retriever as usual, then supply its passage text and query to FlashRank. Use the returned relevance scores to order the passages before building the generator context.
Compare the same candidate set with and without reranking. Record the model name, candidate cutoff, and time spent reranking so you can measure the tradeoff on your own corpus.
-
Hybrid retrieval with PostgreSQL and pgvector
A database-side recipe that combines PostgreSQL text search with vector similarity using rank fusion.
Supabase · SQL recipe for PostgreSQL with pgvector. Embeddings are supplied separately.- Compatibility
- PostgreSQL, pgvector, SQL
- Components
- Hybrid retrieval, PostgreSQL full-text search, Reciprocal rank fusion
-
Dense and sparse retrieval with Qdrant Query API
A retrieval recipe for merging candidate lists from multiple vector representations in one request.
Qdrant · Local or managed Qdrant with compatible Query API and embedding models.- Compatibility
- Qdrant, Python, REST
- Components
- Hybrid retrieval, Sparse vectors, Reciprocal rank fusion
-
Keyword and semantic search with OpenSearch
An OpenSearch workflow for combining lexical and semantic results through a search pipeline.
OpenSearch Project · Requires an OpenSearch deployment and a configured embedding model.- Compatibility
- OpenSearch, REST, JSON
- Components
- Hybrid retrieval, Search pipeline, Score normalization
-
Retrieve then rerank with Sentence Transformers
A local retrieval recipe that searches with a fast first stage and rescores candidate pairs with a cross-encoder.
Sentence Transformers contributors · Local Python recipe. Download the selected model weights before offline runs.- Compatibility
- Python, Sentence Transformers, PyTorch
- Components
- Two-stage retrieval, Cross-encoder reranking, Embedding search
-
Structure-aware chunking with Docling
A document-preparation recipe for balancing document structure with an embedding model’s token budget.
Docling Project · Local Python recipe. Tokenizer or model artifacts may need downloading.- Compatibility
- Python, Docling, PDF
- Components
- Structure-aware chunking, Document parsing, Token budgets
-
Hybrid vector and full-text search in LanceDB
A table-level retrieval recipe for combining vector similarity and full-text results.
LanceDB · Local LanceDB recipe with full-text indexing and an embedding model.- Compatibility
- Python, LanceDB
- Components
- Hybrid retrieval, Full-text indexing, Vector search
