Notes
The notes explain the economics and the theory behind each topic. Each chapter is available in HTML and as a PDF for printing. The notebooks contain the code for the same topics.
Building with AI
How These Notes Are Built Repositories, Quarto and AI coding agents, and why checking what the agent produces is the part of the work that matters.
Neural Networks and Language Models
From Regression to Neural Networks Regression as minimizing a loss, gradient descent, what a neural network adds, overfitting, and why models are judged on data they were not trained on.
Neural Networks and Option Pricing The Black-Scholes model as a benchmark, learning option prices from data, and what a network can and cannot learn from one day of prices.
Language Models in Finance Text as data, embeddings, how language models are trained, and where they fail.
Blockchain
Hashing and Proof of Work Hash functions, blocks and chains, mining as a search, and why changing the past is expensive.
Proof of Stake Staking, validators and slashing, finality, and the cost of security under proof of stake and proof of work.
Decentralized Finance
Automated Market Makers Constant-product pricing, slippage, arbitrage, and what liquidity providers earn and lose.
Lending Protocols and Liquidations Overcollateralized loans, health factors, liquidations and their bonuses, and the oracles that feed prices to the protocol.
Stablecoins Reserve-backed and algorithmic designs, why a stablecoin can trade below one dollar, runs, and the GENIUS Act.