Introduction
The UTXO Chains is a strategic vision of how to approach the architecture of the smart contract platform with parallel smart contracts, which is also multi-chain yet bridgeless. It becomes possible due to determinism and parallelism of the UTXO ledger model (while otherwise the UTXO is notoriously problematic when it comes to smart contracts).
UTXO Chains is the next step in the development which started with IOTA Smart Contracts aka ISC (already implemented). It generalizes the concept and extends it with validity proofs and with L1 execution (also known as L1 smart contracts), while continuing with the same general principles of the reasoning and the architecture. It also assumes programmability-related extensions and generalization of the Stardust specification, which was designed with ISC in mind.
Originally, the concept was named IOTA Chains, however the name UTXO Chains better reflects the universal nature of the envisioned architecture: at its core it is not dependent on any particular UTXO implementation.
In these writeups we are trying to think from first principles, rather than following other narratives and naming of the crypto space. This is not possible 100%, however we hope readers will appreciate the effort.
To avoid confusion, we narrow down the term ‘smart contract’ to programmable state machines with unbounded state. That makes smart contracts Turing-equivalent. They are atomically composable over a shared persistent state. By this understanding, the ‘smart contract’ is something fundamentally equivalent to the Ethereum smart contract and its transaction model. The programmable logic of the ledger with the state locked inside the UTXO transaction bounds, for example Cardano’s EUTXO model or EasyFL-programmed UTXO transactions, we leave aside (while they do have own merits).
By UTXO ledger here we understand some ideal UTXO ledger without any assumptions about the global order among UTXOs. We will also call it pure or genuine UTXO ledger. Note, that in the crypto reality the pure UTXO ledger does not exist: Bitcoin, Cardano, Fuel etc., directly or indirectly assumes global order in the ledger by putting all UTXO transactions into the blockchain. We hope it will become a reality with the arrival of transaction-DAG-based consensus protocols to mainnets.
The UTXO Chains exploits the powerful features of the pure UTXO ledger: parallel execution and parallel writing to the ledger state. UTXO Chains, unlike existing UTXO platforms on blockchains, does not assume any total order among UTXO ledger state, even implicit or hidden. From this point of view, the UTXO Chains may be seen as a generic and ultimate architecture of a smart contract platform built on top of the UTXO ledger and preserving nice features of it. It is because, given the deterministic UTXO transaction model and absence of total order, there are not much other options how to combine real smart contracts (which are non-deterministic with total order) with UTXO fundamentals (which are deterministic and with partial/causal order).
UTXO transactions are constraint-based and deterministic. They consume (take as an input) a particular local state, a deterministic fragment of the global state. Meanwhile, the smart contract transactions are execution-based, i.e. non-deterministic: that is why they can share and consume the global unbounded state. Both options have their own advantages and trade-offs. The execution-based approach is predictably dominating the space because of its simplicity and developer-friendliness.
UTXO Chains tries to combine the best of the two worlds in one framework. It results in the decentralized sharded/multi-chain and bridgeless system with enormous scalability, fast probabilistic finality and composability, in theory many hundreds thousands TPS of throughput (depending on the particular setup).
The concept of UTXO Chains encompasses the following existing narratives:
- multi-chain composable system with chains validated on L2 by permissioned committees based on real-world identities and social trust. This is the model of ISC chains. This is also similar to the optimistic rollup and side-chain model, though there are differences. We further call this approach L2-validated UTXO chains
- a trustless multi-chain system with validity proofs (aka zk-proofs), provided to the L1 UTXO ledger. We call its UTXO-chains with validity proofs. It is similar to the zk-rollup model
- trustless chains with execution and data availability on L1 without involvement of L2 for data availability nor execution. We call it L1-validated UTXO chains. It is also known as L1 smart contracts.
The three are variations of the UTXO Chains, they are similar to each other. The essential difference is one: are the state transitions validated on the UTXO ledger at L1 or not. The state transition can be validate on L1 by checking the validity proof or (re)running the VM on each node.
Each approach has own advantages and tradeoffs.
All three options share the same sequencing concept, which is outside the UTXO ledger itself. The sequencing is stateless, distributed and leaderless. Due to being leaderless it therefore is MEV-and-censorship-resistant. (We will discuss the sequencing in next posts. In short: whenever there’s a need to deal with the competing access to the same state (think, same asset) and non-determinism as a consequence, the pure UTXO ledger itself leads to contention and therefore does not provide efficient sequencing, because it avoids any assumptions about the total order)
Why UTXO chains, as an umbrella and modular concept, even makes sense?
The reason is practical and strategic: all three variations of UTXO Chains share significant parts (modules) of the architecture as well as big and complex codebase (already implemented in the ISC, the Wasp node). The distributed and leaderless sequencer, L2 data availability layer (the access nodes) and the Stardust UTXO ledger is already a part of the Shimmer network.
This way can see the UTXO Chains as an ongoing development effort which has been started with the ISC. It keeps, however, full independence from existing developments as a concept.
Disclaimer
We put this under a separate title because the statement is a very important assumption of the UTXO Chains.
The UTXO Chains concept only makes sense if we have a truly pure UTXO. I.e. we need a ledger consensus layer, which does not brake parallel properties of the UTXO. The ingenious blockchain consensus protocols does not suit. Programming languages with parallel execution semantics are even less relevant.
Instead, we just need a consensus, which does not make any total order assumptions in the fast probabilistic consensus phase and defers total ordering of transaction until the deterministic finality (finality gadget) phase, i.e. much later and irrelevant in most practical situations. UTXO ledger is a DAG, so the consensus must be DAG-based too.
We believe, the Tangle, a transaction-DAG-based consensus concept proposed by Serguei Popov, will ultimately lead to this kind of permissionless consensus protocol, which is both secure and which offers fast probabilistic finality in the leaderless setup without making global assumptions about the order among transactions.
If, for some yet unknown reasons, this kind of DAG-based consensus layer on the distributed UTXO ledger will turn out to be unfeasible practically, the efforts to parallelize state updates with UTXO and the concept of UTXO Chains will be deemed useless automatically.
In the latter case it will mean, that efforts of other projects to take advantage of parallel properties of non-deterministic quasi-UTXO ledger model made for example by Fuel (which uses blockchain consensus and non-deterministic SC requesting model) already squeezes maximum possible from UTXO ideas by executing independent transactions in parallel. So, why bother with DAG-based consensuses then?
Outline of blog posts
These blog posts should be considered a first iteration, a draft of the UTXO Chains concept. The style of writeups is very informal and even popular. It takes significant part of the blog space to discuss very general matters, which is not directly a part of the proposed architecture, but rather a fundamental basis of it. The proper document on UTXO Chains should take form of a whitepaper or similar.
The preliminary outline:
- This Introduction
- State and determinism
An informal detour to the very general topic: a global, shared, atomic and parallel state concepts in the context of chains and smart contracts. The intent is to bring abstract analogies with the purpose to develop intuition around the atomic state concept in DLTs, needed for the further discourse. - Chain constrains and sequencing
Discusses main constructs of the UTXO Chains: the chains on the UTXO ledger and sequencing. Why and when we need sequencing, what forms does it takes. This is a pretty general discussion. - Generic architecture. L2-validated UTXO chains. UTXO chains with validity proofs
Introduces the generic architecture of UTXO Chains and 3 main variations of it: (a) L2-validated chains, (b) chains with validity proofs and (c) L1-validated chains. Also discusses (a) and (b) - L1-validated UTXO chains. Conclusions
Discusses L1-validated chains (aka L1 smart contracts). Discusses stateless computations and unbounded state layers of the UTXO ledger.
Compares all three setups side-by-side, its advantages, tradeoff and use-cases