Lessons
919 lessons · page 15 of 39
- AIadvanced
The Mathematics of Discrete Diffusion
The formal machinery under masked text generation: categorical transition matrices, the kernel choices that were tried and discarded, the variational bound, and the two parameterizations that made the objective trainable at scale.
9 steps·~14 min - AIadvanced
Causal Interventions, Steering, and What Remains Open
Turning interpretability stories into tested claims: activation patching, model editing, steering vectors, the attribution graphs that trace circuits in production models, and the problems the field has not solved.
10 steps·~15 min - AIadvanced
Sparse Autoencoders and Dictionary Learning
How an unsupervised model trained on activations pulls features back out of superposition, what it found when scaled to a production language model, and where the method still breaks down.
9 steps·~14 min - AIadvanced
Circuits: Reverse-Engineering Transformer Algorithms
How attention heads read and write to a shared residual stream, how they compose into circuits, and the two best-understood examples: the induction head behind in-context learning and the indirect object identification circuit in GPT-2.
9 steps·~14 min - AIadvanced
Features, Directions, and Superposition
Why individual neurons are the wrong unit for understanding a neural network, and what the superposition hypothesis says is really going on inside the activations.
10 steps·~15 min - AIadvanced
Beyond Greedy: Minimization, Non-Monotone, and Richer Constraints
The monotone, cardinality-constrained case is only the entrance. This lesson maps the rest: why submodular minimization is easy while maximization is hard, how to maximize non-monotone functions, what to do under matroid and knapsack constraints, and where submodularity keeps appearing across machine learning.
8 steps·~12 min - AIadvanced
Submodularity in the Wild: Sensors, Influence, and Summaries
The theory pays off because so many real problems are submodular in disguise. This lesson works through the landmark applications: near-optimal sensor placement, influence maximization in social networks, and document summarization, each reduced to monotone submodular maximization and solved by the greedy algorithm.
8 steps·~12 min - AIadvanced
The Greedy Algorithm and Its 63% Guarantee
Maximizing a submodular function is NP-hard, yet the simplest possible algorithm gets provably close to optimal. This lesson presents the greedy algorithm, the celebrated (1 - 1/e) guarantee of Nemhauser, Wolsey, and Fisher, why that bound cannot be beaten, and the lazy trick that makes greedy fast at scale.
8 steps·~12 min - AIadvanced
Submodularity: The Mathematics of Diminishing Returns
Many selection problems share one property: each new item helps less than the last. Formalized, that property is submodularity, and it is what makes otherwise intractable problems solvable with guarantees. This lesson defines it precisely, shows the everyday examples, and explains why it is called the discrete analog of convexity.
8 steps·~12 min - AIadvanced
What Neural Language Models Can Actually Compute
The same hierarchy that classifies grammars can classify neural networks. This lesson places recurrent networks and transformers on the Chomsky ladder, explains why a transformer is theoretically weaker than it looks, and shows how formal language theory predicts where today's language models generalize and where they break.
8 steps·~12 min - AIadvanced
Morphology and Finite-State Methods
Words have internal structure, and modelling it is computational linguistics' cleanest success. This lesson covers morphemes and the ways languages build words, why the finite-state machines at the bottom of the hierarchy are enough, and how finite-state transducers analyze and generate word forms, up to the modern neural shared tasks.
9 steps·~14 min - AIadvanced
Formal Grammars and the Chomsky Hierarchy
How much computational power does a language need? The Chomsky hierarchy answers it with four nested classes of grammar. This lesson builds the ladder from regular to recursively enumerable, shows the machine that recognizes each rung, and locates human language on it using the classic proof that it is not context-free.
9 steps·~14 min - AIadvanced
The Science of Language, Computationally
Computational linguistics treats human language as something to be modelled precisely, and language fights back at every level. This lesson maps the levels of linguistic structure, shows why ambiguity, recursion, and Zipf's law make naive approaches fail, and frames the formal and statistical traditions the rest of the path builds on.
9 steps·~14 min - AIadvanced
Bayesian Optimization in Practice
The theory becomes useful through libraries, and its flagship job is tuning machine-learning models. This lesson covers that application, the Tree-structured Parzen Estimator behind Hyperopt and Optuna, the tools you would actually reach for, batching, and the honest limits of the method.
8 steps·~12 min - AIadvanced
Acquisition Functions: Deciding Where to Look Next
A Gaussian process gives a mean and an uncertainty everywhere; the acquisition function turns them into one decision about where to spend the next expensive evaluation. This lesson covers Expected Improvement, GP-UCB and its no-regret guarantee, and Thompson sampling, and how each resolves exploration against exploitation.
9 steps·~14 min - AIadvanced
The Gaussian Process Surrogate
Bayesian optimization needs a model that predicts the objective everywhere and knows how unsure it is. The Gaussian process delivers exactly that. This lesson builds the GP as a distribution over functions, shows how a kernel encodes assumptions, and explains why its posterior variance is the engine of the whole method.
9 steps·~14 min - AIadvanced
Optimizing an Expensive Black Box
Some functions cost hours or dollars to evaluate once, give no gradient, and must be optimized in as few tries as possible. This lesson sets up that problem, shows why grid and random search waste the budget, and introduces the surrogate-model loop that Bayesian optimization is built on.
9 steps·~14 min - Computer Scienceintermediate
Tries and Radix Trees: Structures Keyed by Prefix
A trie stores keys in their spelling rather than hashing them, which buys the one query a hash table cannot answer: find everything starting with this. This lesson covers the trie, the memory problem that makes it impractical, and the radix compression that fixes it and routes the internet.
9 steps·~14 min - Computer Scienceintermediate
Heaps and Priority Queues: Keeping Only the Top
A heap is the structure for when you need the smallest item repeatedly but never need the whole set sorted. This lesson builds the binary heap as an array, derives why building one costs linear rather than n log n time, and shows the top-k pattern that makes it worth knowing.
9 steps·~14 min - Computer Scienceintermediate
Balanced Search Trees: Why Rotations Exist
A binary search tree is elegant until sorted input turns it into a linked list. This lesson explains how balance is enforced: the rotation as the one legal repair, what red-black and AVL trees each guarantee, and why databases use B-trees with hundreds of children instead.
9 steps·~14 min - Computer Scienceintermediate
Hash Tables: Collisions, Load Factor, and Swiss Tables
A hash table promises constant-time lookup, and the promise holds only because of how it handles collisions. This lesson builds one from the array up: hashing, chaining versus open addressing, why load factor is the tuning dial, and how modern tables scan sixteen slots at once.
10 steps·~15 min - Computer Scienceintermediate
Why Most Code Is Memory Bound: The Roofline Model
Most real code never approaches a processor's arithmetic peak because it cannot be fed fast enough. The roofline model makes that concrete: plot operational intensity against achievable performance and the binding constraint becomes visible. This lesson covers the model, bandwidth versus latency, and the layout changes that follow.
9 steps·~14 min - Computer Scienceintermediate
The Cache Hierarchy and Why Locality Decides Speed
DRAM is roughly two orders of magnitude further away than a register, so processors interpose several levels of cache. This lesson covers measured latencies at each level, cache lines and associativity, the three kinds of miss, and why identical algorithms differ tenfold based on access order alone.
10 steps·~15 min - Computer Scienceintermediate
Superscalar and Out-of-Order Execution
Modern cores issue several instructions per cycle and execute them in whatever order their inputs become ready, while still appearing to run the program strictly in order. This lesson covers register renaming, the reorder buffer, the scheduler, and why the instruction window exists at all.
9 steps·~14 min

