Topics / Embeddings & RAG
Embeddings & RAG
Retrieval-augmented generation. Embeddings, vector databases, and pipelines.
Why learn Embeddings & RAG?
-
Lets LLMs answer questions about your data, not just the open web.
-
The dominant pattern for AI chat products in 2026.
-
Vector search has applications well beyond chat.
-
A practical, high-impact skill for backend and AI engineers.
What you can build with Embeddings & RAG
Customer support over a knowledge base Internal "ask my docs" tools Semantic search and recommendations Multi-step agentic retrieval
Embeddings & RAG tutorials
27 articles · page 1 of 2Hand-written tutorials, ordered as a recommended learning path.
- 01 What Is RAG? A clear introduction to retrieval-augmented generation — why LLMs don't know your data, how embeddings and vector search solve it, and when RAG beats fine-tuning.
- 02 Embeddings What an embedding is, why cosine similarity works, how dimensionality and chunking choices affect retrieval, and a tiny numpy example you can run in your head.
- 03 Vector Databases Why a normal database struggles with vector search, how ANN indexes like HNSW and IVF work, and a clear comparison of pgvector, Qdrant, Pinecone, Chroma, and Weaviate so you can pick one.
- 04 Chunking Strategies Learn fixed-size, semantic, recursive, and document-aware chunking strategies for RAG pipelines. Includes overlap techniques, benchmarks, and Python code.
- 05 Embedding Models Compare text-embedding-3-small/large, Cohere embed-v3, and sentence-transformers on dimensions, cost, MTEB scores, and practical RAG performance.
- 06 Hybrid Search Learn how to combine BM25 keyword search with vector similarity using reciprocal rank fusion for better RAG retrieval. Includes Python code and benchmarks.
- 07 Evaluation Metrics Learn to evaluate RAG pipelines with Recall@k, MRR, NDCG for retrieval and faithfulness, relevance, hallucination rate for generation. Includes RAGAS setup.
- 08 Advanced Retrieval Improve RAG retrieval quality with advanced techniques: query expansion, multi-query retrieval, cross-encoder reranking, and reciprocal rank fusion.
- 09 RAG in Production Build a production-ready RAG pipeline with document ingestion, chunking, retrieval, and generation. Covers error handling, monitoring, and optimization.
- 10 Vector DB Comparison Compare Pinecone, Weaviate, and Chroma vector databases for RAG applications. Covers setup, performance, pricing, and when to use each one.
- 11 Context Windows Why bigger context windows are not always better: cost, attention degradation, retrieval design, and how to architect for long-context tasks.
- 12 Chunk Overlap Learn how chunk overlap rescues boundary context in RAG pipelines, with practical strategies for choosing overlap size and shape for different corpora.
- 13 Chunking Compare fixed-size, sentence, semantic, and structural chunking for retrieval augmented generation and pick the right one for your corpus.
- 14 Doc Loaders An overview of document loaders in RAG pipelines, covering common formats, libraries, and how to choose the right loader for your data.
- 15 RAG Eval Measure RAG quality with recall@k, MRR, context precision, faithfulness, and answer relevancy so you can iterate on data, not vibes.
- 16 Graph RAG Graph RAG combines knowledge graphs with retrieval augmented generation to handle multi-hop questions and complex reasoning.
- 17 Hybrid Search Combine lexical BM25 with dense vector search to recover the queries each method misses on its own and boost RAG retrieval quality.
- 18 HyDE Learn how Hypothetical Document Embeddings (HyDE) improve RAG recall by embedding a generated answer instead of the raw query, with examples and trade-offs.
- 19 Metadata Filters How to use metadata filters in RAG to improve precision, scope retrieval, and enforce permissions without sacrificing recall.
- 20 Rerankers Add a reranker on top of vector retrieval to dramatically improve top-k quality with cross-encoders, late interaction, and LLM rerankers.