Skip to content
All posts
7 min read

The Digital Decretals: hyperlinking a 13th-century law code

A professor's Word transcription of medieval canon law became a searchable, cross-linked web edition — 9,872 Latin gloss units, 18,257 citation links, and an errata list handed back to the scholarship.

Case studyClient workData engineering

The Decretals of Gregory IX served as the Church's legal backbone for centuries, and medieval law students learned it through Bernard of Parma's Glossa Ordinaria — the standard commentary keyed, phrase by phrase, to the text. Our client, a professor of medieval canon law, put it best: if the Decretals are the Torah, the gloss is its Talmud. He had spent years hand-transcribing the complete gloss into a Word document — about 4.4 million characters of Latin — and standardizing the medieval citation abbreviations into a searchable form. What he needed was the web edition: free-text search, filters by book and title, and a home for the whole apparatus.

The brief arrived as a detailed email and two files. The first working edition came back the same way the studio builds everything — AI-accelerated, senior-reviewed — and the complete delivery landed as five commits in a single day.

Gloss units
9,872
Citation links
18,257
Chapter pages
1,970
CI checks
47

The transcription is the database

The professor's Word file already had structure: native heading levels for book, title, chapter, and gloss word. The pipeline honors it — a Python parser walks the heading hierarchy into JSON, and zero text loss was confirmed against the Word file. His publishing rule is encoded too: an --books auto mode publishes only books whose title counts match the expected complete-book counts, because he never wants a partially transcribed book online.

Search that respects the apparatus

Medieval legal citations depend on punctuation — qui fil. sint leg., per venerabilemis a precise address, not prose — so search matches exact punctuation by default, with ignore-punctuation, match-case, and whole-word modes on top. An orthographic-tolerance mode collapses ae/oe to e and v to u so medieval spellings match classical ones — and highlight ranges map back to the original string, so a match found under tolerance still highlights the manuscript's own digraphs. Everything runs client-side, and the app measures itself: typical full-corpus queries over all 9,872 units come back in single-digit milliseconds.

Eighteen thousand links, one click each

Because the citations were standardized, they could be precomputed: a build step finds every citation to the Decretals themselves — 18,257 of them, out of roughly 40,000 total allegations across six law codes — and turns each into a hyperlink to the chapter it cites, both in the app and in 1,970 pre-rendered, SEO-indexable chapter pages. The link extraction was validated against the professor's own register of citation counts: 1,970 of 1,971 chapters agree exactly, and the single mismatch is a documented over-count in the register itself.

Validation as a deliverable

Checking every count against the register surfaced things no one had seen in years of transcription: a chapter that appears twice in the Word file, two chapters with no gloss sections, a spreadsheet typo, and that register over-count. Each went into an errata list for the professor — and where the site had to make a call, it makes the call visibly: the duplicated chapter's page renders both blocks with an inline scholarly note, rather than silently merging them.

The most valuable deliverable wasn't the search box — it was the errata list. Systematic validation gave the scholarship something back.

Ships two ways

  • A static site — no server, no tracking, zero external requests; system fonts only; CI runs the 47-check corpus suite and a production build on every push to main.
  • A single 5 MB HTML file — the same core search and complete text in one self-contained file that runs offline from a double-click. USB-stick scholarship, for colleagues who'd rather not trust a URL.
  • The client's files, improved — per-book Word downloads regenerated from his master with formatting preserved, plus his full abbreviations spreadsheet as a live, filterable explorer.

The licensing is split on purpose: the software is MIT, while the transcription and all derived data remain the professor's — his life's work stays his.

What we'd tell a client

  • If your data already has structure — even in a Word file — honor it instead of re-inventing it. The heading hierarchy was the schema.
  • Validate against an independent source of truth and treat the discrepancies as deliverables, not noise.
  • Respect the domain's conventions: exact-punctuation search sounds pedantic until it's the whole point.
  • Offline copies still matter. A single file that works from a double-click travels further than any deployment.