Whitepapers Deconstructed: The Terra Protocol

Cameron Welland
7 min readMar 2, 2022

The Terra protocol is a Layer 1 blockchain using the Cosmos Software Development Kit (SDK). Terra is uniquely focused on building a better currency with core values of stability and adoption. The plan for adoption of a price-stable cryptocurrency is achieved through creating an economy, powered by its collection of native stablecoins (particularly TerraUSD, UST) and native token (LUNA). Terra was built by Terraform Labs, a fintech firm founded by Daniel Shin and Do Kwon, based in Seoul. Terra’s mainnet was launched in April 2019.

Early Vision

The Problem

Terra’s value proposition is to create a cryptocurrency that can be used as a medium of exchange, particularly in e-commerce payments and decentralised finance (DeFi). The creation of Terra was based on the premise that price volatility of cryptocurrency landscape caused by speculative demand and predetermined supply schedules is the major roadblock of mass adoption as a medium of exchange or store of value.

Stability — Stablecoin Ecosystem

Terra introduces decentralised stablecoins algorithmically pegged to world currencies such as USD or KRW, while also retaining the beneficial properties of a cryptocurrency such as security, immutability and availability. The ability to maintain a stable peg to fiat currencies is achieved through an elastic supply policy, more on this later.

Adoption — Growth Driven Fiscal Policy

From the beginning, Terra’s approach has been to optimise its on-chain economy for growth. To do this, Terra has based their core strategy around Metcalfes Law, which stipulated that the value of a network is exponential to the number of connected users. In accordance with this, their strategy has been to deploy its treasury to fund the development of decentralised applications (DApps). These DApps are smart contract based financial tools centred around UST, which will be explored later. The utility of these DApps will drive demand for UST and onboard new users up to the point where the ecosystem reaches a critical mass adoption where the network effects kick in.

Technology

Consensus and Governance Mechanisms

Terra is a Layer 1 blockchain that uses the Cosmos-SDK which is secured using the Tendermint Distributed Proof of Stake (DPoS) consensus mechanism, allowing for near instant transaction finality with low fees. This DPoS algorthim relies on a set of 130 validators (full nodes) to secure the network by committing and validating new blocks of transactions to the blockchain. In return they receive transaction fees generated by the network and oracle submission rewards. However, validators are subject to having their stake slashed for malicious behaviour. A delegator delegates LUNA to a validator and receives a portion of their staking rewards. The 130 validators are determined by their own LUNA staked + that of their delegators.

Staking on TerraStation

Constant updates of the price of world currencies, are critical for the Terra network, however a decentralised blockchain cannot access external data (more can be read on oracles on my Chainlink article). The validators act as a decentralised oracle network, each committing a vote every n blocks for the current price of, for example, $USD. To incentivise validators to submit accurate reports, rewards are given for a submission within 1 standard deviation of the median, however staked funds are subject to slashing if it falls outside 1 standard deviation. This provides strong a strong incentive for validators to provide accurate reports, preventing the possibility for a coordinated attack on the network.

The final role validators and delegators play is in the governance of the network. On-chain governance is the process in which participants can manage and implement changes to adapt to the ever-changing blockchain landscape. Participants can stake a minimum of 50 LUNA in a two-week deposit period to submit proposals, in which the network votes and will be implemented once it crosses a threshold of support. For a proposal to be accepted, the number of total votes must exceed 40% of all LUNA staked and exceed 2/3 proportion of YES votes. If a proposal is unsuccessful, the staked LUNA will be slashed to ensure only quality proposals are submitted. Examples of network changes through the governance mechanism will be explored later in the Columbus-5 upgrade.

Governance on TerraStation

Tokenomics: UST and LUNA

Terra’s ecosystem relies on its two native tokens: The Terra stablecoins (primarily UST), and LUNA.

UST: UST is Terras algorithmically stablecoin pegged to $USD. The Terra protocol has an automated market maker, in which $1UST can be swapped for $1USD of LUNA at any time via a mint and burn mechanism. If UST starts deviating from its $1 USD peg, an arbitrage opportunity occurs. However, there is a daily cap to prevent manipulation from whales.

  • If UST begins to rise above $1 USD, it can be minted from the protocol at a discount in exchange for burning LUNA and then sold on the market for instant profit. This expands UST circulating supply, bringing the price back down to $1 USD.
  • If UST begins to fall below $1 USD, it can be bought on the market in exchange for LUNA and then burned back to LUNA on the protocol for instant profit. This contracts UST circulating supply, bringing the price back to up $1 USD.

It should be noted that through decentralised financial tools in the ecosystem such as Anchor (article on Anchor coming soon), UST can be borrowed, using LUNA as collateral. A sharp decline in the price of LUNA would result in loans becoming under-collateralised. This would trigger a liquidation event, whereby the collateral is instantly sold on the market by the protocol. Selling onto the market increases circulating supply, making price fall further, causing more liquidations, which is known as a liquidation cascade. If there selling pressure from a large cascade exceeds the daily cap, then the UST peg can be lost, sometimes significantly such as the May 2021 crash.

LUNA: LUNA is Terra’s native coin used for staking and in on-chain governance of the protocol by validators and delegators. As discussed, there is an inverse relationship in supply with UST. As the Terra ecosystem grows and demand for UST increases, UST must be minted to increase the total supply. To mint UST, LUNA must be burned which decreases the total LUNA supply. In addition, if the Terra ecosystem is growing, there is more competition to become a validator to receive rewards, increasing the demand for LUNA.

TerraStation Wallet

Terra is non-EVM (Ethereum Virtual Machine) compatible, which means Ethereum smart contracts cannot run on Terra. This means users cannot use popular blockchain wallet, Metamask. Terra has its own wallet called TerraStation, which is a browser extension. TerraStation includes an in-built decentralised exchange to swap tokens, and pages to stake LUNA to validators, as well as participate in governance proposals.

TerraStation Wallet

Columbus-5 Upgrade

In September of 2021, The Columbus-5 upgrade went live, implementing a collection of successful governance proposals, marking some of the biggest changes in the Terra protocol.

Economic Changes

In Columbus-4 mainnet and earlier, when LUNA was burned through the expansion of UST supply, a portion would go to the Treasury fund described earlier to turbocharge growth. The amount burned + amount sent to the treasury is known as seigniorage. The Columbus-5 upgrade implemented the “Burn All Seigniorage” proposal that was voted in the governance mechanism. In this proposal, 100% LUNA will be burned when UST is minted, benefitting validators and LUNA holders by making the native token more deflationary.

Murray Rudd, applied micro-economist (PhD) had this to say in his Terra Bounty winning piece:

“The elegance of the UST/LUNA design is evident here: every sustained increase in UST demand simultaneously results in the expansion of the LUNA demand curve and contraction of the LUNA supply curve. From a microeconomic perspective, the importance of this unique feature cannot be overstated.”

Since validators will no longer receive seigniorage rewards for accurate oracle reports, they will now receive dividends of stablecoin swap fees which scales with the economies transaction volume. This increase in staking reward APY will ensure validators continue to submit accurate price reports.

In accordance with another governance proposal, $1B USD of LUNA in the community treasury will be burnt for UST and used to bootstrap the Ozone insurance protocol. Ozone is Terraform Labs own decentralised insurance protocol that facilitates leveraged coverage of technical risks in the Terra DeFi ecosystem.

IBC

Another governance proposal “Enable IBC Transfer” was implemented in the Columbus-5 upgrade. Because Terra blockchain is built using the Cosmos SDK, it can utilise the Inter-Blockchain Communication (IBC) protocol to communicate with the broader Cosmos blockchain ecosystem. Interoperability with other blockchains means UST and LUNA can be exported to other IBC compatible chains and utilised in inter-chain DeFi.

A follow up article will be released shortly, on the primary DApp in Terra’s ecosystem, Anchor Protocol.

--

--