Simplicity: Jets Release

A new developer preview of Simplicity introducing jets to streamline contract development

An Intro to Simplicity

Simplicity is a blockchain programming language expressly designed for formal verification of correctness and for efficiency. It was built to overcome the limitations of Bitcoin scripting on Bitcoin and “Bitcoin-like” chains (e.g. Elements and Liquid), introducing:

  • Introspection: allowing contracts to observe and control the amounts and destinations of transactions based on spend criteria.
  • Generality: supports any program a developer can think of, while still guaranteeing the verifiability of resource costs.
  • Extensibility: even new library-level functionality can be implemented in Simplicity itself—for example, Schnorr signatures.
  • Vaults: users can secure their coins by requiring a devaulting withdrawal notice period before moving to their final destination. During the devaulting stage they can approve or cancel the withdrawal. This means that even if keys are stolen, an attacker cannot abscond with coins without giving the user sufficient time to detect and block the theft.
  • Limit order swaps: a limitation of swaps made using the Liquid Swap Tool is the atomic swap contract only supports the execution of a trade of a fixed amount of an asset. A partial order match requires a new contract to be created. With Simplicity, traders can set up far more flexible swap contracts that support partially-filled orders. This enables the generation of “limit orders” with reduced settlement risk — useful for building P2P and non-custodial asset exchanges. Even more advanced uses are possible, including algorithmic trading or even smart contract-based derivatives.

History

The last technical blog update on Simplicity was in November 2018, when we announced the first source code release of the interpreter in multiple languages, along with a technical report detailing the language. This announcement marked a shift from Simplicity as a research project, to Simplicity as a production-targeted blockchain language intended for real use cases on real blockchains.

The Advent of Jets

To deploy Simplicity in real life, we need a feature called jets. Jets are fragments of Simplicity programs that have efficient machine-code implementations and are implemented in a language such as C designed for raw performance. When validators recognize a Simplicity fragment for which a jet exists, they can substitute the high-performance C version of the code for the raw Simplicity. On a network with a standard set of jets, the original Simplicity code does not even need to be provided on the blockchain.

Simplicity on Bitcoin

Like Segregated Witnesses, which was originally developed by Blockstream researchers for Elements Alpha before being overhauled by the Bitcoin community, we hope that one day Simplicity will make its way into Bitcoin. To demonstrate what this might look like, we have made a branch of Bitcoin Core to allow the creation of Simplicity-enabled Bitcoin regtest networks.

Simplicity-based Schnorr signatures: jets vs no jets

Simplicity on Elements & Liquid

Unlocking the full power of Simplicity is a long-term project, and we expect it to take some years for the technical community to get to grips with the potential of the new language. Uptake should be aided by being able to try Simplicity within the Bitcoin-like context of Elements, and later, Liquid.

Future Work

Before Simplicity is ready for deployment on Liquid, some of the steps we’ll be working on include:

  • Implementing Taproot on Liquid.
  • Cleaning up our Elements branch and updating Simplicity to build on Taproot, which provides a more flexible script-updating mechanism than raw SegWit.
  • Determining an accurate cost model for Simplicity programs, starting from the formal Bit Machine (as in Section 3.5.2 of the Simplicity Tech Report) but modified to take account of jets. Similarly, designing an update mechanism to allow these costs to change as new jets are implemented.
  • Completing the implementation of Simplicity, including all resource estimation features, anti-denial-of-service mitigations, and finalizing the canonical program representation.

To keep up with the latest Simplicity developments, make sure you sign up for our official newsletter or subscribe to the simplicity-dev mailing list.

Our CEO, Adam Back, will be presenting a webinar on basics of Simplicity on the 8th of April at 16:00 UTC. It’ll be a great chance for bitcoiners to get their questions answered, so make sure you don’t miss it!

Register here!

Developers who want to explore potential uses of Simplicity are encouraged to check out either of the Bitcoin or Elements branches and start playing around, but we’d stress that for now, this should only be attempted by expert users.

--

--

The latest developments in cutting-edge Bitcoin technology from Blockstream.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Blockstream

Blockstream is the global leader in Bitcoin & blockchain technology, making financial markets more efficient by reducing reliance on trust.