We hear a lot about smart contracts these days.
But what exactly is one, how do we create it and when can we use it?
The term was invented by Nick Szabo, who applied his interests in computer science, law and cryptography to create a cyberspace equivalent of gold – and came up with the idea of decentralized digital currency.
The point of a currency, however, is that it acts as a store of value and a medium of exchange – but when do we actually need it?
Nick, in his original article, says a contract is really a set of promises.
The things that go into a contract have evolved over time – from a contract of marriage to a contract of employment, from a contract of sale to a contract of lease.
All these structures say that the people involved promise to do certain things as set out in the contract.
While the concept of a contract can encompass a blood oath sworn at midnight under a lightning blasted oak tree, normal contracts have four characteristics:
- The participants can observe how each party is performing on the contract.
- An arbitrator can verify that the contract is performing as set out or is being breached.
- The only people involved are the people that need to be involved – their rights are secure and private.
- The contract can be enforced – for which we need acceptance of the contract by the powers that be.
A smart contract takes these concepts and recreates them in the digital world.
The difference is that parties enter into a digital agreement instead of signing a paper contract.
This has been done several times before – every payment with a Visa debit card, Ebay purchase with Paypal and software contract we sign without reading are all digital contracts.
The idea of smart contracts when linked with Blockchain technology adds a few ideas to standard paper contract.
The first is that contracts can be expressed in code using an algorithm.
Common algorithms may be if-then or when-do.
For example, if you pay me X, then I will give you an hour of work.
Or when a shipment of copper is delivered in two months time I will pay you the price then that we agree now.
So this means that we need to identify the real life elements that the contract talks about like money and stuff.
For example, payments might be done using a decentralized digital currency like Bitcoin or Ethereum while each hour of work or shipment of copper is tagged with a digital identifier.
So, a second part of a smart contract is the ability to give things a digital ID.
Then there is the question of where to store the smart contract – and that’s where the idea of a ledger comes in – especially a blockchain based distributed ledger.
This keeps the information related to the contract secure by design.
Smart contracts are the way things are going to go – paper agreements have little place in the future.
Many other part of a contract – the promises we make, the reliance on the state to enforce agreements, and the lawyers that create and interpret them – are all still likely be around.
The key, however, is going to be to get the contract algorithm right.