When a pretrained language model such as BERT or RoBERTa is fine-tuned on a few hundred or a few thousand labelled examples, the outcome depends heavily on the random seed. Two runs that differ only in data order or in the random starting weights of the classification head can land anywhere from strong accuracy to majority-class guessing. Even when their average scores agree, they often disagree on which test examples they get right. This note proposes that much of this seed dependence comes from updates the data do not actually support. In small-data fine-tuning, many parameters receive gradients whose direction flips from minibatch to minibatch. Each run follows its own particular sequence of those noisy gradients, so each run drifts somewhere different. A parameter should change only in proportion to how confident we are about the direction it should move. That confidence can be read almost for free from the running gradient statistics Adam already keeps.
The idea comes from uncertainty-modulated plasticity, the continual-learning principle that a weight's rate of change should follow the learner's certainty about it. We carry it into the single-task, small-data setting, with one deliberate reversal. In continual learning, uncertain weights are made more plastic. Here, the uncertainty that matters is about the update direction rather than the weight value, and uncertain directions are made less plastic. The proposal makes two linked claims. The first is diagnostic and checkable from a single run: parameters with low gradient signal-to-noise are the ones whose final values scatter across seeds and that drive disagreement between runs. The second is interventional: shrinking each Adam step by a per-parameter estimate of how reliable its direction is reduces seed variance, failure rate, and cross-seed prediction disagreement. It does so without longer training, re-initialization, bi-level optimization, or ensembles, and it adds almost no compute.
Core Claim
Adam already maintains an exponential moving average $m_i$ of parameter $i$'s gradient and an average $v_i$ of its squared gradient. From these we form a direction-evidence score $r_i = m_i^2 / (v_i - m_i^2 + \epsilon)$. This is the squared signal-to-noise ratio of the gradient: large when minibatches agree on the sign and size, near zero when they cancel. We then replace the Adam step with a shrunken one:
$$\Delta\theta_i = -\eta \, \frac{r_i}{r_i + \kappa} \, \frac{\hat m_i}{\sqrt{\hat v_i} + \epsilon}$$
Here $\eta$ is the global learning rate, $\hat m_i, \hat v_i$ are Adam's bias-corrected moments, and $\kappa$ is a single threshold on the signal-to-noise ratio. The gate $r_i/(r_i+\kappa)$ is the shrinkage factor from a Gaussian posterior over the true mean gradient. If the observed mean has noise variance proportional to $v_i - m_i^2$ and the prior on the true mean has variance proportional to $\kappa^{-1}$ times that noise, the posterior mean is the observed mean multiplied by this factor. The gate therefore has a clean reading: move each weight by the expected, not the observed, gradient direction.
We call this evidence-gated fine-tuning (EGF). Its central prediction is that EGF lowers the cross-seed spread of the final weights mainly in low-evidence parameters, and that this translates into lower prediction disagreement, not just lower accuracy standard deviation.
How This Relates to Prior Work
The mechanism draws on uncertainty-modulated plasticity, but it deliberately departs from that literature's usual rule. Uncertainty-guided Continual Learning with Bayesian Neural Networks scales each weight's learning rate by its posterior standard deviation, so poorly determined weights stay plastic for future tasks. Task-Agnostic Continual Learning Using Online Variational Bayes With Fixed-Point Updates derives similar variance-as-learning-rate behaviour without task boundaries. Fast and Scalable Bayesian Deep Learning by Weight-Perturbation in Adam shows Adam's second moment can stand in for weight precision.
All three reason about uncertainty in the weight. In single-task small-data fine-tuning, their rule points the wrong way. A pretrained weight that the small task barely constrains has high posterior variance. Making it more plastic lets minibatch noise push it around, which is exactly what makes seeds diverge. EGF instead reasons about uncertainty in the gradient's direction. We test the weight-uncertainty rule directly as a competitor, so the reversal is an empirical claim rather than an assertion. The biological work on Bayesian synapses, Synaptic plasticity as Bayesian inference, motivates the general principle but does not constrain the design.
On the fine-tuning side, two papers constrain the design. On the Stability of Fine-tuning BERT: Misconceptions, Explanations, and Strong Baselines shows that failed runs are not forgetting but under-fitting, with vanishing gradients in lower layers early in training. Revisiting Few-sample BERT Fine-tuning traces many failures to missing Adam bias correction and fixes the rest by re-initializing top layers. Together they warn that a gate which suppresses weak early gradients could make under-fitting worse. We treat this as the main risk, described below.
Several methods restrict which parameters move. Raise a Child in Large Language Model: Towards Effective and Generalizable Fine-tuning (CHILD-TUNING) computes Fisher information once and freezes everything outside a fixed subnetwork. BayesTune: Bayesian Sparse Deep Model Fine-tuning samples posterior scales with Langevin dynamics, then discards the uncertainty and fine-tunes a fixed binary mask. Entropy-based Stability-Plasticity for Lifelong Learning gates whole layers using the entropy of auxiliary side-branch classifiers. EGF differs from all three in the same three ways: it is continuous rather than binary, it is recomputed at every step rather than fixed before training, and it works per parameter with no extra networks or sampling.
Model Balancing Helps Low-data Training and Fine-tuning (TempBalance) sets layer-wise learning rates from weight-matrix spectra at up to 25% overhead; EGF is finer-grained and nearly free. Generalizable and Stable Finetuning of Pretrained Language Models on Low-Resource Texts learns a blend between pretrained and tuned weights by bi-level optimization. It costs about 4x in compute and spends scarce labels on a validation split, whereas EGF uses neither.
Finally, Measuring the Instability of Fine-Tuning supplies our evaluation lens. It shows that lowering accuracy standard deviation can coexist with rising disagreement between runs. That is why our headline metrics are prediction and representation agreement across seeds.
Research Program
The work has three parts, each gating the next.
The first part is a diagnostic study with no new method. We fine-tune RoBERTa-base on RTE, MRPC, CoLA and STS-B, both at full size and subsampled to 300, 500 and 1,000 examples following the splits of Somayajula et al. Each configuration runs for 25 seeds under the corrected Adam baseline of Mosbach et al. For every parameter we compute two quantities. One is its time-averaged gradient signal-to-noise ratio $r_i$ within one run. The other is the cross-seed variance of its final displacement from the pretrained value. We ask whether $r_i$ from a single run predicts which parameters will scatter across seeds. We also ask whether low-$r_i$ parameters account for the pairwise prediction disagreement: resetting only the low-$r_i$ parameters of each run to their pretrained values should reduce disagreement far more than resetting an equal number of random or high-$r_i$ parameters. If neither correlation nor causal reset shows an effect, the hypothesis is wrong and we stop.
The second part builds EGF itself. The gate needs about three lines of code on top of Adam and no additional passes. Because Mosbach et al. identify lower-layer under-fitting as the cause of collapse, EGF normalizes $\kappa$ per layer, using the layer's median $r_i$. A layer whose gradients are uniformly weak is then not shut off wholesale. We also add a small plasticity floor, in the spirit of the confidence-based lower bound in CONGA:Confidence-and-Gradient-Aware Learning Rate Schedule for Test Time Adaptation. Both choices are ablated.
The third part asks how EGF composes with the strongest existing fixes, re-initialization and long training, and whether it reduces how many seeds a practitioner must try.
Baselines
The naive reference point is standard fine-tuning under the old BERT recipe: no Adam bias correction, 3 epochs. We include it only to reproduce the collapse phenomenon; Revisiting Few-sample BERT Fine-tuning reports that 48% of RTE runs fail (accuracy below 55%) in this setting.
The main reference is the corrected-Adam, 20-epoch recipe of On the Stability of Fine-tuning BERT: Misconceptions, Explanations, and Strong Baselines. It reports mean RTE accuracy of 67.3% with a standard deviation of 2.7 across 25 seeds, and a CoLA standard deviation of 1.8. It is the strongest simple competitor because it isolates whether any cleverness beyond "use Adam correctly and train longer" is needed. We run EGF at 20 epochs for an equal-compute comparison and at 3 epochs to test whether EGF matches the long recipe at about one-seventh of the cost.
Re-initialization of the top layers, from Revisiting Few-sample BERT Fine-tuning, is the strongest existing mitigation on prediction and representation metrics according to Measuring the Instability of Fine-Tuning. We tune the number of re-initialized layers per task with the same number of trials that EGF gets for $\kappa$.
For the low-resource splits, we run Attention-Guided Weight Mixup from Generalizable and Stable Finetuning of Pretrained Language Models on Low-Resource Texts, which reduced XLNet standard deviation from 10.69 to 0.96. We also run CHILD-TUNING with the Fisher-selected mask, reported at +2.24 points on 1,000 samples, and DENI from Fighting Randomness with Randomness: Mitigating Optimisation Instability of Fine-Tuning using Delayed Ensemble and Noisy Interpolation, reported at +0.25 to 2.11 F1 on 1,000-sample tasks. Every method uses the same data, the same seeds, and the same hyperparameter budget of 12 trials on a held-out portion of the training set. The one exception is mixup, which receives its required validation split, and we report that data advantage explicitly. No reported result was found on Lacuna for pairwise disagreement, Fleiss' kappa, or CKA values of these baselines on RoBERTa-base, so we measure all of them ourselves.
Three ablations isolate the key ingredient. The first swaps the gate for a UCB-style rule that scales steps by estimated weight standard deviation, derived from Vadam precision; this tests the direction reversal. The second freezes the gate at its values after the first 5% of training; this tests whether dynamic recomputation matters versus a static mask. The third replaces the gate with a random mask of matched sparsity per step; this separates evidence-based selection from mere step shrinkage.
Beating the field means three things. On the 300- and 500-example splits, EGF must lower pairwise disagreement and raise cross-seed CKA relative to both the Mosbach recipe and re-initialization. Mean accuracy must be no lower than these baselines, within seed noise. The failure rate must be no higher than the Mosbach recipe's. A reduction in accuracy standard deviation alone would not count.
Why not just…?
Why not just lower the learning rate or clip gradients? Uniform damping shrinks consistent and noisy directions alike, so it trades stability for under-fitting. Mosbach et al. already show under-fitting is the failure mode. The random-mask ablation and a learning-rate sweep of the Mosbach recipe, run at matched average step size, settle this directly. If a tuned smaller learning rate matches EGF on disagreement, the evidence-gating claim fails.
Why not just raise Adam's momentum coefficient, since Adam's $m/\sqrt{v}$ already shrinks noisy directions? This is the most serious threat. Adam's normalized step is roughly the gradient's signal-to-noise ratio, bounded by one, so it already down-weights noisy parameters to some degree. EGF's gate is quadratic in that ratio and thresholded, so it suppresses low-evidence directions much more sharply. Whether that sharpness matters is an empirical question. We give the Mosbach baseline a sweep over the momentum coefficient within the same tuning budget and report the comparison honestly. If a higher momentum coefficient closes the gap, the contribution shrinks to the diagnostic finding.
Why not just re-initialize the top layers? Re-initialization works well, but the best number of layers varies across tasks. It also throws away pretrained features that 300 examples cannot rebuild, which Revisiting Few-sample BERT Fine-tuning itself notes. The two methods are not exclusive, so we test re-initialization, EGF, and both together. We expect EGF's advantage to be largest at the smallest data sizes.
Why not just ensemble, or use DENI? Ensembles reduce variance by paying for many runs at training and inference time. They do not yield a single checkpoint that other seeds would agree with. We compare EGF against DENI at matched training steps, and against a 5-model ensemble on disagreement with a held-out ensemble's predictions.
Decisive Checks
The single most informative result is the causal reset in the diagnostic study. If resetting each run's lowest-evidence parameters to their pretrained values cuts cross-seed disagreement substantially more than a random reset of the same size, seed instability really does live in low-evidence directions. If it does not, EGF has no reason to work.
The second check is the UCB-direction ablation. If scaling steps up with weight uncertainty increases disagreement while EGF decreases it, the reversal of the continual-learning rule is confirmed.
The third check is the failure rate on the 300-example RTE split. If EGF raises failures relative to the Mosbach recipe, then evidence gating starves early learning. In that case the per-layer normalization and plasticity floor are necessary parts of the method, not optional details, and must be justified as such.
References
- Uncertainty-guided Continual Learning with Bayesian Neural Networks
- Task-agnostic continual learning using online variational bayes with fixed-point updates
- Fast and Scalable Bayesian Deep Learning by Weight-Perturbation in Adam
- Synaptic plasticity as Bayesian inference
- On the Stability of Fine-tuning BERT: Misconceptions, Explanations, and Strong Baselines
- Revisiting Few-sample BERT Fine-tuning
- Raise a Child in Large Language Model: Towards Effective and Generalizable Fine-tuning
- BayesTune: Bayesian Sparse Deep Model Fine-tuning
- Entropy-based Stability-Plasticity for Lifelong Learning
- Model Balancing Helps Low-data Training and Fine-tuning
- Generalizable and Stable Finetuning of Pretrained Language Models on Low-Resource Texts
- Measuring the Instability of Fine-Tuning
- CONGA:Confidence-and-Gradient-Aware Learning Rate Schedule for Test Time Adaptation
- Fighting Randomness with Randomness: Mitigating Optimisation Instability of Fine-Tuning using Delayed Ensemble and Noisy Interpolation