Back to Dictionary
ConceptsBackend
RAG
Retrieval-Augmented Generation — feeding an AI relevant documents so it can answer based on your actual data.
The Full Picture
RAG is a pattern where you first retrieve relevant documents (code files, docs, database records) and inject them into the AI's prompt before generating a response. Instead of relying solely on what the model learned during training, RAG grounds responses in your actual data. Cursor uses RAG when it indexes your codebase and pulls relevant files into context.
It's also the standard approach for building AI chatbots that answer questions about your product.
Related Terms
Was this helpful?
Want to go deeper? I write about the real gaps vibe coding leaves behind.