Reference

RAG glossary

Key terms from this course, in plain English.

Agentic RAG
RAG where an LLM decides when and what to search, possibly running several searches before answering.
Approximate nearest neighbour (ANN)
Search methods that find very close vectors quickly, trading a little accuracy for speed.
BM25
A classic lexical ranking function that scores documents by matching query words, weighting rare words more.
Chunk
A passage of a document indexed as a unit for retrieval.
Chunk overlap
Repeating the end of one chunk at the start of the next to preserve context across boundaries.
Citation
A reference in an answer to the source passage that supports a claim.
Contextual retrieval
Prepending an LLM-written description of each chunk's place in its document before indexing, to improve retrieval.
Cosine similarity
A measure of how similar two vectors' directions are, from −1 to 1.
Embedding
A vector of numbers representing the meaning of a piece of text.
Faithfulness
Whether every claim in an answer is supported by the retrieved sources (also called groundedness).
HNSW
Hierarchical Navigable Small World — a popular graph-based ANN index.
Hybrid search
Combining lexical and semantic search results.
Indexing
Preparing documents for retrieval: cleaning, chunking, embedding and storing them.
LLM-as-judge
Using a language model, with a rubric, to grade outputs.
Metadata
Information stored with each chunk — source, date, section, permissions — used for filtering and citations.
MRR
Mean reciprocal rank: the average of 1/rank of the first relevant result.
Query rewriting
Transforming a user's question (e.g. a follow-up) into a better standalone search query.
RAG
Retrieval-augmented generation: retrieving relevant passages and giving them to an LLM to ground its answer.
Recall@k
The share of test questions where a relevant passage appears in the top k results.
Reciprocal rank fusion (RRF)
Merging ranked lists by summing 1/(k + rank) for each document.
Reranker
A model that scores query–passage pairs more accurately than first-stage retrieval, used on a shortlist.
Semantic search
Search by meaning using embeddings rather than exact words.
Vector database
A database designed to store vectors and run similarity search, often with metadata filtering.