@barrowjoseph: New paper: every law in America is technically public. But not really, until now! With @DenisPeskoff at UC Berkeley, we…
Summary
A new paper builds and releases a corpus of 2.2 million city and county laws from across the United States, making publicly accessible legal texts that were technically public but hard to find.
View Cached Full Text
Cached at: 06/22/26, 01:37 PM
New paper: every law in America is technically public. But not really, until now!
With @DenisPeskoff at UC Berkeley, we built a corpus of ~every publicly accessibly city and county law, and released a huge chunk of it!
2.2 million laws, you’re (probably) covered in it!
First, the released dataset has pretty good geographic coverage, and accounts for a majority of the US population!
Everything including zoning, noise, housing codes, and whether or not you can ride an ATV without a license.
How do you build such a dataset when all the laws come in heterogeneous formats? To me the obvious answer is: OCR it all!
In this case, using the smallest/best OCR model we could, @LightOnIO’s LightOnOCR-2-1b.
That gives us a high-quality, consistent format we can parse.
First approach was to try and make my local GPUs go brrrr.
That worked quite well for the first million pages, but we had millions more to go, and needed to scale.
Thankfully @modal (and @charles_irl) very kindly provided a compute grant to make this work happen!
You wanna really see GPU’s go brrr? (And CPUs, for rendering)
We were able to process all 7M pages at ~0.30/1k, much cheaper than options like AWS Textract (1.50/1k pages).
Once we had processed the laws, the question was: how to analyze them.
One idea I really like is @TheStalwart’s http://Havelock.ai, where he distills pairwise comparisons from an LLM + TrueSkill into a BERT model to score orality.
In our case, we do the same for the laws across 4 axes: paternalism, opacity, enforcement discretion (how much leeway does the law provide), and salience.
We analyzed the 2.2 million laws and some interesting patterns emerged.
California and Florida, you need to get your shit together so people can actually understand your laws! And Ohio and West Virginia, wtf is going on with how you run people’s lives??
Our released dataset scores all 2.2 million laws along these axes, and we’ve released the distilled models for scoring/understanding the laws!
All distilled into @benjamin_warner/@bclavie/@antoine_chaffin/@orionweller/@answerdotai’s ModernBERT.
Paper Link: https://arxiv.org/abs/2606.19334 Dataset: https://huggingface.co/datasets/LocalLaws/LOCUS-v1… Models: https://huggingface.co/LocalLaws
And obviously a huge thank you to @modal for enabling this work.
N.B. I wonder if we’re the first academic citation for @TheStalwart’s @Havelock_AI.
If there’s a better way to cite, let me know and I’ll update the preprint!
Very cool, happy to chat. Though from what I understand municode only covers a fraction of municipalities — benefit of our approach is coverage, though you do lose the “easy weekly diff”
We have not done that yet, but I think it’s an excellent (and worthwhile!) research project.
Please tell me more?
LOCUS is what we could get from the internet. The scans are just… what’s available for some municipalities. And some don’t have an online presence to the best of our knowledge.
Don’t really have a good definition of common sense or good enforcement, unfortunately.
We tried to tease some of that out with the axes (opacity is what makes a law difficult to understand, for instance, or enforcement discretion relates to what makes it arbitrary to enforce.)
If you give me more info about the shape of the data happy to offer advice!
No dedup applied at all! A (municipality, law) tuple is unique, but some laws might be reused across municipalities! Tbh a neat research project imo!
Formatting? OCR and vision language models.
Text and dataset linked!
Whole thing is already available for download and perusing on @huggingface !
Federal? No. State? Not yet.
Similar Articles
Freeing the Law with LOCUS: A Local Ordinance Corpus for the United States
Introduces LOCUS, a comprehensive corpus of U.S. local ordinance codes designed to enable machine-readable legal AI research, covering codes from 9,239 cities and counties with ModernBERT-based classifiers for analysis.
Court Records Should Be Free
The Open Courts Act of 2026 would eliminate PACER fees and modernize federal court electronic filing systems to improve public access and cybersecurity. The article argues that court records belong to the public and should not be behind a paywall.
PapersWithCode new features - week 1 [P]
Niels from Hugging Face announces new features for the revived PapersWithCode platform, including multi-metric leaderboards, support for external papers, paper lineage, and more.
@james_y_zou: We added >220K FDA regulatory and >1M clinical trial docs to #paperclip. All natively indexed for agents and free. Now …
Paperclip adds over 220K FDA regulatory documents and 1M clinical trials from multiple registries, enabling AI agents to search and reason over clinical and regulatory data without web search. This update allows users to query FDA documents, ClinicalTrials.gov, and international registries via a unified filesystem interface.
Automatic Construction of a Legal Citation Graph from 100 Million Ukrainian Court Decisions: Large-Scale Extraction, Topological Analysis, and Ontology-Driven Clustering
This paper constructs the first large-scale citation graph from 100.7 million Ukrainian court decisions, extracting over 500 million citation links. It demonstrates that the citation structure can automatically recover legal domain boundaries and predict legislative importance with near-perfect accuracy, and releases the pipeline and data as open resources.