What is Rules As Code?
Rules As Code (RaC) is the process of taking legislation, regulations and policies and turning them into machine-readable code so they can be understood and interpreted by computers. The encoded legislation exists alongside the natural language version (it does not replace it) to facilitate digital service delivery.
Why Rules As Code?
Turning rules into machine-readable code provides many benefits for government, citizens and broader society. RaC helps to reduce ambiguity, reduces the difficulty of interpretation and therefore makes it easier for citizens and organisations to comply with the rules. Importantly, it also leads to greater transparency in rules.
Turning legislation into code can also identify gaps and inconsistencies in the original legislation.
What type of legislation can be coded?
In general, rules (legislation, regulation or policy) that are prescriptive rather than discretionary are best suited for coding. However, it’s worth mentioning that the that discretionary rules can be written in code too.
In terms of focus, because the process of transforming existing legislation into code can be complex and time consuming, focusing on rules that can reduce the burden on citizens, create service efficiencies or automate processes will have the most immediate impact.
When to code rules?
While most rules will be coded after the legislation is written, writing RaC alongside the written legislation (i.e. at the same time) is the most efficient approach and can significantly improve the quality of the written legislation.
Who’s using Rules As Code?
Many governments around the world are exploring and implementing RaC — although it’s still definitely an emerging field.
New Zealand and are also active in this space. Rules As Code is part of NZ’s , which brings a new approach to policy and legislation. RaC was also used in creating NZ’s , a portal for NZ parents that includes birth registration.
Rules As Code and the Observatory of Public Sector Innovation (OPSI)
The OPSI has a dedicated . One of the outcomes of that project was OPSI’s report . The report provides an introduction to RaC, including benefits, use cases, the effort involved, and general advice and guidelines.
RaC is an emerging field and it’s currently being used in several projects and jurisdictions. Case studies include:
- GovZero Aotearoa (New Zealand)
- Fair Trading New South Wales (Australia)
- Mes Aides (My Helpers) — Entitlements eligibility simulator (France)
- Lex Impact — Policy difference engine (France)
- Les meves ajudes (My Aides) — Entitlements eligibility simulator (Spain)
- Rapu Ture — Exploring the Rules (New Zealand)