Live data from Hacker News

CatalaLang/catala: Programming language for law specification

github.com

271–280 of 301 posts

Re: CatalaLang/catala: Programming language for law specification

#271
post #261

Earlier quoted context omitted.

This seems obvious to me and seems something that law already strives to: you end up with very precise law regardless via case law, but with a high legal cost to reach that point. At the very least, it's not something I'd expect to be on Catala's homepage. I think this is closely related to rule of law too. Per https://www.britannica.com/topic/rule-of-law > In particular, laws should be open and clear, general in for…

"What are the benefits of ambiguous laws? " Freedom and flexibility. Reality is infinitely complex, trying to encode real world problems 100% accurate into code can only work by rounding a lot, with the result of oversimplification with the result of lots of "unjust" rulings, when you do not take the intent of the law into account, but only the words. We have this problem already (a lot) many things that seem very wr…

I'd say, it's useful to distinguish between intentional and unintentional ambiguity/underspecification. For example, many jurisdictions that have statutory contract law have a statute that says that a provision in a contract is unenforceable if it is "unconscionable". There is, of course, a broad spectrum of things that can fall under that term, but that's intentional, i.e. the law maker specifically wanted to open a door there for a judge to hold a contractual provision unenforceable if they need it to be to get to a just outcome.

However, a lot of ambiguity, underspecification, and just plain sloppiness in language is there for no good reason and causes problems, and it would obviously be a good thing to get rid of that.

Re: CatalaLang/catala: Programming language for law specification

#272
post #261

Earlier quoted context omitted.

This seems obvious to me and seems something that law already strives to: you end up with very precise law regardless via case law, but with a high legal cost to reach that point. At the very least, it's not something I'd expect to be on Catala's homepage. I think this is closely related to rule of law too. Per https://www.britannica.com/topic/rule-of-law > In particular, laws should be open and clear, general in for…

"What are the benefits of ambiguous laws? " Freedom and flexibility. Reality is infinitely complex, trying to encode real world problems 100% accurate into code can only work by rounding a lot, with the result of oversimplification with the result of lots of "unjust" rulings, when you do not take the intent of the law into account, but only the words. We have this problem already (a lot) many things that seem very wr…

But that doesn't mean freedom or flexibility for citizens. It means freedom and flexibility for the judiciary. For citizens, it takes away their freedom and flexibility because vague or contradictory laws (often coupled with severe penalties) create risk, or the perception of risk, where there wasn't meant to be any to begin with. It causes people to stop trying new things out of fear that Rule By Law will happen to them.

Whose freedom is more important? The people's, or their rulers? If you believe in enlightened rulers, you may legitimately conclude the latter, but for the rest of us, we'd rather the government be properly constrained. After all that's why laws are written down to begin with, it's why there is such a thing as the professional lawmaker.

Vague law is usually not written due to some deep philosophy of law making, after all. Nobody really tries to defend it in practice. It's almost always a result of lazy or politically contentious lawmaking when the people writing the laws don't really know what they want in the first place, so trying to divine their intent will never get you far.

Re: CatalaLang/catala: Programming language for law specification

#273
This paper definitely has thoughts on the matter https://law.mit.edu/pub/interpretingtherulesofcode/release/4

"As the Rules as Code movement gains momentum, questions are starting to be asked about the performance and practical effects of expressing law computationally. This article examines the strengths, weaknesses, and new opportunities of engaging with these emerging systems."

The Future of Coding podcast covered it recently https://futureofcoding.org/episodes/065

The abstract says, "Software code is built on rules. The way it enforces them is analogous in certain ways to the philosophical notion of legalism, under which citizens are expected to follow legal rules without thinking too hard about their meaning or consequences. By analogy, the opacity, immutability, immediacy, pervasiveness, private production, and ‘ruleishness’ of code amplify its ‘legalistic’ nature far beyond what could ever be imposed in the legal domain, however, raising significant questions about its legitimacy as a regulator."

It's a complex paper/topic that I personally need more time to grasp before throwing my opinions around too heavily. But my first, knee-jerk reaction so far is that moving laws into code is a bad idea. Specifically, as the paper says, "...code by its very nature tends toward a kind of strong legalism. This is the case regardless of the intent of the programmer, however vicious or virtuous that may be."

The "strong legalism" inherent in code means "the sovereign’s exercise of power is de facto legitimate, and thus not open to question." Not to be reductive, but that ain't good.

I feel we've seen evidence of this path already, with (easily refuted, but somewhat common) claims like "data can't be biased" (for example). The tendency to blindly follow a computer's dictate with, "Well, the computer says this is so, so it must be so." is strong in our society at times, I think.

Re: CatalaLang/catala: Programming language for law specification

#274

Earlier quoted context omitted.

> ..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 Jap…

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 la…

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 specification

#275

programmers love to propose using "programming language" or similar for law But this fails to realize that _ambiguity (in some ways) is a fundamental important part of law_. This is because the world itself is fundamental ambiguous (in some ways)/clear cut. Naturally not all ways of ambiguity are wanted. But you can be sure that with "code as law" the ways loopholes are abused will get worse in my opinion. I would ev…

Agreed. Although I don't think this is a bad idea, I think of the idea of perfectly defined laws and perfectly enforceable laws are terrifying. If every law on the books today were able to be perfectly enforced and perfectly monitored, our lives would be utterly miserable. I'm not going to argue that's a problem with laws vs. enforcement, but either way, our society is built around ambiguity and unequal enforcement o…

Enforcement and clarity are different concepts. We don't have a big problem with courts or police declining to enforce laws because they aren't precise enough.

Re: CatalaLang/catala: Programming language for law specification

#276

Earlier quoted context omitted.

I think that comparison is way off. Smart contracts are much more comparable to "a webshop", than actual logic describing rules of arbitrage or other concepts at play in "law".

A smart contract is a well-defined series of rules, that anyone can choose to interact with and have certain well-specified guarentees of the outcome -- in that sense I think there are quite a few similarities, the main differences being that a smart contract deals with a way narrower set of concepts and is immutable.

Part of the problem with smart contracts is the term usually means Ethereum programs, which are usually neither good law nor good programming. They're not only playing a game with high stakes but the actual programming environment is a textbook case of how not to do computing. You can't generalize much from the experience there, it'd be like judging all of computing by looking at piles of PHP written by drug-addled teenagers.

Re: CatalaLang/catala: Programming language for law specification

#277

Earlier quoted context omitted.

Agreed. Although I don't think this is a bad idea, I think of the idea of perfectly defined laws and perfectly enforceable laws are terrifying. If every law on the books today were able to be perfectly enforced and perfectly monitored, our lives would be utterly miserable. I'm not going to argue that's a problem with laws vs. enforcement, but either way, our society is built around ambiguity and unequal enforcement o…

Do you have any examples where ambiguity is truly beneficial? For all the examples I can think of, the most beneficial outcome is removing the law altogether.

Speed limits is one example.

Re: CatalaLang/catala: Programming language for law specification

#278
post #272

Earlier quoted context omitted.

"What are the benefits of ambiguous laws? " Freedom and flexibility. Reality is infinitely complex, trying to encode real world problems 100% accurate into code can only work by rounding a lot, with the result of oversimplification with the result of lots of "unjust" rulings, when you do not take the intent of the law into account, but only the words. We have this problem already (a lot) many things that seem very wr…

But that doesn't mean freedom or flexibility for citizens. It means freedom and flexibility for the judiciary. For citizens, it takes away their freedom and flexibility because vague or contradictory laws (often coupled with severe penalties) create risk, or the perception of risk, where there wasn't meant to be any to begin with. It causes people to stop trying new things out of fear that Rule By Law will happen to…

"But that doesn't mean freedom or flexibility for citizens. "

It does, because if laws want to cover every case, they need to be so verbatim and rule out so many possibilities, that in the end, every action is encoded in law, which will result in people only doing things that are explicitely allowed. That limits a lot.

Simple example, despite being an adult, I like to climb trees. And sometimes also in parks. So I had discussions with officials or or wannabe officials about: is this allowed? It turns out, there is no rule allowing it. But there is also usually no rule forbidding it. But most people default to, if it is not explicitely allowed, it must be forbidden (which is a very german thing, but is not unique to us).

Michael de Montagne, a old french philosopher who is also quoted around this thread, put it way better in words. I try to find the passage.

Re: CatalaLang/catala: Programming language for law specification

#279

Earlier quoted context omitted.

"What are the benefits of ambiguous laws? " Freedom and flexibility. Reality is infinitely complex, trying to encode real world problems 100% accurate into code can only work by rounding a lot, with the result of oversimplification with the result of lots of "unjust" rulings, when you do not take the intent of the law into account, but only the words. We have this problem already (a lot) many things that seem very wr…

I'd say, it's useful to distinguish between intentional and unintentional ambiguity/underspecification. For example, many jurisdictions that have statutory contract law have a statute that says that a provision in a contract is unenforceable if it is "unconscionable". There is, of course, a broad spectrum of things that can fall under that term, but that's intentional, i.e. the law maker specifically wanted to open a…

"However, a lot of ambiguity, underspecification, and just plain sloppiness in language is there for no good reason and causes problems, and it would obviously be a good thing to get rid of that."

100% agreed. When clear (and simple) rules are possible, vague rules just create opportunities for shady things. And yes, we have many, many laws that could be made simpler and therefore more clear. And if a programming language can help with that, that would be awesome.

Re: CatalaLang/catala: Programming language for law specification

#280
post #268

Earlier quoted context omitted.

"What are the benefits of ambiguous laws? " Freedom and flexibility. Reality is infinitely complex, trying to encode real world problems 100% accurate into code can only work by rounding a lot, with the result of oversimplification with the result of lots of "unjust" rulings, when you do not take the intent of the law into account, but only the words. We have this problem already (a lot) many things that seem very wr…

Can ambiguity be quantified, and/or codified? Risking sounding like a painfully naive layman, would it be possible to define the range in which to apply the rule as function of range of inputs? When uncertaintu on inputs increases or veers outside of some well known range, then bandwidth for the judge increases?

I think something like this exists actually, even though I can't think of a concrete example, but I am sure it is not easy to implement (in a just way) either.
Post reply on HN