Hacker News new | past | comments | ask | show | jobs | submit login
GitHub for Lawyers (2013) (jduclos.com)
131 points by walterbell on Jan 20, 2017 | hide | past | favorite | 50 comments

As a corporate transactions lawyer, what I think is just as important as a "Github for lawyers" is a package manager. Contracts are fairly modular. What I'd love is some way to mix and match different contract provisions, some way to verify that I'm using the latest version of each provision, and a simple way of specifying how everything fits together.

I mean, I'd be super happy if lawyering eventually looks like this:

    import stock_sale
    import confidentiality
    import lockup
    import governing_law
    import states
    import conflicts
    export build(
        company: "Corp Inc.",
        purchaser: "Jane Employee",
        shares: 10000
      lockup(120 /* days */),

      // If two legal terms conflict, the latter takes precedence
And I just type "make" and get back an e-signature URL.

Contracts are similar to software in many ways, but a few crucial differences justify a whole new programming language custom-made for the task.

Not a markup language: a full-blown strongly typed specification language with first-class functions, that supports formal verification / static analysis / model checking.

Those ideas, rooted in computer science, are what will set the next generation of legal drafting apart from traditional work.

Of course the language will be compilable to both natural languages and "smart contract" languages like Ethereum.

I justify these claims and work through your example in detail here: https://medium.com/@Legalese/code-is-law-is-code-4492c864f33...

Other thinkers, like Primavera de Filippi, have commented on "from code is law to law is code": http://firstmonday.org/ojs/index.php/fm/article/view/7113/56...

An archive of prior art is available at https://legalese.com/v1.0/page/past

We're working to build an opensource language called L4 with these properties. If you know, or want to learn, declarative programming (Haskell), dependent types (Agda, Idris), theorem proving (Coq), model checking (CTL*), rule systems (Prolog), modal logic, CCS, CSP, etc etc, join us! Computational thinking required, legal experience a bonus but not really needed. (evil laughter)

Incredibly valuable thoughts, Meng – thank you.

IIRC those exist for law firms and they are called knowledgebases or knowledge management (which also are broader technical terms). I came across them years ago doing some research, though I didn't look into them deeply.

Management can be difficult: Each 'module' needs a maintainer, someone responsible for keeping it updated, fixing problems, finding ways to integrate new concepts and requirements, etc. Based on what I know of law firms, finding attorneys with the time and attention for that can be difficult.

Once that exists, people just won't use lawyers for preparing those kind of docs at all, they'll by the service that provides it (just like people by Nolo Press books and the like, only it will handle more complex issues.)

It will reduce lawyering (around those documents) to litigating when things go wrong, and negotiating custom agreements when two parties have different preferences as to standard terms to include and neither is in a position to do a "take it or leave it".

Astute insight on the shift from transactions to litigation that AI foreshadows.

IBM Watson's legal offering is making this pitch, https://www.washingtonpost.com/news/innovations/wp/2016/05/1...

"ROSS has joined the ranks of law firm BakerHostetler, which employs about 50 human lawyers just in its bankruptcy practice. The AI machine, powered by IBM’s Watson technology, will serve as a legal researcher for the firm. It will be responsible for sifting through thousands of legal documents to bolster the firm’s cases. These legal researcher jobs are typically filled by fresh-out-of-school lawyers early on in their careers."

Maybe. Maybe not. What if the model changes?

Today's model of contracting is fire-and-regret: spec out as much as you can of the next five or ten years, and when the world changes, litigate.

That's not very agile. Hart and Holstrom won the 2016 Nobel in Economics for pointing out the futility of the idea of a complete contract. http://www.economist.com/blogs/freeexchange/2016/10/science-...

What's the alternative? Hirschman remarked that your voice sounds loudest when you are closest to exit. https://en.wikipedia.org/wiki/Exit,_Voice,_and_Loyalty

What if we treated contracts as an iterated stream instead of an immutable invariant? What if every contract had a maximum term of one year, one month, one day? Power imbalances might be reduced precisely because nobody's locked in: it's a lot easier to break up when you're just dating. After the marriage you might let yourself go.

Software is eating law, but "law is code" is only the first step. Just as the historic transition from proprietary to opensource informs ideas like "Github for law", the historic transition from waterfall to agile will find its analog in the legal and business domains by changing the way we develop and deploy contracts, ultimately driving changes in economic relations.

Think about how "no-contract" phone plans have made the telco market more competitive, to the benefit of the consumer.

Think about how agile development means less software project failure, and less software project failure means less litigation between client and outsourced development vendor.

That's just one example of how litigation might be reduced. If better tools and languages mean that we can better transform our intent into specification, we might be forced to be clearer about what we actually do and don't agree on, we might be more honest in our dealings, there might be an actual "meeting of minds", and when things don't turn out the way we expect, rather than blaming the other party, which seems dysfunctional, we embrace change together, and agree to consciously work on the relationship, to improve the next iteration of the contract … which is due to be revised and renewed anyway, next month, not next decade.

Short-term contracts where continuation requires renegotiation aren't a novel innovation, they are routine. Longer-term contracts don't occur because no one understands short-term contracts, they occur because interests exist that aren't well-known served by them.

If I may, as long as lawyers charge by the hour, there will be little incentive to improve efficiency.

This. I worked with a lot of law firms in my previous career (finance) and in my experience it seemed like they generally went out of their way to reinvent the wheel -- even with trivial things that should be standardized like non-disclosure agreements.

I can't remember the company, but there was a Mixergy interview about a product to manage contracts that are in force, and he was getting little to no uptake in the legal market. And then 2008 hit, and lots of big companies pulled their legal work in house and/or demanded better results for their money, and they sell a lot to in house corporate lawyers (who do not bill by the hour).

That's a factor, but like IT people, lawyers have opinions that vary, even for seemingly straightforward stuff.

I've worked with in house and outside counsel on a variety of matters. The meter makes a difference in some things, it the individual attorney or lead attorney made a much bigger one.

For sure, the incentives aren't lined up quite right. I know of a couple attorneys who have switched to some standard rates for stuff (perhaps called value-based billing, or I might be making that name up).

It works well for lots of things. After a 30 minute consultation with a new client, the attorney can estimate the documents which will be required and can give a reasonably close estimate of the total cost. It also encourages the attorneys to still track time on a per-task basis and actually look for ways to improve.

Unfortunately for one attorney I know, the bankruptcy court still requires hourly billing, so he can only do value-based billing on the stuff he can get resolved outside of court.

The amount lawyers can charge per hour is determined by the perceived quality of their output, so efficiency wins are very much desirable.

Not if your clients are paying by way of an insurance policy (which often happens in litigation). Then they might as well spend up to the policy limit. And in lots of other cases, you hire lawyers based on the prestige principle. I.e., "hey don't blame me, I hired the best lawyers I could!"

That reminds me of "Common Draft", a collection of contract language apparently meant to be included by reference in a doc that specifies parameters.

An example usage: http://www.commondraft.org/#ConfKExpress

(I'm not sure how the reference is meant to work because I'm pretty sure commondraft.org has been edited since I saw it some years ago; maybe it's meant to copy whole sections and then include the specific details in a page like the one linked above?)

Note that the CC license mentioned in the header isn't actually useful except to lawyers: it contains the noncommercial restriction with separate special permission for most uses by licensed attorneys (looks intended to prevent non-attorneys from actually using anything there in transactions).

There's probably a billion+ dollar market for this, especially if you can GUI-fy it enough. My guess is a good test group would be paralegals. If they can "click together" contracts with up to date modules you're probably on the right track.

Super long term it could also be interesting if you could provide a fill in the blanks mask for clients that generates your contracts (a simple workflow where they fill in some details like names, corp, state etc. and a "what do you want")

This exists and has existed in various forms for a long while. It's not a billion dollar idea. Business people prefer to pay lawyers hourly for peace of mind, despite lawyers having almost no accountability. Lawyers prefer to cobble documents together in Word because if they bill 8 hours a day at market rates, they're clearing at least $750K p.a. If lawyers want more money, they employ a standard labor pyramid, delegate workload, and raise their rates. I'm not saying it's right, or good, but that's the reality.

Agree with much of the above with some exceptions: secretaries create documents for partners and senior level associates. There is usually a bank of standard provisions that the secretary pulls from. Partner A says pull the standard template plus x and Y provisions. Secretary prepares and Partner reviews. On the billing, you may see preparation charged at the secretary's hourly rate with review at the partner's rate. Lawyer's have plenty of accountability from their clients. Corporate clients hire outside firms to review billings. Each year corporations review their outside counsel and decide if they want to find new counsel. Big Corp invites big law firm X, Y and Z in for a "dog and pony show". Competition between law firms is fierce.

We're building this at Ironclad. Happy to show you, and it will be more widely available later this year.

Contracts aren't very far from what you described in some businesses. Tools like pandadoc or proposify let you organize yourself so that you've prewritten language that you can pick and choose from. You can then publish and share the doc straight into hellosign.

I have a Jekyll install set up to do just that. It's quite primitive, but better than nothing.

IMHO this needs a new language that acts like VHDL or Verilog. Language level constructs that make contract writing possible.

I think Ethereum Smart Contracts are a good first step. It is independent of the blockchain concept though.

Why doesn't this exist? It seems like an instant win.

The principal reason is the complexity of integrating ever-changing legalities from all three branches of government across all jurisdictions – and it's not just the logistics; it's the very modality of interoperation with democratic institutions. Despite a modern push for efficiency in public administration, extant inefficiency is still deep and vast, and capital markets can hardly bear it (i.e. investment in development of the concept).

But don't discount a secondary complexity – that of the contextual analysis and pure judgment inherent to legal practice, for which the human mind has a mysteriously unsurpassed capacity.

i assume not actively pushed b/c most get paid by the hour and by "customization to needs"

It seems like a slightly modified static site generator (like hugo, hexo, or jekyll) fits this description perfectly.

Isn't this just what latex is for?

Doesn't hotdocs do this?

This may have changed, but the last time I used HotDocs it was a simple form wizard. Can't mix-and-match or version sections of a document independently of each other.


2014 review of open-source legal doc repos, with screenshots of each site, and ideas for improvement, http://www.openlawlab.com/2014/08/05/githubbing-law/

That is more in depth than the posted article. Doesn't mention three things I would think would be needed though..

Live updating of document section numbers/names and references back to them. Lots of named clauses in legal docs.

Workflow and electronic signatures.

Support for rendering as word docs or PDF files.

Proprietary tools that do those sorts of things are currently penetrating the market, yet slowly. I've been called to advise on a few projects under development, but have found the mindset behind them lacking for meaning or purpose beyond commercial activity, which is perfectly ok and useful – though what interests me most in this realm is version control coupled with open access and put to use by citizen groups for legislative proposals.

Check out Contract Express from Thomson Reuters (http://contractexpress.com) for the establishment's instantiation of something that approximates the features you describe.

As a lawyer and a programmer, this is a project I worked on for a bit as it makes perfect sense for things like document comparisons, or for a more senior lawyer reviewing a junior's work (just do a pull request on the contract etc).

The problem with it is, as others have said, that you are fighting an industry. The whole model is built around 6 minute units and the work is passed down to junior lawyers in order to make it as profitable as possible. There's a little bit of pushback from a company on occasion, but most pay as having your lawyer do it is, in effect, a form of insurance. You can always sue the law firm if it all goes wrong.

The better way to look at doing something like this would be to turn the legal industry on its head and make a law firm that's tech-enabled from the ground up. Most of the incumbents are now using tech (think Dentons etc) but none have been built with tech in mind. You could then massively undercut the market and have far more efficient working practices which would make you the go-to.

I actually gave a TEDx talk on all this stuff as I found the industry to be extremely frustrating and small-minded when it came to entrepreneurial activity.

Is the TEDx talk online?

Sure is! You can check it out here: https://www.youtube.com/watch?v=5HakaHEDs7Q

> [1] MIT (Computer Science & Artificial Intelligence Laboratory) / Harvard University (HLS, Berkman Center for Internet & Society) bearing this philosophy out in 2014.

The notion is far older than that.

Can you help us trace it further back with an older citation? That would be much appreciated.

10 May 2012: https://blog.abevoelker.com/gitlaw-github-for-laws-and-legal...

I assume if my google-fu were better, I could find references to "RCS for lawyers" or "SCCS for lawyers" though, that were decades old.

Thank you.

Abe's piece is definitely notable – many thanks.

The idea that law is a kind of code (in the CS sense) seemed like a pretty common idea to me... I remember various jokes revolving around that. I doubt anyone wrote those down, though ;)

My father, who is a lawyer on the brink of retirement with programming experience, mentioned this to me many times throughout his career.

Congressional lawmaking should also be done like this, in the open. It would make accountability so much easier.

2014 discussion panel at Stanford Law School, with entrepreneurs building marketplaces for legal services, including contracts, https://youtube.com/watch?v=EqR_4Xhmng0

Can someone weigh in on the advantages of using Git for drafting legislation as opposed to a Wiki?

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact