Business IEA Says Data Center Power Demand Could Double to 1,000 TWh by 2030, With AI Supplying Three Quarters of the Growth Chatbots ChatGPT Now Transcribes as You Talk: OpenAI Removes the 10-Minute Cap and Streams Words Live on Every Plan Business Ex-Alibaba Executive's Everful Raises $48.5 Million to Put AI Agents in Charge of Sourcing From 30,000 Factories AI Agents Google Built a Mirror Dimension of the Internet to Train Its Chrome AI Agents Without Breaking the Real Web Productivity Canva Finally Adds an Off Switch for Its Generative AI Features, and a Filter to Hide AI-Made Templates Business Anthropic Begins Trading Today: 980 Million Shares at $83, a $1.5 Trillion Valuation and the Largest IPO on Record News Google Books Blue Origin New Glenn to Launch TPU-Carrying AI Satellites in Early 2029 Security Hackers Used the AI Penetration Tool ARTEX to Disrupt European Commission Systems for Over Ten Days Business IEA Says Data Center Power Demand Could Double to 1,000 TWh by 2030, With AI Supplying Three Quarters of the Growth Chatbots ChatGPT Now Transcribes as You Talk: OpenAI Removes the 10-Minute Cap and Streams Words Live on Every Plan Business Ex-Alibaba Executive's Everful Raises $48.5 Million to Put AI Agents in Charge of Sourcing From 30,000 Factories AI Agents Google Built a Mirror Dimension of the Internet to Train Its Chrome AI Agents Without Breaking the Real Web Productivity Canva Finally Adds an Off Switch for Its Generative AI Features, and a Filter to Hide AI-Made Templates Business Anthropic Begins Trading Today: 980 Million Shares at $83, a $1.5 Trillion Valuation and the Largest IPO on Record News Google Books Blue Origin New Glenn to Launch TPU-Carrying AI Satellites in Early 2029 Security Hackers Used the AI Penetration Tool ARTEX to Disrupt European Commission Systems for Over Ten Days

Retrieval-Augmented Generation: How It Works

Retrieval-Augmented Generation: How It Works

RAG fetches relevant passages from your own documents and places them in the prompt, so answers are grounded in material the model was never trained on.

Retrieval-augmented generation combines a search system with a language model. Instead of relying purely on what the model memorised, the system finds relevant text and supplies it as context for the current question.

The pipeline

  • Chunking. Documents are split into passages small enough to be precise and large enough to be coherent.
  • Embedding. Each chunk is converted into a vector representing its meaning.
  • Indexing. Vectors are stored in a database that supports similarity search.
  • Retrieval. The user's question is embedded and the closest chunks are fetched.
  • Generation. The model receives the question plus the retrieved passages and answers from them.

Where RAG fails

Most failures are retrieval failures, not generation failures. Chunks that split a table, break a list, or separate a heading from its explanation rarely retrieve correctly. Overlapping chunks and keeping headings attached to their content fix many of these cases.

Hybrid search helps

Vector similarity handles paraphrase but misses exact identifiers — part numbers, error codes, names. Combining keyword search with vector search and merging the results solves most of it.

Cite everything

Return the source chunk with the answer. Citations let users verify in seconds and give you a diagnostic signal: when an answer is wrong, the citation usually shows why.

Comments (0)

Log in to join the discussion

Log In

No comments yet