Capturing Legal Reasoning Paths from Facts to Law in Court Judgments using Knowledge Graphs
Ryoma Kondo, Riona Matsuoka, Takahiro Yoshida, Kazuyuki Yamasawa, Ryohei Hisano
TL;DR
This paper addresses the challenge of capturing how courts reason from facts to law by constructing a Legal Knowledge Graph (LKG) from Japanese administrative district court judgments. It introduces an RDF-based ontology with core elements (Fact, LegalNorm, LegalApplication, Provision) and a prompt-driven pipeline to extract nodes and edges from judgments, normalizing references and linking facts to norms through explicit reasoning steps. The LKG enables a specialized legal search task where fact sentences are embedded and retrieved against provisions via structured inference paths, outperforming LLM-based baselines and retrieval-augmented systems in both precision and recall, and providing interpretable reasoning traces. The work contributes a scalable methodology, an open-source ontology and LKG, and demonstrates that explicit knowledge structures improve robustness and transparency in legal AI applications.
Abstract
Court judgments reveal how legal rules have been interpreted and applied to facts, providing a foundation for understanding structured legal reasoning. However, existing automated approaches for capturing legal reasoning, including large language models, often fail to identify the relevant legal context, do not accurately trace how facts relate to legal norms, and may misrepresent the layered structure of judicial reasoning. These limitations hinder the ability to capture how courts apply the law to facts in practice. In this paper, we address these challenges by constructing a legal knowledge graph from 648 Japanese administrative court decisions. Our method extracts components of legal reasoning using prompt-based large language models, normalizes references to legal provisions, and links facts, norms, and legal applications through an ontology of legal inference. The resulting graph captures the full structure of legal reasoning as it appears in real court decisions, making implicit reasoning explicit and machine-readable. We evaluate our system using expert annotated data, and find that it achieves more accurate retrieval of relevant legal provisions from facts than large language model baselines and retrieval-augmented methods.
