Smart Contracts and Business Rules          

Stephane   Mery
Stephane Mery Chief Architect, IBM Operational Decision Manager, IBM Read Author Bio || Read All Articles by Stephane Mery

One of the key concepts in the Blockchain world is the notion of Smart Contract.  This article explores how business rule practices and technology apply to Smart Contracts.[1]

The term Smart Contract was coined in 1996 by Nick Szabo, who outlined the functional and technical requirements for contracts that could be embedded in software and hardware in such a way to make breach-of-contract expensive.  Later, as blockchain was introduced, the term was used to designate the software mechanism in the platform that allows automation of the processing of transactions.  Vitalik Buterin, the founder of the Smart-Contract-based Ethereum blockchain, defined blockchain as "a computer program that directly controls digital assets and which is run in such an environment that it can be trusted to faithfully execute."[2]

Blockchain is known as 'the platform of trust' that can store and manage anything of value in a secured and trusted way.  Transferring something of value is often controlled by a set of rules that protect both the initiator and the recipient of this transfer.  This set of rules is often part of a contract agreed by the parties involved in the transaction.

Contracts that describe and are used to enforce rules for trade have been used since ancient times.  All modern economies are heavily reliant on contracts with their suppliers, clients, employees, business partners, and so on.  Centuries of trade has resulted in sophisticated paper-based contracts, with supporting practices like contract law concerned with the rights and duties that arise from agreements.  It's not really a surprise that the mechanism that controls the transfer of value in a blockchain is known as a '(smart) contract'.

However, it would be hard to consider blockchain smart contracts as real contracts that create a strict legal binding between parties.  The legal framework under which entities are trading value between each other is usually little more than the code that automatically processes transactions in the blockchain.  Smart contracts should be considered as a way to automate some of the conditions and obligations described in the contract — but they are not necessarily considered to be legal instruments, at least not today.  Interesting developments in legal tech are targeting smart legal contracts, bridging the gap between automated actions derived from contractual conditions and actual legal contracts.

If blockchain could be considered as an immutable database, the smart contracts would be the equivalent of stored procedures.  Just as blockchain transactions are secured by complex distribution and cryptographic mechanisms, the behaviour of smart contracts is also protected by those mechanisms, making them the trusted instrument to apply the transaction-processing logic that has been decided by the business network of participants.

Trusted automation brought by smart contracts, combined with the finality of transactions in blockchain, is likely what makes blockchain the most powerful (and also potentially disruptive) innovation of recent times, opening the door to more efficient, more automated systems and new business models.

Although the most basic usage of blockchain — where it is used as a simple immutable ledger of transactions — doesn't require much logic to be executed by smart contracts, most of the use-cases that imply value exchange do require encoding precisely-defined rules in the smart contracts to validate transactions or evolve the state of the assets that are the object of the trade.  Those rules, implementing the clauses of the contract, are really business rules that will be likely defined and negotiated by the business partners involved in the value exchange.

If contract clauses are business rules, key attributes of decision management should apply to smart contracts:

  • Transparency and readability:  contract clauses should be owned by the business and written in the language of the business.
  • Managed as explicit business assets, and not buried in code.
  • Governed according to principles business partners have agreed upon to control the life-cycle of the contract.

In most blockchain platforms, the smart contracts are written by developers using traditional programming languages like Go lang, Java, or Javascript.  Ethereum has defined a dedicated technical language called Solidity.

Implementing the logic of smart contracts using business rule languages proposed by most products in this field has two advantages:

  1. The clauses are written in high-level, business-friendly languages and can be easily reviewed and shared between business partners.
  2. A rule engine provides a much more-constrained execution environment, making smart contracts easier to analyse, validate, and test.

Blockchain is an eco-system play where different companies or individuals will interact and transact in the platform.  To work efficiently, the marketplace enabled by blockchain requires the different participants to agree on the rules.  To be able to do that, business people from all participating entities must be able to understand the logic implemented in the smart contracts.

Smart contracts are manipulating value stored in the blockchain, transferring ownership of assets (for instance) or moving crypto-currencies from one account to another.  The behaviour of the smart contract must be non-ambiguous and fully predictable, which is hard to achieve with a general programming model supported by a Turing-complete execution machine.  On the contrary, a rule engine limits what can be done, which also limits the risk of flaws and facilitates static analysis and validation of the smart contract.

As blockchain fosters decentralization and connects independent business entities, the need for strong and transparent governance of the rules is critical.  Tools and practices that exist in the decision management space are fulfilling this need to have business-level collaboration and governance of assets that have an impact on the business.

The need for controlled and limited expressivity, transparency, business involvement, and governance pushes for introducing the notion of rule-based smart contracts, which are smart contracts supported by a rule engine whose behaviour is specified as a set of business rules.

The business rules of the smart contract can ensure the transactions submitted to the blockchain are compliant with a given regulation or can automate actions triggered by specific transactions under specific conditions.

A more-detailed article[1] illustrates how we can implement rule-based smart contracts using IBM Operational Decision Manager and HyperLedger Fabric blockchain.  That article describes the technical details of embedding a rule engine in all blockchain nodes endorsing transactions.  It also describes some challenges specific to blockchain, such as ensuring that all nodes have the same version of the rules at all times.

Blockchain has the potential to enable new applications and new business models, removing a lot of the friction in value exchange.  Smart contract is the enabling technology for that and this raises a lot of challenges that are well-known to the business-rules/decision-management community.  The business rules approach and decision management practices already bring a lot of agility to companies and will likely be a must-have in the context of blockchain, where (by nature) the business logic of the smart contracts needs to be shared and governed by independent participants of the business network.


[1]  Further technical experimentation that applies the market-leading, IBM business rule offering, Operational Decision Manager, to HyperLedger Fabric blockchain is described in Make Your Blockchain Smart Contracts Smarter with Business Rules return to article

[2]  Quoted in The Impact of Blockchains & Smart Contracts on Legal Services Demand & Spend return to article

# # #

Standard citation for this article:

citations icon
Stephane Mery, "Smart Contracts and Business Rules           " Business Rules Journal, Vol. 19, No. 6, (Jun. 2018)

About our Contributor:

Stephane   Mery
Stephane Mery Chief Architect, IBM Operational Decision Manager, IBM

Stephane Mery is a Distinguished Engineer at IBM and Chief Architect for IBM Operational Decision Manager, the Decision Management offering of the Digital Business Automation portfolio. He has spent most of his career innovating, developing, and promoting rule-based systems, complex-event-processing platforms, and distributed systems. Recognized as a technical expert with a track record of innovations in providing programming models and languages accessible to business people, his latest innovations are in the domain of Blockchain and Artificial Intelligence.

Read All Articles by Stephane Mery
The BRSolutions Professional Training Suite

BRSolutions Professional Training Suite

All About Concepts, Policies, Rules, Decisions & Requirements
We want to share some insights with you that will positively rock your world. They will absolutely change the way you think and go about your work. We would like to give you high-leverage opportunities to add value to your initiatives, and give you innovative new techniques for developing great business solutions.