Skip to content
RAG Repo

Knowledge graphs & structured data

Machine-readable knowledge graphs that encode entities, relationships, and facts in structured formats like RDF and JSON-LD.

4sources

Knowledge graphs store facts as a web of entities and the relationships between them, rather than as paragraphs of text. Think β€œMarie Curie, won, Nobel Prize in Physics, 1903” expressed in a machine-readable form. For RAG, they solve a problem that plain text handles badly: precise, unambiguous lookups. When a user asks for an exact date, a capital city, or every drug that treats a condition, a graph can return the fact directly instead of hoping a relevant passage was retrieved.

Choosing within this category is mostly about how you query. Many graphs are published as RDF, a standard way of writing facts as subject-predicate-object triples, and queried with SPARQL, a language built for searching that structure. That is powerful but has a real learning curve. Others expose a friendlier API or downloadable tables. The other axis is breadth versus depth: some graphs cover everything shallowly, while domain graphs go deep on one field like biology or geography. General-purpose graphs are a good default; reach for a specialist one when accuracy in a single domain matters most.

The main things to watch are completeness and freshness. Graphs are often crowd-built, so coverage is uneven and some facts are missing or out of date. Structured data can also be surprisingly hard to feed to a language model, which reads prose more naturally than triples, so many teams convert facts into short sentences before retrieval.

The sources below range from broad, general-purpose graphs to focused domain ontologies, so you can match structure and coverage to your needs.

Other categories