>_TheQuery
← Glossary

Context Fusion

Information Retrieval

The process of combining structured knowledge from a knowledge graph with unstructured text from RAG retrieval into a unified context for LLM generation.

Context fusion is the technique of merging structured knowledge (facts, relationships, and paths from a knowledge graph) with unstructured knowledge (retrieved document chunks from vector search) into a single coherent context that an LLM can use to generate comprehensive answers.

The standard approach formats graph results and document results into clearly labeled sections within the prompt: "STRUCTURED KNOWLEDGE (from Knowledge Graph)" containing entity facts and relationship paths, and "UNSTRUCTURED KNOWLEDGE (from Documents)" containing relevant text passages. Instructions guide the LLM to use structured knowledge for facts and relationships while using unstructured knowledge for details and explanations, citing each source type appropriately.

Context fusion is where many hybrid RAG+KG systems fail. The naive approach of dumping both sources into a prompt without structure leads to the LLM ignoring one source or hallucinating connections between them approximately 40% of the time. Effective context fusion requires clear labeling, explicit instructions about when to prefer each source (structured knowledge for facts, documents for details), and conflict resolution rules (prefer structured knowledge when sources disagree on factual claims).

Last updated: February 22, 2026