What is entity resolution in graph-based RAG?
Entity resolution in graph-based RAG is the process of deciding whether different names, mentions, or extracted graph nodes refer to the same real-world entity. It helps build a connected, accurate knowledge graph instead of fragmenting one person, product, or organization into duplicates.
Beginner-friendly example
Three documents mention:
- “International Business Machines” released a product.
- “IBM” maintains the product.
- “IBM Corp.” operates its support portal.
If all three mentions refer to the same organization, entity resolution maps them to one canonical organization node, with the original names retained as aliases and links to their source documents.
But “Apple” the technology company and “apple” the fruit must not be merged. Likewise, two different employees named “Ravi Kumar” may need separate nodes.
Entity extraction vs entity resolution
- Entity extraction identifies potential names and things in text.
- Entity linking connects a mention to a known entity identifier in a catalog or knowledge base.
- Entity resolution decides which records or nodes represent the same entity, including cases without an existing catalog.
They often work together but solve different parts of graph construction.
How does it work?
- Extract and normalize mentions: Standardize capitalization, punctuation, common abbreviations, and entity types without discarding meaningful distinctions.
- Generate candidates: Use exact or fuzzy name matches, known aliases, external identifiers, embeddings, or blocking rules to find possible duplicates.
- Compare context: Check descriptions, organization, location, domain, relationships, dates, and source documents.
- Resolve cautiously: Merge only high-confidence matches; retain ambiguous entities separately or send them for review.
- Preserve provenance: Keep aliases, original mentions, source passages, stable IDs, and the reason for each merge.
- Maintain the graph: Recheck merges when updated documents or new evidence reveal previously hidden differences.
Numerical example
Suppose 100 extracted mentions include “Acme Ltd” (42 mentions), “ACME Limited” (35), and “Acme” (23). If evidence confirms that all refer to the same company, the graph can connect 100 mentions to one canonical entity. The count of graph nodes decreases, but the 100 original mentions and citations remain available.
If “Acme” also names a different supplier, blindly merging all 23 ambiguous mentions would contaminate retrieval. Context and identifiers matter more than string similarity alone.
Why does this improve RAG?
Without resolution, relationship paths may break because the same company appears as separate nodes. With incorrect over-merging, unrelated facts can mix and create misleading answers. Accurate resolution supports multi-hop retrieval, entity-centered search, and trustworthy source tracing.
Common pitfalls
- False merges: Two distinct entities are combined, leaking unrelated relationships into results.
- Missed merges: Aliases remain separate, hiding valid graph connections.
- Name changes over time: Mergers, rebranding, or employee-role changes need temporal context.
- Unexplained merges: Without provenance or confidence records, it is hard to audit and correct mistakes.
Interview takeaway: Entity resolution makes graph RAG *connect mentions that truly refer to the same thing while keeping different things separate*. Treat it as an evidence-based identity decision, not just lowercase-string deduplication.
Further reading: https://neo4j.com/blog/developer/entity-resolved-knowledge-graphs/ and https://microsoft.github.io/graphrag/index/default_dataflow/.
Sources & Research References
Learning Sequence
Retrieval-Augmented Generation Curriculum
Explore Related Questions
Deepen your understanding across related Retrieval-Augmented Generation topics.