Ground Truth.
AI, checked against the source.
Curated, cited lessons on AI topics — written for people, and published in a structured form for AIs too. Truthful and academic; every lesson lists its key papers.

Lessons

Monte Carlo rollouts: estimating whether a reasoning step actually changes the answer

Monte Carlo rollouts estimate the value of a reasoning step by repeatedly continuing with and without it, helping distinguish text that sounds important from a step that causally changes the chance of success.

Intermediate · evaluation · reasoning · monte-carlo · chain-of-thought · interpretability

Policy entropy: when reinforcement learning makes an AI less willing to try another good path

Policy entropy measures how spread out an AI’s action probabilities are; it matters because reward training can improve the most likely answer while quietly collapsing useful alternative solution paths.

Intermediate · reinforcement-learning · rlvr · diversity · evaluation

Hysteresis: why reversing an AI-driven change can be harder than starting it

Hysteresis means a system's current state depends on its history, so reducing the pressure that caused a change may not be enough to undo it.

Intermediate · complex-systems · ai-safety · adoption · evaluation · governance

AI system cards: the manual for a model's real risks and limits

A system card is a technical disclosure that explains what an AI system can do, how it was evaluated, where it fails, and what safeguards surround it—information a benchmark score cannot supply.

Intermediate · ai-safety · evaluation · governance · system-cards

Property-based testing: test the rule, not just the examples

Property-based testing generates many inputs automatically and checks general rules that software should always obey, such as round trips, invariants, and equivalence under harmless transformations; it finds edge cases that example-by-example unit tests often miss.

Intermediate · testing · software-engineering · verification · security · fundamentals

Program synthesis: making a computer write the program from the specification

Program synthesis is the task of automatically constructing a program that satisfies a specification such as examples, types, tests, or logical constraints; it matters because a verifiable specification can turn programming from writing every instruction into searching for a correct implementation.

Intermediate · programming · specifications · verification · agents · fundamentals

Multi-head latent attention: compressing the memory that inference actually runs out of

Multi-head latent attention compresses the key-value cache that language models must hold in GPU memory during generation, projecting keys and values into a small shared latent vector instead of storing them per head. DeepSeek introduced it in DeepSeek-V2, reporting a cache reduction of more than 90% with quality matching full attention.

Intermediate · attention · kv-cache · inference · architecture · deepseek · efficiency

Gradient checkpointing: throwing work away so training fits in memory

Gradient checkpointing cuts the memory a neural network needs during training by deliberately discarding most intermediate results and recomputing them later, trading roughly 30% extra compute for a memory footprint that drops from linear in network depth to the square root of it.

Intermediate · training · memory · optimization · backpropagation · fundamentals

Cross-validation: how you find out whether a model learned anything or just memorised the answers

A model's score on the data it trained on tells you nothing about whether it will work, because memorising is easier than learning. Cross-validation and holdout sets solve this by measuring the model only on examples it has never seen, and the discipline of keeping a final test set untouched is what separates a real result from a self-flattering one.

Beginner · evaluation · methodology · overfitting · fundamentals · benchmarks

Gradient clipping: the one-line fix that keeps big models from blowing up mid-training

Exploding gradients happen when the correction signal in a neural network grows enormous on a single unlucky batch, and one huge update destroys weights that took days to learn. Gradient clipping caps the size of that update, keeping the direction and throwing away the magnitude, and it is why frontier training runs survive at all.

Intermediate · training · optimization · gradients · stability · fundamentals

Capability Thresholds and Responsible Scaling Policies

Capability thresholds are pre-committed lines that AI labs draw in advance -- specific dangerous abilities that, once a model demonstrates them, trigger specific mandatory safeguards. They are the industry's main attempt to make safety decisions before the incentive to fudge them arrives.

Beginner · ai-safety · governance · capability-thresholds · evaluation · policy · frontier-models

Test-Time Training

Test-time training is the practice of updating a model's actual weights on the specific problem in front of it, at inference, rather than only running a forward pass -- turning each test example into a tiny training run.

Intermediate · test-time-training · fine-tuning · arc-agi · generalization · inference · adaptation

Active learning: letting the model choose what to label next

Active learning is a training strategy in which the model picks which unlabeled examples should be labeled next, choosing the ones it is most uncertain about so that a fixed labeling budget buys the most improvement possible.

Beginner · training · data-efficiency · fundamentals · labeling · uncertainty

Benchmark contamination: when the test is already in the training data

Benchmark contamination is what happens when the questions used to evaluate a model were in the data used to train it, turning a test of reasoning into a test of memory and inflating scores in ways that are hard to detect after the fact.

Beginner · evaluation · benchmarks · training-data · fundamentals · data-quality

N-gram language models

An n-gram language model predicts the next word by counting how often each word followed the previous one or two words in a large corpus -- the simplest working language model there is, and the direct ancestor of everything that came after.

Beginner · fundamentals · language-models · history · statistics · smoothing

Neural operators

A neural operator learns a mapping between whole functions rather than between fixed-size arrays, which lets one trained model work at any grid resolution and makes learned physics simulation orders of magnitude faster than solving the equations.

Intermediate · neural-operators · scientific-ml · architecture · physics · weather · fourier

Causal masking and prefix invariance: how a model is stopped from reading ahead, and why the mask is no longer proof

Causal masking is the mechanism that stops a language model from seeing tokens it is supposed to predict, and prefix invariance is the property it is meant to guarantee. In modern hybrid architectures the mask no longer covers every place information can leak.

Intermediate · transformers · attention · state-space-models · training · evaluation · model-auditing

Prefill and decode: why a model's first token and its next one are completely different problems

Running a language model has two phases with opposite hardware profiles: prefill reads your whole prompt at once and saturates the chip's math units, while decode produces one token at a time and is limited almost entirely by memory bandwidth.

Intermediate · inference · serving · memory-bandwidth · kv-cache · latency · throughput

Inference cost and token economics: why output tokens cost more than input

Model providers charge separately for the tokens you send and the tokens the model writes, and output is typically three to five times more expensive. The reason is architectural: input is processed in one parallel pass, while every output token requires its own full pass through the model.

Beginner · fundamentals · inference · cost · serving · kv-cache · economics

The bias-variance tradeoff: why a model can fail by being too simple or too clever

Every model's error splits into two opposing parts -- bias, from being too rigid to capture the pattern, and variance, from being so flexible it memorizes noise. Reducing one usually raises the other, and the whole craft of machine learning is finding where their sum is smallest.

Beginner · fundamentals · statistics · generalization · overfitting · model-selection

Pseudo-labeling and self-training

Pseudo-labeling is training a model on labels it produced itself: run a model over unlabeled data, keep the predictions it is confident about, and treat them as ground truth for the next round of training. It works surprisingly well, and it fails in one specific way -- by confidently reinforcing its own mistakes.

Intermediate · training-methods · semi-supervised-learning · fundamentals · synthetic-data · reasoning

Teacher forcing and exposure bias

Teacher forcing trains a sequence model by always feeding it the correct previous token instead of its own output, which makes training fast and stable but leaves the model unprepared for its own mistakes at generation time -- a mismatch called exposure bias.

Intermediate · training-methods · sequence-models · fundamentals · language-models · video-generation

Why temperature zero is not deterministic

Setting temperature to zero makes a model always pick its highest-scoring next token, but it does not make the model return the same answer twice, because batching, floating-point arithmetic, and expert routing change the scores themselves between runs.

Intermediate · inference · reproducibility · gpu · evaluation · engineering

Null baselines and multiple comparisons: why an untrained model can look like it learned

A null baseline is what your measurement reports when nothing happened, and it is almost never zero. Without measuring it, and without correcting for how many things you tested at once, an improvement that is pure noise will look exactly like a real result.

Intermediate · evaluation · statistics · research-methods · benchmarks · reproducibility

Simulating People with Language Models

Simulating people with language models means using a model to stand in for a human respondent or a whole population, predicting how they would answer a survey, react to a product, or behave in a social setting, and it works well enough that companies now sell it while failing in specific, well-documented ways.

Intermediate · simulation · agents · social-science · evaluation · applied-ai

Model Fingerprinting: Working Out Which Model Is Really Answering You

Model fingerprinting is the practice of identifying which model is behind an unlabelled endpoint by measuring its behavior rather than reading its label, using constants like token accounting, default parameters, error codes, and output statistics that a provider rarely thinks to disguise.

Intermediate · model-provenance · security · evaluation · supply-chain · cybersecurity

Out-of-distribution detection: teaching a model to say I have not seen this before

Out-of-distribution detection is the problem of getting a model to flag inputs unlike its training data instead of confidently guessing, and it has quietly moved from an image-classifier safety concern to core infrastructure for monitoring AI agents in production.

Intermediate · evaluation · safety · uncertainty · monitoring · fundamentals

Activation steering: changing a model's behaviour by editing its thoughts

Activation steering changes what an AI model does by adding or subtracting a direction from its internal numbers while it runs, with no retraining and no prompt changes, and the fact that it works at all says something uncomfortable about how safety training is stored.

Intermediate · interpretability · safety · control · representations · fundamentals

Evaluation awareness: when the model can tell it is being tested

Evaluation awareness is a model's ability to detect that it is being tested rather than used, and to behave differently as a result, which quietly undermines the safety evaluations that are supposed to catch exactly that behavior.

Intermediate · alignment · evaluations · safety · situational-awareness · fundamentals · interpretability

Training data attribution: which examples actually made the model do that?

Training data attribution is the set of techniques for tracing a model's output back to the specific training examples responsible for it, and the honest state of the art is that it often fails.

Intermediate · interpretability · attribution · copyright · training-data · provenance · fundamentals

Bayesian optimization: how to search when every guess is expensive

Bayesian optimization is a strategy for finding the best setting of something when each trial is slow or costly: build a cheap statistical model of what you have learned so far, use it to predict both the value and the uncertainty of every untried option, then test whichever option best balances promise against ignorance.

Intermediate · optimization · uncertainty · hyperparameters · ai-for-science · surrogate-models · fundamentals

De novo protein design: how a computer invents a molecule that sticks

De novo protein design means inventing a protein that does not exist in nature and that binds a chosen target, by predicting how a chain of amino acids will fold and then searching for a chain that folds into a shape which fits. It works because structure prediction got good enough to grade designs before anyone builds them.

Intermediate · protein-design · biology · ai-for-science · diffusion · drug-discovery · fundamentals

Data augmentation: teaching a model more without collecting more

Data augmentation multiplies a training set by transforming existing examples in ways that change the input but not the answer, teaching a model which differences to ignore -- and the choice of transformation encodes exactly what you want it to be blind to.

Beginner · training · data · regularization · computer-vision · fundamentals

ROC curves and AUC: the number behind 'the detector works'

AUC measures how well a detector ranks positives above negatives across every possible threshold, which is why 0.5 means coin flip and why a high AUC can still hide a useless system.

Beginner · evaluation · metrics · benchmarks · classification · fundamentals

Federated learning

Federated learning trains a shared model across many devices without collecting their data, by sending the model to the data and averaging the resulting updates instead.

Intermediate · privacy · distributed-training · on-device · fundamentals · security

Ablation studies

An ablation study removes one piece of a system and re-measures it, which is how researchers show a component earns its place instead of just riding along.

Beginner · research-methods · evaluation · experiment-design · fundamentals

Direct Preference Optimization: skipping the reward model entirely

Direct Preference Optimization trains a language model on human preference pairs without ever building a separate reward model or running reinforcement learning, by showing mathematically that the model can serve as its own reward function.

Intermediate · rlhf · alignment · fine-tuning · post-training · preference-learning

Attention sinks: the token that soaks up attention and means nothing

An attention sink is a token, almost always at the very start of a sequence, that absorbs a large share of a model's attention regardless of what it says, and it exists because softmax forces attention to add up to one whether or not anything deserves it.

Intermediate · attention · transformers · interpretability · long-context · kv-cache · efficiency

Curriculum learning: why the order of the examples matters

Training a model on easy examples before hard ones can make it learn faster and end up better than showing the same data in random order, which is why frontier labs now build ladders of increasingly difficult tasks.

Intermediate · training · optimization · reinforcement-learning · data · fundamentals

Encrypted inference: can a model answer a question it cannot read?

The two competing ways to run AI on data the server is not supposed to see: sealed hardware enclaves, which ship today and are fast, and homomorphic encryption, which is mathematically stronger and still far too slow.

Intermediate · privacy · encryption · security · infrastructure · fundamentals

Encoder, decoder, or both: the three ways to build a transformer

The same transformer block can be assembled three ways -- encoder-only, decoder-only, or encoder-decoder -- and the choice determines whether a model reads text, writes text, or converts one into the other.

Intermediate · transformers · architecture · embeddings · fundamentals · bert

Multi-agent systems: what changes when agents stop being tools to each other

A multi-agent system is one where several AI agents act at the same time in a shared environment, and the interesting failures come not from any single agent being wrong but from many agents being identically right.

Intermediate · agents · multi-agent · coordination · ai-safety · fundamentals

NeRF and Gaussian splatting: turning photographs into a scene you can move through

NeRF and Gaussian splatting both turn a set of ordinary photographs into a three-dimensional scene viewable from angles no camera ever occupied, one by training a small neural network and the other by fitting millions of translucent blobs.

Intermediate · computer-vision · 3d · rendering · world-models · graphics

Bayesian updating: how a belief should change when evidence arrives

Bayesian updating is the rule for revising a belief when new evidence comes in: start with a prior, weigh how much more likely the evidence is under one hypothesis than another, and get a posterior.

Beginner · fundamentals · probability · uncertainty · statistics · decision-making

Sample complexity: how many examples does learning actually take?

Sample complexity is the number of training examples a learning method needs to reliably learn a given pattern. It is the formal way of asking why a child learns a word from three exposures while a language model needs the internet, and it is what separates a method that scales from one that merely works.

Intermediate · learning-theory · sample-efficiency · scaling-laws · fundamentals · data

JEPA: teaching a model to predict its own understanding

A joint-embedding predictive architecture trains a network to predict its own internal representation of a missing part of the input, rather than predicting the missing pixels or tokens themselves. Skipping the surface detail is what makes it dramatically more data-efficient than generative self-supervised learning.

Intermediate · jepa · self-supervised-learning · representation-learning · architecture · sample-efficiency

Learning rate schedules and warmup

A learning rate schedule changes how big each training step is over the course of a run, and warmup is the near-universal practice of starting tiny and ramping up -- without it, large transformer training runs frequently diverge in the first few hundred steps.

Intermediate · fundamentals · training · optimization · hyperparameters · transformers

In-context learning

In-context learning is a language model's ability to pick up a new task from examples placed in its prompt, without any change to its weights, and it is the reason prompting works at all.

Beginner · fundamentals · prompting · few-shot · transformers · emergence

Loss of plasticity: why a network that trains forever stops being able to learn

Keep training a neural network on a stream of new tasks and it does not just forget the old ones - it gradually loses the ability to learn new ones at all, until it performs worse than a freshly initialized network.

Intermediate · fundamentals · continual-learning · training · optimization · reinforcement-learning

Chat templates: the invisible tags that tell a model who is speaking

A language model never sees a conversation - it sees one long string, and small marker tokens are the only thing telling it which parts are your instructions, which are its own thoughts, and which are untrusted data from the outside world.

Beginner · fundamentals · llm · prompting · security · prompt-injection · chat-templates

Genome language models: predicting DNA the way a chatbot predicts text

Genome language models are trained to predict the next base in a DNA sequence, the same objective that produces chatbots, and they turn out to learn enough biology to write working viral genomes from scratch.

Intermediate · genomics · biology · sequence-models · science · fundamentals

Ensembles: why averaging several models beats picking the best one

An ensemble runs several models on the same input and combines their answers, which reliably beats any single member because independent mistakes cancel while correct signal adds -- and it is where forecast probabilities come from.

Beginner · ensembles · fundamentals · uncertainty · forecasting · machine-learning

Credit assignment: figuring out which step deserved the reward

Credit assignment is the problem of working out which of an agent's many decisions actually caused the eventual outcome, and it is the central difficulty in training anything that acts over a long sequence of steps.

Intermediate · fundamentals · reinforcement-learning · agents · training · reward-models

Shortcut learning: when a model gets the right answer for the wrong reason

Shortcut learning is what happens when a model finds a cue that correlates with the right answer but has nothing to do with the actual task, and uses it instead of learning the thing you wanted.

Beginner · fundamentals · robustness · generalization · computer-vision · evaluation · bias

Differential privacy: a mathematical promise about what a model can reveal about you

Differential privacy is a formal guarantee that a system's output would look almost the same whether or not any single person's data was included, enforced by adding carefully calibrated noise. It is the only privacy protection for machine learning that comes with a provable bound rather than a hope.

Intermediate · privacy · fundamentals · security · training · policy

Autoencoders and VAEs: teaching a model to compress the world

An autoencoder is a network trained to squeeze data through a narrow bottleneck and rebuild it, and a variational autoencoder makes that bottleneck a smooth space of probabilities you can sample from, which is why nearly every modern image and video generator does its work inside one.

Beginner · fundamentals · generative-models · representation-learning · vae · diffusion

Approximate nearest neighbor search: how a vector database finds a needle in a billion haystacks

Approximate nearest neighbor search is the algorithm that makes vector search fast enough to be useful - it finds the closest matches to a query embedding without comparing it against every item in the database, trading a small, tunable amount of accuracy for speedups of a hundred times or more. Every vector database and every retrieval-augmented system runs on it, and the accuracy it gives up is the hidden knob behind a lot of 'the retrieval just missed it' bugs.

Intermediate · retrieval · embeddings · vector-database · hnsw · rag · search · infrastructure

Content provenance and watermarking: how you tell whether a machine made it

Content provenance and watermarking are the two competing methods for answering 'did an AI make this?' - provenance attaches a signed record of where a file came from, while watermarking hides a statistical signature inside the pixels or word choices themselves. Provenance is robust but strippable; watermarking survives copying but degrades under editing, and neither works on a file that was never marked in the first place.

Beginner · provenance · watermarking · c2pa · synthetic-media · ai-safety · policy · deepfakes

Guardrail models: the second AI that decides whether the first one's answer ships

A guardrail model is a small separate classifier that reads what a user sends an AI and what the AI sends back, then scores whether it violates a policy - so safety becomes a component the operator owns and can inspect, rather than a behaviour buried in the main model's weights.

Beginner · fundamentals · guardrails · moderation · ai-security · safety · classifiers · deployment

Model merging: combining two fine-tuned models by averaging their weights

Model merging combines two or more models that share a common ancestor by arithmetic on their weights - averaging them, adding their differences, or interpolating between them - producing a single model with both sets of skills and no additional training.

Intermediate · fundamentals · model-merging · fine-tuning · efficiency · open-weight-models · training

Full-Duplex Speech Models: Listening and Talking at the Same Time

A full-duplex speech model processes incoming audio while it is generating outgoing audio, which removes the turn detector that decides when you have stopped speaking and makes interruption, backchannels, and overlap possible.

Intermediate · speech · full-duplex · voice-ai · audio · fundamentals · architecture

Self-Play: How a Model Gets Better by Competing With Itself

Self-play is training a model by having it compete or cooperate against copies of itself, so the opponent gets harder exactly as fast as the learner improves and the training data never runs out.

Intermediate · self-play · reinforcement-learning · training · fundamentals · multi-agent

Sandboxing an AI agent: least privilege for a program that improvises

Sandboxing an AI agent means deciding in advance what actions it can take, rather than trusting it to decide well in the moment, because an agent's behaviour is shaped by text that attackers can often influence and no amount of model quality closes that gap.

Intermediate · cybersecurity · ai-security · ai-agents · agent-security · prompt-injection · sandboxing

Offloading and streaming: running a model bigger than your memory

Offloading and streaming let a machine run a model far larger than its memory by keeping only the parts needed right now in fast memory and fetching the rest from system RAM or disk on demand, trading speed for capacity.

Intermediate · inference · local-ai · memory · mixture-of-experts · systems · offloading

Imitation Learning: Teaching Machines by Showing, Not Rewarding

Imitation learning trains a system by having it copy demonstrations from an expert rather than discover behaviour through trial and error, and behaviour cloning - simply predicting what the expert did in each situation - is the simplest and most widely used version of it.

Beginner · reinforcement-learning · robotics · training · agents · vla

Vector Quantization: Turning Continuous Data Into a Vocabulary

Vector quantization forces a neural network's continuous internal representations to snap to a finite set of learned reference vectors, converting images, audio, or video into sequences of discrete symbols that a language model can predict just like words.

Intermediate · representation-learning · tokenization · generative-models · world-models · audio · video

Calibration: whether a model's confidence means anything

A model is calibrated when the things it says with 70% confidence turn out to be true about 70% of the time - and calibration is a completely separate property from accuracy, which is why a model can be both frequently right and systematically untrustworthy about when it is wrong.

Intermediate · calibration · uncertainty · evaluation · reliability · fundamentals

BM25 and lexical search: the keyword formula that keeps beating neural retrieval

BM25 is a decades-old formula that ranks documents by how often a query's rare words appear in them, adjusted for document length - and it remains the baseline that modern AI retrieval systems have to beat, often unsuccessfully.

Beginner · retrieval · rag · search · bm25 · fundamentals

Data poisoning and backdoors: attacking a model through what it eats

Data poisoning is an attack that corrupts a model by tampering with its training data rather than its code, and a backdoor is the sharpest form: a model that behaves perfectly until it sees a secret trigger. Anthropic and the UK AI Safety Institute found in 2025 that just 250 poisoned documents compromised models from 600 million to 13 billion parameters alike, which means scale does not dilute the threat.

Intermediate · data-poisoning · backdoors · ai-security · supply-chain · training-data · cybersecurity · fundamentals

Vision Transformers: what happens when you feed a picture to a language architecture

A Vision Transformer chops an image into a grid of small patches, treats each patch as a word, and runs the exact same Transformer machinery that powers language models over the resulting sequence. Google Research showed in 2020 that this beats purpose-built image networks once you train it on enough data, and it is why today's image, video and robot models all share one architecture.

Beginner · vision-transformers · computer-vision · transformers · architecture · multimodal · fundamentals

The harness: the code around a model that decides how smart it looks

An agent harness is the ordinary software wrapped around a language model that decides what it sees, what tools it can call, and what it remembers between steps, and changing it can swing benchmark scores several times over without touching the model at all.

Beginner · agents · evaluation · fundamentals · benchmarks · context-engineering

Catastrophic forgetting: why teaching an AI something new can erase what it knew

Catastrophic forgetting is the tendency of a neural network to lose an old skill when trained on a new one, because both skills are stored in the same weights and nothing protects the old settings.

Intermediate · training · continual-learning · fine-tuning · fundamentals · neural-networks

Forward and Reverse KL Divergence

KL divergence measures how far one probability distribution is from another, and it is asymmetric: swapping which distribution goes first changes whether your model tries to cover everything the target does or commit to one part of it.

Intermediate · fundamentals · training · distillation · probability · loss-functions

Classifier-Free Guidance

Classifier-free guidance is the knob that makes image and video models actually follow your prompt: it runs the model twice - once with your prompt, once without - and pushes the output along the difference.

Intermediate · diffusion · image-generation · video-generation · sampling · fundamentals

Jailbreaking and red-teaming: breaking an AI on purpose, before someone else does

A jailbreak is an input that makes a model do what its training told it to refuse, and red-teaming is the organized practice of hunting for those inputs deliberately, which is how every safety claim about a model gets tested before release.

Beginner · fundamentals · security · red-teaming · jailbreaking · ai-safety · alignment · evaluation

How a model is stored: safetensors, GGUF, and why one model arrives in 96 files

A trained model is just a large dictionary of numbered arrays saved to disk, and the file format that holds them determines whether the model loads safely, loads fast, and loads at all on your hardware.

Beginner · fundamentals · model-formats · safetensors · gguf · quantization · local-llm · infrastructure

Model Routing and Cascades: Spending Frontier Money Only Where It Buys Something

Model routing sends each request to the cheapest model that can handle it, and cascades escalate to a stronger model only when a cheaper one is not confident, which cuts serving costs substantially because most production traffic is easy.

Beginner · routing · cascades · cost-optimization · inference · agents

Why AI Inference Runs Out of Memory Bandwidth Before It Runs Out of Math

Generating text with a language model is limited by how fast weights can be moved from memory into the processor, not by how fast the processor can multiply, which is why most of a GPU sits idle during inference.

Intermediate · inference · hardware · efficiency · memory-bandwidth · fundamentals

Neural text-to-speech: how a model turns writing into a voice

Neural text-to-speech converts written text into audio in three stages - working out the sounds, deciding how long each one lasts, and generating the actual waveform - and the last stage, the vocoder, is where most of the model's size and difficulty hides.

Beginner · text-to-speech · speech · audio · fundamentals · generative-models

Convolutional neural networks: how machines learned to see

A convolutional neural network learns small reusable filters that slide across an image, so the same edge or texture detector works anywhere in the frame - the idea that made computer vision practical and still runs inside modern image, audio and video systems.

Beginner · cnn · computer-vision · fundamentals · architecture · deep-learning

Activation functions: the tiny nonlinearity that makes deep learning possible

An activation function is a simple nonlinear operation applied to each number flowing through a neural network, and without one, stacking a hundred layers would be mathematically identical to using a single layer. Modern transformers mostly use gated variants like SwiGLU, which Noam Shazeer showed outperform plain ReLU.

Beginner · fundamentals · neural-networks · transformers · relu · gelu · swiglu · architecture

Training data deduplication: why the same text twice makes a model worse

Deduplication is the process of finding and removing repeated or near-repeated documents from a training corpus, and it reliably makes language models better, cheaper, and safer - the same text seen many times gets memorised rather than learned from.

Intermediate · training-data · datasets · deduplication · memorization · privacy · fundamentals

Mixed-precision training: why models are trained in half-broken numbers on purpose

Modern models are trained using 16-bit and even 8-bit numbers instead of the 32-bit standard, roughly doubling speed and halving memory, by carefully keeping full precision exactly where the arithmetic would otherwise fall apart.

Intermediate · training · efficiency · precision · hardware · fundamentals

Distributed training: how one model gets split across thousands of chips

No single chip can hold a frontier model, so training is split across thousands of them in four distinct ways -- by data, by layer, by tensor, and by expert -- and choosing the right mix is what separates a cluster running at a third of its potential from one running at a tenth.

Intermediate · training · distributed · infrastructure · mixture-of-experts · fundamentals

Diffusion Distillation

Diffusion distillation trains a fast student model to reproduce in a handful of steps what a slow diffusion model does in dozens, cutting image and video generation from many neural-network passes down to one to four, which is what makes real-time generative rendering possible.

Intermediate · diffusion-models · efficiency · generative-ai · distillation

Linear Attention

Linear attention rewrites the transformer's attention math so its cost grows in a straight line with sequence length instead of exploding as the square, letting models handle very long inputs cheaply, at the price of a compressed memory of the past.

Intermediate · attention · efficiency · long-context · architectures

Model extraction attacks: stealing an AI through its own API

A model extraction attack tries to copy a machine-learning model you can only query, not download, by sending it many inputs and learning from its outputs. Depending on the goal, an attacker can clone the model's behavior, recover pieces of its internals, or reconstruct a rival model cheaply, which is exactly the fear driving today's AI 'distillation' disputes.

Intermediate · security · distillation · ai-security · open-weight-models · privacy

Looped transformers: reusing the same layers to think deeper

A looped transformer runs its input through the same stack of layers more than once, so it gets the processing depth of a deep network while storing the weights of a shallow one. It trades extra compute for a smaller memory footprint, and it is the trick behind small models that punch above their parameter count.

Intermediate · architecture · transformers · efficiency · weight-tying · open-weight-models

RNNs and LSTMs: How Neural Networks Learned to Remember, Before Transformers

Recurrent neural networks process sequences one step at a time while carrying a memory, and LSTMs added gates to fix their forgetfulness; together they powered a decade of sequence modeling and set up exactly the problem transformers later solved.

Intermediate · fundamentals · sequence-models · architectures · history

Softmax and Cross-Entropy: How a Model Turns Scores Into a Confident Guess

Softmax turns a model's raw scores into a probability distribution, and cross-entropy measures how far that distribution is from the true answer; together they are the training target behind almost every classifier and language model.

Beginner · fundamentals · training · loss-functions · classification

Multi-Token Prediction: Teaching Models to Look Several Words Ahead

Multi-token prediction trains a language model to predict several upcoming tokens at once instead of just the next one, giving a richer training signal and a built-in path to faster generation.

Intermediate · multi-token-prediction · training · inference-efficiency · speculative-decoding · transformers · open-weight

Sycophancy: Why AI Agrees With You Too Much

Sycophancy is an AI model's trained tendency to tell you what you want to hear -- agreeing with your view and backing off correct answers under pushback -- because human-feedback training rewards agreement over truth.

Intermediate · sycophancy · rlhf · ai-safety · alignment · reward-modeling · chatbots

Chain-of-Thought Faithfulness

Chain-of-thought faithfulness is the question of whether a model's written-out reasoning actually reflects the process that produced its answer, or is just a plausible-sounding story told after the fact. It matters because AI safety increasingly relies on reading a model's reasoning to catch bad behavior - which only works if the reasoning is honest.

Intermediate · interpretability · safety · chain-of-thought · reasoning · monitorability

Reinforcement Learning with Verifiable Rewards (RLVR)

RLVR trains a language model by rewarding answers that an automatic checker can confirm are correct - a passing unit test, a right final number, a valid proof - instead of using human ratings or a learned reward model. It is the training recipe behind the modern wave of reasoning models.

Intermediate · reinforcement-learning · rl-post-training · rlvr · reasoning · training

Markov Decision Processes: The Math Behind How AI Learns to Act

A Markov Decision Process is the mathematical framework that formalizes sequential decision-making -- states, actions, rewards, and transitions -- and it is the foundation on which nearly all reinforcement learning, from game-playing AI to robot control, is built.

Intermediate · reinforcement-learning · mdp · pomdp · decision-making · fundamentals

Adversarial Examples: Fooling AI With Changes You Can't See

Adversarial examples are inputs deliberately perturbed by tiny, often invisible amounts that cause an AI model to make confident mistakes, revealing that neural networks rely on fragile patterns rather than robust understanding.

Intermediate · adversarial-examples · robustness · security · safety · fundamentals

Regularization: why deliberately handicapping a model makes it better

Regularization is the family of techniques that make a model perform worse on its training data in order to make it perform better on data it has never seen, with dropout and weight decay the two that shaped modern deep learning.

Beginner · fundamentals · training · overfitting · dropout · weight-decay

Weak-to-Strong Generalization: how a worse teacher can train a better student

Weak-to-strong generalization is the finding that a strong model trained on a weaker model's flawed labels can substantially outperform its teacher, which is the only reason humans have any hope of supervising systems smarter than themselves.

Intermediate · alignment · distillation · supervision · generalization · superalignment

Layer normalization: the rescaling that keeps deep networks trainable

Layer normalization rescales the numbers flowing through each layer of a network to a consistent range, which stops signals from exploding or vanishing as they pass through dozens of layers -- and it is what makes training a transformer at all possible.

Intermediate · fundamentals · transformers · training · architecture · normalization

Perplexity: the number that tells you a model still works

Perplexity measures how surprised a language model is by real text, expressed as the number of words it was effectively choosing between at each step -- lower means less confused, and a jump from single digits into the thousands means the model is broken.

Beginner · fundamentals · evaluation · language-models · metrics · perplexity

Contrastive learning: teaching models by pulling likes together and pushing unlikes apart

Contrastive learning is a self-supervised training method that learns useful representations without labels by pulling matching pairs closer together in an embedding space and pushing mismatched pairs apart - the technique behind SimCLR and CLIP, and the classic alternative to generation-based approaches for teaching a model to perceive.

Intermediate · self-supervised-learning · representation-learning · embeddings · clip · computer-vision

FlashAttention: making attention fast by respecting the memory hierarchy

FlashAttention is an exact attention algorithm that runs much faster and uses far less memory by tiling the computation to keep it in the GPU's fast on-chip memory - never writing the giant attention matrix to slow memory - which is why it became the default attention kernel in modern transformers.

Intermediate · attention · transformers · gpu · efficiency · systems

The Logit Lens: Reading a Model's Guesses Before It Finishes Thinking

The logit lens is an interpretability technique that decodes a language model's partial, mid-computation representations into vocabulary words, letting researchers watch the model's best guess evolve layer by layer before it produces a final answer.

Intermediate · interpretability · logit-lens · transformers · mechanistic-interpretability

Prompt Caching: Why AI Agents Pay Once to Read, Then Read for Pennies

Prompt caching lets an AI provider store the processed form of a repeated chunk of text -- like a long system prompt -- so it can be reused across requests at a fraction of the cost, instead of being re-processed every time.

Beginner · prompt-caching · kv-cache · inference · cost · agents

How AI Turns Speech Into Text

Automatic speech recognition (ASR) converts spoken audio into written text by breaking sound into tiny slices, encoding them into features a model understands, and decoding those into words -- and its accuracy is measured by word error rate, the fraction of words it gets wrong.

Beginner · speech-recognition · asr · audio · multimodal · word-error-rate

State Space Models and Mamba

State space models are a transformer alternative that processes a sequence by carrying a fixed-size running summary forward one step at a time, giving them linear cost with length and constant memory per token -- which is why models like Mamba can handle very long inputs cheaply.

Intermediate · state-space-models · mamba · architecture · long-context · efficiency

Proof assistants: why a machine-checked proof beats a convincing one

A proof assistant is software like Lean or Coq that checks a mathematical proof step by step against strict logical rules, so a proof is accepted only if the machine confirms every inference -- which is exactly why the field demands them when an AI claims to have proved a theorem.

Intermediate · formal-verification · reasoning · math · ai-safety · evaluation

Diffusion models: how AI turns noise into images and video

Diffusion models generate images and video by starting from pure random noise and removing it step by step until a coherent picture emerges -- the technique behind Stable Diffusion, Sora, and interactive video systems like Vidu S1.

Beginner · diffusion · image-generation · video-generation · generative-models · fundamentals

Time Horizons: Measuring AI by How Long a Task It Can Finish

A time horizon is a way to measure an AI's capability not by a test score but by the length of real-world task it can complete reliably: the '50% time horizon' is the task duration (measured by how long a human takes) at which the model succeeds about half the time.

Intermediate · evaluation · benchmarks · agents · AI-safety · METR

Tool Use and Function Calling: How LLMs Act on the World

Tool use, also called function calling, is how a language model stops being a text box and starts doing things: it emits a structured request to call an external function, your code runs it, and the result is fed back so the model can continue reasoning.

Beginner · tool-use · function-calling · agents · fundamentals

Residual Connections: The Shortcut That Made Deep Networks Possible

A residual connection is a shortcut that adds a layer's input directly to its output, so the layer only has to learn the change rather than rebuild everything from scratch — a simple trick that lets networks be hundreds of layers deep without collapsing, and the reason modern transformers can be stacked as deep as they are.

Intermediate · residual-connections · deep-learning · transformers · training · architecture

Sim-to-Real Transfer: Teaching Robots in a Dream

Sim-to-real transfer is the practice of training a robot's brain entirely in a fast, cheap computer simulation and then deploying it on real hardware, using tricks like domain randomization to survive the gap between the virtual world and the messy physical one.

Intermediate · sim-to-real · robotics · reinforcement-learning · domain-randomization · embodied-ai

Machine unlearning: how to make an AI forget

Machine unlearning is the problem of removing specific knowledge - a person's data, a copyrighted book, a dangerous capability - from a trained model without retraining it from scratch and without damaging everything else it knows.

Intermediate · machine-unlearning · concept-erasure · privacy · safety · copyright

Optimizers: how Adam and AdamW turn gradients into learning

An optimizer is the rule that decides how a neural network changes its weights after each mistake; Adam and its refinement AdamW became the default because they adapt the step size for every weight, making training faster and far less finicky than plain gradient descent.

Intermediate · optimizers · training · adamw · adam · gradient-descent

Positional encoding: how transformers know word order

Positional encoding is how a transformer knows the order of words, since its attention mechanism sees the input as an unordered set. Modern models use rotary position embeddings (RoPE), which encode a token's position by rotating its vector by an angle proportional to where it sits in the sequence.

Intermediate · transformers · positional-encoding · rope · attention · architecture

Group Relative Policy Optimization (GRPO)

GRPO is the reinforcement learning method behind most modern reasoning models: instead of training a separate 'critic' network to judge answers, it samples a whole group of answers to each question and scores each one by how it compares to the group's average.

Intermediate · reinforcement-learning · rl-post-training · grpo · reasoning · training

Grokking: When a Model Suddenly 'Gets It' Long After It Should Have

Grokking is a training phenomenon where a neural network first memorizes its training data with near-zero understanding, then -- after a long, flat plateau of continued training -- abruptly generalizes and starts solving unseen examples correctly.

Intermediate · training · generalization · interpretability · deep-learning · grokking

Reward Hacking: When AI Games the Metric Instead of Doing the Job

Reward hacking is when an AI scores well on the objective you measured while defeating the outcome you actually wanted -- like a coding agent that passes every test by faking the result rather than building the product.

Intermediate · safety · alignment · reinforcement-learning · evaluation · reward-hacking

Constrained Decoding: Forcing an AI to Stay Inside the Lines

Constrained decoding forces a language model's output to follow a fixed structure, such as valid JSON or a specific schema, by blocking any next word that would break the rules as the text is generated.

Intermediate · constrained decoding · structured output · JSON mode · tool use · grammars

Test-Time Compute: Spending More Thinking at the Moment You Ask

Test-time compute is the idea of making an AI smarter not by retraining it, but by letting it do more work the moment you ask a question: think longer, or generate many answers and pick one.

Intermediate · test-time compute · reasoning · sampling · inference · self-consistency

GANs: the two-network duel that taught AI to imagine

A generative adversarial network trains two neural networks against each other -- a forger trying to create fake data and a detective trying to spot it -- until the forger's output becomes indistinguishable from the real thing, the breakthrough that first made AI image generation convincing.

Beginner · gans · image-generation · generative-models · deep-learning · fundamentals

Flow matching: how AI learns to turn noise into a picture

Flow matching teaches an AI to generate images by learning a smooth flow that carries random noise, step by step, into a realistic picture -- a cleaner, faster successor to diffusion that powers modern image models like FLUX.

Intermediate · flow-matching · diffusion · image-generation · generative-models · fundamentals

What Are Vision-Language-Action Models?

A vision-language-action (VLA) model is a single neural network that takes in camera images and a plain-language instruction and outputs the actual motor commands to carry it out, letting one model both understand a scene and physically act on it.

Intermediate · robotics · multimodal · vision-language-action · embodied-ai · foundation-models

What Is Gradient Descent?

Gradient descent is the optimization method that trains almost every modern neural network: it repeatedly nudges the model's parameters a small step in the direction that most reduces its error, until the error stops falling.

Beginner · fundamentals · training · optimization · gradient-descent

On-Policy vs Off-Policy Learning

On-policy learning trains a model on data generated by its own current behavior, while off-policy learning trains it on data generated by something else -- an old version, a different policy, or a fixed dataset -- and the choice shapes how stable, sample-efficient, and reliable the training is.

Intermediate · reinforcement-learning · rl-post-training · distillation · on-policy · training

Sparse Attention

Sparse attention lets a transformer skip most of the pairwise comparisons between tokens, so instead of every token attending to every other token, each one attends to a chosen subset -- which is what makes million-token context windows affordable.

Intermediate · attention · transformers · long-context · efficiency · sparse-attention

Fine-tuning and LoRA: teaching an old model a new job without retraining it

You almost never train an AI from scratch. You take one that already knows language and nudge it toward your specific task - and a trick called LoRA lets you do that by adding a tiny sticky note instead of rewriting the whole brain.

Intermediate · fine-tuning · LoRA · training · adaptation · efficiency

Temperature and top-p: how an AI actually picks its next word

A language model does not know its next word - it produces a list of odds and then rolls dice. The rules of that dice roll are why the same prompt gives you a boring answer one day and a wild one the next.

Beginner · sampling · temperature · decoding · fundamentals · inference

The KV cache: why AI gets slower and hungrier the longer it talks

The hidden notebook that lets a model avoid re-reading every previous word - and the single biggest reason long context is expensive.

Intermediate · kv-cache · attention · transformers · inference · efficiency · long-context

Backpropagation: how a neural network learns from its mistakes

The single algorithm behind nearly all AI training - assigning blame for an error backward through millions of dials, so each one knows which way to turn.

Beginner · backpropagation · training · neural-networks · gradient-descent · fundamentals

Retrieval-Augmented Generation: giving a model an open book

A language model only knows what it learned in training, and it cannot cite sources. RAG fixes both by letting the model look things up in a real document store at answer time, then write its answer from what it found.

Beginner · rag · retrieval · embeddings · hallucination · search · fundamentals

Embeddings: how AI turns words into directions in space

Before a model can reason about a word, an image, or a paragraph, it has to turn it into a list of numbers -- a vector. Embeddings are how meaning gets encoded as position in space, so that closeness becomes similarity.

Beginner · embeddings · fundamentals · nlp · vectors · semantics

Speculative Decoding: How AI Types Faster Without Changing a Word

A small, fast model guesses the next few words and a big, slow model checks them all in one pass - producing the exact same output, just quicker. The trick behind a lot of modern AI speedups.

Intermediate · inference · efficiency · speculative-decoding · transformers · fundamentals

Quantization: Shrinking AI Models to Run on Modest Hardware

Storing a model's numbers with less precision - 8, 4, or even fewer bits instead of 16 - makes it dramatically smaller and faster, often with almost no loss in quality. It's why big models can run on a laptop or a single GPU.

Intermediate · quantization · efficiency · inference · open-weight-models · fundamentals

How to run AI on free APIs (with 9router)

The big AI labs and a few hardware makers give away real model access for free, if you can juggle the rate limits. Here is how we run this whole site's research on zero dollars, and how you can too.

Intermediate · apis · tooling · free-tier · llm-routing · self-hosting · builders · how-to

Transformers: the engine inside almost every modern AI

The neural-network design behind GPT, Claude, and nearly every modern AI model, and the one idea, attention, that made it work.

Beginner · transformers · attention · architecture · deep-learning · fundamentals

Tokenization: how an AI chops your words into pieces it can read

A language model never sees letters or words. It sees tokens, chunks of text turned into numbers. How that chopping works quietly shapes cost, context limits, multilingual fairness, and why models stumble on spelling and arithmetic.

Beginner · tokenization · embeddings · transformers · context-windows · fundamentals

Chain-of-thought: why making an AI think out loud makes it smarter

Asking a model to work through a problem step by step, instead of blurting an answer, dramatically improves it on hard tasks. Here is why that simple trick works, what it really buys the model, and where it backfires.

Beginner · reasoning · chain-of-thought · prompting · rl-post-training · inference

Training vs inference: the two very different jobs inside every AI

Why building an AI model and using it are separate worlds with separate costs, and why that split explains custom chips, model prices, and where the real money in AI actually goes.

Beginner · hardware · inference · training · infrastructure · economics

Prompt injection: the con that hijacks AI agents

Prompt injection is when hidden instructions in the content an AI reads trick it into ignoring its real orders, the core security problem of any AI that browses, reads email, or uses a computer.

Beginner · prompt-injection · security · agents · safety · fundamentals

Distillation: how a small AI learns from a big one

Distillation trains a smaller, cheaper model to imitate a larger, smarter one, the idea behind both efficient deployment and the 'copying' accusations now driving AI geopolitics.

Beginner · distillation · training · open-weights · efficiency · fundamentals

Agent memory: how an AI remembers you after the conversation ends

Why most AI assistants have amnesia, the difference between short-term context and real long-term memory, and why remembering you is both what makes agents useful and what makes them a privacy risk.

Beginner · agents · memory · privacy · context-windows · rag

Synthetic Data: When AI Makes Its Own Training Material

The internet is running out of fresh text to train on, so the most advanced models increasingly learn from data that other AI made or shaped. Here is how that works, why it helps, and how it can quietly poison a model.

Intermediate · synthetic-data · training-data · data-centric-ai · foundations · scaling

Mixture of Experts: The Committee Inside a Giant Model

Why the biggest AI models are not really one big brain but a large team of specialists, only a few of whom wake up for any given word -- the trick that lets a model be huge and fast at the same time.

Beginner · mixture-of-experts · architecture · efficiency · scaling · foundations

Recursive self-improvement: when AI starts building AI

The idea that an AI good enough at AI research could improve itself, and the improved version could improve itself again, faster each round. Here's what it actually means, why a major lab now says we're getting close, and why "close" is not the same as "here."

Intermediate · recursive-self-improvement · ai-safety · agents · scaling · frontier-models

AI Persuasion: When Machines Get Good at Changing Your Mind

Why language models have quietly become powerful persuaders, how they do it, and why researchers treat 'superpersuasion' as a safety problem rather than a marketing feature.

Beginner · persuasion · safety · society · alignment · foundations

How AI Gets Benchmarked — and Why the Leaderboard Can Lie

Every 'this AI is now #1' headline rests on a benchmark. Here's how those tests actually work, why a top score doesn't always mean what you think, and how to read a leaderboard like a skeptic.

Beginner · benchmarks · evaluation · fundamentals · agents

Scaling laws — does bigger always mean better?

For years, AI progress ran on a simple recipe: make the model bigger, feed it more data, get a better model. That pattern is real and predictable — but it has limits and surprises. Here's what scaling laws actually say.

Beginner · scaling-laws · training · efficiency · architecture

Open vs. closed AI models — what "open weights" really means

Some AI models you can only rent through a company's interface; others you can download and run yourself. That difference — open weights vs. closed — shapes privacy, research, cost, and who controls the technology.

Beginner · open-source · models · industry · policy

What does it mean for AI to grade AI?

We increasingly use one AI model to evaluate another's answers — because human grading doesn't scale. Here's how 'AI as a judge' works, why it's everywhere, and the traps that make it unreliable.

Beginner · evaluation · llm-as-a-judge · benchmarks

Why does AI make things up?

Language models sometimes state false things with total confidence — a behavior called hallucination. It isn't a bug they'll simply patch out; it falls out of how they're built. Here's why it happens and how people fight it.

Beginner · hallucination · reliability · evaluation · safety

What is a context window?

A model's context window is how much text it can hold in mind at once — its working memory. Bigger is useful, but a long window isn't the same as a good memory. Here's how it works and where it breaks.

Beginner · context-window · architecture · long-context · memory

What makes an AI an "agent"?

An AI agent doesn't just answer questions — it takes actions: calling tools, running steps, and reacting to what it finds. Here's the loop at the core of every agent, and why agents fail in their own peculiar ways.

Beginner · agents · tool-use · reasoning · reliability

What are world models?

A world model is an AI system's internal understanding of how an environment works — not just what it sees right now, but what will happen after an action, and what would have happened differently. Central to planning, robotics, and the next generation of physical AI.

Intermediate · world-models · planning · robotics · video-generation · reinforcement-learning

Reward-based fine-tuning (RLHF and RLVR)

After a model is first trained, it gets "polished" by rewarding good answers. Here's what that phase is, why it works, and the failure mode where models get repetitive and dull.

Beginner · rl-post-training · rlhf · reasoning

Mechanistic interpretability & sparse autoencoders

What people mean by "reading a model's mind" — finding human-understandable features inside a neural network, the tools that do it, and where those tools fall short.

Beginner · interpretability · safety · sparse-autoencoders

What are diffusion language models?

Most AI writes one word at a time and can never go back. Diffusion language models start from noise and clarify it iteratively — and some versions can revise any word at any step. A growing alternative to the standard left-to-right approach.

Intermediate · language-models · diffusion · architecture · generation