Retrieval-Augmented Generation (RAG) is the leading pattern for grounding large language models in accurate, up-to-date knowledge. For developers who build assistants, search tools, and document question-answering systems, it combines the fluency of generative models with the reliability of real retrieval. This book is a practical guide to RAG in Python. It covers the foundations of RAG and synthetic data generation, fast evaluation techniques and metrics, query segmentation and analysis, leading and lagging metrics, advanced retrieval and indexing, query routing, hybrid search, structured data extraction, embedding models, feedback loops, and streaming. It also covers product design, user experience, and advanced prompting, so you can take working code through to production. Each chapter includes runnable Python examples you can reuse in your own projects, with an emphasis on clean code, accuracy, and the modern RAG tooling of 2026.
ThriftBooks sells millions of used books at the lowest everyday prices. We personally assess every book's quality and offer rare, out-of-print treasures. We deliver the joy of reading in recyclable packaging with free standard shipping on US orders over $15. ThriftBooks.com. Read more. Spend less.