Date:
10 February 2023

The main focus for this month's Melbourne Drupal Meetup was a presentation by Suchi Garg and Phillipa Martin.

Phillipa started the presentation by looking at the context behind a recent Rules as Code (RaC) proof of concept. She then moved onto the process of codifying Australia’s COVID vaccination rules. Suchi then took a deep dive into how the Drupal OpenFisca module works with a Drupal webform. She also talked about how the webform sends API calls to OpenFisca, and how based on the responses, the user is redirected to different pages and results are generated and displayed.

Exploring Drupal and Rules as Code: A GovCMS proof of concept (presentation summary)

In this presentation, the speakers Suchi Garg and Phillipa Martin discuss the integration of Drupal with Rules as Code, focusing on a GovCMSExternal Link (a whole-of-government content management system for Australian Government) proof of concept project. The presentation covers the process, architecture and benefits of using Rules as Code with Drupal, showcasing a practical example related to COVID-19 vaccinations.

Rules as Code overview

The presentation begins with an introduction to the topics to be covered, emphasising the relevance of Drupal's involvement in Rules as Code for government projects.

Context and project background

The Gov CMS project emerged in response to a request for expressions of interest. Suchi and Phillipa highlight a particular user journey concerning citizens navigating entitlements and compliance with government policies. This led to the exploration of codifying Rules as Code for improved accessibility and transparency. The presentation also references another ongoing project, BenefitMeExternal Link that codifies New Zealand's Social Security Act.

Rules as Code defined

Rules as Code involves transforming legislation, regulations or policies into machine-readable code. The benefits include reduced ambiguity, accessibility, reusability and easier policy formulation. OpenFiscaExternal Link , an open-source Python-based rules engine, is introduced as a key tool for Rules as Code projects.

Solution architecture overview

The architecture involves user interfaces (websites, mobile apps) connecting with both Drupal and OpenFisca. The aim is to illustrate how they function together in the context of a rules-based project.

GovCMS proof of concept (PoC)

The presenters delve into a proof of concept for GovCMS. The challenge was to help citizens determine their COVID-19 vaccination status. Two user journeys were created:

  1. Checking vaccine status
  2. Vaccine requirements for work

Suchi and Phillipa showcase a user interface that enables individuals to input information and obtain results based on OpenFisca's evaluation.

Exploring the user interface

The user interface provides examples of scenarios users might face, such as checking vaccination status for various age groups. A step-by-step walkthrough demonstrates how inputs lead to OpenFisca evaluations to ultimately inform users whether they’re up-to-date with their vaccinations.

Workflow and configuration

The presentation shifts focus to the workflow and configuration process. Rules analysis involves mapping plain English rules into machine-readable code. OpenFisca's configuration includes defining entities, parameters and variables, crucial for calculations. Drupal's integration is showcased through a custom module named "Webform Fisca."

Deep dive into configuration

Suchi demonstrates how the Drupal module links web form fields with OpenFisca variables, ensuring seamless interaction. She emphasises the importance of defining variables and parameters, enabling accurate evaluations. She also explains the significance of input variables and how OpenFisca's calculations work in response to these inputs.

Rules content and journey mapping

The project's rules content involves mapping out different scenarios and their corresponding actions. This section includes a glimpse into related content creation, where tokens are used to dynamically present OpenFisca's evaluated results within Drupal content.

Bringing it all together

The presenters emphasise the importance of defining the journey based on OpenFisca's evaluations. They explain how Drupal's content types, along with OpenFisca's evaluations, guide users through different pathways and present relevant information based on evaluations.

Q&A and conclusion

The presentation concludes with a Q&A session, allowing attendees to seek clarifications and insights from the speakers. The overall message conveyed is the synergy between Drupal and Rules as Code, enabling user-friendly interfaces backed by accurate evaluations of complex regulations.

Closing remarks

The presentation successfully showcases the integration of Drupal and Rules as Code in the context of a GovCMS PoC, offering insights into the benefits and process of using machine-readable rules for enhanced user experiences.