What's this Rebase thing?
There's a lot of chatter around Ampleforth and the new mechanism its' introduced known as supply smoothing.
This is triggered daily by the Rebase function. Anyone can invoke Rebase; There's even a fun button on the AMPL dashboard where you can try to be the first to successfully activate it. Only one can succeed a day though. For everyone else, its Out Of Gas!
When Rebase is invoked, it applies the current supply smoothing implementation. This is a policy which can be updated. We've seen examples of policy changes in the past, such as a decrease to the rebase lag (covered later), and adjustment to the time rebases occur in order to better align with oracles.
Supply smoothing is intended to reflect changes in demand of Amples. It seeks to create a synthetic commodity money with absolute scarcity, yet a manageable supply.
Sounds crazy, but because AMPLs are able to expand and contract the supply by applying changes proportionally to all holders, the scarce ownership of the network can be maintained. After a rebase, all holders own the same share of the network they did before the rebase. The network is simply divided into a new number of shares.
As market cap increases, it will be easier to confidently price assets in Amples.
Supply smoothing also creates neat intersections with other DeFi use cases to provide the first volatility dampened asset strategies without relying on collateralized positions or banks.
This has some pretty intriguing implications we'll get into...
But First, How?
The Rebase function requires a transaction to trigger it. If this transaction is not submitted then it will not occur.
It must be triggered during the configured Rebase Window (15 min), to ensure it is not triggered outside of the expected time range. It also requires that the Minimum Rebase Interval (1 day) has passed to ensure no reentrancy.
First it gets an Exchange Rate from the Market Oracle (covered later), and confirms the rate is valid.
Then it computes the Supply Delta with the below formula:
supplyDelta = totalSupply * (exchangeRate - targetRate) / targetRate
- Ex: 1000 = 1000 * (2 - 1 ) / 1 or if the price is double the target, then the supply needs to be increased by 100% to reflect demand at the target price.
But correcting the price fully every night can be intense on the market. In order to dampen the impact, and avoid overcorrection, there is a Lag applied to the Supply Delta
supplyDelta = supplyDelta / rebaseLag
The Rebase Lag is currently set to 10 so that the price is corrected 10% of whats needed to hit the Target Price once a day. The greater the lag, the longer it is expected to take to return to the target price.
The Supply Delta up until this point is governed by the Supply Smoothing Implementation. It is then passed into the token contract, where the the Supply Delta is applied across all holders proportionally by a process which can cause slight deviations in the Supply Delta guaranteed to sum to less than 1. A new Total Supply is then calculated from the fragments.
Due to this mechanism the supply of Amples contracts or expands daily unless the Exchange rate falls within the Expansion or Contraction Thresholds (atm 0.97 - 1.06). These thresholds provide a small window of flexibility in the supply around the target price.
Don't wan't to micro manage ya' know.
(Modeling July 18th Rebase on a holder with 10,000 AMPL)
So, what about these Market Oracles?
Ampleforth relies on Chainlink to provide data about the Exchange rate of Amples, as well as the Consumer Price Index (CPI) for the 2019 dollar.
The CPI rate is used as the target rate, allowing Amples to adjust to inflation and is sourced from the Bureau of Economic Analysis.
The AMPL/USD Exchange Rate is composed of a volume weighted average price (VWAP) from these aggregators:
- AnyBlockAnalytics (unsure if started supplying yet)
- CyptoAPIs (unsure if started supplying yet)
Each supplied by independent node operators, with multiple price feeds being reported from each node. These price feeds currently cover Bitfinex, Kucoin, Uniswap, and Bancor markets.
This Market Oracles section was mostly a summation of this very handy article.
Why Rebase at 02:00 UTC?
Most data providers aggregate 24hr average prices from midnight-to-midnight. By aligning our operations to this same schedule, we increase the number of aggregators that can be utilized by our oracle system. - policy change example
On to the Juicy Bits
What does this mean to me as a ...
Once a day the number of tokens you own are subject to change. The new number of tokens you own will reflect the same share of market cap you held before the rebase. You are exposed to changes in market cap, as you would be in any other non stabilized asset.
Eventually holders will benefit from increased stability in the price of Amples while maintaining exposure to its volatility.
Order Book Trader
While subject to the same ramifications as a holder, the rebase has a unique affect on order books. Rebases causes bids to go stale, no longer reflecting the supply(@ 02:00 UTC).
This exposes bidders to the loosing side of arbitrage if not properly managed. If not participating in arbitrage around the rebase, I suggest closing bids before it occurs, or including sufficient padding anticipating the supply change.
Automated Market Maker
Things start to get wonky right around here. AMMs are better suited to adapt to rebases, and adjust their pricing according to their relative supplies of assets. This makes them a great source of liquidity for the market and attracts impressive fee generating activity.
However this also exposes Liquidity Providers to changing supplies of Amples, and thus disproportional rebases.
- If Amples are overbought, and the pool has excessive supply, then the pool faces a stronger rebase.
- If Amples are oversold, and the pool has reduced supply, then the pool faces a dampened rebase.
I interpret this to mean providing liquidity is greater exposure to volatility in downward trending markets, and lower exposure to volatility in upward trending markets.
Another interesting feature is that impermanent loss mechanics are altered. Liquidity Providers have optimal gains when the price ratio returns to the ratio they supplied. AMMs are a bet on a stable price and are optimized for that bet. For most tokens this implies returning to the same Market Cap ratio, but not for Ampleforth.
Liquidity Providers are able to absorb more Market Cap changes due to rebases returning the pool to earlier price ratios. The Market Cap changes reflected in rebased supply are distributed proportionally across holders, kinda like a rebase!
Like Market Makers, Lenders are disproportionately affected by rebases. However Lenders are always in a position of holding less assets than they own. To be owed 1 Ample is to lose exposure to that Ample's rebases. This means Ample lenders are always faced with a dampened rebase proportional to the amount of assets utilized by borrowers.
The best way to avoid Ample volatility is to lend it.
Borrower with Ample Collateral
Unless Collateral pools are mixed with lending pools, collateral should act like any other asset so long as the smart contract governing holdings is able to handle the change in supply. This hinges on there being an adequate source of liquidity to adapt the market rate to supply changes. Without an efficient market, Ample can be a dangerous collateral.
If Collateral is pooled with lending supply such as in Compound Finance, then the Collateral Ample's volatility is dampened in proportion to the share of the pool lent out.
I wonder if this dampening affect will also dampen borrow rates?
(Ample collateral is a subject of hot debate. Many disagree with me that it can be used like other assets in a pure collateral form. Over the coming weeks looking forward to seeing more discussions across DeFi around how it can be integrated)
Borrower of Ample
You gain exposure to the rebases, and don't have to pay any of them back. Owing one Ample is owing one Ample. This makes borrowing AMPL the only asset where Borrowing is equivalent to longing it.