DeFi Lending and Borrowing
Instructors: Andreas Park
2021
MakerDAO
4 ETH
(1 ETH = $375)
(Oct 15, 2020)
\(\approx\) $1,500
\(\vdots\)
1,500 DAI
(1 DAI = $1)
formally: this smart contract is a collateralized debt position (CDP)
borrowing/lending
on-chain ability to exchange arbitrary value
(last class)
Idea:
Sidebar: what is a DAO?
fractional collateral \(\to\) collateralization factor \(=\) 150%
total collateral = $1,500
maximum loan = $1000
overcollateralization = $500
actual loan (example) = $500
buffer = $500
ETH \(\nearrow\) $500
value of ETH collateral = $2,000
maximum loan = $2,000/150%=$1,333
total collateral = $2,000
maximum loan = $1,333
overcollateralization = $667
actual loan (example) = $500
buffer = $500
overcollateralization = $667
new loan capacity= $333
ETH \(\searrow\) $187.5
value of ETH collateral = $750
maximum loan = $750/150%=$500
total collateral = $750
maximum loan = $500
overcollateralization = $250
actual loan (example) = $500
buffer = $0
for reference: former value of collateral
ETH \(\searrow\) $150
value of ETH collateral = $600
maximum loan = $600/150%=$400
total collateral = $600
maximum loan = $400
required overcollateralization = $200
actual loan (example) = $500
buffer = -$100
for reference: former value of collateral
\(\Rightarrow\) triggering of liquidation auction by "keeper"
sell 3.33 ETH=$500=500 DAI
repay $500=500 DAI loan
retain incentive
return remainding ETH to vault owner
\(\Rightarrow\) all relies on behavioral assumptions
\(\Rightarrow\) But: there are also real incentives & mechanisms
borrowers of DAI need to pay interest \(\to\) stability fee
DSR paid on "locked" DAI
total amount of debt (or DAI) outstanding is limited
Sidebar: how is this decided?
\(\to\) special "governance" token MKR
Source: daistats.com (Oct 27, 2021)
Source: daistats.com (Oct 26, 2022)
The Problem:
The Solution:
Note: In May 2021, ETH prices dropped again by >30% but no drama in DAI
Interest rates influenced by the FED, access to loan products controlled by regulation and institutional policies
MakerDAO platform is openly controlled by the MKR holders.
Difficulty of obtaining loans for large majority of population
Open ability to take out DAI liquidity against an overcollateralized position in any supported ERC20 token. Access to a competitive USD denominated return in DSR.
Costs of time and money to acquire a loan
Instant liquidity with minimal transaction costs.
Can't seamlessly use the same USD across many platforms
Issuance of DAI, a permissionless USD-tracking stablecoin backed by cryptocurrency. DAI can be used in any smart contract or DeFi application.
interoperability
inefficiency
centralized control
limited access
opacity
Unclear collateralization of lending institutions.
Transparent collateralization ratios of vaults visible to entire ecosystem
legacy finance
MakerDAO
Pool-based lending principles
Example 1
Example 2
Example 3
borrowing and lending rates compounded per block
Token Accounting:
tracking ownership
Compound
AAVE
Token Accounting: TWO Types
Fundamentally, what does a bank do?
And how is this done?
on blockchain
100%
fraction of supplied that's been borrowed
base rate
borrow rate
In Compound
translated
new deposit
1,000 DAI
100 cDAI
500 DAI
add 50 new cDAI
In Compound
translated
new deposit
1,000 DAI
150 cDAI
500 DAI
1 year later: 10% interest on compound
150 DAI
(same cDAI, ownership shares don't change, just each cDAI is worth more)
(accrues per block per deposit)
AAVE
Liquidity Mining
Yield Aggregators
Flash Loans
common theme in DeFi: jumping between dApps
Source: Harvey, Ramachandran, and Santoro (2020)
1. flash-borrow DAI
5. repay DAI
3. receive ETH
4. convert ETH to DAI
2. liquidate ETH loan with DAI
Loan liquidation opportunity
Commercial Paper/T-Bill like securities
1 ETH = 150 DAI
collateralization ratio 125%
seller
buyer
supplies 1 ETH collateral today
mints (=borrows) 100 yDAI to be repaid in 1 year
y
receives 92 DAI today
pays 92 DAI today
y
receives 100 yDAI
repays loan with 100 DAI
deposits yDAI and receives 100 DAI
seller
buyer
Scenario 1: ETH \(\ge\)125 DAI
deposits 100 yDAI
withdraws 100 DAI
receives balance of 1 ETH - 100 DAI
What does the seller own (ignore keeper fee)?
seller
buyer
Scenario 2: ETH falls to <125 DAI
keeper
closes undercollateralized position \(\to\) sells 0.8 ETH for 100 DAI
receives 100 DAI early
receives balance
of 0.2 ETH
disclaimer: an incomplete list
Bitcoin,
stablecoins, etc.
"higher layer"
lending
payments processing
financial
advice
trading
services
funding
services
prop trading to manage risks
too early, but projects are underway
as it turns out, these items are often directly related
interoperability
inefficiency
centralized control
limited access
opacity
interchange (=VISA) fees, settlement times, microtransactions, physical infrastructure
between-institution or transfers, reconciliation process, international remittances, various securities custody and trading systems
information for users, health of deposit taker, what-happens-behind-the-scenes, counterparty risk
local monopolies/switching costs, central banking, deposit concentration, control vs. competition
1.7B unbanked in the world, 24M in the US, many services or products not available based on location etc, lack of SME support, inability to collateralize
Source: Wendy Rotenberg's Payments lecture
CDS
ACSS
LVTS
Cheques
Debit at POS
e-transfer
Credit Card/
open loop
ATMs
Wire
Interac
Credit
Card
deposit based retail
Interac standard
credit card network
SWIFT
CSN
Settlement
Clearing process
Underlying network
Type of payment
Financial market infrastructure purpose
Securities Trading
e-transfer
Wire
deposit based retail
CDS
Securities Trading
derivatives
swaps
property registry
interoperability
inefficiency
centralized control
limited access
opacity
siloed legacy system
is interoperable by design
reduces frictions and separates service from "commodity"
decentralized control and common operation
fewer barriers\(\to\) broad access
is/can be highly transparent
common infrastructure system
interoperability
inefficiency
centralized control
limited access
opacity
payments
lending
trading
services
funding
services
prop trading
manage risks
@financeUTM
andreas.park@rotman.utoronto.ca
slides.com/ap248
sites.google.com/site/parkandreas/
youtube.com/user/andreaspark2812/