What is GraphRAG and which kind of question is it built for?
GraphRAG turns a corpus into an entity-relationship graph, clusters it into communities, and pre-summarizes each — so it can answer global "what are the themes?" questions that top-k vector RAG can't.
Imagine a giant pile of meeting notes and someone asks "what were the big themes this whole quarter?" Plain search just hands you the few sticky notes that mention the exact words you typed — useless for a question that needs the whole pile. GraphRAG does prep work ahead of time instead. It reads everything, draws a map of who talked to whom and what connects to what, groups that map into neighborhoods of related stuff, and writes a short summary for each neighborhood. Now when the big-picture question arrives, it reads those neighborhood summaries instead of hunting for matching words. The downside: drawing the map and writing all those summaries takes a lot of reading up front, so it is slow and pricey to build.
Concept explanation~2 min read
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Concept explanation~2 min read
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
GraphRAG shows up in interviews as the answer to a question vanilla RAG keeps failing: "what are the big themes across this whole corpus?" If you have ever watched a top-k pipeline confidently return five chunks and miss the point of an aggregative question, you have felt the gap GraphRAG fills.
The goal here is to make the mechanism concrete and to be honest about the price. GraphRAG is not magic and it is not cheap. It moves a pile of reasoning work from query time to index time, and whether that trade pays off depends entirely on the kind of questions your users actually ask.
Why top-k retrieval structurally can't answer global questions
Standard RAG embeds chunks and, per query, returns the k chunks whose embeddings are nearest the query embedding. That is a local operation by design — it surfaces the passages most similar to what you typed.
For "what is the refund window," that is perfect: the answer sits in one passage, retrieval finds it, the LLM reads it back. For "what are the recurring themes across all 4,000 support tickets," it falls apart. There is no single chunk that contains the themes. The answer is an emergent property of the whole collection.
The instinct to raise k doesn't help. Bumping k from 5 to 50 just stuffs more locally-similar chunks into the context window — more of the same neighborhood, not a representative sample of the corpus, and you blow the context budget while still missing the global picture. The limit is not the size of k; it is that similarity search retrieves by local proximity, and a corpus-wide theme has no single location to be proximate to.
Situations where this technique stops working.
2–4 min · Everything important, quickly.
Real products, models, and research that use this idea.
- Microsoft's open-source GraphRAG project is the canonical implementation of entity-graph plus community-summary retrieval.
- Sensemaking over incident-report or research-paper collections, where users ask for cross-document themes, not single facts.
What an interviewer would ask next. Try answering before peeking at the approach.
QHow does GraphRAG's global query mode actually combine community summaries into one answer?
Describe the map-reduce: query each relevant community summary for a partial answer, score the partials, then reduce them into a final synthesized response.
Red flags & common mistakes
The phrases that signal junior thinking. Click to expand.
Red flags & common mistakes
The phrases that signal junior thinking. Click to expand.
Thinking a bigger k fixes global questions. No value of k makes top-k synthesize a corpus-wide theme — the answer lives in no single chunk, so you need a precomputed structure, not more chunks.
60 second bullets to scan on the way to the call.
The offline GraphRAG pipeline: extract entities and relationships into a graph
Why community detection and summarization are the enabling steps
Primary sources. Browse if you want the original framing.
Same topic, related formats. Practice these next.