NeurIPS 2026

Where You Backpropagate Matters:
Token Hypothesis for Memory-Efficient Fine-Tuning

Md Kowsher1,2    Chen Chen2
1Meta  ·  2University of Central Florida
Which positions receive gradients?
t = 1sequence position →t = T
12.5%
of positions on the
backward graph
87.5%
per-token activations
never stored (1 − M/T)
backprop (trainable) forward only, under torch.no_grad() Causal models: later positions carry the richest signal (Theorem 3), so train the last M.
TL;DR

Fine-tuning a transformer stores activations at every token position, and that cost grows linearly with sequence length. We show, through a Neural Tangent Kernel lens, that each position is a low-dimensional bottleneck, so you only need to backpropagate through a small, architecture-dependent subset of positions. The full forward pass stays intact, and inference is unchanged.

1.5–5.2
Effective rank of a single position's Gram matrix, across every tested model, position and dataset size.
6 × 5
Task families × backbones where a small M matches or beats full-sequence fine-tuning in nearly all settings.
−81.8 GB
Total GPU memory saved on LLaMA-3-8B long-context tuning at T = 8192 with M = 500.
3.6×
Larger attainable batch size under a fixed memory budget (batch size 64).
Overview

The Token Hypothesis at a glance

Overview of the Token Hypothesis and training procedure
figures/figure_1.pngOverview figure
Figure 1. (a) Three theorems and a corollary characterize how fine-tuning signal is distributed across positions: capacity per position is bounded, equal across positions in bidirectional models, and monotonically increasing in causal models. (b) We select M trainable positions and reorder the sequence so that only that group receives gradients. (c) Attention masks for four selection strategies: Random, Last-M, First-M and Any subset.
Abstract

Activations, not parameters, dominate the bill

Fine-tuning large transformers routes gradients through every token position, paying the cost in activation memory that scales linearly with sequence length and dominates the GPU budget. Existing efficient methods reduce the parameter side (low-rank adapters, prefix tuning, weight-decomposed updates) but leave the activation footprint untouched.

We present the Token Hypothesis, a memory-efficient fine-tuning procedure motivated by a Neural Tangent Kernel analysis of how fine-tuning signal is distributed across token positions. We prove that every position is a low-dimensional capacity bottleneck whose width does not grow with the model, that positions with aligned hidden-state geometry are interchangeable in bidirectional models, and that causal positions form a monotone capacity chain in which later positions strictly dominate earlier ones.

The analysis provides an assumption-qualified criterion for estimating how many positions are needed and which ones, using quantities computable from forward passes alone. We translate this into a procedure that backpropagates through only a small subset of positions while running the full forward pass over the rest. Empirically, it matches or exceeds full-sequence fine-tuning in nearly all settings across six task families and five backbones, reduces activation memory substantially, and composes cleanly with LoRA and DoRA.

Theory

Three theorems about a single token position

Let $\phi_t(x) := \nabla_\theta o_t(x;\theta_0)$ be the position-$t$ feature map and $K_t[n,m] := \langle \phi_t(x^{(n)}), \phi_t(x^{(m)})\rangle$ its Gram matrix. Under the NTK regime, training through position $t$ is kernel regression with $K_t$, so everything follows from how $K_t$ behaves across positions and architectures.

THEOREM 1

Limited capacity per position

Training through one position confines every update to a subspace whose dimension is at most $\mathrm{rank}(K_t) \le \min(N,P)$, independent of model size. Measured effective rank is tiny: $d_{\mathrm{eff}}(K_t)\in[1.5,\,5.2]$.

$\hat f_t(X) \in o_t(X;\theta_0) + \mathrm{Im}(K_t)$
THEOREM 2

Equal capacity, bidirectional

When every position sees the full sequence, positions with aligned hidden-state geometry yield nearly identical fine-tuned predictors. The gap is bounded by quantities you can compute from forward passes alone, so choosing positions reduces to sampling.

$\|f_i - f_j\| \le \delta_{\text{init}} + \tfrac{\delta_k R}{\lambda_0^+} + \tfrac{\|k_j\|\,\delta_K R}{(\lambda_0^+)^2} + \tfrac{\|k_j\|\,\delta_r}{\lambda_0^+}$
THEOREM 3

Monotone capacity, causal

Under a contraction condition linking adjacent hidden states, Gram matrices form a monotone chain up to a vanishing slack: later positions carry at least as rich a gradient signal as earlier ones. The natural subset is the last M.

$K_{t+1} \succeq K_t - \delta_t I_N$
COROLLARY 1 · how many?

Define $M^\ast := \min\{M : \mathrm{Im}(K^{(M)}) = \mathrm{Im}(K^{(T)})\}$, the fewest positions whose combined Gram matrix spans the same prediction space as the full sequence. Its value is set by the architecture.

  • Bidirectional: $M^\ast \le \lceil \epsilon_K T / \lambda^+ + 1 \rceil$, and $M^\ast = 1$ when position kernels coincide.
  • Causal, last-to-first: $M^\ast = 1$. The single last position spans the whole prediction space.
  • Causal, first-to-last: $M^\ast = T$. Every position adds a strictly new direction.
Image-space saturation on RoBERTa-base
figures/figure_2.pngSaturation · RoBERTa-base
Figure 2. Image-space saturation on RoBERTa-base (bidirectional). All three saturation metrics cross the 0.90 threshold at $M^\ast \le 4$, stable across $(N,T)$.
Image-space saturation on SmolLM2-135M
figures/figure_3.pngSaturation · SmolLM2-135M
Figure 3. Image-space saturation on SmolLM2-135M (causal). Reverse ordering (R2L) reaches $\mathrm{Im}(K^{(T)})$ at $M=1$; forward ordering (L2R) needs $M=T$.
Method

Full forward pass, partial backward pass

Theory becomes a few lines of code. Every per-token module (linear projections, embeddings, LayerNorm and RMSNorm) is wrapped so that its input is split along the sequence axis.

  1. Pick S, |S| = M. A random subset resampled each epoch for bidirectional models; the last M positions for causal models.
  2. Freeze the rest. Positions outside S run under torch.no_grad(), so their activations never enter the computation graph.
  3. Train the rest. Positions in S get the base op plus a method-specific delta: identity for full FT, $BA$ for LoRA, the normalized update for DoRA.
  4. Deploy as usual. Drop the wrapper and merge any adapters into $W$. No inference overhead.

Attention scores still run on the full rejoined sequence, which keeps compatibility with SDPA and FlashAttention. The method also stacks with gradient checkpointing.

Algorithm 1 · wrapper for one per-token modulePyTorch
class TokenHypothesisWrap(nn.Module):
    def __init__(self, base, delta, M):
        super().__init__()
        self.base, self.delta, self.M = base, delta, M

    def forward(self, X):            # X: [B, T, d]
        Tf = X.size(1) - self.M        # frozen length
        Xf, Xp = X[:, :Tf], X[:, Tf:]

        with torch.no_grad():         # no activations kept
            Yf = self.base(Xf)

        Yp = self.base(Xp) + self.delta(Xp)  # full grad
        return torch.cat([Yf, Yp], dim=1)

# delta = 0           → full fine-tuning
# delta = B @ A       → LoRA
# delta = DoRA update → DoRA
Results

A few hundred positions match the full sequence

Every run in a (modality, regime) pair shares the same learning rate, batch size, schedule and GPUs; the only variable is $M$. Pick a setting below to see accuracy and total GPU memory as $M$ grows, with the full-sequence baseline dashed. Numbers are from Table 1 (LLaMA-3-8B for text, Qwen3-VL-8B for VQA and video).

Mean accuracy vs. trainable positions M
Total GPU memory, GB vs. trainable positions M
Token Hypothesis (M positions) All positions (baseline) filled dot = matches or beats baseline

Against other token-selection methods

At matched token budgets and identical memory, the Token Hypothesis (TH) leads TokenTune (TT) and TokenSeek (TS) in most cells. It does this without TokenSeek's pre-scoring pass over the training set or its per-model grid search: it just applies the last-M rule.

Commonsense reasoning on LLaMA-3-8B. GPU = peak allocated memory (GB), shared across the three methods at each budget. Bold = best in each benchmark group.

Long context: the savings get large

LLaMA-3-8B on LongAlpaca-12k at $T=8192$ on 8×A100-80GB. Long-form generation needs a larger budget, since the required $M$ scales with the length of the supervised span.

TokensM/TGPU (GB)Time (min)PPL ↓
All1.00292.8301.58.14
5000.06211.0 −81.8230.2 −71.39.12 +0.98
10000.12215.4 −77.4239.5 −62.09.04 +0.90
20000.24224.4 −68.4248.4 −53.18.61 +0.47
50000.61276.4 −16.4286.7 −14.88.11 −0.03

Savings are additive with gradient checkpointing: on top of GC, M = 2500 cuts memory from 193.1 to 182.9 GB while perplexity improves slightly (8.103 vs 8.143).

Bidirectional backbones too

On RoBERTa-base (GLUE) and ViT-L/16 (image classification), accuracy saturates at M = 50–100, consistent with Theorem 2: in bidirectional models, small subsets of aligned positions suffice.

Ablation studies for token-masked fine-tuning
figures/figure_28.pngAblations
Figure 28. Ablation studies for token-masked fine-tuning: batch-size scaling, sequence-length scaling, convergence across M and NTK laziness.
Empirical validation

The theorems hold on real models

Validation of Theorem 1
figures/figure_4.pngTheorem 1 · RoBERTa-base
Figure 4 · Theorem 1. On RoBERTa-base ($N=500$), eigenvalues of $K_t$ drop by more than ten orders of magnitude near the tail, and $d_{\mathrm{eff}}(K_t)\in[1.5,3.9]$ across all eight positions tested.
Validation of Theorem 2
figures/figure_5.pngTheorem 2 · RoBERTa-base
Figure 5 · Theorem 2. Across 12 fixed prompt positions, eigenvalue and cumulative-variance curves are nearly indistinguishable, with $d_{\mathrm{eff}}\in[1.02,1.12]$ (CV = 0.02). All ten position pairs pass a permutation test at $p<0.001$.
Validation of Theorem 3
figures/figure_6.pngTheorem 3 · LLaMA-3-8B
Figure 6 · Theorem 3. On LLaMA-3-8B, $\mathrm{tr}(K_t)$ grows with position and $\lambda_{\min}(K_{t+1}-K_t+\delta_t I)\ge 0$ at every transition. Linear-probe accuracy rises from near chance at position 1 to about 0.8 at position 45.

Ablations

3.6×

Batch size

Activation memory grows linearly in batch size with slope ∝ M, so a smaller M buys a bigger batch.

97.6%

Sequence length

Fixing M = 50 decouples activation memory from T, up to 97.6% saved at T = 2048 on video.

50–100

Convergence

M = 50–100 matches full-sequence accuracy on LLaVA-OneVision-7B over 1000 eval steps.

<0.011

NTK laziness

Mean weight drift stays below 0.011 across every parameter group and every M.

~4×

Less forgetting

M = 100 on ARC-C cuts forgetting on four untrained benchmarks by about 4× vs. full FT.

Citation

BibTeX

@inproceedings{kowsher2026token,
  title     = {Where You Backpropagate Matters: Token Hypothesis
               for Memory-Efficient Fine-Tuning},
  author    = {Kowsher, Md and Chen, Chen},
  booktitle = {Advances in Neural Information Processing Systems},
  year      = {2026}
}