Blockchain and Decentralized Finance:
The 2024-25 Intro Lecture
Presenter: Andreas Park
What is a Blockchain?
What is a Cryptocurrency?
Conceptually, what is a blockchain?
payments
stocks, bonds, and options
swaps, CDS, MBS, CDOs
insurance contracts
payments
stocks, bonds, and options
swaps, CDS, MBS, CDOs
insurance contracts
\(\approx\) 50% is bitcoin (but used to be 70%)
Smart contract accounts
Externally owned accounts
controlled by private keys
private
key
public
key
seed phrase
public
address
wallet = software to keep and use private keys
Decentralized Trading
payments network
Stock Exchange
Clearing House
custodian
custodian
beneficial ownership record
seller
buyer
Broker
Broker
Source of savings:
Possible transaction cost savings when applied to equity trading: \(\approx\) 30%
Source: "Learning from DeFi: Would Automated Market Makers Improve Equity Trading?" working paper, Malinova & Park 2023
Pool-based lending principles
borrow
provide collateral
Application: Pool-based borrowing and lending
Obvious Smart Contract Application: Automate Investment Strategies
idea: create new mutual fund like asset
"yield aggregator:" push capital where rate of return is highest
Flash Loans
5. repay DAI
for loan
with health factor <1
liquidation
opportunity
1. flash-borrow DAI
2. repay loan
with DAI
3. claim
collateral ETH
4. convert ETH to DAI
What roles do tokens play?
What roles do tokens play?
recall the differences
\(\to\) key feature: no necessary intermediaries
Problems:
lesser problem because
Common solution: create a reward token! Here's how this works
Step 4: users receive a reward token based on the time that they lock up the "receipt" token
Step 3: users lock up the "receipt" token in a smart contract
Step 2: users contribute liquidity and get a "receipt" token
Step 1: create reward tokens and deposit into a smart contract
borrow
provide collateral
Application: Pool-based borrowing and lending
Same problems as with trading:
But: in contrast to trading, here you need both!
liquidity \(\nearrow\)
volume \(\nearrow\)
protocol fees \(\nearrow\)
token value \(\nearrow\)
Platform economics is tricky:
Without intermediaries:
platform economics!
incentives for both?
Asset Tokenization or
"The Creation of Asset-Linked Tokens"
Tokenization is coming
What is a stablecoin?
digital representation of a unit of a fiat currency on a blockchain
pulled from Nick Carter's talk on "Will stablecoins serve or subvert U.S. interests?"
Collateral Backed Stablecoins: USDT & USDC
\(\Rightarrow\) 5% over-collateralized
primary market acces: 6 entities only
Collateral Backed Stablecoins: USDT & USDC
primary market acces: 560+ entities
What makes a Stablecoin stable?
USD-USDT (6 months)
\(\Rightarrow\) need a primary/reference market mechanism to allow for forces of arbitrage to align prices
Stablecoin use cases
What do central bankers think about stablecoins?
BIS Survey of Central Banks:
Source: On-chain Foreign Exchange and Cross-border Payments by Austin Adams, Mary-Catherine Lader, Gordon Liao, David Puth, Xin Wan (2023) [team from UniSwap Labs]
DeFi fees:
Challenges
Source: Cambridge Bitcoin Energy Consumption Index https://cbeci.org/
Challenge 1: Energy Consumption
Ethereum Challenge 1: Environment
problem solved
| transactions per second | T per 12 hours (business day) | |
|---|---|---|
| Bitcoin | 7 | 302,400 |
| Ethereum | 30 | 1,296,000 |
| Algorand | 2000 | 86,400,000 |
| Conflux | 4000 | 172,800,000 |
| Athereum | 5000 | 216,000,000 |
| Payments Canada ACSS | 648 | 28,000,000 |
| US retail | 7639 | 330,000,000 |
| Canada number of equity trades | 46 | 2,000,000 |
| Orders on Canadian equity markets | 3588 | 155,000,000 |
Tweaks: lighting network (BTC) or side chains, SegWit, blocksize possible, but there are limits
microtransactions, IoT, and other smart contract use cases place very high demands
Ethereum Challenge 2: Throughput
Ethereum Challenge 2: Throughput
Source: Etherscan w re-scaling
Ethereum Throughput Solution: L2s/Rollups
Ethereum Challenge 3: State Size
Source: Ycharts
Money Laundering and Crime
What's special about crypto-crime?
extra info:
Central Bank-Issued Digital Currencies
Evolution
2008
2014/5
2019
2020
The Year is 2008: what the Toronto a la cart program teaches us about CBDCs
Cautionary tales for central bank innovation
what people want
what we got
Features of Digital Money
fast money
CBDC run by
Central Bank
CBDC on new communually run system
bank-issued stablecoin on public blockchain
|
What? |
||||
|---|---|---|---|---|
| 24/7 instantaneous | ||||
| borderless | ||||
| programmable | ||||
| privacy | ||||
| p2p | ||||
| no commercial 3rd party | ||||
| nominal fee |
Final Thoughts
Some Final Thoughts
@financeUTM
andreas.park@rotman.utoronto.ca
slides.com/ap248
sites.google.com/site/parkandreas/
youtube.com/user/andreaspark2812/
Why are Blockchains challenging for current regulation?
UniSwap Lab supports development
a website app accesses the code
token holders control contact features
don't own the code
operation = decentral
control = decentral
anyone can use the baseline code
core code runs on the blockchain
tokens used as rewards
Illustration of the Challenges: The UniSwap Token
Questions around Regulation & Compliance
present vs future
Challenge 1: How do you get data onto a blockchain?
The Oracle Problem
<standings: 7,3,8,4,2,1,6,5> + digital signatures
Disagreement?
Majority Vote
1 ETH = $4780
1 ETH = $4789
1 ETH = $4781
DEXes can be used as on-chain price oracles
Time-Weighted Average Price (TWAP)
The Oracle Problem
Oracle nodes form their own ecosystem
staked LINK can be slashed
Chainlink
Same follow-on challenge for builders: how can you fit staking, rewards, and inevitable speculation into securities law?
Challenge 2: the settlement layer has a mind of its own
a
b
c
d
e
f
g
Problem: Public Mempools allow Sandwich (MEV) Attacks
A brief look under the hood: the workflow
liquidity pool
blockchain
user
website
router
liquidity pool
blockchain
user
A brief look under the hood: the workflow
aggregator protocol
router
pool 1
blockchain
user
pool 2
multiple
pools
A brief look under the hood: the workflow
back to UniSwap
pool 1
blockchain
user
pool 2
A brief look under the hood: the workflow
back to UniSwap
pool 1
blockchain
user
pool 2
just-in-time
liquidity bots
A brief look under the hood: the workflow
back to UniSwap
pool 1
blockchain
user
pool 2
just-in-time
liquidity bots
in the settlement layer ("MEV")