Smart contracts are self-executing or computer protocol contracts on a blockchain where the terms of an agreement can be expressed in code as a conditional statement or conditional block that will execute if a certain expression evaluates to true, which is to say that smart contracts check whether a certain condition is true or a certain event has occurred and then they execute either a transaction or they set a flag that can be used to evaluate the conditions on another smart contract.

Smart contracts can provide superior security compared to traditional contracts that can be executed without emotion and with lower transaction costs. Due to the nature of blockchain technology once executed those transactions are traceable, transparent, and irreversible.

Cryptographer, Nick Szabo, started discussing smart contracts as early as 1996 when he realized a decentralized ledger or blockchain could be used for self-executing contracts where all participants of the contract would have full transparency, could easily verify the agreed upon terms while divulging only the necessary details specific to that contract in play, all at a lower cost due to the removal of traditional middlemen.

The purpose of smart contracts, if designed properly, is to make transactions more available, efficient and economically more viable

Think of the execution of a smart contract similar to how your bank operates – if your late on a payment the bank automatically penalizes you. If you pay your bill on time nothing happens, if you are one second late you are penalized and it is all done automatically via a computer program. The emotion is removed from the equation. Smart contracts act in a similar way – If Action A happens, we move to the Action B part of the contract. If A does not happen then Action C of the contract gets executed. It does not take a human to go over the terms of the contract to execute any part of it – it happens automatically.

In a perfect world smart contracts would be used in day to day business transactions. Think of companies that have to issue invoices based on 30 days net, 60 days net, etc. Imagine being able to physically issue invoices once and only once on delivery of a product or service – the payment terms are automatically taken care of on a blockchain instead of an accountant having to follow up with emails, letters and phone calls asking for payment.

Challenges with Smart Contracts

A contract, according to Wikipedia is a promise or set of promises that are legally enforceable and, if violated, allow the injured party access to legal remedies.[1] Contract law recognises and governs the rights and duties arising from agreements.[2] In the Anglo-American common law, formation of a contract generally requires an offer, acceptance, consideration, and a mutual intent to be bound. Each party must have capacity to enter the contract[3]. Although most oral contracts are binding, some types of contracts may require formalities such as being in the form of a signed, dated written agreement in order for a party to be bound to its terms.

A smart contract is similar to a traditional contract – except the conditions of the contract are trustless – the need for ‘trust’ (a third party overseeing the contract terms) is removed because the conditions of the contract are executed by computer.

But what happens when a 3rd party outside of the contract is needed to verify a condition of the contract has been met?

The Oracle Problem

Szabo realized a decentralized ledger or Blockchain could be used for immutable and tamper-resistant contracts that could be self-executing as long as they were able to establish the veracity of the fact of occurrence of an event from a decentralized source of truth such as an oracle. A blockchain oracle is a third-party information source – a trusted third-party entity that provides data to blockchains about real world events and a means to communicate outside the blockchain to verify events.

Smart Contract Legal Concerns

In the US contract law there is a concept known as implied covenant of good faith and fair dealing. This is a presumption that the participants of a contract will deal with each other honestly, fairly, and in good faith. This is an assumption that all parties in a contract will act in good faith, deal with each other honestly and not interfere with the other party’s ability to successfully execute their part of the contract. Smart contracts currently lack the ability to account for unspoken expectations or deal with unforeseen circumstances. In a traditional contract dispute a mediator or judge would use reason along side the rule of law in resolving any conflict that should arise from a breach in contract whether intentional or not intentional.

Smart Contract Programming Challenges

To create smart contracts on Ethereum, programmers must learn an entirely new programming language called “Solidity.” This can be complex and challenging and if not done properly, poorly written smart contracts, when executed can experience detrimental security breaches that can result in huge economic losses.

One of the most popular smart contract blunders was with the Distributed Autonomous Organization (DAO) which occurred in 2016 and resulted in a financial loss to the tune of 3.6 million Ether.

Addressing Smart Contract Challenges

There’s no denying that smart contracts are an incredible development and they are only going to get more sophisticated as we move forward in blockchain’s life cycle.

Artificial Intelligence (AI) and the Oracle Problem

Artificial intelligence (AI) and machine learning (ML) are providing an opportunity to increase the capabilities of smart contracts through blockchain oracle solutions. An oracle can supply verifying 3rd party data without needing to know the full context of the transaction, preserving contract integrity and privacy.

A few blockchain companies are working on providing effective oracle solutions including Zap, Akroma and Auger.

Zap – A smart contract platform will allow any user to become an oracle by building a peer-to-peer ecosystem in which all types of data can be made available to those interested. Zap currently works with Ethereum and will eventually provide oracles for Lisk, NEO, as well as any future smart contract platforms.

Augur – A decentralized oracle and prediction market platform, have programmed complex smart-contracts on the Ethereum network that users can use to create markets and select oracles.

Akroma – Akroma Oracles will build on the software developed for the current Masternode solution to execute queries into the real world and update the Akroma Foundation signed smart contracts.

Programming Challenges – Simplifying the Smart Contract Coding Process

BUMO – A next-generation commercial-grade public Blockchain for ubiquitous and trusted value transfer, BUMO solves the developer’s barrier to entry challenges by providing a user friendly ‘contract-less app’ feature.

In most smart contract platforms developers need to know a specific, challenging code language like Solidity. By providing a unique interoperability platform that makes development on a blockchain easy for developers regardless of their language of choice (JavaScript, Java, Go, C/C++, Python, etc), BUMO simplifies the smart contract process.

Developers can build DApps based on the user account, not purely on the smart contract, which allows them to achieve more functionality without having to submit sensitive data to the smart contract. The user can choose what data should be sent to the smart contract and what data should remain private, giving the developer more account privacy, reduced security risk and higher performance capabilities.

BUMO’s developer friendly and robust platform has gained the attention of the blockchain technical community, forming valuable partnerships with blockchain industry leaders BlockGeeks and the Blockchain University.

Some people deem that the smart contract is the beauty of Blockchain, but when you look into real business scenarios, especially ones with a complex business model you will see why smart contracts still have a long way to go. In the future, smart contracts need to be much more powerful, not only in function, but also in flexibility and security, to satisfy multiple business scenarios. BUMO is working hard on solving these issues by providing a platform which is more secure, more functional and easy-to-use.

Kevin Liu, the Director of BUMO Foundation

Ethereum – The leader when it comes to DApps, Ethereum has an estimated 2000 DApps on their platform (I have seen various numbers in regards to DApps numbers). All of these DApps rely on smart contracts to accomplish a number of important tasks, and in their current state smart contracts can be vulnerable to it errors which can turn into incredibly costly mistakes.

The Ethereum Foundation is actively looking for ways to address this and other challenges including the implementation of CASPER, a widely anticipated upgrade to the Ethereum network and the use of VYPER, a smart contract code built to simplify the smart contract writing process in order to create easier-to-understand smart contracts that are more transparent for all parties involved, and have fewer points of entry for an attack.

Blockchain technology is still in the early stages of development. I spoke with Arunabh Das, founder of App Liaison Inc. on what we can expect to see in the future with smart contracts and here’s what he had to say…

My prediction about smart contracts is that over the course of the next 10 years, Blockchain developers are going to give law firms a run for their money by translating all traditional legal contracts into smart contracts and the lawyers of the future will be software developers who will need to have training in Computer Science and Law in order to do their jobs effectively as custodians of contracts between various parties as it applies to all industries of the future. Arunabh Das, Founder, App Liaison Inc.

It is definitely exciting to see where smart contracts and blockchain technology is headed. 2019 is sure to be a ground breaking year.

Arunabh Das, founder of App Liaison Inc and I discuss smart contracts in an episode of the Crypto Blockchain Podcast https://overcast.fm/+Or6NqYcE0

Check out my BlockDelta link for my full profile.