What is @TimeswapLabs and does it create an oracle-free permissionless lending protocol?
A ๐งต providing all you need to know about @TimeswapLabs (incl. 3 variable AMM, Timeswap V2 basics and my thoughts)
(AIP-8)
Diving in! (1/29)
"๐ฃ๏ธ There's a lot of existing money markets out there!"
But do they provide permissionless listing?
"๐ฃ๏ธ @eulerfinance@RariCapital does"
Okay, do they work without an oracle or liquidators?
"๐ฃ๏ธ yo uh hmm"
Here's how ๐.
Read their docs.
Their docs and visualizations are one of the easiest to understand in the market tbh.
But I know y'all still gonna be too lazy.
So here's my oversimplified overview.
The 3 variable AMM.
Inspired by Uniswap's 2 variable AMM (X*Y=K; CFMM), rates in Timeswap are calculated by 3 variables.
X*Y*Z=K
Simply:
X - assets available to be lent out
Y - total (pool's) interest rate per second
Z - total (pool's) collateral needed
K - a constant
What's A and C?
X, Y and Z are all virtual pools. Assets are not locked here, you can think of them as "counters" to be used for calculations.
A and C are where the assets are actually locked in.
A - deposited asset (to be lent) + repaid debt
C - collaterals (from borrowers)
What calculations?
From the previous diagram, there are two key calculations.
(Y/X) - max interest rate per unit borrowed asset
(Z/X) - minimum collateral ratio
As a result, Timeswap allows an interest rate and collateral ratio that responds to market demand for borrowing.
Remember, X*Y*Z = K.
When more people lend, X increases. Thus, the value (Y*Z) must decrease.
Vice versa, when more people borrow, X decreases. The value (Y*Z) increases.
"When the demand of borrowing increases, interest and/or collateral ratio increases."
Ta da, a money market that responds to supply/demand.
Akin to utilization ratios of typical DeFi money markets.
Oh wait, Timeswap only offers fixed-maturity (specified expiry date) lending/borrowing.
Why? See below.
Non-liquidatable loans.
What? How do they guarantee people to pay back their loans then?
Simple.
Due to the fixed-maturity, late payments are fully considered a default.
Locked collateral is taken and distributed (more below) to lenders.
Default case.
By rationality, borrowers will only default when their locked collateral is worth less than value borrowed on expiry.
Defaults can only happen upon expiry, none pre-expiry.
Similar OTM call options, they would just let it expire.
Native tokens.
Comparable to @AaveAave 's AToken and DebtToken.
Simply, they represent (share of pool) rights to claim:
BPT - assets lent
BIT - interest owed upon maturity
IPT - 'lost' assets in a default case
IIT - 'lost' interest in a default case
LT - supplied liquidity
CDT (ERC721) - stores info. about debt issued and collateral stored
IPT and IIT holders claim their 'lost' assets/interests from the collateral. Only activated when there is a default in BPT and BIT.
i.e., upon default, locked collateral is distributed b/w IPT & IIT holders.
Customizable.
As you lend/borrow assets, you could select the parameters (interest rate and collateral ratio; Y and Z) that best fits your risk profile.
Though this will be depreciated in Timeswap V2 due to lack of use.
Distribution.
The higher the collateral ratio you lend in, the more IPT and IIT you get.
i.e., if you select to lend with a higher collateral ratio (lower interest rate; lower risk profile), you will be given "higher" insurance (more protected).
To thicken liquidity, we need LPs.
LPs borrow and lend at the same time.
They are last in line to claim assets (i.e., junior tranche).
They can earn/lose based on the spread b/w (borrow & lending interest rates) and/or (total lent & borrowed)
i.e., divergence spread.
(cont.)
(cont.)
"If the total value borrowed by borrowers exceed the total value provided by lenders (excl. LPs), the interest goes purely to LPs."
For their risk exposure, they are additionally rewarded with a 1.25% (of @TimeswapLabs 1.5%'s) fee from both borrowers and lenders.
Arbitrageurs.
Arbitrageurs are incentivized to normalize interest rates and collateral ratios between pools (internally) and between protocols (externally).
Thus making market rates on par.
Permissionless.
Anyone is allowed to setup a lending/borrowing pool b/w 2 ERC20 tokens.
Though this functionality (for now) can only be accessed via Polygonscan.
Timeswap V2.
Significant quality of life improvements.
1. Lenders can exit pool prematurely (for a fee)
2. Repaid debt can be re-loaned out and no longer incur interests
3. Bidirectional pools, lend and borrow both tokens in a single pool
(cont.)
(cont.)
4. Native tokens from ERC20/721 into ERC1155
5. Removal of customizable interest rate / collateral ratio for lenders (default is max interest rate for both sides, safer for collateral ratio)
Timeswap V2 dedicated post coming!
More details:
medium.com/timeswap/introducing-timeswap-v2-9ac962c048e6
Now that you're amazed by how intuitive @TimeswapLabs is.
Here's some of my thoughts and updates:
1) An option, not a replacement
2) What investors care
3) Cross-chain
4) @3xcalibur69 adoption
1) An option, not a replacement
More time and volume is needed to test out their model.
But for now, all I can say is, innovation is good.
In fact, they're building to coexist with existing protocols, as they rely on arbitrageurs.
2) What investors care
Their V2 is one of the best things to prove to an investor.
Literally.
"Here's what we did, what we've learnt, what we're gonna do to improve our product"
Sadly, no tokens confirmed yet.
3) V2 launch and cross-chain
V2 is expected to go live on Polygon in December 2022.
With plans to expand to Arbitrum, Ethereum and Optimism.
4) @3xcalibur69 adoption
3xcalibur is a combination of @solidlyexchange (swaps) and @TimeswapLabs V1 (lending/borrowing), currently live on @arbitrum.
Their lending market is still not open tho.
"Imitation is the highest form of flattery"