---
title: "OpenContracts Turns Legal Document Chaos Into a Forkable Citation Graph"
subtitle: "OpenContracts turns a folder of documents into a programmable citation graph, exposing the same substrate to humans, apps, and MCP-compatible agents."
url: "https://alphasignal.ai/news/opencontracts-turns-legal-document-chaos-into-a-forkable-citation-graph"
author: "AlphaSignal Newsroom"
author_url: "https://alphasignal.ai/editorial-team"
company: "AlphaSignal"
company_url: "https://alphasignal.ai/company/alphasignal"
published: "2026-04-23T06:15:10.000Z"
updated: "2026-08-22T23:30:05.463Z"
type: "Repo"
topics:
  - "Open Source"
  - "Agents"
subtopics:
  - "Mcp"
  - "Agent Frameworks"
upvotes: 12
source_url: "https://github.com/Open-Source-Legal/OpenContracts"
comments: 0
truncated: true
---

# OpenContracts Turns Legal Document Chaos Into a Forkable Citation Graph

> OpenContracts turns a folder of documents into a programmable citation graph, exposing the same substrate to humans, apps, and MCP-compatible agents.

[OpenContracts](https://github.com/Open-Source-Legal/OpenContracts) treats a document repository as a graph rather than a bag of files. Point it at a folder of PDFs, DOCX, or plain text and it builds a navigable citation network you can query from React, GraphQL, REST, or an MCP client. The project is MIT-licensed, self-hosted, and has crossed 1.4k stars on GitHub.

## Documents as nodes, citations as edges

Documents are nodes, citations are edges, and annotations are the layer humans and agents build the graph from together, against the same source of truth. Create a corpus, drop in documents, and click Set up. That one click installs the intelligence bundle: agents describe and summarize every document, and the reference web starts weaving, with every statutory citation detected, resolved, and drawn as an edge.

The README walks through the flow with 36 SEC filings. By the end of the setup clip, those filings become a navigable graph wired to the Delaware General Corporation Law, the Securities Act, and the SEC rules they cite, section by section. Law the library doesn't hold yet is tracked as a backlog, automatically, until you ingest it.

![Governance graph showing filings linked to specific statute sections](https://github.com/Open-Source-Legal/OpenContracts/raw/main/docs/assets/images/screenshots/auto/corpus--governance-graph--with-data.png) 

## Three surfaces on the same substrate

The engine exposes one graph through two interfaces: a GraphQL and REST API for humans and applications, and a Model Context Protocol endpoint for agents. The React UI is another client on top of the same API, which means anything you do in it (annotate, extract, chat) is scriptable.

_Preview only. Full text requires an AlphaSignal Pro account._

## Sources

- [OpenContracts GitHub Repository](https://github.com/Open-Source-Legal/OpenContracts)
- [OpenContracts Documentation](https://open-source-legal.github.io/OpenContracts/)
- [OpenContracts MCP Server Documentation](https://open-source-legal.github.io/OpenContracts/mcp/)
- [OpenContracts LLM Framework](https://open-source-legal.github.io/OpenContracts/architecture/llms/)
