Walk me through a production RAG pipeline end to end, then tell me where quality actually breaks.
Whether you have shipped one or only read about one.
The pipeline has eight stages. Ingestion parses source files and preserves structure and metadata. Chunking splits documents with size, overlap, and a link back to the parent section. Embedding turns chunks into vectors with a pinned model version. Indexing stores vectors plus filterable metadata. Retrieval rewrites the query and pulls a wide candidate set. Reranking cuts that set down to the best three to five. Prompt assembly injects context with citation instructions. Generation produces the answer, and post checks validate groundedness and citations before the user sees anything. Quality almost never breaks where people expect. Ranked by how often I see it: parsing, where tables and multi column PDFs turn into garbage, chunk boundaries that split the answer across two chunks, an embedding model that does not match the domain vocabulary, top k too small so the right chunk never enters the candidate set, no reranking so the answer sits at rank 12, and a stale index. Generation failures are usually a symptom of a weak context, not a weak model. The debugging method matters more than the list. Measure retrieval in isolation first. If the correct chunk is not in the retrieved set, no prompt change will save the answer. Fix recall at k, then measure answer quality on top of a known good context.
Retrieval recall is high but users still complain. Now you are talking about chunk quality, reranking, and synthesis, not retrieval.