News for hackers. Stuff that matters.
Re:CatalaLang/catala: Programming language for law specifica... by LudwigNagasena on Sunday September 17, 2023 @05:43PM (#37549644)
The words almost always mean almost exactly what they mean in plain English. That’s why the law is a huge mess.

As a fun exercises, try to find how many definitions of “child” there are in the US law and how many times it’s used undefined.

Re:CatalaLang/catala: Programming language for law specifica... by tsimionescu on Sunday September 17, 2023 @05:52PM (#37549694)
I don't agree that the law is a huge mess. It is certainly far less of a mess than any code base I've ever seen, given the gigantic scope of what it applies to, and how many people if affects.

Note that the legal system is indeed a huge mess, but that happens because of many other reasons - not a problem with the wording or vagueness of the law, but with the explicit (malicious) intentions of law-makers, judges, police and others involved in the whole process.

For your example of "child": how often does it actually cause a problem in practice? How many people have been improperly punsihed/set free because of a poor interpretation of the word "child" in a specific law? This is far more relevant than every law taking up valuable space to define what such a common word means.

Re:CatalaLang/catala: Programming language for law specifica... by LudwigNagasena on Sunday September 17, 2023 @06:21PM (#37549878)
> How many people have been improperly punsihed/set free because of a poor interpretation of the word "child" in a specific law?

How many improperly punished people is good enough? How many cases go to Supreme Court because the amount of needless ambiguity just adds up, one word at a time?

> This is far more relevant than every law taking up valuable space to define what such a common word means.

Right? Why do many laws redefine it?

Re:CatalaLang/catala: Programming language for law specifica... by tsimionescu on Sunday September 17, 2023 @06:56PM (#37550162)
I don't know how many is good enough. If it's every other person, than that's bad; if it's two people since the law was written 50 years ago, I would say that's good enough in my book. Which is it?

And no, cases don't often make it to the Supreme Court because the wording of the law is ambiguous. They make it to the SC because the parties disagree on legal principles and on whether laws are unconstituional or not.

> Right? Why do many laws redefine it?

I would have to see some specific examples to judge for myself. Still, this seems to be the opposite problem compared to what was raised earlier. So which is it? Do we want laws to be more explicit about their exact definitions of words, or more implicit?

Re:CatalaLang/catala: Programming language for law specifica... by OJFord on Sunday September 17, 2023 @07:47PM (#37550550)
> And no, cases don't often make it to the Supreme Court because the wording of the law is ambiguous. They make it to the SC because the parties disagree on legal principles and on whether laws are unconstituional or not.

I'm not from your legal system, and yet even I know that's not right: they make it the SC because the 'losing' party disagrees with a lower judge's decision that's already been made, and makes an argument compelling enough in appealing it that it needs to be reconsidered. (A few times, to get as far as the SC, probably.) That almost has to be because of some 'ambiguity' - the lower judge decided one way and the appeal is 'well no I don't think that's the correct reading'.

Re:CatalaLang/catala: Programming language for law specifica... by hnfong on Sunday September 17, 2023 @11:13PM (#37551801)
The GP is taking a restricted meaning of "ambiguity", where the ambiguity is within the laws relevant to the case being appealed.

But cases that go to the Supreme Court of the United States are often cases where the "ambiguity" is on how the US constitution should be interpreted and applied.

In a practical sense you're not going to be able to codify the US constitution into code. It's even a well received "feature" that constitutions are sometimes a bit ambiguous, see: https://en.wikipedia.org/wiki/Living_Constitution

Re:CatalaLang/catala: Programming language for law specifica... by tsimionescu on Monday September 18, 2023 @04:13AM (#37553592)
Note that the SC almost by definition only looks at cases that pertain to the constitution, or to base legal principles, not to individual laws. And good luck codifying the constitution itself and/or the rules of common law into formal math.

Also, appeals essentially mean that at least one of the parties believes that a judge made a mistake in the way they applied the law, not necessarily that the law itself is ambiguous. A judge can fail to apply a perfectly unambiguous law, or at least a plaintiff can believe that they did, and can bring enough evidence that their belief has some merit.

Re:CatalaLang/catala: Programming language for law specifica... by LudwigNagasena on Tuesday September 19, 2023 @02:48AM (#37566433)
> And no, cases don't often make it to the Supreme Court because the wording of the law is ambiguous. They make it to the SC because the parties disagree on legal principles and on whether laws are unconstituional or not.

I don’t see how those are exclusionary principles. Also, I have never heard about this case, but after some simple googling I learned that the Supreme Court indeed had to figure out the definition for children in a particular law: https://berkeleysolicitors.ie/supreme-court-determines-defin...

> Still, this seems to be the opposite problem compared to what was raised earlier.

No, it is the same problem I mentioned before: some laws define it in a contradictory way; some laws don’t define it. I told you it’s a fun exercise!

> Do we want laws to be more explicit about their exact definitions of words, or more implicit?

I want laws to make sense. Inconsistency doesn’t make sense and only brings troubles. Vagueness is good. Ambiguity is bad.

Re:CatalaLang/catala: Programming language for law specifica... by sheepscreek on Sunday September 17, 2023 @06:02PM (#37549758)
> ..and how many times it’s used undefined

This is the real advantage of codifying law into a programming language. You can have validation and assertion that is automated. And a strict structure, free from ambiguity.

As an additional advantage, multilingualism becomes more accessible, with the codified program/definition acting as the lingua franca of law. Thus, someone who only knows English could make sense of Japanese laws by reading it.

Re:CatalaLang/catala: Programming language for law specifica... by tsimionescu on Sunday September 17, 2023 @06:11PM (#37549812)
Why would you want every law that applies to children to explain what a child is? Why stop at child, perhaps each law should include a definition of every word it contains, right? That would certainly make every law much more readable for the masses.

The text of the law is meant to be understood by the people that it applies to, i.e. everyone living in the locality which passed said law. Expressing law in a formal language goes directly against that goal. Imagine if a EULA you get presented with, instead of being a wall of repetitive text, would be a wall of code with symbols you at best remember from some class you took in 8th grade.

Re:CatalaLang/catala: Programming language for law specifica... by nvm0n2 on Monday September 18, 2023 @09:34AM (#37555887)
Having EULAs and many types of contract be code would be a huge upgrade.

For one, it'd make them a lot shorter. You could use inheritance or composition to refactor out repetitive boilerplate, which is 90% of what EULAs are. The thing you see would only be the places where it deviates from a base EULA that you could study once.

For another, it would catch bugs automatically. I have caught bugs in contracts drafted by lawyers a bunch of times, just by reading them carefully. For example numbers that are stated in both words and digits but they don't match. References to clauses that no longer exist. Statements that are contradictory.

A properly written language could be compiled to English for people who for some reason can't read the "real" language. But a well written PL for law would be quite readable.

Re:CatalaLang/catala: Programming language for law specifica... by tsimionescu on Monday September 18, 2023 @12:40PM (#37558534)
Programming languages and other formal languages add boilerplate, they never remove it. Compare pseudocode for an algorithm with the actual implementation: it will almost always be much shorter.

All of the rest of what you mention could be achieved with plain language contracts exactly as well. Nothing prevents the software industry from getting together and producing a base EULA that all others refer.

Except of course for the fact that it would be utterly impossible to convince companies to agree to such an endeavor, whether in code or plain language or any other way. Especially since the purpose of EULAs is not to be clear, but to confuse end users with verbiage.

Re:CatalaLang/catala: Programming language for law specifica... by lanstin on Sunday September 17, 2023 @08:34PM (#37550848)
I cannot imagine some system that goes from a formal language to reality not having ambiguity. Even going from mathematical formalism to mathematical truth you can’t get all the truth. I imagine getting all the justice would be harder.

And I have heard lawyers explain that sometimes ambiguity, in contracts at least, is a good thing as it reduces the amount of a priori negotiation for low probability events. The the low probability event happens and the contract is ambiguous then you negotiate at that time and maybe sue.

And for laws, I think a bit of flex in the system probably would be a good thing. Give some scope for local judgment an autonomy to the people closest to the situation.

Re:CatalaLang/catala: Programming language for law specifica... by runlevel1 on Monday September 18, 2023 @02:33AM (#37552944)
How do you codify the effects of judicial review? What if the court's decision is not binding but is still persuasive -- such as when it's a decision from another jurisdiction?

Common law has like 800 years of tech debt. It's turtles all the way down. And by turtles I mean precedent, and not all of them are compatible.

None of what I've described is malicious. It's just what happens when law meets the messiness of the real world.

Re:CatalaLang/catala: Programming language for law specifica... by mschuster91 on Sunday September 17, 2023 @06:30PM (#37549939)
> As a fun exercises, try to find how many definitions of “child” there are in the US law and how many times it’s used undefined.

Which is why it is the common standard in German law to define every possibly unclear term either in the relevant section of the law itself or in an introduction article.

Re:CatalaLang/catala: Programming language for law specifica... by lolinder on Sunday September 17, 2023 @08:20PM (#37550760)
It's the standard in the US, too, but "child" is a case where plenty of lawmakers have assumed it couldn't possibly be misunderstood, while plenty of others have defined it with contradictory definitions in their respective sections.

The latter is better than the former, but it also makes it even harder to interpret sections with no definition.

Re:CatalaLang/catala: Programming language for law specifica... by insanitybit on Sunday September 17, 2023 @10:51PM (#37551664)
> As a fun exercises, try to find how many definitions of “child” there are in the US law and how many times it’s used undefined.

I don't see how a language is going to solve this. This isn't really an issue of language, it's an issue with ambiguity in the very intent itself. That's why we have judges, who interpret that intent.

Re:CatalaLang/catala: Programming language for law specifica... by p-e-w on Monday September 18, 2023 @01:00AM (#37552406)
Indeed. Ambiguity in legal codes is a feature that allows them to remain relevant for more than a couple of years, and the formal-law "utopia" that some commenters here appear to desire would be a nightmare if put into practice.
Re:CatalaLang/catala: Programming language for law specifica... by alexvitkov on Monday September 18, 2023 @01:38AM (#37552599)
Personally I'd rather have laws that work, are consistent and easily understood if you can follow 'if A then B' logic, even if they have to be updated more often.

Relying on ambiguity is admitting there are no laws, and we rely on the common sense of the people in thr judicial system.

Re:CatalaLang/catala: Programming language for law specifica... by TuringTest on Monday September 18, 2023 @02:43AM (#37553023)
> Relying on ambiguity is admitting there are no laws, and we rely on the common sense of the people in thr judicial system.

What's better:

- relying on the common sense of the people in the judicial system to interpret the intent of the law as it applies to a particular situation,

- or relying on the common sense of legislators to write a precise, unambiguous law that will cover all possible situations without negative unintended consequences, and without the law-writing process being influenced by spureous interests and pressures?

The answer highlight why the law is interpreted as is now, with a body of trained public servants analyzing the particulars of each situation, rather than by fanatics trying to follow the letter of the law.

Languages like this may help clarify the intent of legislators so that it is not twisted by clever lawyers; but a human reviewer should always check the relevance of one law to any particular case, and wether the text corresponds to the original intent as applied to a given situation.

Re:CatalaLang/catala: Programming language for law specifica... by mratsim on Monday September 18, 2023 @03:04AM (#37553168)
They mean disputes go on for years, costing society a lot and enriching intermediaries.
Re:CatalaLang/catala: Programming language for law specifica... by insanitybit on Monday September 18, 2023 @08:34AM (#37555292)
Exactly, it is truly horrifying to think of a law encoded such that it can not be superseded by human interpretation.
Re:CatalaLang/catala: Programming language for law specifica... by alexvitkov on Monday September 18, 2023 @01:32AM (#37552557)
This is a solved program in programming, you hover Child and hit "Go to definition". If it's ambiguous, the lawmakers would get a compile error instead of pushing a broken law. They may even have to pay us for consulting to fix it, depending on how esotrtic the language is, how nice is that!
Re:CatalaLang/catala: Programming language for law specifica... by kdmccormick on Monday September 18, 2023 @02:21AM (#37552873)
Legal codes aren't meant to work like programming languages. It is impossible for a legislator to predict how the world will work when their law is applied, and it is highly unlikely that they will anticipate every situation and context in which their law will be invoked.

Judges and juries and lawyers all exist to help us interpret the inexact legal code in a way that is (hopefully usually; but obviously not always) fair and reasonable given the often-nuanced situations at hand.

Re:CatalaLang/catala: Programming language for law specifica... by alexvitkov on Monday September 18, 2023 @02:45AM (#37553038)
That doesn't add up with how the average piece of legal code looks. Even when I read a brand new piece of legislature it's an impossible soup of words, attempting to document every possible edge case the legislators thought of. If the point was to leave room for interpretation by a judge and you concede yoy don't have full context of how what you're writing will be applied, surely you could write much more sensible and human-readable text.
Re:CatalaLang/catala: Programming language for law specifica... by TheOtherHobbes on Monday September 18, 2023 @06:25AM (#37554352)
It adds up to how the average piece of legal code works in practice.

Law is political. It's persuasive, not deterministic. It often comes down to a judgment based on the relative political power of the entities in question.

Even if you find a statute that says very clearly that X is unlawful, there will be situations where a lawyer will argue that it isn't.

Sometimes they'll make that case successfully - for various possible reasons, not all of which will be lawful themselves.

This is one reason why statute law is expanded by case law. And good luck trying to automate case law.

Re:CatalaLang/catala: Programming language for law specifica... by epups on Monday September 18, 2023 @05:09AM (#37553916)
I would be happy if the law conforms to other existing laws, not future edge cases. The solution being proposed here would do that, while the existing system would not.
Re:CatalaLang/catala: Programming language for law specifica... by victorbjorklund on Monday September 18, 2023 @06:06AM (#37554256)
It isnt a bug it is a feature. There is a point in law sometimes being a bit vague to create flexibility
Re:CatalaLang/catala: Programming language for law specifica... by LudwigNagasena on Tuesday September 19, 2023 @02:51AM (#37566452)
Being vague and up to interpretation because lawyers can’t foresee all possible circumstances is a feature.

Being a mess riddled with inconsistencies is not a feature.