Lexicon [32]
The terms the writing and the plates rely on, defined for a numerate reader and cross-linked. Where a plate demonstrates a term, it is named.
A mechanism that computes a weighted combination of value vectors, where the weights measure relevance between a query and a set of keys. Scaled dot-product attention is , with the factor stabilizing gradients. Self-attention lets every position in a sequence attend to every other, giving a global receptive field in a single layer; it is the core operation of the transformer.
An algorithm for computing the gradient of a scalar loss with respect to every parameter in a neural network by applying the chain rule from output to input. It performs one forward pass to cache intermediate activations, then a backward pass that propagates the derivative through each layer in reverse. It is reverse-mode automatic differentiation, computing all parameter gradients in time proportional to a single forward pass.
A layer that standardizes activations across a mini-batch to zero mean and unit variance, then rescales and shifts by learned parameters : , . It stabilizes and accelerates training by reducing internal covariate shift and smoothing the loss landscape. At inference it uses running estimates of the mean and variance instead of batch statistics.
A learned map from discrete or high-dimensional objects to dense vectors in , where geometric relationships encode semantic structure. Token embeddings turn vocabulary indices into trainable vectors that downstream layers consume. A well-trained embedding space places similar items near one another, so distances and directions become meaningful (e.g., analogies as vector offsets).
An iterative optimization method that minimizes a differentiable objective by repeatedly stepping against the gradient: , where is the learning rate. Stochastic gradient descent estimates from a mini-batch rather than the full dataset, trading variance for cheaper steps. Convergence to a global minimum is guaranteed for convex with suitable step size; for non-convex deep networks it converges to a local minimum or saddle region.
The scalar controlling how far each gradient-descent step moves the parameters, . Too large a value causes divergence or oscillation; too small wastes computation and may stall in flat regions. It is typically the most important hyperparameter and is often annealed over training via a schedule or set adaptively by optimizers like Adam.
The S-shaped function mapping the real line to , used to turn a single logit into a probability. Its derivative is the convenient . It is the two-class special case of softmax and saturates for large , which can cause vanishing gradients.
The unnormalized real-valued score a model produces before a normalizing nonlinearity. For a probability , the logit is the log-odds , the inverse of the logistic sigmoid. In multiclass settings, logits are the raw inputs to softmax; only their differences affect the resulting probabilities.
A composition of parameterized affine maps interleaved with nonlinear activation functions, . The universal approximation theorem states that a network with one sufficiently wide hidden layer can approximate any continuous function on a compact set to arbitrary accuracy. Depth makes many functions expressible with far fewer parameters than width alone, and parameters are fit by gradient descent via backpropagation.
The failure mode in which a model fits idiosyncratic noise in the training data and so generalizes poorly to unseen examples, exhibiting low training error but high test error. It worsens as model capacity grows relative to the amount and signal of the data. It is diagnosed by a widening gap between training and validation performance and is mitigated by regularization, more data, or early stopping.
Any technique that constrains a model to reduce variance and improve generalization, typically by penalizing complexity. Common forms add a norm penalty to the loss, such as (weight decay) or , which induces sparsity. Dropout, data augmentation, and early stopping are also regularizers; from a Bayesian view, a penalty corresponds to a prior over parameters.
A method for taking gradients through a sampling step by expressing a random variable as a deterministic function of the parameters and an independent noise source. For a Gaussian, with moves the stochasticity off the differentiation path, so flows through . It is what makes the variational autoencoder trainable by ordinary backpropagation.
An additive shortcut that lets a layer learn a residual: the block computes rather than . This gives gradients a direct path to earlier layers, mitigating vanishing gradients and enabling very deep networks to train. Residual connections are a defining feature of ResNets and appear around every sublayer of a transformer.
A function mapping a vector of real logits to a probability distribution: . The outputs are positive and sum to one, with relative magnitudes set by the exponentiated differences of inputs. It generalizes the logistic sigmoid to multiple classes and is the standard final layer for classification, typically paired with the cross-entropy loss.
The process of segmenting raw text into discrete units (tokens) that a model can index and embed. Subword schemes such as byte-pair encoding learn a vocabulary by greedily merging frequent adjacent symbol pairs, balancing vocabulary size against sequence length and gracefully handling rare or unseen words. The choice of tokenizer fixes the input alphabet of a language model and affects its effective context length.
A neural network architecture built from stacked blocks of multi-head self-attention and position-wise feedforward layers, each wrapped with residual connections and normalization. It dispenses with recurrence and convolution, processing all sequence positions in parallel and injecting order via positional encodings. Introduced in 2017, it is the backbone of modern large language models and many vision and multimodal systems.
The rule for inverting conditional probabilities: . It updates a prior belief into a posterior given evidence , with the likelihood doing the reweighting. It is the foundation of Bayesian inference, where the denominator is the marginal likelihood normalizing the posterior.
The statement that the normalized sum of many independent, identically distributed random variables with finite variance converges in distribution to a Gaussian, regardless of the original distribution’s shape. Concretely, . It explains the ubiquity of the normal distribution and underwrites much of statistical inference.
The probability of event given that has occurred, defined as whenever . It restricts the sample space to outcomes consistent with and renormalizes. Independence is the special case , and rearranging the definition gives Bayes’ theorem.
A measure of the joint linear variability of two random variables, . It is positive when the variables tend to move together and zero when they are uncorrelated (which is implied by, but does not imply, independence). Normalizing by the standard deviations gives the Pearson correlation coefficient in , and stacking pairwise covariances forms the covariance matrix.
The probability-weighted average of a random variable, in the discrete case or in the continuous case. It is linear, so regardless of dependence. The law of large numbers guarantees that sample averages converge to the expectation as the sample size grows.
The property that a process’s future depends on its present state alone, not on its full history: . A process with this property is a Markov chain, characterized by a transition matrix whose rows are probability distributions. Under mild conditions the chain converges to a stationary distribution, the basis of MCMC sampling.
A principle for estimating parameters by maximizing the probability the model assigns to observed data: , equivalently maximizing the log-likelihood. For i.i.d. data it is consistent and asymptotically efficient under regularity conditions. Minimizing cross-entropy loss is exactly maximum likelihood, and adding a prior yields maximum a posteriori estimation.
The expected squared deviation of a random variable from its mean, . It measures spread; its square root is the standard deviation, which shares the units of . For independent variables, variances add, a fact central to the central limit theorem.
A measure of the expected coding cost of using distribution to encode samples drawn from the true distribution : . It decomposes as , so minimizing cross-entropy over is equivalent to minimizing KL divergence. As a training loss with the one-hot label and the softmax output, it coincides with the negative log-likelihood.
The expected amount of information, in bits (base 2) or nats (base ), in a random variable: . It quantifies uncertainty and equals the minimum average code length for the source under Shannon’s source coding theorem. Entropy is maximized by the uniform distribution and is zero for a deterministic outcome.
A measure of how one distribution differs from a reference : . It is non-negative, zero only when almost everywhere, and asymmetric, so it is not a metric. It underlies variational inference, where minimizing KL to a posterior yields an evidence lower bound.
A function is convex if its domain is convex and for all ; geometrically, the line between any two points on the graph lies above it. For twice-differentiable , convexity is equivalent to a positive semidefinite Hessian. Convexity guarantees every local minimum is global, making convex optimization tractable.
For a square matrix , a scalar is an eigenvalue with eigenvector if , meaning acts by pure scaling along . Eigenvalues are the roots of the characteristic polynomial , and for symmetric matrices they are real with orthogonal eigenvectors. The spectrum governs stability, conditioning, and the behavior of iterated linear maps.
The gradient of a scalar field is the vector of partial derivatives . It points in the direction of steepest ascent, and its magnitude equals the maximal rate of change of at that point. The gradient is orthogonal to the level sets of , and it vanishes at stationary points.
An integer greater than 1 whose only positive divisors are 1 and itself. By the fundamental theorem of arithmetic, every integer above 1 factors uniquely into primes, making them the multiplicative building blocks of the integers. Euclid proved there are infinitely many, and the prime number theorem states the count below is asymptotic to .