Insights
Jan 8, 2026
Knowledge Graph using the example of law: the BGB as a digital knowledge network
If the BGB could speak…
The Civil Code (BGB) is a prime example of complex yet logically structured knowledge:
Thousands of paragraphs that reference, complement, or condition one another.
What legal professionals intuitively recognize when reading must be explicitly modeled by AI.
A Knowledge Graph can do just that: It transforms the BGB into a digital network of relationships that makes connections visible and machine-readable.
How is a Knowledge Graph created from the BGB?
Identify concepts
Legislation, books, sections, paragraphs, terms
Relationships: “consists of,” “refers to,” “applies under condition”
Establish connections
§433 BGB (Purchase Agreement) refers to §929 BGB (Transfer of Title)
Both belong to Book 2: Law of Obligations
§929 is in turn related to §158 (Conditions)
Digitize as a graph
Each paragraph = node
Each reference = edge
Comments, judgments, examples = linked knowledge objects
The result is a connected legal knowledge system.
An AI can now navigate along these nodes, understand cross-connections, and provide informed answers.
How AI works with the graph
The AI does not only work with keywords but combines different approaches to better understand information. On one hand, it uses semantic search through embeddings, allowing it to recognize similar terms, for instance. On the other hand, it incorporates the logical structure from the graph to capture paragraph dependencies and thus understand the connections in the text better.
Example:
“What happens in the purchase agreement if the buyer is not legally competent?”
The AI follows the graph:
§433 (Purchase Agreement)
→ §104 (Incapacity)
→ §105 (Nullity of the Declaration of Intent)
The result is legally correct and explicable – not just “probably appropriate.”
Why the BGB is an ideal example
The BGB clearly shows:
how strongly knowledge is interconnected rather than linear,
how important precision of terms and references are,
and why explainability in AI is essential.
Companies face similar challenges:
Their policies, contracts, processes, and data are just as complex and interconnected as laws.
A Corporate Knowledge Graph applies the principle of the BGB to all corporate knowledge.
Conclusion
A Knowledge Graph in law demonstrates how knowledge with structure emerges from texts.
It is the link between human understanding and machine reasoning.
Thus, the BGB – and with it every complex set of rules – becomes not only readable but also thinkable for artificial intelligence.
