a typical RAG flow has three stages: data prep, retrieval and generation. Documents are turned into text, chunked and converted to numerical vectors, so related ideas sit close together (coffee and tea, for example). When a question comes in, the closest chunks are fetched and handed to the model with the question. A common misunderstanding is that RAG removes hallucinations. The source says it reduces the chance of wrong answers, and that it lets a system cite sources or say "I don't know". It is also not the same as fine-tuning: new data is added by swapping documents, without retraining the model. source: https://www.redhat.com/en/topics/ai/what-is-retrieval-augmented-generation