Guido Governatori, Hamish Fraser, Matthew Waddington, Tom Barraclough and Devansh Kaushik

LSPR would like to acknowledge the contribution of the following people in organization of the panel discussion. Editors: Keshav Soni, Prem Parwani, Anant Prem Joshi, Uday Dabas, Rohan Mehta, Mohit Meena. Technical Editors: Shauryaveer Chaudhry, Jaisila Bajaj. Observers: Bala Yamini, Pranav Mittal, Bhavya Parameswaran Lakshmi. Volunteers: Sriram Adithya Gopinathan, Satej Prabhughate, Aadit Anand, Mohamed Thahir Sulaiman
On 9th February 2025, Law School Policy Review hosted a panel discussion on ‘Rules as Code’ with Professor Guido Governatori, Hamish Fraser, Matthew Waddington, Tom Barraclough and Devansh Kaushik as the moderator. The panel explored the feasibility and implications of translating legal rules into machine-readable code. The conversation delved into the conceptual, practical, and philosophical dimensions of the initiative—discussing its potential to enhance legal clarity, aid enforcement, and transform policymaking. The panellists examined questions around discretion, automation, interpretation, and accessibility, emphasizing both the promises and limitations of coding the law. They also debated the roles of public and private actors, the suitability of the approach across jurisdictions, and the importance of preserving human oversight in an increasingly digitized legal landscapeLISTEN TO THE RECORDING
Prem Parwani
Hello, everyone. My name is Prem Parwani, and I am the Editor-in-Chief at the Law School Policy Review (‘LSPR’). Today, LSPR is hosting a panel discussion on ‘Rules as Code’. The concept of ‘Rules as Code’ is based on turning legislation into computer-readable code that can be understood and interpreted by computers. It is done not just to improve the drafting and implementation of the law, but also to help people better understand the law. Today’s panel will discuss this concept and try to explore whether it is feasible to code the law and what are the challenges surrounding it.
In today’s panel, we have firstly, Professor Guido Governatori, who is a Professor of Information and Communication Technology at Central Queensland University, and he is a Research Fellow in responsible AI and Cyber Futures Institute, Charles Sturt University.
Secondly, we have Mr. Hamish Fraser, who is a software developer and researcher, and he is the director of Verb. He has worked to improve digital civic infrastructure and is a recognized pioneer of ‘Rules as Code’ and the better rules programs.
Thirdly, we have Mr. Matthew Waddington, who has been a legislative drafter since 2004. He leads the Computer-Readable Legislation Project at the Legislative Drafting Office in Jersey. He also teaches part time at Jersey’s Institute of Law.
We also have Mr. Tom Barraclough, who is a director of BrainBox Institute. He is a legal researcher and consultant working in the intersection of law, policy, and technology. He works with the civil society, industry, and the government.
This panel discussion will be moderated by Devansh Kaushik. He is the Head of Operations at Lucio, an AI-powered tech platform. He previously worked as a technology lawyer at Cyril Amarchand Mangaldas and is a graduate of NLSIU, Bangalore. So let’s start with our panel discussion.
Devansh (Moderator)
Welcome everyone to our discussion on ‘Rules as Code’. Now as we all know, but for the benefit of the audience, ‘Rules as Code’ is a concept that proposes encoding laws in machine-readable formats ostensibly to improve accessibility, enforcement, and compliance. In this very diverse panel today, we have practitioners, academics, and the leading voices in this area.
We will explore whether ‘Rules as Code’ can actually work in complex legal systems. Which are the stakeholders that should be involved and what are the potential risks. Now, in order to ensure a balanced discussion, I will play the role of a sceptic. I will question the panellists = regarding some of the more optimistic claims. ‘Rules as Code’ Let’s start with Hamish who has been a key figure in implementing ‘Rules as Code’ initiative in the real world.
Hamish, can you give us a quick overview of what is the problem that rules as code is trying to solve? And what does success look like?
Hamish Fraser
I’ve always looked at it from the perspective of the purpose of the law. The principle behind the rule of law is that the law s clear and clearly enforceable, butwe’ve wandered from that to some degree.
There’ll be a lot more qualified people to talk to that specifically but we also have invented computers which we’ve used in multiple different fields to deal with complexity. The use of computers to understand complex things is not new either.
So applying the concept of ‘Rules as Code’ is just using these tools which have already been used in other areas. To model this complexity that we find in law, the question is: how do we do that well, and how do we do that correctly? And also on how do we do that in a way that continues to honour the institutions in the separation of powers and the constitutional arrangements that we have set up surrounding this rule of law concept. And that’s something that, when I first was involved in this work, wasn’t particularly clear to me.
Through the research work that Tom and myself have done, it has become apparent what was the role of ‘Rules as Code’ and models of law and code. So Tom will probably go into more detail in the future in this panel, but tackling that complexity and making the law explainable I think is a really key component.
Devansh (Moderator)
. So, Tom, you have worked on ‘Rules as Code’ as well on policy and technology. Do you think that the legal system—as it exists currently—is ready for the shift, or are we pushing a solution onto a system that is already broken? In the sense that the legal system is already so complicated and so far down the road, so broken, so dynamic, and so unconnected to logical flows and principles that it cannot be automated.
Tom Barraclough
I think that’s a really good question. My background in this area involves working with Hamish, and we took a critical look at the concept of ‘Rules as Code’. Part of my background before getting into technology policy was helping people with their claims against the government in New Zealand. My experience involved observing very complex and poorly drafted laws being applied in ways that were not very principled. I also saw the role of large institutional operational systems in trying to deliver systems of law and entitlements to people and observed that they were not working very well.
When I saw Hamish and the work he was doing—along with many others the work that Guido was doing over in Australia—I approached it from the perspective of these two things: law and code. It’s interesting how they sometimes align, as both involve systems of logic and computational processing when applying legal systems at scale. However, there are also critical differences between law and code, as they are fundamentally distinct in how they are applied—sometimes for good reason.
In terms of your question, we have focused on finding areas—tightly defined and specific areas—where we can explore the implementation and development of “rules as code.” One key takeaway from our research is that you can not codify all laws, nor is it appropriate to attempt to turn all laws into code. For instance, it’s not necessary to draft legislation in the same way that code is written, as doing so would make the problem worse. Drafting legislation like code would result in excessively long and complex texts, requiring consideration of every single detail, which would not improve the situation. So what we’ve tried to focus on is how can we find areas where we can actually tightly define a particular set of laws.
We have concentrated on identifying areas where we can precisely define a specific set of statutes, regulations, or other legal instruments, and deploy operational systems to both learn from the process and demonstrate how it can be done. Our aim is to provoke discussions through our work, openly and transparently, to address some of the concerns people might have—particularly regarding the notion of a “robot judge” scenario.
Devansh (Moderator)
Got it. That’s a very fair point. Matthew, I would like you to chip in here. The question I would raise is that we are just attempting to fix a symptom rather than addressing the core problem? For instance, instead of encoding, why not focus on using plain English or more logical, cleaner drafting?
There are movements all around the world, including in India, Australia, and the UK, to write clearer and simpler laws that are understandable to the masses. Do you think those solutions are better placed, or are we just attempting to over-engineer a solution here?
Matthew Waddington
I don’t think it’s a choice. I think plain language drafting is a reality now—it’s what everyone is trying to do. However, human life is complicated and is becoming more complicated, and regulating it is equally complex. You’re not going to get away from that in the modern world.
So, as much as you try to make the English expression—or any other natural language expression—as simple as possible, if you have complicated rules, people are going to need help with that. To me, that’s where technology comes in. I was interested in listening to Tom earlier—there are so many things we agree on, and then some points where we sort of disagree.
The blog piece I wrote for the symposium was about the idea that “it’s not for all law, it’s only for some.” Our approach, however, is that it’s for all law—not necessarily for all existing law, because you can’t fix the problems in existing law, but for all new law. It’s just that it’s not for all of what’s in that law. It’s not about automating the life out of the law—that’s not what we are interested in.
From what both Hamish and Tom were saying, if your concern is public understanding of the law, it is not about automating the execution of some process within the law—it’s about helping humans follow the logic and understand the structure. It’s not about telling them what every word means when those words haven’t been defined in the law—that would go beyond what the law says. Instead, it’s about guiding humans to the right questions—that’s how we see it.
It seems obvious when you have a short, simple provision, but when you start adding them up, it gets more complicated. People get lost, and even drafters can get lost. We’re doing some teaching for new law students where they are taught how to understand statutes at the beginning of their law degree. One of the examples they’ve been given is an Anti-Social Behaviour Act from the UK, where there are conditions for issuing a community protection notice against someone, followed by an appeal right. The drafter then sets out a bunch of grounds for appeal, but those grounds don’t match the conditions for issuing the notice. To me, that’s a basic drafting mistake.
It’s not just that the drafter can go wrong—many people reading it go wrong too. It’s difficult to explain even to law students. We ought to be able to do this better. As Hamish was saying, technology has been around for a while. One of the things we often point out is that we’ve been publishing legislation on the web for ages. Doesn’t the web involve hyperlinks? Isn’t that what it’s for? Why are so many of us publishing legislation without hyperlinks?
Yes, obvious cross-references are technically difficult, but definitions and terms that use those definitions should always be linked. Every time you see a defined term, there should be a pop-up that takes you to the definition. When you say it, it seems blooming obvious. It may be technically difficult, sure, but why haven’t we been demanding that tech experts provide a solution for this? This process changes the way you approach drafting—it’s a useful process for both the drafter and the reader.
Devansh (Moderator)
Got it, it’s very interesting you pointed the hyperlinking question Matthew, and I have no explanation for why this hasn’t been implemented.
I’m quite curious about what you mentioned earlier. I see this a lot— as a legal technologist myself, I often observe this dichotomy where lawyers blame the engineers, and engineers blame the lawyers. Engineers say, “You didn’t write the rules correctly,” while lawyers say, “The engineers didn’t write the program correctly.”
That’s my question. If we’re talking about “rules as code,” aren’t we essentially inserting a new layer—a new human element of programmers, in the drafting process? Would that imply a shift in power, where programmers now have influence over how the law is presented to the masses, exercising control and discretion over it? Do you think that’s true?
Guido Governatori
The real issue for me is that when you build a rule-of-code system that is understandable by both lawyers and programmers, in the end, if you just take the current state of computation, then essentially—strictly speaking from a computational point of view—it doesn’t really matter which language you use. If you still trust the basic assumption of computation, then everything that is computable can be processed by the machine.
So, why don’t we just encode everything into the machine? Simply because nobody would be able to understand it. Essentially, what we have to do is create the tools, languages, and formal systems that enable both lawyers and computer scientists to understand what’s going on. That’s the complicated part.
Now, regarding hyperlinks—there are tools available. When I was speaking with drafters in the Australian parliament and also in other parliaments, they mentioned that they have tools for using references and for checking the correctness of those references. For instance, if you look at the Prime Minister and Cabinet (PMC) in Australia, they have tools in place, and they use them to verify references. So, it might depend on the maturity of the system used by the drafters.
Now, on the other takes—as Matthew said—I agree on many points but also disagree on others. One thing we all agree on is that we cannot code the entire body of legislation for a country. It’s too vast and too expensive, and in some cases, it would be useless.
Essentially, what we have to do is focus on areas where there is a potential benefit. We could even encode a constitution, but often there’s no value in doing that simply because it’s too much about interpretation, and there wouldn’t be a real benefit. On the other hand, encoding some legislation that is used thousands of times every single day—like traffic rules—could provide value because that’s where you have a structured framework to work with.
The key is to find the trade-off between what we need to do, what we can do, and where we will get a good return on investment. At this moment, encoding legislation is extremely time-consuming and expensive. One person can encode about 45 pages of legislation per day, but the risk of burnout is very high, which means it requires a significant investment. We need to carefully consider where to allocate that investment to get meaningful benefits.
Devansh (Moderator)
Sowe’re now getting into practical constraints. Hamish, I think you’re the person to reach out to here. Critics of ‘Rules as Code’ often raise the specter of the entire challenge by arguing that you can’t encode an entire legal system, and they try to hold proponents to that standard.Do you agree with that? Or do you think that with recent advancements, the shift from machine learning to large language models, whether now—or at some point in the future—it might be possible to at least reach a certain degree of capability there.
Hamish Fraser
There are two quite distinct perspectives on this work—within and outside of the public service—when dealing with the law as it’s already made. One of my earlier roles was working on what is known as “Better Rules,” which involves designing policy and drafting instructions for composing law. My experience in that role shaped my ultimate goal: to improve policy processes and write more informed laws.
In that early work, the drafters were particularly excited about the Better Rules concept because they wanted better drafting instructions from policy teams. This was interesting to me because, from their perspective, it must be worthwhile—they were the ones closest to the task at hand. However, it soon became apparent that we didn’t have the tools needed to bring policy people on board and have them use those tools effectively. That led us to focus on rules-as-code engines, exploring what existed in that space and identifying what was needed to bridge the gap.
As we delved into the engines, I realized—based on the research that Tom and I were doing—that the link between natural language rules and rules-as-code models was a real problem. We needed to clearly articulate in our code exactly what we were describing and link it back to its source. While that sounds simple, the reality is far more complex.
When you factor in constantly changing documents—often updated annually—along with the need to track code that is difficult to write in the first place, maintaining it becomes even harder. On top of that, you need to consider case law developments, evolving interpretations, building reliable feedback mechanisms, and ensuring scrutiny through comprehensive test suites. We realized that linking natural language and computational rules effectively was essential, and we also needed to address how rules were being published—a point that Matthew Waddington touched on about hyperlinks and identification IDs.
Currently, I find myself deep in this rabbit hole—looking at how legislation is published to solve that problem—so that we can ultimately return to the rules engines and models with interpretations that are maintainable and trustworthy. That way, we can bring all the necessary tools and insights back to the policy development space.
Like Matthew, I believe all new laws should go through this improved process. From the Better Rules perspective, we can and should do policy better—we have the tools to make it happen. However, I don’t see any practical reason to tackle the entire body of law, and I remain skeptical about the current capabilities of AI and large language models in this context. The human level of interpretation required to grapple with legal texts is still far beyond what these models can manage.
For instance, we recently worked on a small set of rules in New Zealand—the Drinking Water Quality Assurance Rules, specifically the reporting requirements for drinking water suppliers. Although these rules were fairly prescriptive and computational, there were still numerous points where human judgment was necessary to resolve contradictions within the document. By the time we completed our model, we had both a representation of the rules and a record of every interpretive decision made—areas where human expertise was essential to clarify the original rule set.
That level of patience and attention to detail can’t be achieved by simply feeding documents to a large language model and expecting accurate, nuanced outputs. I don’t see that becoming feasible anytime soon.
Devansh (Moderator)
Got it. That was a very useful insight, Hamish. Tom, I would like to bring you in at this point, do you agree with Hamish on this that, total ‘Rules as Code’ or is a goal that can never be reached.Given if that is true then do you think the purported benefits of ‘Rules as Code’ are achievable if we cannot capture the nuance of judicial interpretation, policy goals, and case laws in a set of digital rules.
Tom Barraclough
I have been sitting here listening to the really interesting discussion, and I would like to make a few points that draw across all the comments that have been made. I would also love to bring in Guido afterward, as I know that you have been working in this space probably the longest of all of us, in terms of putting it into context. One of the other interesting things about ‘Rules as Code’ , when it emerged in 2018 in the form that it has now, is that there was a long history of attempting to convert law into code. Many of the newcomers to the ‘Rules as Code’ space were not necessarily aware of that, as they might have been working in policy environments within government rather than in academia. As a result, they did not see it in that context.
Hamish described an example we worked on with the drinking water quality assurance rules. I find it an insightful example because it highlights that the space for ‘Rules as Code’ may be in areas that are not necessarily related to legislation or case law. If we think about regulation and the extent to which it shapes economic and government activities, much of it is not necessarily legislation itself, but rather a cascade of different legal and regulatory instruments that must work together. This is why it is tempting to focus solely on legislation and place the burden on legislative drafters and policy experts to develop expertise in how we should be publishing law in a perfect format. However, in response to one of Matthew’s points, the reason we have not seen that happen is that it is often considered an add-on—a “nice to have” rather than an essential. In reality, the lawmaking process is messy, political, and marked by compromise, making it unlikely to ever reach a utopian state of coherence. This is why it is important to focus on small, isolated examples.
I would also like to add one more point. In a recent paper in the MIT Computational Law Review, we explored the drinking water quality assurance rules example and combined it with an understanding of current regulations around artificial intelligence and large language models, particularly in the European Union, which is the first mover in this area. I argued that, for ‘Rules as Code’ systems to generate excitement among public and private sector decision-makers, they must demonstrate the automation of tasks that would otherwise require human effort. This justification is necessary to account for the time and expense involved, including the investment required to transition entire systems onto new tech stacks.
If we are to make a significant impact with ‘Rules as Code’ , it will likely occur through the automated implementation of laws and regulations. However, it is important to recognize that many ‘Rules as Code’ systems could easily fall into the category of automated decision-making systems, which are subject to enhanced regulatory oversight, particularly in the European Union context. One example is the exploration of ‘Rules as Code’ for visa processing, which would be categorized as a high-risk system in the European Union. This highlights the need to examine assurance and oversight mechanisms around the development of ‘Rules as Code’ systems. As Hamish has pointed out, traceability between the source and the implementation is crucial.
I have also been experimenting with large language models for code generation, despite not being particularly skilled in programming. I have been surprised at how effective they can be for prototyping. However, if asked to explain the resulting code, I would struggle to do so in any meaningful detail. If I handed the code to Hamish and asked for an analysis, he would likely dismiss it as poorly written by an LLM and not worth his time. While these tools have potential, they are certainly not a silver bullet.
Devansh (Moderator)
Those are some very useful insights I would say on where we are headed. Matthew, I am interested to hear from you because as I understand you have actually argued that a lot of discretion can be encoded in ‘Rules as Code’. The discussion so far is suggesting that the real benefit might be there in the low-hanging fruit of enforcement rather than going for the big ticket items such as legislation and the tricky portions of that. Do you agree with that or do you think there’s more to be achieved here?
Matthew Waddington
I’m not saying discretion can be encoded. The problem is that it depends on what you mean by discretion. I get absolute shivers when I hear AI proponents saying things like:“Oh yeah, we just need to work out fairness—we just need to code it up a bit, train an AI to be fair, and then everything will be fine. We’ll get reasonableness done, and everything will be computerized.”
No, please—I don’t want to live in that world. The way these rules are set up is that some of them are automatable if you like orthey’re rigid, if you like—so that human input is still required at certain points. Each of these discretionary points represents human input. But so is determining what a word means in an edge case. Fundamentally, there is no clear, bright line between prescriptive law and discretionary law. Prescriptive law still uses natural language—English or any other language—and how those words apply to real-life scenarios is not computable unless you decide:
“Oh, we’ll only treat a dog as a dog if it’s on our computerized register of dog ownership”’
Sure, that might work—we already do that to some extent. But the idea that you can digitize and automate the concept of ‘what is a dog’—no, someone still has to make that call: “Is this a dog—yes or no?” That’s a human input point. A lot of tech people are fixated on definitions: “Oh, you don’t have enough definitions!” Sure, we have definitions, but they’re not magic. Every non-circular definition introduces more undefined words.
We’re not legislating for mathematical certainties like whether 2 + 2 equals 4. We’re legislating about real-world concepts like ‘what a farmer is’ or ‘what a dog is.’ A definition might make some edge cases clearer, but in doing so, it will use more undefined words. You’re always breeding undefined terms, and definitions are usually just shorthand for something more complicated that you don’t want to write out in full every time.
In that sense, all types of law are codable, but that doesn’t mean they are automatable. It also doesn’t mean that every aspect of a given piece of law is codable. What we’re interested in coding is the logical structure—for example, if something is a dog, then it needs a license.
Devansh (Moderator)
Now, this is interesting. The way I’m hearing it, the discussion has matured to the point where we all seem to agree on the need for human input. This is where I would like to get Guido’s view on the matter.
From a policymaking perspective, Guido, do you think it is possible for a rules-as-code system to be implemented at scale with sufficient legal safeguards and a review process for automated decision-making? Would the potential benefits justify the costs associated with implementing such a system from a policy angle? Do you think it’s possible?
Guido Governatori
Yes, it’s absolutely possible. A few years ago, we were actually building a prototype to do that, and technically it was feasible. The challenge wasn’t with the technical aspects but with adoption and securing support from politicians and other stakeholders. So, yes, it’s absolutely possible. However, there are significant costs involved because every time you write a new piece of legislation or regulation, you essentially need not only another language version but also a formal representation.
I fully agree with what Matthew said—the fundamental asset here is support for natural language, as natural language will remain the ground truth. Ultimately, you still need a human to determine whether something qualifies as a ‘dog’ or not. In some cases, we can avoid certain issues, but in the end, human involvement will always be necessary during application.
Practically, it is possible, but the real issue is determining who should bear the cost—whether it should be public or private. In my view, the real benefit comes when it is done by the public.
Regarding current models, such as LLMs, they might not yet be able to perform the translation correctly. There are still some issues—they are far from being capable. They can perform certain tasks well, but they lack logical reasoning. As Tom mentioned, when working on programming tasks, I have occasionally discovered significant logical errors. I was able to catch them because I was tracking the code and testing it, but blindly relying on the output would have been problematic. Especially when dealing with large legal documents, it becomes entirely unclear what is happening. I’ve seen a few experiments touted as groundbreaking, but in reality, the results were quite poor.
Devansh (Moderator)
. You have also mentioned the critical choice of public versus private. When we talk about ‘Rules as Code’ , it seems that the private sector has already taken the lead in this area. In some respects, large e-commerce players like Amazon, Flipkart, and Uber are already utilizing ‘Rules as Code’, as part of their customer interface. For instance, mostcustomer requests raised are now processed automatically by bots, with human intervention only required in specific cases.
The question then becomes: Who should take the lead in implementing ‘Rules as Code’ ? Should it be the government, or should the private sector take the lead, with government oversight ensuring compliance and accountability?
Guido Governatori
Oh, it definitely should be the government. It should be the government because if it is done by the government, then, in the end, you will have one version of the regulations. The private sector can then add its own interpretations or customize the regulations for their customers, but at least there will be one authoritative and reputable version that serves as the ground truth.
If the private sector handles it, the question arises: why is one version considered better than another? Even if one method is technically superior, how do we determine that? Who holds the truth? On the other hand, if encoding is done by a body with the power to enforce and maintain it, it grants an authoritative and authentic interpretation.
Of course, it might vary based on jurisdiction, and in law, there is always room for argument. But the key is to start from a widely accepted ground truth and then delineate exceptions or reinterpretations of particular terms as needed.
Devansh (Moderator)
Hamish, I want to bring you in on this because I think you have been at the forefront of this topic. Do you agree with Guido that it should be the government rather than the private sector leading the implementation of ‘Rules as Code’ ?
Hamish Fraser
I think there are many answers to that question. It really depends on which laws we should code and how we determine where to start. Should we code them all? I’ve been saying for a long time that we’ve had ‘Rules as Code’ for quite some time—just not intentionally. The public service has been building software systems to perform various tasks, but the legal encodings within them are mixed up with operations and other components. A significant amount of money is also spent on these systems.
If the government took the lead, it could first develop a component representing the legislation model whenever these systems were built. On top of that, they could build a policy-level component and then add the operational layer. This approach would break down a large software project into smaller, more manageable parts while making decisions traceable. I believe that model has potential, and I’d like to see it implemented.
I’ve also been involved with a project here in New Zealand, which is outside of government, that aims to model Social Security benefit rules. I think there’s room for initiatives like this, especially given that New Zealand has very few lawyers working in this space, creating a power imbalance regarding legal interpretation. ‘Rules as Code’ in the public or civic sphere could help rebalance power by offering interpretations that don’t solely depend on the government’s perspective.
My thinking has evolved as the environment around rules has changed since we first established the separation of powers among the three branches of government. Given the increased complexity, I’ve somewhat cheekily suggested the idea of a “fourth role”—a keeper of interpretations—who would work alongside those responsible for interpretation and support that work. While the majority of that role would still belong to the government, it’s in the public’s interest to ensure access to code interpretations to uphold the rule of law in a civil society. I believe we should take that seriously.
Devansh (Moderator)
Got it, Hamish. That’s a good point. We’re now reaching the end of our discussion, but I’ve been informed by the organizers that the panel has received some questions through a questionnaire that was released at the National Law School. I’ll just direct them across the panel here.
Tom, I have a specific question for you. In your experience, do you think ‘Rules as Code’ is a feasible approach for all countries, or do you get the sense that it might be more suitable for civil law countries compared to common law countries?
Tom Barraclough
I think it’s suitable for a wide range of contexts, but I hesitate to say it’s inherently better suited for either civil law or common law systems. It really comes down to the approach taken. There’s such a diversity of methods within the ‘rules as code’ framework that it doesn’t neatly align with one legal tradition over another.
One insight I’ve gathered from our research is that a lot of the discussion around ‘Rules as Code’ often involves people talking past each other—whether it’s lawyers, technologists, or policy experts. It’s kind of ironic, given that definitions are at the heart of all those disciplines. Yet, despite that, there’s still a lot of confusion and disagreement on what ‘Rules as Code’ entails.
In my view, it’s about creating digital legal systems that perform specific tasks within a legal context. That context will be shaped by a range of legal instruments, and ultimately, you’re designing a system that reflects how you interpret the law in a given situation. As long as your encoded interpretation is traceable back to the original legal source—so it can be scrutinized, audited, and debated—it should work in any legal system.
Devansh (Moderator)
Hamish, do you think that the implementation of ‘Rules as Code’ and the costs associated with such an initiative make it accessible to all countries? In particular, do you see it being feasible for developing countries to invest in this, or should we be considering alternative approaches—like an open-source model or other initiatives—to make ‘Rules as Code’ more accessible and practical across various jurisdictions?
Hamish Fraser
I would probably lean on my earlier comments about the lack of testing to make ‘Rules as Code’ takes off in the policy development space. The reason I say that is because once we can get it to work effectively in that space, it could actually represent significant cost savings. So much of what currently happens in the public service—and further down the line—involves reworking or reapplying policy that hasn’t been practically tested.
Ultimately, my answer would be yes—it is feasible. In fact, it could lead to much better outcomes. This might even be an opportunity for some countries, particularly those less invested in existing systems like New Zealand, to leapfrog ahead and adopt more efficient approaches.
Devansh (Moderator)
That makes sense. The next question I will direct to Matthew. Until ‘Rules as Code’ becomes feasible, should we just give up on coding legislation altogether like has been raised in this panel or like and or should do you think it’s still an avenue worth approaching to expand the benefits of ‘Rules as Code’ or should it be limited to, as Hamish is suggesting, to keep it at the enforcement or at the base regulation level?
Matthew Waddington
I think a feature of this discussion has been that although we keep saying different things, we are often approaching the same point from different angles. Generally, when I say something like, “Oh, we should do this,” I don’t mean that we shouldn’t do that. I mean, yes, let’s have a pincer movement. For instance, the idea that automated implementation is going to be an incentive to get people to spend—yes, sure. Where it is appropriate, where it will work, and where it is safe.
However, I do believe that if we can develop better drafting tools, they will pay for themselves. They will be attractive to both drafters and policymakers, and that can lead somewhere. The idea that you have to produce a, bells-and-whistles solution to demonstrate value is not necessarily true. Just showing people legislation with defined terms that have a pop-up to the definition would sell itself so easily that people would say, “What? We don’t have this?”
To go back to what Guido said, yes, there are many jurisdictions that have XML drafting systems with lovely cross-referencing. However, when you look at their websites, there is not a single hyperlink. The public is not getting the benefit. It is a bit like what Hamish mentioned—obviously, Social Security departments are not using a quill pen and an old-fashioned calculator to work out everyone’s benefits. They are using a computer system. It is just a matter of making it more public and accessible.
On the legislative side, from our end, it would involve exposing the logical structures we are already putting in place but not explaining very well. Sometimes we make mistakes, so it is about helping us avoid those mistakes by allowing us to see what we are doing and recognizing when we are hitting a brick wall, so we can correct it before it is enacted.
It is also about acknowledging that some rules we work by are not explained to the public. For example, we have an Interpretation Act in every Commonwealth jurisdiction, but we never mention it. Very few Australian jurisdictions do, but the concept of a “person”—the most fundamental unit of legislation—is embedded in the Interpretation Act. A person must not do this, a person must not do that. We never define that in an individual law because it is already defined in the Interpretation Act.
Who knows about the Interpretation Act? Nobody—just us drafters. We complain that these lawyers never read the Interpretation Act. Why don’t they? Because we don’t tell them about it. We have the World Wide Web, for heaven’s sake—why shouldn’t we have a link on every page of legislation that points from every instance of the word “person” back to the definition of “person”? I truly believe that once people see it, they will recognize the value on their own.
Devansh (Moderator)
I agree with that Matthew. Tom, you had something?
Tom Barraclough
Yeah, I just wanted to jump in quickly to say that I don’t mean we shouldn’t try to implement ‘Rules as Code’ in legislation. I think we should. The work that Matthew and his team are doing is fantastic in that regard, but it’s also so rare. I think it’s a testament to the fact that they have managed to persuade people to come on this journey and demonstrate what can be done with it because it makes so much sense.
Just as an example, since we’re talking about Interpretation Acts, one fantastic candidate for published ‘Rules as Code’ models would be working day calculations in statutes. In the New Zealand Interpretation Act, a working day is defined in a particular way. But throughout the rest of our statute book, who knows if those things are consistent? I’m not sure.
Think about how frequently working day calculations appear across the statute book and how much time must go into understanding how they actually work. Then think about how beneficial it would be to publish a single module that clearly states, “This is what we mean in terms of calculating time.” Again, this is particularly challenging because if the directions are imprecise to a computer, it simply can’t be done.
In terms of savings, and linking it back to policy development, it also forces policy developers to clearly state, “This is exactly what we mean,” rather than leaving it vague and having to translate it into natural language later.
Devansh (Moderator)
And that’s totally true. Guido,a lot of the discussion on this panel has focused on the economic benefits or the enforcement benefits of ‘Rules as Code’ . But do you think it can also serve some sociological purpose? Especially in developing countries, law is often a normative instrument that seeks to achieve societal goals and benefits. Do you think there might be advantages from that perspective as well?
Guido Governatori
It really depends on what you mean by sociological aspects. I would definitely say there would be some other benefits, probably somewhere between economic, financial, and sociological.
If regulations are published as a single, authoritative version by a credible authority, it becomes possible for third parties to build their own solutions on top of that. They can incorporate their particular definitions and expertise, creating specific applications without having to interpret the entire legislation, such as the Interpretation Act in Australia. Instead, they can provide their customized interpretation for particular cases. This could ultimately result in better access to justice by reducing the cost of obtaining reliable legal advice.
I’m not entirely sure whether this would be classified as a financial benefit, a socioeconomic benefit, or something else, but it represents one of the possible approaches.
Another potential solution is that if we make regulations available in a logical and exposed form, as Matthew suggested, the legislation and regulations might become more explainable, visible, and understandable.
However, whether this will translate to wider public understanding is something I’m a bit skeptical about. Even if we achieve the perfect form of presentation, I’m not entirely convinced that the general public would necessarily be able to fully appreciate or engage with it.
Devansh (Moderator)
Got it. Now that actually makes perfect sense that there are benefits here and economic benefits always will have a sociological and societal impact. You’re completely right.
That’s a great closing note everyone. Thank you so much for this discussion. You all shared very valuable insights. I’m sure the people reading the transcripts of this discussion and watching it later will be greatly informed by this. The students at National Law School thank you. I thank you and I also thank you on behalf of the Law School Policy Review who invited you all. Thank you so much for your time.
Categories: Podcast
