Original author: Shin Hyojin, founder of Mint Cash
Original compilation: Frank, Foresight News
In fact, what happened to Terra and its stablecoin ecosystem is truly one of the most interesting, dramatic, and excruciatingly painful stories in cryptocurrency history—second only to the collapse of FTX in terms of value loss.
While critics may tell investors involved in the Terra/LUNA debacle that they were part of a sophisticated Ponzi scheme orchestrated over the course of three years, if we look back at how Terra started, what it promised, and Anyone affected can easily see that this is not the case.
This is the story of a stablecoin project that promised a truly meaningful vision and had the execution capabilities to make it work.
The case for “decentralized” stablecoins
We have heard countless stories of people converting funds into UST and depositing it into the Anchor Protocol instead of depositing it into a bank account. This is not because they are crypto enthusiasts who blindly invest in leveraged trading, but because UST gives them free access to the banking infrastructure that many of us take for granted.
For example, some families in Ukraine transferred their life savings to Anchor deposits because their banks were closed during the war; people in Venezuela, Argentina, and other Latin American countries held UST and deposited it into Anchor because their governments did not allow them to hold it freely. There are and convert dollars to hedge against inflation; small sub-Saharan African communities hold UST instead of dollars to try to avoid being hit by exchange controls during periods of inflation. But they were all seriously hurt after the UST collapse.
These are the true stories revealed by people emailing a former Anchor employee shortly after the UST collapse, and many more people were severely affected by FTX during a similar crisis because they believed they were holding FTX spot accounts. There was their USDT, and 6 months later FTX also collapsed.
Did they stop being so stupid and withdraw all their money from cryptocurrencies? No, most of them actually turned to holding USDT on Binance hot wallets or Binance Earn in a desperate attempt to hedge against inflation in the absence of stable financial infrastructure.
Most cryptocurrency liquidity does come from speculative demand, which no one in the crypto industry can deny, nor is it changing anytime soon. Even we would like to get the same speculative demand, but it is ironic that making UST on Anchor or USDT on exchange wallets an unintended side effect of speculative demand.
Why did they choose USDT or UST instead of something fully regulated? As we all know, neither stablecoin is backed by 1:1 fiat currency. For UST, the situation is relatively simple - a 20% yield provides these folks with a great opportunity to easily hedge against crazy levels of inflation. But for USDT, its actually because they tend to have higher OTC liquidity because Bitcoin liquidity is highly correlated with USDT.
Being unregulated makes them a popular choice for drug lords and criminals, and also allows people in areas with underserved financial infrastructure or high capital and exchange controls to safely avoid the devaluation of their national currencies.
So do we, we believe in financial privacy and the right to free movement of capital, and stablecoins that are not fully backed by “legal” assets are more likely to achieve these properties, as USDT and UST have proven. Holding Bitcoin directly is another popular option, but in the current state of the economy where dollarization has made significant progress, this may not be an option at all for many people.
UST and Anchor have the opportunity to be better options than USDT, as Anchor deposits do not require as complicated a KYC login process as exchanges, especially for those who should rely on OTC transactions anyway. For the average person, it’s simple enough to replace exchange-based stablecoin savings products.
However, in a fatal crash of UST and Anchor, the world lost a potentially better alternative to USDT. This is where our story begins.
Terra Stability Mechanism: The Story So Far
Before we dive in, lets briefly review how Terra works. UST is an algorithmic stablecoin designed to be pegged to 1 USD through an arbitrage-based mechanism that allows synthetic exchange of UST with LUNA.
The basic idea behind Terra is to allow 1 UST to always be redeemable for 1 USD worth of LUNA, with the value of LUNA provided by a price oracle protected by Terra validators, and vice versa.
When the value of 1 UST is higher than 1 USD, external arbitrageurs will be incentivized to buy 1 USD worth of LUNA from the market, exchange it for 1 UST, and sell it at a price higher than 1 USD, thus making a profit;
When the value of 1 UST is less than $1, external arbitrageurs will be incentivized to buy 1 UST at less than $1, exchange it for LUNA worth $1, and sell it on the market for $1 , while earning profits;
At least thats how it works in theory, and the rest is history.
So, what went wrong?
First, there are a few little-known facts about how Terra Minting (officially known as the Terra Market Module) actually works - because the above explanation is too simplistic and leaves out several important points.
The Terra market module executes the above-mentioned casting and destruction synthetic exchange mechanism (first implemented in Columbus-2) based on the two parameters set by the governance (BasePool and PoolRecoveryPeriod):
BasePool is a parameter defined in units of TerraSDR, which defines the total virtual liquidity available for exchange at both ends during the PoolRecoveryPeriod block number;
PoolRecoveryPeriod is a parameter defined in the Tendermint block count that defines how often the BasePool should be reset (replenished) back to its initial state;
Under the Terra system, it is very important to set these parameters correctly, because if the virtual liquidity parameters are not set to be slightly lower than the actual market liquidity of LUNA (i.e. relative to the actual fiat currency of the exchange), the entire system will quickly enter a death spiral .
Fundamental Issues in Identifying Terras Stability Mechanism
Why is this happening? Lets see what happens in the following scenario without an external market maker maintaining the peg:
Virtual liquidity is significantly smaller than LUNA’s actual market liquidity
When external participants sell a large amount of LUNA from the market (which is much higher than the liquidity defined by the on-chain market module), and the UST value is also decoupled downwards, the system will not have enough virtual liquidity to keep up with LUNA externally The size of transactions taking place in the market.
This means that there are enough external arbitrageurs involved and the on-chain market module cannot burn enough UST to mint LUNA on time to restore the UST value. The UST decoupling becomes protracted and people start to lose trust in the system and sell more UST. - A crisis will only worsen over time until it loses all value and enters a death spiral;
Theoretically, in this case, the supply of LUNA will not be affected, although people will likely sell off their LUNA holdings as trust in the system is lost.
Virtual liquidity is less than LUNA’s actual market liquidity
This means that, given sufficient capital, it is relatively easy to manipulate USTs market capitalization below $1 (because market liquidity is low). Even if there is no attacker, a large number of people trying to log out of the system can cause this problem.
But this time, the on-chain market module can mint more LUNA than the external market can handle. Due to this oversupply, the value of LUNA quickly plummeted. If this situation continues, LUNA will continue to be minted until it loses All value, and as LUNA loses value, UST also loses any value to arbitrage against the arbitrage market module, entering a death spiral.
Simply put, there will be no arbitrage incentive to buy LUNA from the market because the changes on the chain will be less than the actual buying pressure off the chain, causing LUNA to be minted infinitely.
To prevent the second scenario, the Terra whitepaper originally defined a maximum cap on the LUNA supply - this was quietly removed sometime between Columbus-3 and Columbus-4, resulting in LUNA being minted infinitely during the Terra Crisis. Even if they dont lift the LUNA supply cap, a death spiral similar to the first scenario will ensue when UST supply is asked to shrink more than the supply cap allows.
Another change introduced shortly after the Columbus-4 upgrade was to redirect all UST/LUNA exchange transactions on the Terra Station frontend to Terraswap (and later Astroport). LUNA/UST exchange transactions on Terra Station will continue to burn LUNA to Get more UST.
While the actual functionality of Terra Core itself remains intact (i.e. manual interaction via the Terra LCD will still allow native UST to LUNA redemption), the end user effectively loses operational access to UST value shrinkage. Columbus-5 made another change to the market module allowing different exchange liquidity limits for UST to LUNA exchanges and LUNA to UST exchanges, but this was reinstated shortly thereafter.
Another important parameter of the Terra Market module that many people are unaware of is the oracle time delay. In 2019 alone, Terra experienced 1 oracle attack, leading the team to deploy patches on Terra oracles that largely improved oracle-based attacks at the expense of potential decoupling resiliency.
Initially, the Terra oracle only provided the current spot price of LUNA to the on-chain market module. This led to the attack - an attacker artificially created a large bid-ask spread for LUNA on South Korean cryptocurrency exchange Coinone, allowing the attacker to trade between TerraKRW (another Terra stablecoin pegged to the Korean won instead of the US dollar) and LUNA. Repeated on-chain exchanges, although with very small funds, allow more LUNA to be minted than initially.
The Terra team initially responded by temporarily deploying additional exchange liquidity to narrow spreads, then changed their oracle logic from spot prices to 15-minute moving averages. This doesnt stop the same attacker from performing another attack, another attack - its the same tactic, just forced to perform the same attack over a longer period of time (due to the additional 15 minutes of delay). So the Terra team responded again by changing the oracle logic to a 30-minute mid-price moving average of on-chain spot price data.
As the Medium article and report noted, this made sense at the time because LUNA had very low liquidity on exchanges.
However, this comes with a trade-off, and slower oracle price feeds will mean that arbitrage between on-chain and off-chain markets is also possible, which will quickly dilute the value of LUNA.
However, Terra didn’t seem to really delve into this oracle trade-off issue until Terra crashed, with the only parameter being an adjustment to the time delay between the spot price and the on-chain oracle.
The more liquid LUNA market raises additional issues not addressed in any of the companys previously published research: the implicit risk of oracle delays in highly liquid markets with higher trading volumes. Typically when a market becomes more liquid, volatility is assumed to be less because for an increasingly liquid market, more funds are required to make the same change in the spot price. However, this is not always the case - when markets become volatile in these environments, there can be significant capital flows.
In this case, oracle delays would be fatal if something went wrong, as the arbitrageurs described in the above scenario have room for massive capital outflows. This is exacerbated by the fact that UST liquidity on DeFi is restricted to StableSwap-like AMMs like Curve Finance, which does not exist in 2019, as the StableSwap Curve is designed to stay pegged as long as possible until it Quickly unhook.
As mentioned before, since Terra’s oracle is inherently delayed, it simply does not have enough time to cope with high volatility and high liquidity markets.
In summary, we believe that even as the Terra ecosystem continues to grow, without further research in this area, it is expected that Luna Foundation Guard (LFG) will improve by becoming another native module on the Terra blockchain that holds Bitcoin as collateral. Take over the job. In the process, it was speculated that the market makers would take over the job of maintaining the UST peg without fundamentally changing its underlying mechanics - unfortunately, before TFL and Jump Trading fully implemented their plans for the native LFG module, what happened to us Well-known attacks.
Mint Cash: Pick up where we left off
Mint Cash is a continuation of previous work on the Terra stablecoin system, patching its mechanism-level flaws and unlocking more use cases. This is a major redesign involving so many fundamental changes that it is closer to an over-collateralized stablecoin like DAI than an algorithmic system like UST. especially:
Make all stablecoins fully backed by Bitcoin collateral, inspired in part by Jump Trading’s original proposal for Luna Foundation Guard (LFG);
An organic synthetic exchange mechanism provided between Bitcoin collateral, Mint (equivalent to LUNA) and CASH (equivalent to UST);
Anchor becomes part of the stablecoin leverage rather than a money printing machine;
The first challenge of this redesign is to define a market where Bitcoin collateral can be synthetically exchanged for stablecoins and vice versa – similar to LUNA/UST. The Luna Foundation Guard (LFG) proposal proposes creating another market module and assigning virtual liquidity parameters that simulate governance settings for Bitcoin liquidity – similar to the existing market module between UST/LUNA.
One problem with this approach is that there will not be market liquidity between the stablecoin we create and the Bitcoin collateral at launch. When there is no market liquidity, synthetic market parameters may not be set as there is no reference market to determine these parameters.
To mitigate this, we use a new type of trading curve that essentially generates trading liquidity on demand. This will serve as an initial market generation bootstrapping mechanism as it can establish a market for any existing illiquid assets as long as there is demand for those in exchange for liquid assets.
There is also a trade-off in that this curve creates exponential implied volatility (i.e. exponentially increasing delta and linearly increasing gamma), so the goal is to have a hybrid market with both on-demand liquidity and a synthetic market curve (Similar to the original LFG proposal) phase it out.
This process is completely permission-free and requires no intervention from the project side. Anyone can exchange Bitcoin for MINT or CASH. Perhaps most importantly, new MINT or CASH cannot be minted without providing explicit Bitcoin collateral. This also means that no free airdrops or private sales of either token will be possible under this redesign.
The value of MINT represents how many corresponding assets in the Mint Cash system are explicitly collateralized by Bitcoin. This also means that an oracle attack similar to the above attack is also possible, but as an initial mitigation measure, the value of Bitcoin is used as the oracle reference, rather than directly obtaining the market value of MINT, which is likely to lack liquidity initially. sex.
This aims to alleviate some of the oracle issues mentioned above by introducing non-synthetic assets as collateral, thereby producing a linear correlation between price and oracles, rather than an exponential correlation.
In summary:
Anyone can mint MINT through the “mint 2” module by providing Bitcoin collateral;
Anyone can exchange MINT burns back to Bitcoin, minus any taxes or liquidity discounts;
MINT can be freely exchanged with the stable currency CASH through the market module;
This sounds fairly simple. There are four additional key mechanisms to ensure currency stability:
MINT staking module (bMINT) has a time limit for canceling staking;
Liquidation module;
Tax module (inherited from Terras original tax policy);
Anchor Sail itself;
MINT staking: better over-collateralization to power PoS
A major problem with overcollateralized stablecoins like DAI is the lack of incentives to provide and withdraw stablecoin supply. As Do Kwon pointed out in a previous Medium article:
DAI is the most widely used decentralized stablecoin on Ethereum, but it has serious problems with scaling due to a supply and demand mismatch in its monetary policy.
DAI is provided by users looking to gain leveraged exposure to ETH and ERC-20 assets;
Users wishing to obtain an on-chain USD-denominated store of value will need DAI;
This mismatch creates problems when the need for stability exceeds the need for leverage on Ethereum assets. The recent use of DAI in many DeFi protocols has resulted in a huge surge in demand for DAI (which does not match the demand for leverage), causing DAI to trade at a large premium to the US dollar, and the Maker Foundation taking emergency measures to try to restore the peg.
The scalability issues with DAI can also be extended to all other stablecoins on Ethereum, which cost more to mint than the face value of the minted asset. The money supply is limited by the market’s willingness to bear the cost of excess capital (such as the need for leverage), which is independent of the demand for stablecoins. In turn, barriers to DAI monetary policy limit DeFi growth and adoption.
Objectively speaking, his problem statement about DAI is very reasonable. Overcollateralization must rely on borrowed positions, which are essentially leveraged long exposures. Obviously, people prefer to look for stablecoins rather than going long ETH or other assets, which creates a supply and demand mismatch problem.
So, how do we solve this problem while ensuring that the system always remains collateralized? Our answer is actually to combine it with Proof of Stake (PoS) and liquidity staking.
Staking means actively taking financial risks and committing to network growth over the long term in exchange for stable transaction fees. This happens to align perfectly with those who want to provide collateral for stablecoins, who also actively take financial risks and work towards stability, while receiving some of the rewards generated by the system.
People either delegate MINT to validators or mint bMINT (Mints liquidity staking derivative), where they first bear the risk of undercollateralization while exclusively receiving ongoing transaction fees and taxes on stablecoin CASH or Anchor interest payment.
This makes staking MINT slightly different from standard PoS blockchains. First, in a liquidation event triggered by the protocol, MINT stakers are first affected by the average slash across the entire validator set (without the usual consequences of other security-related slash events). The protocol also sets a minimum staking rate globally, which is used as a factor in whether to invoke a protocol-wide force liquidation.
Unstaking may also be subject to a vesting period, meaning that MINT will be unstaking and released after a period of time, rather than immediately.
Collateral liquidation within the scope of the agreement
Another feature of the Mint Cash system is the protocol-wide liquidation module, which is present in most synthetic asset protocols. When the currently pledged MINT value is lower than the minimum mint pledge rate, liquidation will be triggered. The value is calculated as follows:
mint_staking_rate = staked_mint / (staked_mint + liquid_mint + (liquid_cash + acash_supply) * mint_oracle_price)
There is a protocol-wide parameter “LiquidationWeights” that determines how much consequential losses MINT stakers should face compared to liquid MINT in order to withstand currency contraction. This is required because:
The higher liquidation weight of staked MINT collateral will lead to significant bMINT decoupling, which will also lead to the liquidation of Anchor Protocol - which may exacerbate the possibility of a run on the protocol;
The lower liquidation weight of pledged MINT collateral will result in a higher impact of MINT on Bitcoin’s oracle price;
In liquidation auctions, both MINT and CASH are accepted. Among them, auction bids denominated in CASH have priority over auction bids denominated in MINT. Any assets received are immediately burned to bring the current MINT staking rate above the minimum staking threshold.
Liquidation events are subject to two additional fees:
Agreement liquidation fee: a fee levied by the agreement to control the withdrawal of funds;
Liquidation premium: paid to the liquidator as compensation for participating in the liquidation of the agreement;
cash tax
Mint Cash directly inherits Terra’s monetary policy, which taxes stablecoin-denominated transactions in addition to standard transaction fees. There are two reasons for this:
No risk incentive for inflation: Unlike most PoS assets, inflation does not exist under the Mint Cash system because all assets minted must be directly backed by Bitcoin. This is particularly important as MINT stakers also bear additional collateral risk than liquid MINT holders – requiring additional incentives;
Economic Leverage of Monetary Tightness: Typically, higher tax rates are associated with monetary tightening and vice versa, similar to interest rate factors. When monetary tightening is required, in addition to standard liquidation procedures, these monetary levers should be adjusted faster than standard governance recommendations (if required), which is relatively true as the Mint Cash system has a direct correlation between tax rates and interest rates. Insignificant;
Anchor interest rate as part of Mint Cash monetary policy
Under modern economic theory, local currency interest rates play a key role in monetary policy and stability. Anchor’s 20% interest rate is crucial to Terra’s huge success – claiming to be the “benchmark interest rate for all DeFi.” DAI has a similar concept called the DAI Savings Rate, which also incentivizes staking DAI holders to earn some interest while contributing to the stability of the protocol.
It is worth mentioning that higher foreign currency interest rates are always associated with higher leverage costs (i.e., reduced liquidity in the domestic market), higher inflation rates (i.e., currency depreciation in the foreign exchange market), or both Related. At the same time, lower interest rates are generally thought to lead to net capital outflows.
With this in mind, we can establish a safety buffer rate between the interest rates offered by the on-chain anchor currency and real-world rates, where the difference in interest rates is sufficient to prevent large-scale capital outflows without resulting in higher effective borrowing interest rate. This buffer rate can be funded by:
The income provided by external liquidity pledged derivatives includes pledged ETH, pledged SOL, pledged ATOM, etc.;
Any efficiency gains achieved by automating the lending process through smart contracts rather than through banks, thereby requiring smaller interest margins;
An external LST (such as Lido or EigenLayer) can also be used to represent underlying unpledged assets as long as it has a sufficient risk hedging strategy or is known to be resilient to potential haircut events to maintain a constant known rate relative to its underlying asset. Leveraged positions. Hedging positions can also be used to combine multiple asset positions and reduce risk while increasing return exposure. This should help incentivize borrowing on the protocol rather than just relying on market makers or artificial token incentives.
As mentioned before, stablecoin CASH deposited into Anchor is not taxable. However its interest is automatically taxed and is either burned or transferred to a vault to reward MINT stakers. Since this corresponds to synthetic M1 supply, while base cash corresponds to M0, exporting CASH to other blockchains may focus on aCash (anchored deposited cash) rather than base CASH to simplify tax calculations.
Anchor Sail is our new version of Anchor that also features non-USD denominated deposits. This is achieved through a new synthetic FX lending module that allows users to borrow CASH into another stablecoin pegged to a currency they are familiar with, such as CashEUR or CashKRW. Since CASH can be minted as long as Bitcoin has liquidity against the base currency, this greatly improves reach for users who wish to continue using non-USD currencies - one of the first feature requirements of the original Anchor.
Why not build on Terra Classic?
A common question we receive from the Terra/LUNA Classic community is: Why dont we build on Terra Classic to rebuild UST?
We need to start from a clean state for several reasons:
Fundamental Redesign – In principle, Mint Cash is a fundamental redesign, albeit still based on similar ideas, concepts, and blockchain code that once powered the old Terra stablecoin protocol. While we could fork existing Terra Classic and start from there, some of the damage that hyperinflation has done may be irreversible;
Unfixed Flaws – As mentioned above, one of the reasons for this complete redesign is because the old Terra stablecoin protocol had fundamental flaws that had not been fixed for years. Regardless, this would require a significant rewrite of the core stablecoin protocol itself. Such an effort is beyond the scope of a single team working on an existing blockchain, but would require a level of funding, support, and infrastructure from new companies and projects;
Centralized Infrastructure - Certain infrastructure, such as LCD (light client daemon) and block explorers, are slowly becoming independent from Terraform Labs, thanks to the work of the Terra Classic community. However, a large portion of the Terra stablecoin protocol and its core DeFi legos (like Anchor) were designed to be operated by centralized entities rather than for fully decentralized ownership transfers. This includes the WLUNA contract on Ethereum (originally designed as part of the now-decommissioned Shuttle Bridge as part of Mirror, which did not provide appropriate design choices for decentralized asset migration on the Ethereum blockchain), Anchor/Mirror Ownership of CosmWasm contracts with other TFL-built protocols, as well as the operational infrastructure associated with these smart contracts (such as commands on Anchor that are manually called by the contract administrator for each Epoch);
Asset Allocation and Curbing Inflation – Following the collapse of the Terra stablecoin, severe inflation resulted in many entities disadvantageous to the average LUNA holder owning large amounts of these now-near-worthless tokens. Asset distribution on the Terra blockchain is already very centralized between TFLs, VCs, exchanges, market makers, and large validators. All in all, it will be very difficult to fix all of these issues without a reboot, as even a full chain rewrite would result in these actors still owning a large amount of supply;
However, we also sincerely want to help the Terra Classic community recover from at least some of the significant losses caused by the devastating collapse of the Terra stablecoin system. That’s why we decided to introduce a “Burndrop” program, where only those interested in this new ecosystem we intend to build will be rewarded, while those who are not interested can still benefit from burned tokens and reduced supply.
Burndrop: Airdrop distribution plan for burning USTC
The Burndrop program will distribute a basket of tokens that will be released when Mint Cash launches. This will include the following two assets (more tokens may be included as the situation develops and we continue to build the Burndrop program for eventual distribution):
oppaMINT (OPtion Per Annum MINT): A special call option token that allows its holders to mint new bMINT at a high discount rate (50% +) at the current spot price of the option execution, the specific discount rate will be To be announced closer to the release date;
ANC: Anchor Sail’s governance token;
oppaMINT will significantly lower the barrier to entry for previous and current Terra Classic token holders. The more USTC these token holders burn, the more oppaMINT will be allocated. Tokens that have been issued after launch will also be freely transferable. So if the user doesnt want them, they can always sell them.
oppaMINT will also be made available to VCs to enable project financing, as the Mint Cash system cannot mint new MINT or CASH tokens without clear Bitcoin collateral.
ANC is similar to previous ANC tokens in that stakers continuously receive buybacks funded by Anchor yields while also compensating borrowers. The difference is that:
ANC will be directly responsible for certain aspects of native Mint Cash protocol governance, and MINT staking will always be subject to a fixed vesting period. While there are far more changes to the ANC token economics than described, more details will be revealed closer to the launch date.
Conclusion
We cover a lot of details in this article. All in all, we take building this right very seriously and are committed to realizing the potential that the original Terra protocol was able to realize but never saw the light of day - including its diverse stablecoin system, liquid markets tied to Bitcoin, and the acceptance of all The protocol building blocks of the CashUSD stablecoin, including Anchor Sail itself.