Skip to content
An official website of the OECD. Find out more
Created by the Public Governance Directorate

This website was created by the OECD Observatory of Public Sector Innovation (OPSI), part of the OECD Public Governance Directorate (GOV).

How to validate authenticity

Validation that this is an official OECD website can be found on the Innovative Government page of the corporate OECD website.

Using Rules as Code during COVID-19

Editor’s note: This guest blog, authored by James Fisk of the New Zealand Government’s Ministry of Business, Innovation and Employment, is a case study in the creation of Rules as Code. James is part of the GovTech Talent Digital Graduate Programme, which is a 24-month programme where graduates rotate across three different government agencies.

Rules as Code is a topic that OPSI is currently exploring through its draft Innovation Primer. Cracking the Code: Rulemaking for humans and machines is currently available for public consultation until 24 June 2020.

Better Rules – better outcomes

The COVID-19 pandemic has given us and our government many challenges, from making sure that citizens are safe to helping the economy survive. Our team wanted to help.

The Better for Business team is part of the Ministry of Business, Innovation and Employment in New Zealand (NZ). Our work with Better rules – better outcomes has helped the NZ Government with the COVID-19 response.

Better rules is an initiative that rethinks the way government develops and implements legislation, regulation, and policy. Simply put, Better Rules is a methodology for producing Rules as Code (RaC).

When the NZ Government announced the Wage Subsidy Scheme as part of the COVID-19 response to support businesses, we jumped at the opportunity to help by creating a digital tool for businesses to check if they are eligible for the wage subsidy. The wage subsidy is a 12-week support package for employers to continue paying their staff while they are unable to work due to the lockdown. It was crucial to get this right.

How the Better Rules methodology works

The Better Rules approach is a methodology that not only allows us to create RaC, but also to simplify a complex process such as the wage subsidy by creating:

  1. Concept models
  2. Decision trees
  3. Rule statements
  4. Rules as Code

The Better Rules methodology typically uses human-centered design techniques and a multi-disciplinary team of business analysts, service designers, software coders, policy analysts and subject matter experts that work in a shared space. Together the team creates an understandable and more accessible expression of the rules that expresses the intent of the regulatory system.

The Wage Subsidy Scheme and Better Rules

We supported the COVID-19 response by creating a digital decision tool for businesses to check their eligibility for the wage subsidy. The tool aims to reduce the amount of complexity that the user experiences while trying to determine their eligibility for financial assistance.

We had a team of five people using the Better Rules methodology to create the wage subsidy tool and had two working days until the tool went live. This required fast iterations and turn around, which we proved to be possible. Previously, we have used the Better Rules approach for projects with a longer design or implementation timeframe, such as the SmartStart project.

The example below is the tool we developed with the Better Rules methodology to help businesses with the wage subsidy application.

Figure 1. Wage Subsidy Eligibility Tool

How we used the Better Rules approach for the Wage Subsidy decision tool

Step 1: Creating the concept model

The concept model is a roadmap that develops the meaning of core concepts for a problem domain. A core concept in the Wage Subsidy Scheme would be “business” or “revenue”. It defines the core concepts’ collective structure and specifies the appropriate vocabulary needed to communicate consistently.

We analysed the available information and, within a few hours, we derived the core concepts that made up the working concept model (Figure 2). The boxes contain the common concepts in the wage subsidy domain and the lines have verbs to show the relationship between the concepts. It also shows where there could be areas of complexity, such as with employment types and business types.

Figure 2. Concept Model for the Wage Subsidy Scheme

Step 2: Decision trees

A decision tree identifies and analyses key questions that arise out of a concept model.

To answer key questions, we use a Q-COE. The Q-COE approach was founded by Business Rules Solutions and outlines:

  • What question (Q) is being asked
  • Considerations (C)
  • Outcomes (O)
  • Exceptions (E) to be aware of.

In the example below, we created a decision tree based on a question discussed when analysing the wage subsidy concept model: “Is a business eligible for the wage subsidy?”

The decision tree provides the foundation for the rule statements that are created in the third step of the Better Rules methodology.

Figure 3. Decision tree for the Wage Subsidy Scheme

Step 3: Rule statements

Rule statements detail the logic of rules derived from the decision trees. Rule statements are a set of practical guidelines. They use the answers from the Q-COEs used in the decision tree and are formatted in a way that can be understood by the different groups working in a domain.

A simple rule statement in the Wage Subsidy Scheme would be, “A business is eligible for the wage subsidy if they have experienced a loss of 30% revenue”.

Rule statements are structured in a way that they can be expressed in English words and translated into RaC.

Step 4: Producing Rules as Code

By doing the previous steps, we can produce Rules as Code.

The software we used to create the digital tool was on CMS in SilverStripe, an approved government website application that has an embedded rules engine. It proved important that by doing the previous steps, the rule statements we put in the rules engine would have the correct intent.

If there are any changes to the eligibility criteria or if rules change – we can use the previous steps of the Better rules approach to make changes accordingly.

Feel free to try the wage subsidy eligibility tool yourself.

What we have learned

We have learnt from working during COVID-19 that:

  • We can be flexible in our approach
  • This approach creates a simple representation of a complex space
  • It is important to focus on influencing the detailed design and implementation of the rules.

We found that we could be flexible in our approach. Typically, we are involved at the start when policy and legislation is being written. Here, we were able to tailor our approach for a different space and still provide assistance on the design and implementation of the tool. We also learnt that this approach could be adopted and applied to other areas.

We focused on the detailed design and implementation of this tool. The tool is focused on giving guidance on what a business could do. We needed to ensure that the information going into the tool was correct and not creating extra burden for the end user.

The Better Rules approach has shown how valuable it can be for producing RaC by following the steps discussed above. It has also shown how the steps can be tailored and applied to areas outside of RaC and be still beneficial.

Creating RaC could provide significant economic benefits, improve government service delivery and enable innovation. Not only does this benefit the public good, but also those creating it. We must continue to develop Better Rules and RaC and support similar initiatives developing around the globe.

To find out more about Better Rules, email us at [email protected].