# mej7.com > mej7.com is a free interactive educational website in English and Albanian for learning how modern AI and large language models work: tokens, embeddings, attention, transformers, training, an advanced track, and a mechanistic interpretability curriculum. Visualizations are simplified teaching models, not production model weights. Independent project by Mehdi Sadriu. No ranking or LLM-recommendation guarantees. ## Pages with one-line descriptions - **mej7.com home (English)** — Free interactive AI lab from beginner to mechanistic interpretability. https://mej7.com/ - **mej7.com home (Albanian)** — Laborator interaktiv falas i AI, nga fillestari te interpretueshmëria mekanistike. https://mej7.com/sq/ - **Beginner path** — Eight short cited lessons for people with no background. https://mej7.com/en/beginner/path/ - **Mechanistic interpretability curriculum** — Twelve cited lessons with demos, quizzes, and primary sources. https://mej7.com/en/mechanistic-interpretability/curriculum/ - **Glossary** — 150+ terms, each with its own URL and DefinedTerm markup. https://mej7.com/en/glossary/ - **About** — Who built the site and that it is independent. https://mej7.com/en/about/ - **Methodology** — How claims are cited or marked [VERIFY]. https://mej7.com/en/methodology/ - **Sources** — Primary papers used in the builder. https://mej7.com/en/sources/ - **Changelog** — Dated published changes. https://mej7.com/en/changelog/ - **Contact** — GitHub issues only. https://mej7.com/en/contact/ - **Guides** — Short static articles. https://mej7.com/en/learn/ - **Intermediate lab** — Interactive visualizations of tokens, attention, transformers. https://mej7.com/en/intermediate/ - **Advanced** — KV cache, MoE, LoRA, RLHF sketches. https://mej7.com/en/advanced/ - **Mech interp hub** — Reading list, concepts, toy labs. https://mej7.com/en/mechanistic-interpretability/ - **What is artificial intelligence?** — AI is software that finds patterns in data and uses them to guess useful outputs. Most everyday systems are machine-learning models, not hand-written rule lists. https://mej7.com/en/beginner/what-is-ai/ - **How do AI models learn?** — They compare a guess to a target, compute a loss, and nudge weights downhill with gradients (Rumelhart, Hinton & Williams, 1986). https://mej7.com/en/beginner/how-ai-learns/ - **What are tokens?** — Tokens are the pieces a language model reads and writes — words, subwords, or symbols. BPE is a common splitting method (Sennrich et al., 2016). https://mej7.com/en/beginner/tokens/ - **How does a language model choose the next word?** — It scores every vocabulary token (logits), turns scores into probabilities with softmax, then picks or samples one token and repeats. https://mej7.com/en/beginner/next-word-guess/ - **What happens between your click and the reply?** — Your text travels to a data centre, is tokenized, flows through transformer layers, and comes back one token at a time. This is a pipeline sketch, not a vendor diagram. https://mej7.com/en/beginner/following-a-message/ - **Does a language model think or feel?** — A language model is a trained next-token machine. Warm prose is not proof of feelings. This page does not settle philosophy of mind; it states what the artifacts are. https://mej7.com/en/beginner/does-ai-think/ - **Why is a language model sometimes wrong?** — It samples likely continuations, not a guaranteed ledger of facts. Fluency and truth are different. Always verify important claims. https://mej7.com/en/beginner/why-ai-is-wrong/ - **What should you learn after the beginner path?** — Go to the Intermediate lab for tokens, embeddings, attention, and training with interactive visuals. Then Advanced, then Mechanistic interpretability if you want to look inside. https://mej7.com/en/beginner/what-to-learn-next/ - **What is the residual stream in a transformer?** — The residual stream is the running vector at each token that every layer reads from and writes to. Teaching model, not production weights. https://mej7.com/en/mechanistic-interpretability/residual-stream/ - **What are attention heads and QK/OV circuits?** — A head is a where-to-look map (QK) plus a what-to-write map (OV). Formula from Vaswani et al. 2017; circuit split from Elhage et al. 2021. https://mej7.com/en/mechanistic-interpretability/attention-heads-qk-ov/ - **What are induction heads?** — Induction heads complete a repetition: A B … A → B. Olsson et al. 2022 link them to in-context learning in the models they studied. https://mej7.com/en/mechanistic-interpretability/induction-heads/ - **What are superposition and polysemanticity?** — Models can pack more features than dimensions by overlapping them. Neurons then respond to mixtures (Elhage et al., 2022). https://mej7.com/en/mechanistic-interpretability/superposition-and-polysemanticity/ - **What are sparse autoencoders (SAEs)?** — An SAE reconstructs activations as a sparse sum of dictionary features. Primary sources: Sharkey et al. 2022, Cunningham et al. 2023, Bricken et al. 2023. https://mej7.com/en/mechanistic-interpretability/sparse-autoencoders/ - **What is activation patching?** — Copy an activation between a clean run and a corrupted run to test causal use (Meng et al. 2022; Heimersheim & Nanda 2024). https://mej7.com/en/mechanistic-interpretability/activation-patching/ - **What are the logit lens and the tuned lens?** — The logit lens decodes intermediate residuals with the unembedding (nostalgebraist 2020). The tuned lens learns a per-layer map first (Belrose et al. 2023). https://mej7.com/en/mechanistic-interpretability/logit-lens/ - **What is probing in interpretability?** — A probe is a small classifier on frozen activations. It tests whether information is present (Alain & Bengio 2016), not whether it is used. https://mej7.com/en/mechanistic-interpretability/probing/ - **What is a circuit in mechanistic interpretability?** — A circuit is a subgraph that implements one identifiable computation, tested by patching and knockout (Olah et al. 2020; Wang et al. 2022). https://mej7.com/en/mechanistic-interpretability/circuits/ - **What is the difference between features and neurons?** — A neuron is a built-in unit. A feature is a direction you claim corresponds to a concept. Superposition is why they often fail to match (Olah et al. 2020; Elhage et al. 2022). https://mej7.com/en/mechanistic-interpretability/features-vs-neurons/ - **What is grokking?** — Grokking is delayed generalization after memorization (Power et al. 2022). Nanda et al. 2023 reverse-engineered one modular-addition case. https://mej7.com/en/mechanistic-interpretability/grokking/ - **What are the limits of current mechanistic interpretability?** — Explanations can be unfaithful, incomplete, scale-sensitive, and easy to over-read. Surveys: Bereska & Gavves 2024; Rai et al. 2024. https://mej7.com/en/mechanistic-interpretability/limitations/ - **Artificial intelligence** — Software that finds patterns in data and uses them to make predictions or decisions. Modern systems people call AI are usually machine-learning models, not hand-written rule lists. https://mej7.com/en/glossary/artificial-intelligence/ - **Machine learning** — A family of methods that fit parameters on examples instead of encoding every rule by hand. Training adjusts those parameters so a loss on the training data goes down. https://mej7.com/en/glossary/machine-learning/ - **Deep learning** — Machine learning that uses neural networks with many layers. Depth lets the network build hierarchical features from raw inputs such as pixels or tokens. https://mej7.com/en/glossary/deep-learning/ - **Neural network** — A stack of layers that transform a vector by multiplying it with weights, adding biases, and applying a nonlinearity. Language models are very large neural networks. https://mej7.com/en/glossary/neural-network/ - **Neuron** — One unit in a layer: it takes a weighted sum of inputs, adds a bias, and applies an activation. In language models a 'neuron' often means one hidden unit of an MLP, which is usually a poor unit of meaning because of superposition. https://mej7.com/en/glossary/neuron/ - **Weight** — A learned multiplier on a connection. Training changes weights. Visualizations on mej7.com use teaching numbers, not production weights. https://mej7.com/en/glossary/weight/ - **Bias (parameter)** — A learned offset added after a weighted sum, before or after an activation, depending on the layer. Not the same as social bias in data. https://mej7.com/en/glossary/bias-parameter/ - **Parameter** — Any learned number in the model, usually weights and biases. GPT-2 small has about 124 million; modern systems have billions to trillions. Count is not the same as intelligence. https://mej7.com/en/glossary/parameter/ - **Activation** — The numbers that flow through the network on one input: the output of a neuron, a residual-stream vector, or a feature. Distinct from the stored parameters. https://mej7.com/en/glossary/activation/ - **Activation function** — A nonlinearity applied elementwise, such as ReLU, GELU, or SiLU. Without nonlinearities, stacked layers collapse to one linear map. https://mej7.com/en/glossary/activation-function/ - **ReLU** — Rectified linear unit: f(x) = max(0, x). A simple activation used in many MLPs. https://mej7.com/en/glossary/relu/ - **GELU** — Gaussian Error Linear Unit, a smooth activation used in many transformers (Hendrycks & Gimpel, 2016). https://mej7.com/en/glossary/gelu/ - **Softmax** — A function that turns a vector of real scores (logits) into a probability distribution: nonnegative numbers that sum to 1. Used in attention weights and in next-token prediction. https://mej7.com/en/glossary/softmax/ - **Logit** — A raw score before softmax. In a language model, the unembedding produces one logit per vocabulary token. https://mej7.com/en/glossary/logit/ - **Loss** — A number that says how wrong a prediction is. Language models typically minimize cross-entropy of the next-token distribution. https://mej7.com/en/glossary/loss/ - **Cross-entropy** — A loss that penalizes a model for putting low probability on the correct class or next token. Equivalent, up to a constant, to maximizing likelihood. https://mej7.com/en/glossary/cross-entropy/ - **Gradient** — The vector of partial derivatives of the loss with respect to the parameters. It points in the direction of steepest increase; training steps the other way. https://mej7.com/en/glossary/gradient/ - **Gradient descent** — The update θ ← θ − η ∇θ L. η is the learning rate. Stochastic variants use mini-batches. https://mej7.com/en/glossary/gradient-descent/ - **Backpropagation** — Applying the chain rule backwards through the network so every parameter gets a gradient (Rumelhart, Hinton & Williams, 1986). https://mej7.com/en/glossary/backpropagation/ - **Learning rate** — The step-size η in gradient descent. Too large and training diverges; too small and it crawls. https://mej7.com/en/glossary/learning-rate/ - **Overfitting** — Fitting the training set so closely that performance on new examples suffers. Grokking is a related, more specific training surprise. https://mej7.com/en/glossary/overfitting/ - **Generalization** — Doing well on inputs the model was not trained on. The point of training is not memorizing the training file. https://mej7.com/en/glossary/generalization/ - **Training set** — The examples used to update parameters. Distinct from a held-out test set used only to measure. https://mej7.com/en/glossary/training-set/ - **Test set** — Examples held out of training so you can measure generalization. If you train on them, they stop being a test set. https://mej7.com/en/glossary/test-set/ - **Batch** — A small group of examples processed together in one update. Mini-batch gradient descent is the usual training method for neural nets. https://mej7.com/en/glossary/batch/ - **Epoch** — One pass through the training set. Large language models are often trained for a small number of epochs on huge corpora. https://mej7.com/en/glossary/epoch/ - **Language model** — A model of a probability distribution over sequences of tokens. Neural language models date at least to Bengio et al. (2003); today's large models are transformers. https://mej7.com/en/glossary/language-model/ - **Large language model** — A language model with enough scale (data, parameters, compute) to show broad in-context behaviour. There is no single official size cutoff. GPT-3 (Brown et al., 2020) is a canonical example of the few-shot era. https://mej7.com/en/glossary/large-language-model/ - **Token** — A vocabulary piece the model reads and writes: a word, a subword, or a symbol. Tokenization is the first real step of every transformer language model. https://mej7.com/en/glossary/token/ - **Tokenization** — Splitting text into tokens and mapping them to integer IDs. Byte-pair encoding (Sennrich et al., 2016) is a widely used method. https://mej7.com/en/glossary/tokenization/ - **Byte-pair encoding** — A subword algorithm that starts from characters (or bytes) and repeatedly merges frequent pairs (Sennrich et al., 2016). https://mej7.com/en/glossary/byte-pair-encoding/ - **Vocabulary** — The finite set of tokens a model knows, typically tens of thousands. The unembedding scores every vocabulary item. https://mej7.com/en/glossary/vocabulary/ - **Embedding** — A learned vector for a token. Similar tokens tend to sit nearer in the space (the intuition popularized for word2vec by Mikolov et al., 2013). In a transformer the residual stream starts from the token embedding plus position. https://mej7.com/en/glossary/embedding/ - **Embedding space** — The vector space in which tokens (and later residual vectors) live. mej7.com's 3D ring is a teaching slice, not a PCA of a real model. https://mej7.com/en/glossary/embedding-space/ - **Context window** — How many tokens the model can attend over in one forward pass. Anything outside the window is not in that pass. https://mej7.com/en/glossary/context-window/ - **Next-token prediction** — The usual pretraining objective: given previous tokens, score the probability of the next one. Generation repeats this one token at a time. https://mej7.com/en/glossary/next-token-prediction/ - **Pretraining** — The large self-supervised run that teaches a model the statistics of text, usually next-token prediction on a corpus. https://mej7.com/en/glossary/pretraining/ - **Fine-tuning** — Further training on a narrower dataset after pretraining. Instruction tuning is one important case. https://mej7.com/en/glossary/fine-tuning/ - **Instruction tuning** — Fine-tuning a pretrained model on instruction–response pairs so it follows requests more reliably than a raw text predictor. https://mej7.com/en/glossary/instruction-tuning/ - **RLHF** — Reinforcement learning from human feedback: a method used to align models with preference data (Ouyang et al., 2022, InstructGPT). https://mej7.com/en/glossary/rlhf/ - **Prompt** — The input tokens you give the model, including system text and the user message. In-context learning is learning from the prompt without changing weights. https://mej7.com/en/glossary/prompt/ - **Completion** — The tokens the model generates after the prompt. An assistant formats this as a reply; a base model just continues text. https://mej7.com/en/glossary/completion/ - **Hallucination** — A fluent output that is not faithful to facts or to a given source. Language models predict likely tokens; they do not look up a guaranteed ledger of truths. https://mej7.com/en/glossary/hallucination/ - **Temperature** — A sampling knob: dividing logits by T > 1 flattens the distribution; T → 0 approaches the greedy (argmax) token. https://mej7.com/en/glossary/temperature/ - **Sampling** — Drawing the next token from the predicted distribution instead of always taking the top logit. Greedy decoding is the T → 0 limit. https://mej7.com/en/glossary/sampling/ - **Assistant** — A language model wrapped in a chat format and usually post-trained to follow instructions (see Ouyang et al., 2022). Not the same object as a raw pretrained predictor. https://mej7.com/en/glossary/assistant/ - **Base model** — A pretrained language model before instruction or preference training. It continues text; it does not reliably follow 'please do X'. https://mej7.com/en/glossary/base-model/ - **Transformer** — The architecture introduced by Vaswani et al. (2017): stacked self-attention and feed-forward layers with residual connections. Almost all modern LLMs are transformers. https://mej7.com/en/glossary/transformer/ - **Encoder** — In the original transformer, the bidirectional stack that reads the source. Decoder-only models used for chat skip this stack. https://mej7.com/en/glossary/encoder/ - **Decoder** — The causal (left-to-right) stack that generates tokens. GPT-style models are decoder-only transformers. https://mej7.com/en/glossary/decoder/ - **Attention** — A mechanism that, for each position, computes weights over other positions and takes a weighted sum of value vectors. In the original paper: Attention(Q, K, V) = softmax(QKᵀ / √d_k) V (Vaswani et al., 2017). https://mej7.com/en/glossary/attention/ - **Self-attention** — Attention where queries, keys, and values all come from the same sequence. That is the default inside a language-model layer. https://mej7.com/en/glossary/self-attention/ - **Causal attention** — A mask that forbids a token from attending to future positions. Required for left-to-right language modelling. https://mej7.com/en/glossary/causal-attention/ - **Multi-head attention** — Several attention heads in parallel in one layer, then concatenated and mixed by an output matrix (Vaswani et al., 2017). https://mej7.com/en/glossary/multi-head-attention/ - **Attention head** — One of the parallel attention units in a layer. Mechanistic interpretability often treats a head as a QK circuit (where to look) plus an OV circuit (what to write) (Elhage et al., 2021). https://mej7.com/en/glossary/attention-head/ - **Query** — The vector a position uses to ask 'whom should I attend to?'. Q = x W_Q in the usual notation. https://mej7.com/en/glossary/query/ - **Key** — The vector a position offers to be matched against queries. Scores are QKᵀ (then scaled and softmaxed). https://mej7.com/en/glossary/key/ - **Value** — The vector that gets mixed once attention weights are known. In the framework picture, OV maps this into the residual stream (Elhage et al., 2021). https://mej7.com/en/glossary/value/ - **QK circuit** — The part of a head that decides where to look: queries and keys, scores, mask, softmax (Elhage et al., 2021). https://mej7.com/en/glossary/qk-circuit/ - **OV circuit** — The part of a head that decides what to write: value vectors mapped into the residual stream and mixed by the attention pattern (Elhage et al., 2021). https://mej7.com/en/glossary/ov-circuit/ - **Scaled dot-product attention** — The formula softmax(QKᵀ / √d_k) V. The √d_k scale keeps dot products from growing with dimension (Vaswani et al., 2017). https://mej7.com/en/glossary/scaled-dot-product-attention/ - **Positional encoding** — Information that tells the model the order of tokens. The 2017 paper used fixed sinusoids; many later models use relative or rotary schemes. https://mej7.com/en/glossary/positional-encoding/ - **RoPE** — Rotary positional embeddings: a widely used relative-position method in later decoder-only models. [VERIFY] consult the original RoFormer paper if you need implementation details. https://mej7.com/en/glossary/rope/ - **Residual connection** — Adding a layer's output to its input instead of replacing it (He et al., 2016). Transformers use this around attention and around the MLP. https://mej7.com/en/glossary/residual-connection/ - **Residual stream** — The running residual vector at each token position that every attention head and MLP reads from and writes to (Elhage et al., 2021). The central picture of transformer mechanistic interpretability. https://mej7.com/en/glossary/residual-stream/ - **Layer normalization** — A normalization over features of one position (Ba, Kiros & Hinton, 2016). Transformers place it before or after sublayers depending on the variant (pre-norm vs post-norm). https://mej7.com/en/glossary/layer-normalization/ - **MLP layer** — The feed-forward network at one position: expand, nonlinearity, project back. Geva et al. (2021) interpret these layers as key–value memories. That is a useful picture, not a proof that each neuron stores one fact. https://mej7.com/en/glossary/mlp-layer/ - **Feed-forward network** — Another name for the MLP sublayer of a transformer block. It does not move information across positions; attention does that. https://mej7.com/en/glossary/feed-forward-network/ - **Unembedding** — The matrix that maps the final residual stream to vocabulary logits. The logit lens reuses this matrix at earlier layers (nostalgebraist, 2020). https://mej7.com/en/glossary/unembedding/ - **d_model** — The width of the residual stream. GPT-2 small uses 768. Teaching diagrams on this site that show 768 are using that familiar width, not measuring a live model. https://mej7.com/en/glossary/d-model/ - **d_head** — The width of one attention head's Q/K/V, often d_model / n_heads (64 for GPT-2 small). https://mej7.com/en/glossary/d-head/ - **KV cache** — Stored keys and values from previous tokens so generation does not recompute the whole prompt every step. A systems trick, not an interpretability method. https://mej7.com/en/glossary/kv-cache/ - **FlashAttention** — An IO-aware exact attention algorithm that reduces memory traffic (Dao et al., 2022). It does not change the mathematical attention function. https://mej7.com/en/glossary/flashattention/ - **Mixture of experts** — A layer that routes each token to a subset of specialist MLPs (Shazeer et al., 2017). Interpreting MoE models is an open, active area. https://mej7.com/en/glossary/mixture-of-experts/ - **Router** — The small network in a mixture-of-experts layer that chooses which experts see a token. https://mej7.com/en/glossary/router/ - **LoRA** — Low-rank adaptation: freeze the base weights and train a pair of small matrices whose product is added to a layer (Hu et al., 2021). https://mej7.com/en/glossary/lora/ - **Quantization** — Storing weights (and sometimes activations) with fewer bits. A deployment technique; it can also change what internal probes see. https://mej7.com/en/glossary/quantization/ - **Mechanistic interpretability** — The research programme of reverse-engineering neural networks into human-understandable algorithms: features, circuits, and causal tests. See Olah et al. (2020) and Elhage et al. (2021). https://mej7.com/en/glossary/mechanistic-interpretability/ - **Feature** — A direction in activation space that lines up with something a person can name. It is not automatically one neuron (Olah et al., 2020; Elhage et al., 2022). https://mej7.com/en/glossary/feature/ - **Polysemanticity** — One neuron (or unit) responding to several unrelated concepts. Toy Models of Superposition treats this as a consequence of packing too many features into too few dimensions (Elhage et al., 2022). https://mej7.com/en/glossary/polysemanticity/ - **Monosemanticity** — A unit that lines up with one relatively clean concept. Sparse autoencoders are one attempt to find more monosemantic directions (Bricken et al., 2023). https://mej7.com/en/glossary/monosemanticity/ - **Superposition** — Storing more features than there are dimensions by letting features overlap, recoverable when they are sparse enough (Elhage et al., 2022). https://mej7.com/en/glossary/superposition/ - **Circuit** — A subgraph of the network — usually heads and MLPs connected through the residual stream — that implements one identifiable computation (Olah et al., 2020; Wang et al., 2022). https://mej7.com/en/glossary/circuit/ - **Induction head** — An attention pattern that completes a repetition: given 'A B … A' it helps predict 'B'. Olsson et al. (2022) link a pair of heads of this kind to in-context learning in the models they studied. https://mej7.com/en/glossary/induction-head/ - **Previous-token head** — A head that attends mainly to the immediately previous token. In the published induction-head account, it is the first half of the pair (Olsson et al., 2022). https://mej7.com/en/glossary/previous-token-head/ - **In-context learning** — Improving at a task from examples inside the prompt, without weight updates. GPT-3 popularized the few-shot form (Brown et al., 2020). Induction heads are one proposed mechanism, not a complete account of every in-context skill (Olsson et al., 2022). https://mej7.com/en/glossary/in-context-learning/ - **Activation patching** — Copying an activation from a clean run into a corrupted run (or the reverse) to test whether that activation carries causally used information (Meng et al., 2022; Heimersheim & Nanda, 2024). https://mej7.com/en/glossary/activation-patching/ - **Causal tracing** — The name Meng et al. (2022) use for a patching-style experiment that localizes where a factual association is used, then edits it (ROME). https://mej7.com/en/glossary/causal-tracing/ - **Ablation** — Zeroing or removing a component and measuring what breaks. Complements patching: patching asks 'is this sufficient to restore the behaviour?'; ablation asks 'is this necessary?' https://mej7.com/en/glossary/ablation/ - **Knockout** — An ablation that disables a head or neuron, often by mean-ablation (replacing activations with their mean over a dataset) rather than hard zero. https://mej7.com/en/glossary/knockout/ - **Path patching** — A patching variant that sends a patched activation along a chosen path of components, used in circuit papers such as Wang et al. (2022). Details differ by implementation. https://mej7.com/en/glossary/path-patching/ - **Probing** — Training a small classifier on frozen activations to test whether information is present (Alain & Bengio, 2016). Presence is not the same as use. https://mej7.com/en/glossary/probing/ - **Linear probe** — A probe that is a linear classifier (or linear regressor) on activations. If a linear probe succeeds, the information is linearly readable — still not proof the model uses it. https://mej7.com/en/glossary/linear-probe/ - **Logit lens** — Decoding an intermediate residual vector with the model's unembedding, as if it were the final vector (nostalgebraist, 2020). A cheap view, biased toward the final basis. https://mej7.com/en/glossary/logit-lens/ - **Tuned lens** — A learned affine map applied before the unembedding at each layer, trained to predict the final logits from that layer (Belrose et al., 2023). https://mej7.com/en/glossary/tuned-lens/ - **Sparse autoencoder** — An auxiliary network trained to reconstruct activations as a sparse sum of dictionary features (Sharkey et al., 2022; Cunningham et al., 2023; Bricken et al., 2023). https://mej7.com/en/glossary/sparse-autoencoder/ - **Dictionary learning** — Finding a set of basis vectors (a dictionary) such that data are sparse combinations of those vectors. SAEs are dictionary learning applied to neural activations. https://mej7.com/en/glossary/dictionary-learning/ - **Sparsity** — Most coefficients being zero (or near zero). SAE training adds a penalty so only a few dictionary features fire on each activation. https://mej7.com/en/glossary/sparsity/ - **L1 penalty** — A loss term proportional to the sum of absolute values of feature activations. One common way to ask an SAE to be sparse. Other SAE papers use different sparsity mechanisms. https://mej7.com/en/glossary/l1-penalty/ - **Feature splitting** — When the dictionary grows, a previously single feature can break into finer ones. Dictionary size is therefore a modelling choice, not a discovery of a unique ontology (discussed in Bricken et al., 2023, and later SAE work). https://mej7.com/en/glossary/feature-splitting/ - **Faithfulness** — Whether an explanation matches the computation the model actually uses, not merely a story that fits the input–output map. There is no single agreed score. https://mej7.com/en/glossary/faithfulness/ - **Steering** — Adding or subtracting a direction in activations at run time to change behaviour. Representation engineering is a related top-down method (Zou et al., 2023). https://mej7.com/en/glossary/steering/ - **Representation engineering** — Reading and steering concept directions in a model's representation space (Zou et al., 2023). Overlaps with mechanistic work but starts from concepts rather than circuits. https://mej7.com/en/glossary/representation-engineering/ - **Attribution graph** — A graph of how features influence one another on one prompt. Anthropic's 2025 circuit-tracing papers describe one large-model version of this idea. https://mej7.com/en/glossary/attribution-graph/ - **Transcoder** — A sparse replacement model trained to approximate an MLP (or another block) with more interpretable features. It is an approximation, not a perfect rewrite. https://mej7.com/en/glossary/transcoder/ - **Universality hypothesis** — The idea that different models learn similar features and circuits (Olah et al., 2020). Evidence is mixed and task-dependent; Chughtai, Chan & Nanda (2023) study a toy case. https://mej7.com/en/glossary/universality-hypothesis/ - **IOI circuit** — The indirect-object-identification circuit in GPT-2 small: a set of heads that complete 'When Mary and John went to the store, John gave a drink to' with 'Mary' (Wang et al., 2022). https://mej7.com/en/glossary/ioi-circuit/ - **Name mover head** — In the IOI circuit, a head that copies the indirect object's name to the output (Wang et al., 2022). https://mej7.com/en/glossary/name-mover-head/ - **S-inhibition head** — In the IOI circuit, a head that suppresses the subject name so the name-mover can copy the other name (Wang et al., 2022). https://mej7.com/en/glossary/s-inhibition-head/ - **Grokking** — A training surprise named by Power et al. (2022): a network memorizes, then much later generalizes. Nanda et al. (2023) reverse-engineered one modular-addition case into a Fourier algorithm. https://mej7.com/en/glossary/grokking/ - **Fourier features** — In the grokking modular-addition study, the late generalizing solution uses periodic (trigonometric) features rather than a lookup table (Nanda et al., 2023). https://mej7.com/en/glossary/fourier-features/ - **Linear representation hypothesis** — The working hypothesis that many concepts are encoded as directions (approximately linear features) in activation space. SAEs and steering both rely on versions of this idea. It is a hypothesis, not a theorem. https://mej7.com/en/glossary/linear-representation-hypothesis/ - **Direction** — A one-dimensional subspace of activation space. Adding a feature often means adding a vector along a direction. https://mej7.com/en/glossary/direction/ - **Subspace** — A linear slice of the residual stream. Heads can read and write overlapping subspaces; if two subspaces are orthogonal, a write in one is invisible to a read in the other. https://mej7.com/en/glossary/subspace/ - **Toy model** — A small constructed system used to make a mechanism visible. mej7.com labs are toy models. Toy Models of Superposition (Elhage et al., 2022) is a research-grade toy, still not a production LLM. https://mej7.com/en/glossary/toy-model/ - **TransformerLens** — A Python library, started by Neel Nanda, for loading models and caching, inspecting, and patching activations. https://mej7.com/en/glossary/transformerlens/ - **SAELens** — A library for training and analysing sparse autoencoders on language-model activations. https://mej7.com/en/glossary/saelens/ - **Neuronpedia** — A public website for browsing SAE features and running some experiments on hosted models. https://mej7.com/en/glossary/neuronpedia/ - **CircuitsVis** — A visualization library for attention patterns and related interpretability plots. https://mej7.com/en/glossary/circuitsvis/ - **nnsight** — A library (NDIF) for intervening on model internals, used in some interpretability workflows. https://mej7.com/en/glossary/nnsight/ - **Activation cache** — Stored intermediate activations from a forward pass, so you can read or patch them without rerunning the whole model from scratch. https://mej7.com/en/glossary/activation-cache/ - **Hook** — A callback attached to a module so you can read or modify its activation during the forward pass. TransformerLens is built around hooks. https://mej7.com/en/glossary/hook/ - **Reverse engineering** — The goal of mechanistic interpretability: recover an algorithm from weights and activations, not merely a correlational story. https://mej7.com/en/glossary/reverse-engineering/ - **Black box** — Treating a model as inputs and outputs only. Mechanistic interpretability is an attempt to open the box; it is incomplete. https://mej7.com/en/glossary/black-box/ - **Explainable AI (XAI)** — A broader family of methods that explain predictions, often via input saliency. Mechanistic interpretability aims at internal algorithms, not only which inputs mattered. https://mej7.com/en/glossary/explainable-ai/ - **Saliency** — A map of which input tokens or pixels a method marks as important for an output. Useful and also easy to over-trust; it is not a circuit. https://mej7.com/en/glossary/saliency/ - **Attention pattern** — The matrix of softmax weights for one head on one prompt. Necessary for a circuit story, not sufficient: you also need the OV write and a causal test. https://mej7.com/en/glossary/attention-pattern/ - **Layer index** — Which transformer block you are looking at, usually counted from 0. Logit lens and patching results are layer-specific. https://mej7.com/en/glossary/layer-index/ - **Head index** — Which attention head inside a layer, usually counted from 0. Papers name heads as L10H7 meaning layer 10, head 7. https://mej7.com/en/glossary/head-index/ - **MLP neuron** — One hidden unit of a transformer MLP. Often polysemantic. Sparse probing (Gurnee et al., 2023) and SAEs are two responses to that problem. https://mej7.com/en/glossary/mlp-neuron/ - **Feature dashboard** — A page of top activating examples for one SAE feature. Suggestive, not a faithfulness proof. Towards Monosemanticity popularized this format (Bricken et al., 2023). https://mej7.com/en/glossary/feature-dashboard/ - **Latent** — An internal variable of a model or of an SAE. In SAE papers, 'latent' often means a dictionary feature. https://mej7.com/en/glossary/latent/ - **Dead feature** — An SAE dictionary element that never (or almost never) activates on the training data. A training failure mode discussed in SAE papers including Gao et al. (2024). https://mej7.com/en/glossary/dead-feature/ - **Shrinkage** — SAE features underestimating true activation magnitude because of the sparsity penalty. A known bias; later architectures try to reduce it (discussed in Gao et al., 2024). https://mej7.com/en/glossary/shrinkage/ - **Hydra effect** — Self-repair: ablating one component causes others to compensate, so the behaviour partly survives (McGrath et al., 2023). Makes naive knockouts hard to interpret. https://mej7.com/en/glossary/hydra-effect/ - **Self-repair** — Another name for the hydra effect: remaining components change their behaviour after an ablation. https://mej7.com/en/glossary/self-repair/ - **ROME** — Rank-One Model Editing: locate a factual association with causal tracing and edit it with a rank-one weight update (Meng et al., 2022). Tested on specific facts in GPT-2/GPT-J-scale models, not a universal fact cell. https://mej7.com/en/glossary/rome/ - **Sparse probing** — Finding a small set of neurons that a probe can use to detect a concept (Gurnee et al., 2023). Still a probe: it shows readable information, then needs a causal check. https://mej7.com/en/glossary/sparse-probing/ - **Sparse feature circuit** — A circuit stated in SAE features rather than in neurons or whole heads (Marks et al., 2024). https://mej7.com/en/glossary/sparse-feature-circuit/ - **Linear representation** — A concept encoded so that a linear readout (a direction) recovers it. The linear representation hypothesis says this is common. Counterexamples exist; do not treat it as a law. https://mej7.com/en/glossary/linear-representation/ - **Residual update** — The vector a sublayer adds back onto the stream. In the framework: x ← x + Attn(x) and x ← x + MLP(x), up to layer-norm placement (Elhage et al., 2021). https://mej7.com/en/glossary/residual-update/ - **Write vector** — The direction and magnitude a component adds into the residual stream. The OV circuit of a head is a map from the attended position to a write. https://mej7.com/en/glossary/write-vector/ - **Read vector** — How a component reads the stream: for a head, the query (and the key at other positions). For an MLP, the first-layer weights. https://mej7.com/en/glossary/read-vector/ - **Orthogonal** — Two vectors (or subspaces) with dot product zero. An orthogonal write is invisible to a read in that subspace — the residual-stream overlap lesson. https://mej7.com/en/glossary/orthogonal/ - **Dot product** — Sum of pairwise products of two vectors. Attention scores start as a dot product of query and key; overlap of subspaces is also a dot product. https://mej7.com/en/glossary/dot-product/ - **Softmax temperature (attention)** — In attention, scaling by 1/√d_k is a fixed temperature-like factor, not a user sampling knob. Do not confuse it with generation temperature. https://mej7.com/en/glossary/softmax-temperature-attention/ - **Pre-norm** — Layer-norm applied before each sublayer. Common in later GPT-style models. It changes the exact residual algebra slightly versus the 2017 post-norm picture. https://mej7.com/en/glossary/pre-norm/ - **Post-norm** — Layer-norm applied after the residual add, as in Vaswani et al. (2017). Many interpretability write-ups still draw pre-norm GPT diagrams. https://mej7.com/en/glossary/post-norm/ - **GPT-2 small** — An openly studied 12-layer, 12-head, 768-width model often used in circuit papers, including Wang et al. (2022). Convenient, not 'the' language model. https://mej7.com/en/glossary/gpt2-small/ - **ARENA** — A public educational programme for mechanistic interpretability (Alignment Research Engineer Accelerator). Linked from mej7.com as an external course, not hosted here. https://mej7.com/en/glossary/arena/ - **Dictionary size** — How many features an SAE is allowed. Larger dictionaries reconstruct better and split features more finely. There is no one true size. https://mej7.com/en/glossary/dictionary-size/ - **Reconstruction loss** — How far the SAE's output is from the original activation, usually mean squared error, traded off against sparsity. https://mej7.com/en/glossary/reconstruction-loss/ - **Feature absorption** — A documented SAE failure mode where a more specific feature 'absorbs' a general one. [VERIFY] see later SAE methodology papers for the exact operational definition used in a given study. https://mej7.com/en/glossary/feature-absorption/ - **Interpretability illusion** — An explanation that looks convincing on a chosen dataset but fails on a wider one. A reason to demand causal tests and held-out prompts. https://mej7.com/en/glossary/interpretability-illusion/ - **Causal mediation** — The statistical idea behind patching: an internal variable mediates between input and output if replacing it changes the outcome in the predicted way. https://mej7.com/en/glossary/causal-mediation/ - **Mean ablation** — Replacing a component's activation with its mean over a reference dataset, rather than zeros. Often milder and more realistic than a hard knockout. https://mej7.com/en/glossary/mean-ablation/ - **Clean run** — The forward pass on the original prompt in a patching experiment. https://mej7.com/en/glossary/clean-run/ - **Corrupted run** — The forward pass on a modified prompt that breaks the behaviour you care about. Patching copies activations from the clean run into this one. https://mej7.com/en/glossary/corrupted-run/ - **Indirect object identification** — The English template used by Wang et al. (2022): two names, then a sentence that should end with the other name, not the subject. https://mej7.com/en/glossary/indirect-object-identification/ - **Modular addition** — The toy task a + b (mod p) used in grokking papers. Small enough that the learned algorithm can be written down (Nanda et al., 2023). https://mej7.com/en/glossary/modular-addition/ - **Progress measure** — In Nanda et al. (2023), metrics that track the Fourier algorithm forming before test accuracy jumps. A tool for that paper's setting, not a universal training dashboard. https://mej7.com/en/glossary/progress-measure/ - **Logit difference** — A common circuit metric: logit(correct token) − logit(incorrect token). Patching is often scored by how much this difference is restored. https://mej7.com/en/glossary/logit-difference/ - **Direct logit attribution** — Reading how much a component's residual write moves the final logits, via the unembedding. A first-order view; later nonlinearities can hide effects. https://mej7.com/en/glossary/direct-logit-attribution/ - **Layer** — One transformer block: attention plus MLP, each with a residual add (and layer-norm). GPT-2 small has 12. https://mej7.com/en/glossary/layer/ - **Position** — The index of a token in the sequence. Each position has its own residual stream. Attention is how positions talk. https://mej7.com/en/glossary/position/ - **Vocabulary space** — The space of token logits. Geva et al. (2022) describe MLP updates as promoting concepts in this space. https://mej7.com/en/glossary/vocabulary-space/ - **Concept** — A human-named property. Whether a model has 'the' concept is a research claim, tested with probes, SAEs, and interventions — not settled by a dashboard screenshot. https://mej7.com/en/glossary/concept/ - **Refusal direction** — A direction in activations that, when steered, can increase or decrease refusal-style completions in some models. Results are model- and prompt-specific; treat demos as demos. https://mej7.com/en/glossary/refusal-direction/ - **Safety feature** — A feature a paper claims is related to a safety-relevant behaviour (for example a refusal or a hazardous topic). Always check the evaluation, not only the name on the dashboard (Templeton et al., 2024 discusses large-scale features including safety-relevant ones). https://mej7.com/en/glossary/safety-feature/ - **Teaching model** — mej7.com's phrase for a visualization that uses made-up numbers to teach a mechanism. Not a trained model and not evidence about a vendor's product. https://mej7.com/en/glossary/teaching-model/ - **Citation** — On this site, a pointer to a primary paper with title, authors, year, and URL. If a claim is not backed that way, it is marked [VERIFY] or omitted. https://mej7.com/en/glossary/citation/ - **Last reviewed** — The date a mej7.com page was last checked against its cited sources. It is not a promise that later papers have been incorporated. https://mej7.com/en/glossary/last-reviewed/ - **Word2vec** — An influential 2013 method for learning word vectors (Mikolov et al.). Vector-arithmetic examples ('king − man + woman') are illustrations with known failures; they are not transformer residual streams. https://mej7.com/en/glossary/word2vec/ - **Self-supervised learning** — Training where the 'label' is derived from the input itself — for language, the next token. Not unsupervised in the clustering sense, and not human-labelled supervised learning. https://mej7.com/en/glossary/self-supervised-learning/ - **Few-shot** — Providing a handful of input–output examples in the prompt. Brown et al. (2020) showed GPT-3 could do many tasks this way without weight updates. https://mej7.com/en/glossary/few-shot/ - **Zero-shot** — Doing a task from an instruction or a question with no in-prompt examples. https://mej7.com/en/glossary/zero-shot/ - **Autoregressive** — Generating the next token from all previous tokens, then appending it. Decoder-only LLMs are autoregressive. https://mej7.com/en/glossary/autoregressive/ - **Bidirectional** — A model (or encoder stack) that can attend to both past and future tokens, as in BERT-style pretraining. Causal LLMs used for chat are not bidirectional at generation time. https://mej7.com/en/glossary/bidirectional/ - **BERT** — A bidirectional encoder transformer trained with masked-language modelling. Historically important; it is not the architecture of ChatGPT-style decoders. [VERIFY] cite Devlin et al. (2019) if you discuss BERT's original training setup in detail. https://mej7.com/en/glossary/bert/ - **Masked language model** — A pretraining task that fills in held-out tokens using both sides of context. Different from causal next-token prediction. https://mej7.com/en/glossary/masked-language-model/ - **Adam** — A widely used adaptive optimizer. Most LLM training runs use Adam or AdamW. The optimizer is not the same thing as backpropagation. https://mej7.com/en/glossary/adam/ - **Regularization** — Any extra term or constraint meant to improve generalization (weight decay, dropout, sparsity penalties). SAE L1 is a sparsity regularizer on an auxiliary network, not on the LLM itself. https://mej7.com/en/glossary/regularization/ - **Dropout** — Randomly zeroing units during training as regularization. Many modern LLM recipes reduce or drop it; do not assume it is present. https://mej7.com/en/glossary/dropout/ - **Weight decay** — A penalty on the size of weights, related to L2 regularization. Common in AdamW training. https://mej7.com/en/glossary/weight-decay/ - **Inference** — Running a trained model to get outputs. No weights are updated. Patching and steering happen at inference. https://mej7.com/en/glossary/inference/ - **Forward pass** — One trip from tokens through the layers to logits (and maybe to sampled text). Reverse-mode autodiff for training is the backward pass. https://mej7.com/en/glossary/forward-pass/ - **Backward pass** — The backpropagation sweep that produces gradients. Interpretability patching is not a backward pass. https://mej7.com/en/glossary/backward-pass/ - **Matrix multiplication** — The operation y = Wx that implements a linear map. Almost every learned transform in a transformer is a matrix multiply plus a bias. https://mej7.com/en/glossary/matrix-multiplication/ - **Linear map** — A function f(x) = Wx + b. Attention scores use linear maps for Q, K, V; the MLP starts with one and ends with one. https://mej7.com/en/glossary/linear-map/ - **Nonlinearity** — Any function not of the form Wx + b. Without nonlinearities, a deep net is one matrix. Softmax and GELU are the two nonlinearities that matter most in a transformer block. https://mej7.com/en/glossary/nonlinearity/ - **Probability distribution** — A list of nonnegative numbers that sum to 1. Softmax turns logits into one. Attention weights in a row are a distribution over positions. https://mej7.com/en/glossary/probability-distribution/ - **Shannon information** — The 1948 theory of communication that treats messages as samples from a probability distribution (Shannon, 1948). Next-token models are in that lineage; they are not a claim about human meaning. https://mej7.com/en/glossary/shannon-information/ - **Perceptron** — An early neural unit (Rosenblatt, 1958). Historical root of 'neuron' as a weighted sum plus a threshold. Modern MLP neurons use smoother activations. https://mej7.com/en/glossary/perceptron/ - **Corpus** — A collection of text used for training or evaluation. Models learn the statistics of their corpus, including its gaps and biases. https://mej7.com/en/glossary/corpus/ - **Bias (data)** — Systematic skew in training text. Distinct from the parameter called bias. Interpretability can sometimes locate features that track demographic or political directions; that is not automatic debiasing. https://mej7.com/en/glossary/bias-data/ - **ChatGPT** — A product name for an assistant built on large language models. mej7.com is not an OpenAI site and does not have ChatGPT's weights. Lessons here explain the shared transformer ideas, not a vendor's unpublished internals. https://mej7.com/en/glossary/chatgpt/ - **OpenAI** — An AI company. Cited on this site only as the author of specific papers (for example Brown et al., 2020; Gao et al., 2024). mej7.com is independent. https://mej7.com/en/glossary/openai/ - **Anthropic** — An AI company whose Transformer Circuits thread published several primary sources used on this site (framework, induction heads, superposition, monosemanticity). https://mej7.com/en/glossary/anthropic/ - **Transformer Circuits** — The Anthropic research thread at transformer-circuits.pub, source of the mathematical framework, induction heads, superposition, and SAE papers cited throughout this curriculum. https://mej7.com/en/glossary/transformer-circuits/ - **Distill** — A visual journal that published Zoom In (Olah et al., 2020) and Feature Visualization (Olah et al., 2017). The site is now archived. https://mej7.com/en/glossary/distill/ - **Alignment Forum** — A research discussion site. Several interpretability reports, including Sharkey et al. (2022) on SAEs and Nanda's open problems list, were posted there. https://mej7.com/en/glossary/alignment-forum/ - **LessWrong** — A discussion site where the original logit lens post was published (nostalgebraist, 2020). https://mej7.com/en/glossary/lesswrong/ - **Gemma Scope** — An open suite of sparse autoencoders trained on Gemma 2 (Lieberum et al., 2024). https://mej7.com/en/glossary/gemma-scope/ - **Claude** — Anthropic's assistant product. Scaling Monosemanticity (Templeton et al., 2024) studies SAE features in Claude 3 Sonnet. mej7.com does not have those weights. https://mej7.com/en/glossary/claude/ - **GPT-3** — The 2020 few-shot language model described by Brown et al. A landmark paper for in-context learning; not an open model you can patch at home. https://mej7.com/en/glossary/gpt-3/ - **InstructGPT** — The paper and model series that described instruction following via human feedback (Ouyang et al., 2022). https://mej7.com/en/glossary/instructgpt/ - **ResNet** — Residual networks for vision (He et al., 2016). Transformers borrow the add-don't-replace idea, not the convolutional blocks. https://mej7.com/en/glossary/resnet/ - **Convolution** — A local linear filter used in vision models. Not how transformer attention mixes tokens. https://mej7.com/en/glossary/convolution/ - **PCA** — Principal component analysis: a linear dimensionality reduction. A 3D embedding plot on this site is not PCA of a real model unless a page says so (none currently do). https://mej7.com/en/glossary/pca/ - **t-SNE** — A nonlinear visualization method for high-dimensional points. Pretty, and easy to over-read. Not used as evidence on mej7.com. https://mej7.com/en/glossary/tsne/ - **Hooked Transformer** — TransformerLens's wrapper that exposes named activations for every block. The practical object you patch in a notebook. https://mej7.com/en/glossary/hooked-transformer/ - **Dataset example** — One prompt (and maybe a label) used to study a behaviour. Circuits found on one template can fail on a nearby template. https://mej7.com/en/glossary/dataset-example/ - **Held-out prompt** — A prompt not used to discover the circuit or feature, used only to test whether the story still holds. https://mej7.com/en/glossary/held-out-prompt/ - **Editorial reading order** — mej7.com's recommended paper order. It is a teaching sequence, not a ranking of scientific importance. https://mej7.com/en/glossary/editorial-reading-order/