research
Simplicity: High-Assurance Smart Contracting
November 28, 2018
|
Russell Oconnor, Andrew Poelstra

Earlier this month we released source code for the blockchain language Simplicity.

Simplicity is our answer to the problems faced when trying to code sophisticated smart contracts in blockchain environments. Prior to Simplicity, blockchain programming languages typically made tradeoffs between expressiveness and reliability; developers could either build a complex but unreliable smart contract, or a very basic but reliable one. With Simplicity, developers can finally design sophisticated smart contracts and be confident in their outcomes.

Simplicity has been built to be compatible with Blockstream’s Elements platform. That means developers building sidechains or independent blockchains on Elements will soon be able to take advantage of the features enabled by Simplicity. As an implementation of Elements, the Liquid Network will also support Simplicity; opening up interesting applications for Liquid users, such as trust-minimised escrow, vaults, and other more complex smart contracts.

The source released this month includes:

Why Simplicity?

Blockchains pose several unique challenges that make traditional programming languages unsuitable.

Existing programming languages designed specifically for blockchains, such as Ethereum’s EVM, still face these challenges. Recently, an EVM upgrade failed during testing because implementations did not agree on the result of a computation. Funds have been stolen or otherwise unrecoverable due to smart contract logic errors and programs that exceed their resource limits.

On the other hand, Bitcoin’s Script language is generally limited to combinations of digital signature checks, timelocks, and hashlocks. While impressive protocols (such as the Lightning Network) have been built on these primitives, Bitcoin’s Script language lacks the expressiveness needed for more complex smart contracts.

Simplicity aims to provide the flexibility and expressiveness for whatever computations you need, while allowing you to verify the safety, security and costs of your smart contracts.

What is Simplicity?

Simplicity is a low-level programming language and machine model for blockchain-based smart contracts. It is designed from the ground up to have simple semantics which lend themselves to static analysis and reasoning by formal methods. The Simplicity language is defined by its implementation in the Coq proof assistant.

While the core language itself is simple enough that it fits on a T-shirt – simplicity of a language does not translate to simplicity of development. There are a few reasons for this:

What’s New?

Since we last blogged about Simplicity, we have been working hard to move from experimental language research to a more formal language specification.

We have reimplemented the Simplicity language in the Coq proof assistant:

While Simplicity development is still ongoing, we have reached a point where developers can now explore the Simplicity language themselves. Therefore, it is time to move Simplicity development into the open and open a mailing list.

What’s Next

Going forward, there are many fronts for Simplicity development.

For our part, we plan to:

Other fronts of development include:

We hope you will join us in our project.