The full research background for RegelRecht's execution-first validation method, fifteen years in the making.
Turning law into working software is hard. For fifteen years, teams have worked in silos on methods, frameworks, and languages for formalizing legal rules. None of them scale.
This document traces those fifteen years and proposes a validation method that fits the way RegelRecht works.
Wetsanalyse is a legal analysis method developed in the practice of Dutch implementation agencies (Belastingdienst, UWV, DUO). The method is codified in the book Wetsanalyse (Ausems, Bulles & Lokin, 2021) and maintained by Lokin (Hooghiemstra & Partners) and Gort (ICTU).
The core of Wetsanalyse is the Juridisch Analyseschema (JAS): a classification system of 13 element types that labels every formulation in legislation, from legal subject and legal relationship to derivation rule and condition.
The process has six steps:
It has three characteristics:
The output is a knowledge model consisting of a data model (FBM/ER), rule model (DMN decision tables), and process model (BPMN). This model is the basis for building an IT system.
Despite differences in terminology, existing methods follow the same pattern:
All these methods are analysis-first: they start from the law and work toward a model or rule set. The translation is done entirely by people.
RegelRecht is a broad execution ecosystem for making laws machine-executable, wider in scope than a method or a DSL. Three principles set it apart from the analysis-first tradition.
Where existing methods share an analysis-first approach, RegelRecht aims to create a coherent system of machine-executable legislation. Laws interact across boundaries and citizens are not burdened with complexity.
The rule specification gets single source of truth status for how the law works. It is not an analysis layer that leads to a translation. The output of the analysis is the law in executable form.
The execution-first starting point requires transparency: open source, and understandable to experts from different disciplines when they need to reach a joint decision on how laws work.
The core of the rule specification schema consists of simple logical operators that people can verify. No vendor lock-in, no convoluted stack of schemas.
Existing methods laid the groundwork for dealing with the legal reality of machine-executability. That process is interdisciplinary and intensive.
Within the RegelRecht ecosystem, generative AI is the starting point: AI generates candidate rule specifications, and the analysis (or validation) runs against those candidates. This creates potential for faster and broader coverage.
AI changes the role of the legal expert:
| Analysis-first | Execution-first | |
|---|---|---|
| Who creates? | Human | AI |
| Who validates? | Same team | Legal expert |
| Cognitive task | Build + check | Challenge + judge |
| Traceability | Built in at creation | Checked after the fact |
| Interpretation choices | Explicitly documented | Implicit in AI output |
| Scale | Limited by human capacity | Limited by validation capacity |
The bottleneck moves from creation to validation.
The shift introduces specific risks that do not exist in analysis-first:
The current RegelRecht ecosystem already has an automated pipeline:
The automated steps cover:
A structured process for legal experts to systematically assess the AI proposals is missing. This differs from the Wetsanalyse validation step (step 4), because:
This is the current pipeline. The AI generates a candidate rule specification and automated checks filter structural errors and untraceable elements. The output is a proposal with documentation:
The expert reviews the proposal before scenarios are run. This is the phase missing from the current pipeline and it draws on insights from Wetsanalyse:
B1. Completeness check: Are all articles covered? Did the AI skip articles that contain executable logic? This is analogous to the scope step (step 1) of Wetsanalyse, asked after the fact: has everything been analyzed?
B2. Assumption assessment: Reverse validation has flagged assumptions. The expert assesses each one: is this a defensible choice, or does it need to change? This addresses the risk of implicit interpretation choices.
B3. Interpretation inventory: Where does the law allow multiple readings? Which reading did the AI pick? Is it defensible? This is analogous to the meaning step (step 3) of Wetsanalyse, asked in reverse: is the AI’s reading correct? This step counters automation bias.
The expert validates the behavior of the specification, not the YAML itself.
C1. Walk through MvT scenarios: The engine runs scenarios from parliamentary documents. The expert checks whether outcomes match legislative intent.
C2. Build adversarial scenarios: This is where the expert is irreplaceable. The AI has no access to case law, implementation practice, or political context. The expert builds scenarios that stress-test the specification:
C3. Run adversarial scenarios: The engine runs them. The expert checks the outcomes. Errors lead to iteration.
Analogous to the policy-gap step (step 5) of Wetsanalyse:
The expert reviews reports and outcomes, not the specification itself. The automated pipeline delivers:
The difference with Wetsanalyse validation matters: the expert did not build the proposal and must actively search for errors. The method structures that search by asking for adversarial scenarios.
Worked examples from the Memorie van Toelichting represent the legislature’s intent. If the engine produces a different result than the MvT example, the specification is wrong, not the example.
The method itself is developed via a Design Science Research approach:
| Wetsanalyse step | RegelRecht equivalent | Difference |
|---|---|---|
| 1. Determine scope | Phase A: select law | Same |
| 2. Structure annotation (JAS) | AI generates machine_readable | Human → AI |
| 3. Pin down meaning | B3: Interpretation inventory | Proactive → reactive |
| 4. Validate with scenarios | C1–C3: Scenario validation | Own work → someone else’s proposal |
| 5. Flag policy gaps | D1: Note policy gaps | Same |
| 6. Build knowledge model | Phase A: machine_readable YAML | Human → AI |
The method keeps the discipline of Wetsanalyse (traceability, scenarios, policy gaps) but adapts the execution to the reality that the expert judges rather than builds.
An exploration by Bureau Architectuur of the Dutch Ministry of Economic Affairs and Climate Policy into the possibilities of transparent, executable legislation.
GitHub repository
How it works
Stay informed
Documentation
Research
Bureau Architectuur
Ministry of Economic Affairs and Climate Policy