1/26
Vocabulary flashcards covering neural network-based language modeling, including representation pipelines, activation functions, loss functions, optimization, and evaluation metrics.
Unsmoothed N-gram Probability
A probability calculated strictly by counting word co-occurrences in a training corpus, which assigns a probability of 0 to any valid or plausible sequence that was never explicitly observed.
Vocabulary (V)
The fixed list of unique words that a language model knows, where each token is assigned an arbitrary integer index.
Vocabulary ID
An arbitrary numerical index assigned to a word in the vocabulary that serves as an identifier without representing semantic meaning or word size.
One-Hot Vector
A sparse vector representation of length equal to vocabulary size (V), containing a single 1 at the word's vocabulary ID and zeros at all other positions.
Word Embedding
A dense vector of real numbers with a chosen dimension (d) representing a word, whose values are learned during training to share information across similar contexts.
Vector Concatenation
The operation of joining multiple word vectors end-to-end in order to create a single input vector, preserving sequence order without adding or averaging the coordinates.
Context Window
A specified, fixed number of preceding words that the neural network is permitted to see and use as input to predict the following word.
Target Word
The word immediately following the context window that the language model is tasked with predicting.
Activation Function
A mathematical function that transforms the calculated weighted sum and bias of a neuron into an output, enabling neural networks to learn nonlinear, complex relationships.
Sigmoid Function
An activation function defined as σ(z)=1+e−z1 that squashes any real-valued score into a continuous value between 0 and 1.
Rectified Linear Unit (ReLU)
A nonlinear activation function defined as ReLU(z)=max(0,z), which outputs 0 for negative values and leaves positive values unchanged.
Hidden Layer
An intermediate layer of neurons located between the input layer and output layer that computes intermediate, nonlinear feature representations.
Forward Propagation
The step-by-step process of computing and passing numerical values through a neural network from the input layer through the hidden layers to the output layer.
Logits (Scores)
The raw, unnormalized numerical scores output by the final linear layer for every word in the vocabulary before probability normalization.
Softmax Function
A function that converts raw output scores into a normalized probability distribution across the entire vocabulary using the formula pi=∑jexp(zj)exp(zi).
Greedy Choice
A decoding strategy that deterministically selects the word with the highest probability from the output distribution.
Sampling
A text generation method that selects the next word randomly according to the model's predicted probability distribution.
Cross-Entropy Loss
A loss metric defined as L=−ln(p), which measures how incorrect a prediction is by taking the negative natural logarithm of the probability (p) assigned to the true target word.
Self-Supervised Learning
A training setup where learning targets are extracted automatically from raw text by using the next token as the ground-truth label without requiring human annotation.
Backpropagation
An algorithm that passes prediction error backward through the network layers to calculate the gradient of the loss with respect to each trainable parameter.
Gradient (g)
A derivative value indicating how much and in what direction the loss function changes in response to a change in a given weight or parameter.
Gradient Descent
An optimization method that iteratively updates weights using the formula wnew=w−ηg to minimize the loss.
Learning Rate (η)
A hyperparameter that controls the step size of parameter updates during optimization by scaling the gradient.
Epoch
One complete training cycle in which the neural network processes every example in the training dataset exactly once.
Overfitting
The condition where a model learns the training data excessively well but fails to generalize or improve performance on unseen validation data.
Perplexity
An evaluation metric for language models that measures surprise or uncertainty across held-out text, calculated as Perplexity=exp(Mean loss), where lower values represent better predictions.
Fixed-Window Limit
An architectural constraint of feedforward neural language models where context is strictly capped at a fixed number of preceding words, leaving any earlier words invisible to the prediction.