· Retrieval
RAG
How an AI model answers from your documents: chunks, two kinds of search, reranking.
Research · Retrieval · Graphs
Updated
GraphRAG is retrieval-augmented generation that reads a map of your documents instead of separate passages. Colidal builds a knowledge graph of the suppliers, products, contracts, and events in your documents and how they connect, so the AI can answer questions that span many documents and show the path it followed.
graph = entities + relationships · search = local + global · path = shown
GraphRAG is a form of retrieval-augmented generation that stores knowledge as a graph of entities and the relationships between them, and retrieves connected facts instead of isolated passages. How it works Ordinary RAG finds passages that look like the question. GraphRAG first works out what the documents are about and how those things connect, then answers from the connections. Indexing Split the documents into chunks. The same first step as ordinary RAG. Extract entities and relationships. An LLM reads every chunk and lists the things in it (a supplier, a product, a contract) and how they relate. Build the knowledge graph. Each entity becomes a node. Each relationship becomes an edge. The same supplier in fifty documents becomes one node. Detect and summarize communities. A clustering algorithm (Leiden) groups closely linked entities. An LLM writes a summary of each group. Query Find the entities in the question. The question is mapped to nodes and edges in the graph. Traverse the graph. Local search follows relationships outward from those nodes. Global search reads the community summaries for broad questions. Assemble the graph context. The retrieved subgraph is pruned and ranked so only the relevant facts remain. Answer. The generative model answers from the question plus the graph context. The path it used can be shown. Building the graph The graph is the hard part of GraphRAG. Most of what makes one system answer well and another answer badly is decided here, before any question is asked. Stages 01 to 03 Design the schema. Decide which kinds of things matter (supplier, product, contract) and which links between them (supplies, covers, replaces). A narrow schema gives a cleaner graph than "extract everything". Extract. An LLM reads each chunk with the schema and a few worked examples. It returns entities (name, type, description), relationships (from, to, description, strength), and claims: dated facts about an entity. A second pass asks what it missed. Resolve entities. The same supplier appears under five spellings. Exact and normalized matching merges the easy ones, embedding similarity proposes the rest, and an LLM decides the close calls. Descriptions from many chunks are merged into one. Stages 04 to 06 Attach provenance. Every node and edge keeps a pointer to the chunks it came from. That is what makes citations possible, and what lets a fact be removed when its source document is. Cluster. A community detection algorithm (Leiden) groups densely linked entities, at several levels: a few broad communities at the top, many narrow ones underneath. Summarize. An LLM writes a report for each community at the lowest level. Higher levels are summarized from the reports below them. These reports answer the whole-picture questions. Input · one chunk The model is told which entity types and relationships to look for, and returns them as structured records, not prose. Example text, written for illustration. Output · nodes, edges, a claim Supplier AsuppliesK-200 valve Supplier Aparty toContract C-114 Contract C-114coversK-200 valve Contract C-131replacesContract C-114 Contract C-114claimexpires in March Four entities, four relationships, one claim, each tied to this chunk. The next chunk that mentions "the K-200" adds to the same node. granularity Too little and the graph cannot connect anything. Too much and real links drown in noise. Start with the entity types your questions actually mention. updates Only new and changed documents are re-extracted. Provenance removes facts whose source is gone. Communities and their summaries are refreshed on a schedule. quality Sample edges and check them against the source text. Track the duplicate rate. Run multi-step questions with known answers. storage A graph database, queried with a graph language such as Cypher, Gremlin, or SPARQL. Many systems keep vector embeddings beside it for hybrid search. Two ways to search A graph answers two kinds of question that passage search handles badly. local search "Which contracts cover the supplier behind these late orders?" The answer is three hops away: order, supplier, contract. Local search walks them. global search "What are the main themes in this year's complaints?" No single passage holds that. Global search combines the community summaries. hybrid Many systems keep the vector index too. The graph finds what is connected, and passage search supplies the exact wording. explainability Because retrieval follows named relationships, the system can show which entities and links led to an answer. Limits A graph adds reasoning power and adds ways to fail. These are the ones to plan for. multi-hop Each hop along the graph is a chance to take a wrong turn. A wrong edge early on carries through every step after it. scale A very large graph is harder to store and query, and extra nodes can bury the links that matter. Pruning is part of the design. privacy Two harmless facts joined by an edge can expose something sensitive. Access rules have to cover the links, not only the documents. evaluation Counting whether the right chunk was retrieved says little about a graph. Test with multi-step questions and check each answer against its sources. Published results GraphRAG was introduced in a 2024 paper from Microsoft, tested on whole-picture questions over two document sets of about a million tokens each. 72 to 83% of comparisons where GraphRAG's answer was judged more comprehensive than vector RAG's 62 to 82% of comparisons where it was judged to cover more diverse points over 97% fewer tokens per question when answering from top-level community summaries instead of the source text Source: Microsoft, "From Local to Global: A Graph RAG Approach to Query-Focused Summarization" (2024, revised 2025). Podcast transcripts and news articles, about one million tokens each. Answers to whole-corpus questions were compared head to head by an LLM judge. Published figures, not Colidal measurements. Fit Compare They are not rivals. Most systems start with RAG, and add a graph or an agent only where the questions need one. How Colidal builds it Colidal builds GraphRAG on top of its RAG engine, for the questions passage search cannot answer. The graph is designed around the entities your business runs on. Used in: Your data · Your documents · colidal/ragBuild the map once. Follow it for every question.
Before any question
When a question arrives
How the graph gets built: six stages.
Find the facts
Make it usable
What extraction produces
Five strategies for building the graph
Strategy How it works Good at Weak at Cost Open extraction An LLM decides for itself what the entities and relationships are A fast start; finding what nobody thought to ask for Inconsistent types, more duplicates, more noise High Schema-guided extraction An LLM extracts only the agreed entity and relationship types A clean, consistent graph that can be queried precisely Misses what the schema did not foresee; needs design up front High Statistical extraction No LLM: noun phrases become nodes, and phrases that appear together become edges Very large document sets on a small budget Edges say "mentioned together", not how things relate Low From structured data Records in your databases are mapped straight to nodes and edges Exact facts, nothing invented Covers only what your systems already record Low Hybrid A backbone from structured data, with entities extracted from documents attached to it Tying what documents say to the records you trust More moving parts to keep in step Medium to high How much to extract
Keeping it current
Checking the graph
Where it lives
Specific questions and whole-picture questions.
Follow the connections
Read the whole picture
Graph plus passages
An answer you can trace
The query side, part by part
Part What it does How Query processor Finds the entities and relationships named in the question and maps them to nodes and edges Named-entity recognition and relation extraction, then a graph query in Cypher, Gremlin, or SPARQL Retriever Collects the relevant part of the graph Graph traversal (breadth-first or depth-first), embedding search, and limits on how far from the starting nodes it may go Organizer Cleans up what was retrieved Prunes irrelevant nodes, reranks the rest, and adds missing context Generator Writes the answer An LLM, given the question and the organized graph context Where GraphRAG goes wrong.
Errors add up
Bigger is noisier
Connections reveal things
Passage scores do not fit
What the research found.
When GraphRAG fits, and when it doesn't.
Use it when
Skip it when
RAG, GraphRAG, or agentic RAG?
RAG GraphRAG Agentic RAG What it retrieves Passages that match the question Connected facts, and summaries of whole topics Whatever the agent decides the task needs A question it suits What does the returns policy say about opened items? Which suppliers are linked to the late orders this year? Compare this month's returns with the policy and draft a reply. Built before any question Chunks, embeddings, a keyword index All of that, plus a knowledge graph and community summaries Nothing new: it uses the other indexes as tools Cost to set up Lowest Highest: an LLM reads every chunk Medium: tools, checks, and tests Cost per answer Lowest: one search, one model call Low for specific questions, higher for broad ones Highest: several model calls per task How it shows its work The passage and page it used The path it followed through the graph Every step, tool call, and source Start here when The answer is written down in one place The answer is spread across many connected documents The answer takes several steps or several systems A knowledge graph of your business, kept current.
FAQ
GraphRAG is retrieval-augmented generation that stores your documents as a graph of entities and relationships, so an AI model can answer from connected facts.
A knowledge graph is a set of things (a supplier, a product, a contract) and the named links between them (supplies, covers, replaced by). It is a map of what your documents say.
No. It costs more to build, so it is added where questions depend on connections. Most systems run both and pick per question.
An LLM has to read every chunk to extract entities and relationships, then summarize each community. Ordinary RAG only has to encode the chunks.
Keep reading
· Retrieval
How an AI model answers from your documents: chunks, two kinds of search, reranking.
· Retrieval · Agents
How an AI agent plans, picks its tools, checks its results, and retries.
· Retrieval · Chunking
How an AI model decides where to cut a document so each passage keeps its meaning.
Next step
Tell us what you need. We reply within one business day with times for a call, and you'll get a short agenda before we talk.
Request a call
Thirty minutes, by video. No preparation needed.
Get times and a short agenda
Within one business day, so the call is spent on your problem.
Leave with a next step
Usually Colidal AI Assessment, or an honest "AI isn't the answer here".