RAG (Retrieval-Augmented Generation) combines a search and an LLM: you first retrieve the relevant passages from a document base, then insert them into the prompt so that the model answers based on them. It makes it possible to use recent or private data, cite sources and reduce hallucinations.