Retrieval-Augmented Generation
A technique that enhances LLM responses by retrieving relevant information from external knowledge bases. Combines the power of search with generative AI for grounded, factual outputs.
Retrieval-augmented generation, RAG, is the architecture that gives a language model the facts it did not memorize: at query time, relevant documents are retrieved, usually by vector similarity, and injected into the model's context, grounding the answer in your data instead of the model's training corpus.
Why it matters to an indie builder: it is the difference between a chatbot that hallucinates and a product that answers from your documentation, contracts or catalog. RAG is also the cheapest path to an AI feature, no fine-tuning, no GPU bill, just chunking, embeddings and retrieval, all available as managed services.
A realistic pipeline: documents split into overlapping chunks, embedded into a vector store, retrieved by top-k similarity with a reranker, then assembled into a prompt with citations back to sources. Evaluation on a held-out question set tells you whether chunk size or retrieval depth needs tuning.
Trade-offs: retrieval quality dominates answer quality, and naive RAG fails on multi-hop questions and tables. Compare with long-context models that simply read everything, and with fine-tuning when the goal is style or behavior rather than knowledge.
Who it's for
Teams building AI that answers from their own documents instead of guessing.
Keep exploring
Concepts in the glossary
16 in catalog
RAG is featured by
-
LlamaIndex
The Data Framework for LLM Applications
Framework -
Cohere
The enterprise RAG platform
AI as a Service -
Pinecone
The vector database for AI
Vector Database -
Qdrant
The vector search engine
Vector Database -
Weaviate
The vector database with hybrid search
Vector Database -
Chroma
The AI-native embedding database
Vector Database -
Milvus
The vector DB built for scale
Vector Database -
pgvector
Vector search inside Postgres
Vector Database -
Turbopuffer
Serverless vector search on object storage
Vector Database -
LanceDB
The embedded vector database
Vector Database -
Firecrawl
Turn websites into LLM-ready data
Service -
MongoDB
The document database
Hosting Service -
Neo4j
The graph database
Hosting Service -
RAGFlow
Build a superior context layer for AI agents
Framework -
Opik
Open-source LLM evaluation and observability
LLM Ops -
Vespa
AI search at scale
Vector Database
1 in catalog