Are there any inventories of expression types used in legislation?

I’m doing an analysis of a piece of legislation to find out what sorts of expression are used, and how often, in the hopes that will help me do a requirements analysis. I have a sort of ad-hoc list of expression types in my head that is based on my own experience with Rules as Code. Some of the things I’m thinking about are:

  • Propositional Logic
  • First Order Logic
  • Mathematics
  • Deontics
  • Defeasibility
  • Scope Limiting (“in this part”)
  • Cross References
  • External Referneces
  • etc…

Does anyone know of any research that has been done, particularly from the legal perspective, on the types of expressions that are used in legislation, and when, and why, and how?

It strikes me as exactly the sort of question that legal academia would have ignored, but I guess it doesn’t hurt to ask.

Maybe @MatthewWaddington, as our resident legislative drafter, would know?

Thanks in advance.

1 Like

I haven’t thought through expression types yet, but I was thinking that the CALC site might be a really good source of inspiration. You can find drafting manuals: http://www.calc.ngo/drafting-manuals-and-other-resources and the Loophole publications might also provide insight: Loopholes | Commonwealth Association of Legislative Counsel

… Are you focusing on Commonwealth approaches to drafting or also considering others (like American, for example, where they’ll often amend in full. Perhaps this distinction doesn’t matter for what you’re looking for though :thinking:

2 Likes

By default I’m looking at Commonwealth, because I’m starting in Canada. But I think you’re right, that the things I’m curious about right now are things that are true or not about a point-in-time statutory text, and don’t really have to do with how it gets amended. There may be stylistic differences between US and Canada drafting, and it seems likely that there are artifacts that belie the different political systems, like “riders.” Hard to say if any of that goes to semantic expression types, or their prevalence.

As it happens, I was looking at Loophole yesterday. I’ll check out the resources, thanks!

1 Like

Just thought of one type of expression that could be relevant for you to consider, even in Canadian legislation (I believe, though likely to a lesser extent). Where I work (and in the AKN world) we refer to the language as “disambiguators”, not sure what they exist as in LegalRuleML. This would be language like “as amended by” or other qualifying language in citations. They could affect references but also incorporate additional amendments that aren’t immediately reflected in the language of the statute you’re analyzing…

1 Like

Just happened to look at this older thread…
This type of analysis would be really interesting. If we had a standard list of these expressions there would be scope to do some manual cross-country comparisons. My experience with US and Australian legislation is that they’re stylistically quite different and I wouldn’t be surprised if they differ quite a bit in the usage of expressions you’ve listed.
What I always find with regulatory legislation is that the logical statement of the obligations is usually a very small part of the actual word count. Most of it is definitions, conditions, exclusions, clarifications, (‘for the absence of doubt’), etc.

1 Like

I think what would also be helpful is a computational characterization of different expression types. Which would likely have an effect on which expression types are considered “different”. For my part I haven’t been able to spend a lot of time on this in recent weeks but I plan to come back to it. I will also be discussing it briefly at ProLaLa and will ask for feedback there.

1 Like

I hope the ProLaLa talk went well. I would be very interested in discussing this with you. I am still not sure what it is you are looking for.
Have you seen UK’s Common legislative solutions: a guide to tackling recurring policy issues in legislation - GOV.UK, with versions by Scotland & Wales drafting offices? Are you looking for that sort of thing or something more like at the level of single words or phrases?

The talk went well, thanks. Going to post here with a link to my blog recap, which in turn has a link to the video for anyone interested.

Let me see if I can explain what I’m talking about in simpler terms.

Let’s say I want to add two numbers, right? If my programming language has “numbers” and “adding”, I’m a happy camper. I can do something like 1 + 3 and expect to get back 4. Now imagine it didn’t have “add”. Imagine it only had loops, and increments, and numbers.

I could implement “add” myself, by doing something like
loop(3,increment(1)). Ultimately, I’m going to get the same answer. But it’s harder for the programmer, and it may have other negative effects.

The problem comes down to the question of “are the abstractions that I’m used to using in the domain that I’m trying to model, in this case, legislation, available to me in the tool I’m using to do the modelling, in this case, a programming language?”

For example, laws have “rules” in them. What kind of rules? Well, more specifically, they have defeasible rules. Just because one rule says “if you are a minor you can’t write a will” doesn’t mean that there isn’t some other rule that overrides it by saying “notwithstanding being a minor, a member of the military can make a will”.

So “defeasible rules” is a thing that exists in legislation. Whether or not it exists in a programming language matters for what the experience of writing the code is like.

There is a language called Flora-2 that has defeasibility, where I might encode those two sections like this:

@rule1
?X[can_make_will->\false] :-
  ?X:Person[is_minor->\true].

@rule2
?X[can_make_will->\true] :-
  ?X:Person[is_military->\true].

overrides(rule2,rule1).

If I wanted to write that code in an identical language without defeasibility, it would look more like this:

?X[can_make_will->?Value] :-
  if ?X:Person[is_minor->\true,is_military->\false]:
    ?Value = \false,
  if ?X:Person[is_minor->\true,is_military->\true]:
    ?Value = \true.

That’s not as good, because now my code doesn’t know anything about where the rules came from, and it can’t explain itself in terms of what the rules say. It also makes the code harder to maintain, because I don’t know where Rule 1 is, and I don’t know where Rule 2 is.

So that’s an example about how whether or not the programming langauge has “defeasibility” as a feature is important, because defeasibility is a feature of legal language.

To generalize that, we can say that the features present in the modelling language should model the important features of the legislative text. “Important” here means the presence or absence of that feature in the coding language is going to have some corresponding positive or negative effect on the quality of the encoding, the capabilities of the software, the efficiency of the encoding process, or something else the programmer cares about.

Some of the things that I know are important are:

  • disjunctions (languages without an “OR” operator require a lot of duplicate code)
  • defeasibility (languages without exceptions require reformulation that makes it harder to write the code, harder to explain the code, and harder to maintain the code)
  • dates and times
  • math, and arithmetic
  • logical implication
  • etc…

So what I’m wondering is if anyone has done a survey of the logical/computational features present in legislation, that I could use as a starting point to discover what else might be worth looking for.

Let me know if that helps, or if I have just made things worse. :slight_smile:

2 Likes

Since lambda calculus can be used as a foundation to mathematics, and since boolean logic, arithmetic, dates and times are all in the realm of mathematics, any turing complete programming language can express them.

I don’t understand what defeasibility is. On the surface it appears to be simply assigning names to expressions.

The problem comes down to the question of “are the abstractions that I’m used to using in […] legislation, available to me in the tool I’m using to do the modelling, […] a programming language?”

The answer is yes, if the language is turing complete - most are.

Regardless I think it’d be massively beneficial for the reason of cross-analysis as mentioned in this thread. It’d be much easier to compare laws with a higher degree of certainty. It would also help in the codification of any legislation. :slightly_smiling_face:

You could probably use NLP frameworks to automatically deconstruct many legislative documents and categorize the terms. You could also propose machine learning for the categorization as it excels at this but might be excessive.

Defeasibility is the idea that a conclusion reached in some code can be overridden by a conclusion reached elsewhere. One conclusion can be defeated by the other. It describes the ability to encode defaults and exceptions apart from one another.

Turing completeness says next to nothing about the abstractions available in a language.

Turing completeness says next to nothing about the abstractions available in a language.

Not sure how this can be said. A language can extend itself if it’s turing complete, implementing any other language and abstractions it needs… See: C → C++ , a prime example.

Edit: I misinterpreted what was written earlier. I completely agree that turing completeness itself does not say anything about the abstractions offered by the language.

What I really meant to express was, if a language is missing an abstraction, but we like the language overall, it can be extended further to support this abstraction. I was just making a comment that any abstraction we need can be created. Sorry!

1 Like

@jason, if I understood you correctly, you could take a look on this document:
Joint Practical Guide of the European Parliament, the Council and the Commission for persons involved in the drafting of European Union legislation

mainly pages from 57 to 73. There are mentioned some expressions used in drafting legislation.
EDIT: I’ve noticed that in CALC resources mentrioned by @SabrinaV The Guide has already been listed. Sorry for repetition.
Also in Poland we have a regulation called ‘Rules for legislative drafting’ that describes exactly what expressions can be used in what types of provisions. Unfortunately, I don’t have English translation of the ‘Rules…’ but could try to run it through autotranslation or could provide you with the original version.

@patryk.ciurak even an auto-translation would be interesting, thanks!