“Lawyers and coders are good at the same thing: parsing language. That they haven’t collaborated more is a historical fuckup. Let’s fix it.” This is a tweet I sent out a little while ago, and in response a bunch of people asked me to elaborate. Well, if we define Artificial Intelligence as enabling computers to talk to us and understand us in a way so far only humans can (I know that technical definitions are much more specific; one person told me a artificial intelligence is “a machine that can learn from its own actions”), then the law should be the first area to tackle. Legalese sounds so strange, because its goal is to permit as little ambiguity as possible. Ambiguity, of course, is why computers still can’t really understand language – irony and hidden meanings prevail. So if computers will ever be able to understand anything, then it will probably be legalese.
I posted the following explanation originally on Quora in response to the question: “Would it be possible to codify the language of laws so a computer could compile and then reason about them?” In response, I changed the questions slightly. Instead of theorizing what computers might be able to do someday (and I have an opinion on that, which I will share here at some point), I asked “What could computers do nowadays (i.e. with current technology) to help solve legal issues?”
To answer that question let me explain very quickly what law is. Being clear about what law is will help narrow down how we can apply computers to it. I am focusing for now only on the law of dealings between two citizens (contracts). The law between a citizen and the state (public law and criminal law) is an entirely different subject.
Law is a system that allows two people to regulate their relationship into the future. So let’s say one person has a car and another does not. One says to the other: “I would like your car.” This is the beginning of a possible contract that will regulate who can use this car in the future. But there are many possibilities of regulating this future: One possibility is for the person with the car to sell it to the person without it. That means from now on only the other person can use the car and the first person can never use it again (unless they enter into another contact to sell it back). OR, person 1 decides to rent the car to person 2. It will say “ok, if you give me 100 bucks and if you give me the car back in two weeks, then I will give you the keys.” And so forth.
So what the law of contracts does is 1) figure out exactly what each person wants and 2) determine whether what the two people want is compatible. If the answer to 2) is yes, then the law of contracts makes sure that both people are aware that they are regulating their common future, so there needs to be a handshake, a wink or two signatures, to evidence that they are in agreement.
So why do people need lawyers? You say that only lawyers can understand agreements. That is not the case. Contracts should be written in a language that everybody can understand. Instead lawyers do two things: First, they think about scenarios that the two people might not have considered. So for example, what if after two weeks person 2 doesn’t give the car back? That depends on whether the car exploded without fault by person 2 or person 2 simply sold the car. In the first case, person 2 probably doesn’t have to give the car back. In the second case, person 2 probably has to give it back or at least give to person 1 the money it received for the car. The other thing lawyers do is tell the two persons what other people usually agree on that are in the same position. So they might say: “I have done this many times and what worked best was to agree in advance that if the car explodes, it’s nobody’s fault and we will leave each other alone, but if person 2 causes an accident, then it will have to pay person 1 damages.”
Now, after this long introduction, let me finally explain how computers can currently help during this process: 1) Computers can ask you questions and through a decision tree can lead you to the type of contract you will probably need. So it can ask person 2: “Do you need the car for a year or for two weeks? Ok, then I think you need a rental agreement. I have an example here.” 2) Computers can find out what everybody else does. They can crawl through contracts and find patterns. The SEC makes all contracts of exchange-listed companies public, so there is a lot data for computers to comb through. And 3) computers can help people collaborate. This is best done through a Wiki. It can let people who like this stuff (i.e. lawyers) edit contracts on a wiki and thereby make contacts open source for everybody to see and use.
The best we can do today is combining these three skills. So we can come up with a website that allows lawyers to collaborate on contracts and thereby build standard forms that take account of the wealth of knowledge that lawyers have. Those standard forms would address the various scenarios that could go wrong during the relationship of the two parties. But that website should also have a side for “users”, on which the machine helps people who want to transact with each other find out what is the right agreement and what it usually contains.
That website exists, although the exact code that makes it run is still being developed. Have a look at www.legale.se, a site I am building with two friends. We are working on using computers in the law to the extent current technology permits us to. By including a wiki-like concept it takes account of the constant changes in the law and also of the power of the wisdom of crowds that helped built Linux and other open source projects succeed.
The future will have more. Computers will “know” what their users want and will look out for transactions that fit. In other words they will take care more and more of the standardization of contract law. Lawyers, on the other hand, will still be necessary but only in limited contexts: Whenever somebody wants to transact in a way that nobody has done before. In those cases you will still need human creativity to figure out how to design that relationship. But for the vast majority of contracts computers will do the work.