Create and explore imaginative 3D worlds with our new product Dreamfield (opens in a new tab)
Papers
Topics
Authors
Recent
Search
2000 character limit reached

Ambient LLMs: Data-Efficient Supervised Fine-tuning via Temperature Matching

Published 17 Nov 2026 in cs.LG, cs.AI, and cs.CL | (2611.23229v1)

Abstract: Collecting large-scale, diverse, and high-quality post-training datasets for autoregressive LLMs is challenging. Consequently, Supervised Fine-Tuning (SFT) is typically applied to datasets significantly smaller than those used for pre-training, which leads to overfitting and the catastrophic forgetting of the tails of the data distribution. To prevent this collapse, we introduce Ambient SFT, a principled framework for leveraging imperfect predictions to augment the fine-tuning set. In our method, a "frozen" version of the pre-trained model serves as a noisy teacher that the fine-tuned model must match at a coarse level. In particular, we require that the high-temperature versions of the conditional distributions produced by the post-training model should match the high-temperature versions of the pre-training ones. The temperature hyperparameter controls the level of trust in the pre-trained model, with the limit T→∞T\to \infty reverting back to regular SFT and T=1T=1 to knowledge distillation. We demonstrate that our approach outperforms standard SFT across domain adaptation, instruction-tuning, and reasoning, leading for up to 21%21\% average relative improvement to standard SFT.

Summary

  • The paper introduces Ambient SFT, which combines clean next-token supervision with temperature-matched KL regularization from a frozen pre-trained model to reduce overfitting while preserving capabilities.
  • Temperature controls the bias–variance trade-off: intermediate values can outperform ordinary SFT and standard distillation, with domain adaptation reaching a 26.7% relative perplexity improvement on News.
  • Experiments show the largest benefits under limited supervision, including instruction-tuning gains up to 20.3% and improvements on five of six reasoning benchmarks, although temperature selection remains task-dependent.

Problem setting and central contribution

Post-training datasets for autoregressive LLMs are typically far smaller than pre-training corpora and are often concentrated on a narrow set of behaviors, styles, or domains. Standard supervised fine-tuning (SFT) therefore faces a familiar bias–variance problem: fitting the limited target data improves the intended capability but can overfit and induce catastrophic forgetting elsewhere in the model’s distribution. “Ambient LLMs: Data-Efficient Supervised Fine-tuning via Temperature Matching” (2611.23229) proposes Ambient SFT, a regularized SFT procedure that uses the pre-trained model itself as a frozen, imperfect teacher.

The key design choice is not to force the post-trained model to reproduce the teacher’s ordinary-temperature distribution. Instead, the student is trained with two objectives on the same target examples:

  1. clean cross-entropy on the observed next tokens; and
  2. a KL divergence between the student and frozen pre-trained model after temperature scaling.

For a temperature TT, the teacher and student conditionals are computed from logits divided by TT. The resulting objective is, schematically,

J^λ,T(θ)=L^SFT(θ)+λDKL(pTθpre  ∥  pTθ),\widehat{J}_{\lambda,T}(\theta) = \widehat{L}_{\mathrm{SFT}}(\theta) + \lambda D_{\mathrm{KL}} \left( p_{T\theta_{\mathrm{pre}}} \;\middle\|\; p_{T\theta} \right),

where λ\lambda determines the regularization strength. The student is initialized from the pre-trained model, whereas the teacher remains frozen. The method is therefore a drop-in modification of SFT rather than a separate data-generation pipeline.

Temperature is the central control parameter. At T=1T=1, Ambient SFT becomes ordinary knowledge distillation toward the pre-trained model. As T→∞T\rightarrow\infty, both distributions approach the uniform distribution, the KL term vanishes, and the method converges to ordinary SFT. Intermediate temperatures preserve coarse structural information from the pre-trained model while allowing the student to alter its sharp, task-specific predictions.

Algorithmic interpretation

The method’s operational structure is summarized by the student–teacher decomposition: the student receives gradients, while the teacher is queried only to produce softened token distributions on the supervised prefixes.

Figure 1

Figure 1: Ambient SFT combines clean next-token supervision with temperature-matched predictions from a frozen pre-trained teacher.

In the implementation, each minibatch is assigned either a clean SFT update with probability pcp_c or a temperature-matching update with probability 1−pc1-p_c. In expectation, this stochastic procedure implements the combined objective with λ=(1−pc)/pc\lambda=(1-p_c)/p_c. The experiments most commonly use pc=0.75p_c=0.75, so approximately one quarter of updates use the teacher-matching loss.

The computational cost is modest but nonzero. Temperature matching requires a forward pass through the frozen teacher. Under the paper’s estimate that a backward pass costs approximately twice a forward pass, using equal-sized teacher and student models with pc=0.75p_c=0.75 makes training approximately 1.1×1.1\times slower than ordinary SFT for the same number of optimization steps. This establishes the intended operating regime clearly: Ambient SFT addresses data-limited rather than compute-limited post-training.

The method differs from classical knowledge distillation in an important direction. The teacher is not expected to be better than the student on the target task; indeed, the student is explicitly expected to improve upon it through SFT. The pre-trained model supplies a low-resolution constraint on the update rather than a target solution. This also distinguishes Ambient SFT from parameter-space anchoring such as L2-SP: the regularizer acts on conditional distributions and has a temperature-dependent geometry rather than penalizing Euclidean distance between weights.

Theoretical results

High-temperature supervision remains identifiable

The first theorem establishes that temperature matching is equivalent to maximum-likelihood training on samples drawn from the teacher at temperature TT. For fixed prefixes, the KL term differs from the cross-entropy under the teacher’s temperature-scaled conditional by an additive entropy constant independent of the student. Consequently, minimizing the matching term is equivalent to learning from high-temperature teacher samples without requiring access to teacher logits.

The result is stronger than equivalence at the selected temperature. If a student exactly matches the teacher’s conditional distribution at any finite temperature T>0T>0, then it matches the teacher at every temperature. In logit space, the student and teacher logits can differ only by a context-dependent additive constant, which leaves all temperature-scaled softmax distributions unchanged.

This explains a potentially counterintuitive empirical phenomenon: samples generated at high temperature can appear nonsensical while still retaining sufficient information to identify the underlying conditional distribution. The paper illustrates this with a model trained exclusively on visibly corrupted, nonstandard text. Despite never observing a conventional English sentence, the model trained with the temperature-matching objective produces coherent generations.

Figure 2

Figure 2: High-temperature training data can appear nonsensical while temperature-matching training recovers coherent generations.

The implication is that the teacher’s high-temperature distribution is not useful because its samples are semantically faithful at the token level. It is useful because temperature corruption preserves relative logit structure in a form that remains statistically informative.

Temperature contracts teacher–target discrepancies

The second theoretical result justifies using the pre-trained model as a proxy for the unavailable post-training distribution. Let Δ(x<i)\Delta(x_{<i}) denote the range across vocabulary items of the difference between post-trained and pre-trained logits at a fixed context. The paper proves

DKL(pTθpost  ∥  pTθpre)≤Δ(x<i)28T2.D_{\mathrm{KL}} \left( p_{T\theta_{\mathrm{post}}} \;\middle\|\; p_{T\theta_{\mathrm{pre}}} \right) \leq \frac{\Delta(x_{<i})^2}{8T^2}.

Thus, for every context, the discrepancy between the two models’ temperature-scaled conditionals contracts at rate O(T−2)O(T^{-2}). Temperature does not make the teacher more accurate in the ordinary sense; rather, it suppresses the component of the teacher’s error that would otherwise make the regularizer conflict with the target task.

The result formalizes the bias–variance interpretation of Ambient SFT. At low temperature, the teacher provides a strong but potentially misaligned constraint. At high temperature, the teacher’s mismatch is reduced, but so is the strength of the regularization signal. The useful operating point is therefore generally finite and task-dependent.

Log-linear bias–variance analysis

The paper analyzes this trade-off in a log-linear next-token model with fixed token embeddings and fixed contextual features. This model is substantially simpler than a transformer, and the result should be interpreted as a statistical characterization of the regularizer rather than a complete theory of neural-network fine-tuning.

Within this model, the clean SFT term has Fisher curvature FF, while the temperature-matching term contributes curvature HTH_T. The estimated parameter incurs two leading-order errors:

  • a squared bias caused by shrinking toward the pre-trained parameter; and
  • a variance reduction caused by additional curvature supplied by the teacher.

Under the local regime in which the pre-trained/post-trained parameter gap is O(n−1/2)O(n^{-1/2}), the expected squared estimation error has the expansion

ρ(λ,T)=λ2∥(F+λHT)−1HTB∥F2+1ntr⁡[(F+λHT)−1F(F+λHT)−1]+O(n−3/2),\rho(\lambda,T) = \lambda^2 \left\| (F+\lambda H_T)^{-1}H_TB \right\|_F^2 + \frac{1}{n} \operatorname{tr} \left[ (F+\lambda H_T)^{-1} F (F+\lambda H_T)^{-1} \right] + O(n^{-3/2}),

where BB is the teacher–target parameter gap. The first term is the regularization bias and the second is the sampling variance.

The result makes precise why teacher matching can outperform maximum likelihood in data-limited regimes. At λ=0\lambda=0, introducing a small amount of matching reduces variance to first order, whereas the bias appears only at second order in λ\lambda. Excessive matching eventually produces the frozen-teacher risk. Therefore, an intermediate regularization strength can dominate both ordinary SFT and the teacher itself.

More strongly, under a non-degeneracy condition on the temperature-dependent curvature and outside a closed measure-zero cone of teacher gaps, some finite T≠1T\neq1 strictly outperforms maximum likelihood, the frozen teacher, and the best T=1T=1 knowledge-distillation solution. The qualification matters: the theorem does not claim that every teacher gap benefits from a temperature different from one. The paper gives an explicit aligned example in which T=1T=1 is the unique optimum within the considered family.

The analysis also shows why temperature is more than a scalar confidence parameter. In the eigenbasis of the curvature matrices, λ\lambda controls the overall scale of shrinkage while TT changes its directional geometry. The best penalty should be stronger in directions where the teacher is accurate and weaker where it is inaccurate. A single T=1T=1 distillation penalty generally cannot realize this geometry.

Synthetic recovery experiments

The authors first test whether high-temperature training can recover a clean distribution. A model is trained on a clean corpus, used to generate corrupted data at various temperatures, and then retrained using either ordinary cross-entropy or the temperature-matching objective. Validation perplexity is measured on clean data.

On Tiny Shakespeare, Ambient SFT maintains comparatively low clean-data perplexity across a substantially wider range of corruption temperatures than ordinary cross-entropy. The full sweep includes temperatures below and above one: low temperatures yield repetitive samples, whereas high temperatures yield noisy samples. In both regimes, ordinary training degrades more rapidly than the matching objective.

Figure 3

Figure 3

Figure 3: Temperature matching preserves clean-data validation performance over a broader corruption range than ordinary cross-entropy.

A larger GPT-2 experiment uses approximately 9 billion tokens of OpenWebText to produce high-temperature synthetic data. The resulting model generates coherent text despite being trained on data that appears locally gibberish. This experiment directly supports the theorem’s identifiability claim, although it does not establish that the same recovery behavior persists under realistic distribution shift or finite-capacity mismatch.

Domain adaptation

The first substantive application is adaptation from generic OpenWebText to five target domains: Python code, computer science text, biomedical text, news, and product reviews. The main model contains 1.5 billion parameters, and each target domain contains approximately 225 million tokens. The comparisons include training from scratch, target-only fine-tuning, data-mixture fine-tuning, and Ambient SFT.

Ambient SFT matches or improves upon the best baseline on every domain. The strongest result occurs on News, where validation loss decreases from $1.99$ for the best baseline to $1.68$, corresponding to a reported 26.7%26.7\% relative perplexity improvement. The complete validation losses are:

Method Python code CS Biomedical News Reviews
Target-only fine-tuning 0.80 2.56 2.36 2.01 2.96
Data-mixture fine-tuning 0.79 2.55 2.36 1.99 2.96
Ambient SFT 0.70 2.54 2.35 1.68 2.96

The gains correlate strongly with the teacher’s zero-shot competence on the target domain. Across the five domains, the Spearman correlation between pre-fine-tuning validation loss and Ambient SFT’s win margin is ρ=−0.90\rho=-0.90. This is consistent with the theoretical bias term: the teacher is most useful where it already represents the target domain reasonably well. Conversely, when the teacher is poorly matched to the target, stronger reliance on it is less beneficial.

The temperature sweep on Python code reaches its minimum validation loss at approximately T=2.5T=2.5, while both T=1T=1 and the high-temperature limit are inferior.

Figure 4

Figure 4: Ambient SFT’s domain-adaptation performance depends non-monotonically on temperature, with an intermediate temperature outperforming both knowledge distillation and ordinary SFT.

The data-scaling ablation further supports the proposed mechanism. Ambient SFT consistently improves over data-mixture fine-tuning, and the margin widens as the target-domain dataset shrinks. This behavior is precisely what the log-linear analysis predicts: the variance term grows in importance as the number of target observations decreases, whereas the teacher-induced bias does not decrease at the same rate.

The teacher-capacity experiments produce a notable result: a 124M frozen teacher can improve a 1.5B student over ordinary fine-tuning on Python code and News. This is contrary to the usual expectation for classical knowledge distillation, where the teacher is normally stronger than the student on the target task. The result is coherent with Ambient SFT’s interpretation of the teacher as a structural regularizer rather than an authority over the target distribution.

Instruction tuning and catastrophic forgetting

The instruction-tuning experiments use approximately 21,000 examples, corresponding to 1%1\% of Dolci-Instruct-SFT, and evaluate Qwen3 models from 1.7B to 14B parameters on eight benchmarks spanning instruction following, knowledge, mathematics, code, and general reasoning.

Vanilla SFT substantially improves instruction following but degrades most other capabilities. For example, at the 4B scale, IFEval rises from 45.5%45.5\% to 76.3%76.3\%, while the model loses performance on MATH, MMLU, PopQA, TriviaQA, HumanEval+, and BBH. Ambient SFT reduces this trade-off. Its average relative improvement over vanilla SFT ranges from 8.0%8.0\% to 20.3%20.3\% across model sizes, with the largest improvement at 1.7B parameters.

Model Vanilla SFT average relative baseline Ambient SFT average relative improvement
Qwen3-1.7B — +20.3%
Qwen3-4B — +8.0%
Qwen3-8B — +10.2%
Qwen3-14B — +8.7%

At 1.7B parameters, Ambient SFT improves MATH from $24.3$ to $40.4$, GSM8K from $61.0$ to $72.3$, and HumanEval+ from $68.0$ to $83.7$, while preserving much of the base model’s knowledge performance. At 8B parameters, Ambient SFT reaches $53.5$ on MATH compared with $38.7$ for vanilla SFT. The improvement is not restricted to Qwen3: the method also improves over SFT on OLMo-3-7B and Llama-3.1-8B, with reported average relative gains of 15.4%15.4\% and 8.3%8.3\%, respectively.

The principal exception is IFEval. Ambient SFT generally trails vanilla SFT on this benchmark when a single global temperature is used. The paper attributes this to heterogeneity among the 21 instruction-data sources: the base model fits some sources well and others poorly. A per-source temperature heuristic, which raises TT for sources on which the base model has a larger prediction–entropy gap, improves IFEval while retaining the other gains. For Qwen3-1.7B, the average relative improvement rises from 20.3%20.3\% to 21.1%21.1\%.

The data-scale results show the expected dependence on supervision scarcity. At 1%1\% of Dolci-Instruct-SFT, Ambient SFT obtains an average relative improvement of 15.4%15.4\% over vanilla SFT; at 10%10\%, the improvement decreases to 3.4%3.4\%; at the full dataset scale, it remains 8.6%8.6\% under the reported training protocol.

Figure 5

Figure 5: Ambient SFT yields its largest average gains in the lowest-data regime, although improvements remain visible at larger data scales.

The epoch sweep provides a more direct test of overfitting. With 10%10\% of the instruction dataset, vanilla SFT improves IFEval from $71.0$ to $80.8$ between two and six epochs, but simultaneously decreases MATH from $37.3$ to $30.0$, GSM8K from $76.4$ to $69.6$, HumanEval+ from $81.3$ to $75.5$, and BBH from $62.8$ to $58.9$. Ambient SFT increases IFEval from $63.8$ to $73.4$ over the same interval while keeping the other benchmarks within approximately two points of their two-epoch values.

Figure 6

Figure 6: Ambient SFT is less sensitive to additional instruction-tuning epochs and attenuates the capability–forgetting trade-off exhibited by vanilla SFT.

The comparison with alternative regularizers is also informative. On Qwen3-1.7B, the reported average relative improvements over vanilla SFT are +0.8%+0.8\% for NEFTune, +15.3%+15.3\% for L2-SP, +17.0%+17.0\% for T=1T=1 knowledge distillation, and +20.3%+20.3\% for Ambient SFT. The comparison indicates that the gain is not explained merely by adding noise or constraining parameter movement toward the initialization. The temperature-dependent distributional geometry contributes materially.

Reasoning post-training

The reasoning experiments use OLMo-3-7B trained on approximately 22,000 examples, or 1%1\% of Dolci-Think-SFT. Ambient SFT outperforms vanilla SFT on five of six benchmarks and trails by only $1.2$ points on GSM8K.

Benchmark Vanilla SFT Ambient SFT
GSM8K 94.2 93.0
AIME 2024 39.8 44.5
AIME 2025 33.2 34.1
GPQA 39.3 40.0
IFEval 34.6 36.0
HumanEval+ 75.6 76.9

The average relative improvement is +3.5%+3.5\%, smaller than in domain adaptation and instruction tuning. This difference is important: the method’s benefit is not uniform across post-training objectives. Ambient SFT improves reasoning scores modestly while preserving or improving knowledge performance. On separate knowledge evaluations, it exceeds vanilla SFT on MMLU, GSM8K, TriviaQA, and BBH.

Figure 7

Figure 7: Ambient SFT’s epoch behavior on the remaining reasoning and capability benchmarks shows improved robustness relative to vanilla SFT.

The negative results for other regularizers are also notable. In this setup, both T=1T=1 knowledge distillation and L2-SP regress relative to vanilla SFT on the aggregate reasoning score, whereas Ambient SFT improves it. This supports the paper’s claim that the temperature parameter is not a cosmetic modification of conventional anchoring.

Limitations and open questions

The strongest theoretical claims are established only under restricted assumptions. The exact risk expansion uses a log-linear conditional model with frozen features, bounded parameters and embeddings, independent prefix sampling, and a local teacher–target discrepancy of order n−1/2n^{-1/2}. These conditions make the bias–variance calculation tractable but do not directly characterize transformer fine-tuning, representation learning, optimizer dynamics, or large distribution shifts.

The empirical studies also rely substantially on hyperparameter selection. Temperature and the clean-loss probability are tuned on validation data in the domain-adaptation experiments, while instruction tuning fixes T=2.5T=2.5 and pc=0.75p_c=0.75 across several model sizes. The per-source temperature rule is explicitly heuristic, and the paper does not establish that its source-level confidence statistic is optimal or calibrated. The method’s computational overhead, although small in the reported equal-sized setting, may become significant when the teacher is larger or when memory bandwidth and activation storage dominate.

Several reported differences are close to experimental uncertainty. In the small-student domain-adaptation results, the paper notes run-to-run standard deviations of approximately $0.003$–$0.006$ across two checked domains, so losses differing only in the second decimal place should not be overinterpreted. More generally, the benchmark evaluations use single training seeds for instruction tuning, and some reasoning scores are obtained through stochastic generation.

The method also depends on the teacher retaining useful information about the target domain. The strong negative correlation between zero-shot loss and win margin suggests a practical failure mode: when the pre-trained model is substantially mismatched to the target, the teacher may provide little useful regularization or may require a much larger temperature. The paper’s own source-specific temperature experiment indicates that a single global temperature can be inadequate for heterogeneous datasets.

The paper leaves open how to select TT and λ\lambda without extensive validation sweeps, whether teacher confidence can be estimated reliably online, and whether the same mechanism remains effective when the target distribution differs sharply from the pre-training distribution. It also identifies but does not resolve the possibility that the optimal risk infimum is approached only in a limiting temperature regime rather than attained at finite (λ,T)(\lambda,T).

Conclusion

Ambient SFT regularizes data-efficient post-training by matching the student to the pre-trained model only after temperature smoothing. Its theoretical analysis establishes three properties central to the method: high-temperature matching retains identifiable distributional information, temperature contracts discrepancies between pre-trained and post-trained conditionals at rate O(T−2)O(T^{-2}), and an intermediate bias–variance trade-off can outperform both ordinary SFT and standard knowledge distillation.

Across domain adaptation, instruction tuning, and reasoning, the empirical results support this account. The largest gains occur under limited supervision, including a 26.7%26.7\% relative perplexity improvement on the News domain, average instruction-tuning improvements up to 20.3%20.3\%, and wins on five of six reasoning benchmarks. The principal unresolved question is how to determine temperature and teacher weight from measurable distributional properties, particularly when post-training data combine sources on which the base model has widely varying competence.

Whiteboard

Explain it Like I'm 14

1. What is this paper about?

This paper introduces a new way to train LLMs, called Ambient SFT.

LLMs are usually trained in two main steps:

  1. Pre-training: The model reads a huge amount of general text, such as books, websites, and articles.
  2. Fine-tuning: The model studies a much smaller collection of special examples, such as instructions, computer code, medical writing, or reasoning problems.

The problem is that the fine-tuning dataset is often small. If the model focuses too much on this small dataset, it may become good at the new task but forget some of what it learned before. This is called catastrophic forgetting.

The paper asks:

Can we teach a model new skills without making it forget its old knowledge, especially when only a small amount of new training data is available?

The authors propose Ambient SFT as a solution.

2. What are the main research questions?

The researchers mainly want to find out:

  • Can a LLM learn effectively from a small fine-tuning dataset?
  • Can it avoid overfitting, which means memorizing the small dataset too closely?
  • Can it preserve knowledge from its original training?
  • Is it better to use the original model as a guide while training the new model?
  • What is the best amount of trust to place in the original model?
  • Does the method work for different goals, such as:
    • adapting to a new subject,
    • following instructions,
    • solving reasoning problems?

3. How does Ambient SFT work?

Ordinary supervised fine-tuning

In normal supervised fine-tuning, a model is shown examples and asked to predict the next word or token.

For example, if the training sentence is:

“The cat sat on the…”

the correct next word might be:

“mat.”

The model changes its settings so that it becomes more likely to predict “mat” in that situation.

This works well, but with a small dataset the model can become too focused on the examples it sees. It may improve on the new task while losing older abilities.

Using the original model as a teacher

Ambient SFT keeps a frozen copy of the original pre-trained model. This copy is called the teacher. The model being trained is called the student.

The student receives two kinds of guidance:

  1. The actual answer in the fine-tuning data. This teaches the new skill.
  2. The general predictions of the original model. This reminds the student of the knowledge and behavior it had before fine-tuning.

The teacher does not force the student to copy every prediction exactly. Instead, the student matches the teacher’s predictions after they have been softened using a temperature.

What does temperature mean?

A model normally gives different probabilities to possible next tokens. For example:

Possible next word Normal probability
mat 90%
floor 7%
chair 2%
tree 1%

A higher temperature makes the predictions less certain and spreads probability more evenly:

Possible next word High-temperature probability
mat 45%
floor 30%
chair 15%
tree 10%

This softer prediction contains more information about the model’s alternatives. It tells the student not only which answer the teacher prefers, but also which other answers are somewhat reasonable.

The temperature controls how strongly the student listens to the teacher:

  • At temperature 1, the student uses ordinary knowledge distillation, meaning it tries to copy the teacher fairly closely.
  • At a very high temperature, the teacher’s predictions become almost uniform, so the teacher has little effect. The method becomes ordinary fine-tuning.
  • At an intermediate temperature, the student learns the new material while still receiving useful reminders from the original model.

The authors call the extra training term Temperature Matching.

An everyday analogy

Imagine a student preparing for a new exam with only a small number of practice questions.

  • Ordinary fine-tuning is like studying only those practice questions.
  • The original model is like an older tutor who remembers many other subjects.
  • Ambient SFT lets the student study the new questions while occasionally checking with the tutor about the broader topic.

The tutor does not give the exact answer every time. Instead, the tutor gives a list of likely answers with different levels of confidence. This helps the student learn the new subject without forgetting everything else.

4. What methods did the researchers use?

The paper combines mathematical analysis with computer experiments.

Mathematical analysis

The researchers prove several facts about their method:

  • Even predictions made with a high temperature still contain useful information.
  • If two models’ predictions are softened enough, their predictions become more similar.
  • This makes the original model a useful, approximate guide for the new model.
  • In a simplified mathematical model, Ambient SFT can have lower error than:
    • ordinary fine-tuning,
    • copying the original model,
    • standard knowledge distillation.

The authors describe the balance as a trade-off between:

  • Bias: Trusting the old model too much and not learning enough new information.
  • Variance: Trusting the small fine-tuning dataset too much and overfitting it.

Temperature helps control this balance.

Computer experiments

The researchers tested Ambient SFT in three major settings:

  1. Domain adaptation: Teaching a model to work with specific kinds of text.
  2. Instruction tuning: Teaching a model to follow user instructions.
  3. Reasoning: Teaching a model to solve problems involving mathematics, coding, and logic.

They compared Ambient SFT with several other methods, including:

  • ordinary fine-tuning,
  • mixing old and new training data,
  • knowledge distillation,
  • keeping the model close to its original settings,
  • label smoothing and other regularization techniques.

They tested different model sizes and different amounts of training data.

5. What did the researchers find?

Ambient SFT helped with domain adaptation

The method was tested on five areas:

  • Python code,
  • computer science papers,
  • biomedical writing,
  • news,
  • product reviews.

Ambient SFT matched or beat the other methods in all five areas. Its largest improvement was on news text, where it reduced the model’s prediction error by up to 26.7% compared with the best competing method.

The method was especially helpful when the new dataset was small. As the dataset became smaller, the advantage of Ambient SFT became larger.

It reduced catastrophic forgetting during instruction tuning

Ordinary fine-tuning made models better at following instructions, but it often caused them to lose abilities in mathematics, coding, general knowledge, and reasoning.

Ambient SFT usually improved instruction following while preserving more of these other abilities.

For example, when training a small model with limited instruction data, Ambient SFT produced an average improvement of about 20.3% over ordinary fine-tuning. For larger models, the improvement was still between about 8% and 10% in many tests.

The method worked on different model families, including Qwen, OLMo, and Llama models.

It helped reasoning abilities

For reasoning tasks, Ambient SFT performed better than ordinary fine-tuning on 5 out of 6 tests.

It improved results on tasks involving:

  • advanced mathematics,
  • general questions,
  • instruction following,
  • computer programming.

The improvement was smaller than in domain adaptation and instruction tuning, but it still showed that the method can help models learn reasoning skills without damaging their other abilities.

A medium temperature worked best

The researchers found that neither extreme was ideal:

  • Temperature 1, which is standard knowledge distillation, was not the best choice.
  • An extremely high temperature removed most of the teacher’s influence.
  • A temperature around 2.5 often worked well in their experiments.

This supports the paper’s main idea: the student should listen to the original model, but not copy it too strongly.

The method costs slightly more computing power

Ambient SFT requires an extra prediction step from the frozen teacher model. This makes training about 10% slower in the authors’ usual setup.

Therefore, the method is most useful when training data is scarce, rather than when computer time is the main limitation.

6. Why are these results important?

The results suggest that LLMs do not always need huge amounts of new training data to learn effectively.

Usually, developers may try to solve limited-data problems by collecting more and more examples. That can be expensive and difficult, especially for expert topics such as medicine, science, or advanced reasoning.

Ambient SFT offers another possibility:

  • use a small amount of carefully chosen new data,
  • keep the original model’s broad knowledge as a guide,
  • reduce forgetting and overfitting,
  • improve several skills at once.

The method is also simple to add to existing fine-tuning systems because it is a small change to the training objective rather than a completely new model design.

7. Conclusion and possible impact

The paper presents Ambient SFT as a way to make language-model training more data-efficient.

Its central idea is:

Train the model on the new examples, but also ask it to remember the general patterns it learned before.

The original model acts as a soft guide rather than a strict teacher. Using a carefully chosen temperature allows the new model to learn new abilities while preserving older ones.

If the findings continue to hold for larger and more varied models, Ambient SFT could make it cheaper and safer to adapt LLMs to new subjects, instructions, and reasoning tasks. It may be particularly useful in areas where high-quality training examples are rare or expensive to collect.

However, the method is not a complete solution to every problem. It requires extra computation, and the best temperature may depend on the model and the training data. Even so, the paper shows that a model’s own previous knowledge can be used to protect it while it learns something new.

Practical Applications

Immediate Applications

  • Data-efficient domain adaptation for specialized LLMs — Industry / Software
    • Apply Ambient SFT when adapting a general-purpose LLM to domains such as software code, biomedical literature, legal documents, financial reports, news, or product reviews using relatively small target datasets.
    • A practical workflow is to initialize a student from a pretrained model, retain a frozen copy as the teacher, and optimize:
    • 1. standard next-token cross-entropy on the target-domain data; and
    • 2. a temperature-matching KL term between teacher and student predictions.
    • This can produce domain-specific models with lower validation perplexity while reducing degradation on general language capabilities. The paper reports especially large gains for code and news adaptation, including up to a 26.7% relative perplexity improvement over the best baseline in one setting.
    • Dependencies and assumptions: the pretrained model must already contain useful knowledge of the target domain; performance is expected to improve most when target data is scarce and the model’s zero-shot target-domain perplexity is reasonably low. An additional teacher forward pass increases training cost by approximately 10% in the reported configuration.
  • Low-data instruction tuning for commercial and open-source assistants — Industry / Software
    • Replace vanilla SFT in the training pipeline for chatbots, coding assistants, enterprise copilots, and customer-service agents when only a few thousand high-quality instruction-response examples are available.
    • Ambient SFT can preserve pretrained knowledge in areas such as factual recall, mathematics, coding, and general reasoning while still improving instruction-following behavior.
    • A practical implementation can use the paper’s reported starting point of approximately pc=0.75p_c=0.75 and T=2.5T=2.5, followed by validation-based tuning. For heterogeneous instruction datasets, separate temperatures can be selected for different data sources.
    • Potential products and workflows: compact enterprise assistants trained on proprietary examples without requiring extensive synthetic or human-labeled datasets; safer model customization pipelines that reduce knowledge loss; and model adaptation services for organizations with limited data.
    • Dependencies and assumptions: the base model must support access to logits or token distributions, and the instruction data must be sufficiently representative of the desired behavior. The method does not guarantee that every capability improves; in the experiments, instruction-following scores could lag vanilla SFT unless temperatures were adjusted per source.
  • Preserving general capabilities during alignment and post-training — Industry / Model governance
    • Use temperature matching as a regularization layer in alignment pipelines to reduce catastrophic forgetting, sometimes called the alignment tax.
    • Organizations can evaluate both target-task performance and retention of pretrained capabilities during post-training, rather than relying only on instruction-following benchmarks.
    • Potential tool: a post-training dashboard that jointly tracks target behavior, factual knowledge, reasoning, coding, and domain perplexity across training checkpoints.
    • Dependencies and assumptions: the frozen pretrained model is treated as a useful prior, not as an authoritative source of truth. If the base model contains serious biases, unsafe knowledge, or systematic errors, temperature matching may preserve those properties.
  • Reasoning-model fine-tuning with small supervised datasets — Industry / Academia
    • Apply Ambient SFT to mathematical reasoning, scientific question answering, code generation, and chain-of-thought-style datasets when reasoning examples are expensive to curate.
    • The experiments show improvements over vanilla SFT on five of six reasoning benchmarks and improved robustness to prompting, suggesting a practical use in training reasoning-capable assistants without sacrificing the model’s pretrained competencies.
    • Potential products: lightweight domain-specific reasoning models for tutoring, scientific search, coding, and technical support.
    • Dependencies and assumptions: reasoning improvements were smaller than those observed for domain adaptation and instruction tuning. Results depend on the quality of reasoning demonstrations and should be verified for factuality, calibration, and susceptibility to prompt variation.
  • Post-training smaller models as alternatives to larger models — Industry / Energy / Software
    • Use Ambient SFT to obtain the performance of a larger vanilla-SFT model with a smaller student model and limited data. The paper reports cases where Ambient SFT at smaller scales approaches or exceeds vanilla SFT at larger scales on selected benchmarks.
    • This could reduce inference cost, memory use, latency, and energy consumption in deployed applications.
    • Dependencies and assumptions: benchmark gains may not transfer directly to production workloads. The student must have sufficient capacity, and the method still requires an additional training-time forward pass; the main savings occur during inference and data collection, not necessarily during training.
  • A drop-in regularization component for existing SFT infrastructure — Software / Industry
    • Integrate Ambient SFT into current supervised fine-tuning systems without changing the model architecture or requiring access to the original pretraining corpus.
    • The frozen teacher can be a copy of the original base model, and the method can be implemented through stochastic alternation between clean cross-entropy updates and temperature-matching updates.
    • Potential tools: Hugging Face-style trainer plugins, distributed-training loss modules, hyperparameter sweeps over temperature TT and mixing probability pcp_c, and checkpoint-selection systems based on retention metrics.
    • Dependencies and assumptions: the implementation must correctly compute temperature-scaled logits and the KL divergence over the vocabulary. Memory availability may be a constraint because both student and teacher are used during training.
  • Data-efficiency diagnostics for model customization — Industry / Academia
    • Measure the base model’s zero-shot perplexity on a target corpus before committing to an adaptation strategy.
    • According to the paper, lower initial target-domain loss is strongly associated with larger Ambient SFT gains. This provides an inexpensive screening procedure for deciding whether to use Ambient SFT, data mixing, additional data collection, or conventional SFT.
    • Dependencies and assumptions: the reported correlation was obtained across five domains and may not generalize to highly different model architectures, languages, or task formats. Perplexity is also less informative for non-linguistic objectives or tasks where success is primarily behavioral rather than distributional.
  • Academic experimentation on learning from noisy or corrupted data — Academia
    • Use the method as an experimental framework for studying whether high-temperature, noisy samples retain information about an underlying language distribution.
    • Researchers can investigate model identifiability, robustness to corrupted supervision, and the relationship between sampling temperature, bias, and variance.
    • Potential outputs: educational demonstrations of how apparently nonsensical training samples can still encode recoverable statistical structure; benchmark suites for noisy-data learning; and empirical comparisons between self-distillation, label smoothing, and regularization.
    • Dependencies and assumptions: the exact theoretical recovery results rely on autoregressive distributions with full support and idealized optimization or log-linear assumptions. Neural-network behavior outside these settings may differ.
  • Personalized local assistants with limited private data — Daily life / Privacy
    • Fine-tune a general LLM on a user’s small collection of writing, notes, workflows, or preferences while retaining broad language and reasoning abilities.
    • Ambient SFT could reduce overfitting to a narrow personal style and lower the risk that the assistant loses general capabilities after personalization.
    • Dependencies and assumptions: the base model must already possess the desired general capabilities; privacy-preserving training and secure storage remain necessary. Temperature matching does not itself prevent memorization of sensitive personal examples or eliminate privacy risks.

Long-Term Applications

  • Continual learning across many domains and tasks — Industry / Academia
    • Extend Ambient SFT to sequentially adapt one model to multiple domains, languages, products, or user groups while using the original or periodically updated model as a stabilizing teacher.
    • A future continual-learning system could select a temperature based on domain similarity, teacher confidence, or measured zero-shot perplexity, and maintain a library of teacher checkpoints.
    • Dependencies and assumptions: the paper studies a single post-training stage more directly than long sequences of adaptations. Repeated teacher regularization could preserve outdated behavior, and methods are needed for handling changing knowledge, task conflicts, and distribution drift.
  • Adaptive or token-level temperature matching — Long-Term / Software
    • Develop systems in which TT varies by domain, data source, context, token type, uncertainty, or training stage rather than using one global temperature.
    • High temperatures could be used where the base model is reliable or where data is extremely sparse, while lower temperatures—or no matching term—could be used for newly introduced facts and behaviors.
    • Potential tools: uncertainty-aware training schedulers, source-specific temperature controllers, and token-level gates that determine when the teacher should influence the student.
    • Dependencies and assumptions: reliable uncertainty estimates and stable optimization are required. Incorrectly assigning high trust to the base model could suppress genuinely useful new information.
  • Federated and privacy-preserving model personalization — Healthcare / Finance / Enterprise
    • Use Ambient SFT to adapt a shared model to hospitals, banks, legal practices, or individual devices using small local datasets while limiting the need to transmit raw examples.
    • The frozen base model can act as a common prior, and each institution can train a local student using its private target data.
    • Dependencies and assumptions: federated optimization, differential privacy, secure aggregation, and regulatory validation would be required. Temperature matching may preserve sensitive biases in the base model and does not by itself address cross-client distribution differences.
  • Specialized healthcare, scientific, and legal assistants — Healthcare / Science / Policy
    • Build assistants for clinical documentation, biomedical literature analysis, scientific research, or legal drafting from small expert-curated datasets while retaining broad language competence.
    • Ambient SFT is particularly relevant where expert annotations are expensive and catastrophic forgetting could remove general knowledge needed for safe operation.
    • Potential products: literature triage tools, clinical coding assistants, research copilots, and legal document-analysis systems.
    • Dependencies and assumptions: high-stakes deployment requires factuality testing, calibration, auditability, human review, data governance, and domain-specific safety evaluation. The method improves distributional fitting but does not establish clinical or legal correctness.
  • Policy and public-sector language-model adaptation — Policy / Government
    • Adapt open or foundation models to public-sector terminology, administrative procedures, regulatory documents, and multilingual government services using relatively small curated corpora.
    • Temperature matching could help preserve broad reasoning and language skills while reducing the need to collect massive government-specific post-training datasets.
    • Dependencies and assumptions: public-sector deployments require transparency, reproducibility, bias audits, records-management compliance, and validation against changing laws and policies. A frozen teacher may encode outdated or inappropriate assumptions.
  • Cost-aware training and model lifecycle management — Industry / Energy
    • Incorporate the method into decisions about whether to collect more post-training data, increase model size, or spend additional compute.
    • A lifecycle system could estimate:
    • target-domain zero-shot perplexity;
    • the amount of available target data;
    • teacher-student compute cost;
    • expected retention of general capabilities; and
    • the projected benefit of Ambient SFT versus data mixing or larger-scale annotation.
    • Dependencies and assumptions: the paper demonstrates data-efficiency benefits but does not provide a complete economic or carbon accounting model. For compute-limited rather than data-limited organizations, the extra teacher pass may outweigh the gains.
  • Knowledge-preserving model editing and targeted behavioral updates — Software / Safety
    • Combine temperature matching with controlled updates for new policies, product information, or organizational procedures, attempting to introduce a narrow change without broadly altering the model.
    • This could support regular updates to assistants while retaining general competencies.
    • Dependencies and assumptions: the method is not a complete model-editing technique and may not guarantee locality of changes. Additional mechanisms are needed to verify that updates affect only intended concepts and do not preserve obsolete or unsafe information.
  • Multilingual and low-resource language adaptation — Education / Government / Global software
    • Apply Ambient SFT to adapt multilingual models to low-resource languages or regional varieties where only small amounts of high-quality text are available.
    • This could support translation, educational tutoring, government access, and local-language conversational systems.
    • Dependencies and assumptions: the pretrained model must contain enough representation of the target language for the teacher to be useful. Language imbalance, script differences, tokenizer coverage, and culturally specific evaluation criteria may limit effectiveness.
  • Automated post-training controllers and foundation-model training platforms — Long-Term / Industry
    • Build automated systems that choose between vanilla SFT, Ambient SFT, knowledge distillation, data mixing, or additional data collection based on validation results and resource constraints.
    • Such a platform could search jointly over TT, λ\lambda or pcp_c, training duration, student size, teacher size, and data-source weights.
    • Dependencies and assumptions: robust multi-objective evaluation is required because improvements on one benchmark may correspond to regressions on another. Automated selection must also account for safety, fairness, factuality, privacy, and production-specific metrics rather than perplexity alone.
  • Broader applications beyond LLMs — Long-Term / Robotics / Vision / Multimodal AI
    • Investigate whether the central idea—learning a new task from sparse clean data while matching softened predictions from a pretrained model—transfers to vision, speech, robotics, multimodal models, and reinforcement learning.
    • Possible examples include adapting a robot to a new environment while preserving prior behaviors, tuning a vision model to a new medical imaging domain, or personalizing speech recognition with limited recordings.
    • Dependencies and assumptions: the current theoretical and empirical evidence is for autoregressive LLMs. Other modalities may require different notions of temperature, probability smoothing, trajectory matching, or teacher confidence, and the effectiveness of the approach remains to be established.

Glossary

  • Alignment tax: The loss of general capabilities that can result from aligning a LLM to specific preferences or tasks. “This phenomenon is known as the alignment tax”
  • Ambient Diffusion: A framework for training generative diffusion models from corrupted or incomplete observations. “The name connects to Ambient Diffusion”
  • Ambient SFT: The proposed supervised fine-tuning method that combines ordinary next-token training with high-temperature distribution matching. “Our algorithm, termed Ambient SFT, mitigates the overfitting typically observed when applying Supervised Fine-Tuning (SFT) to small datasets.”
  • Autoregressive model: A model that represents a sequence distribution as a product of conditional distributions over successive tokens. “Let pθ∗p_{\theta^*} be any AR model over VlV^l”
  • Bias–variance trade-off: The statistical compromise between systematic error from model assumptions and variability caused by limited data. “In Ambient SFT, the temperature controls a bias-variance trade-off”
  • Catastrophic forgetting: The abrupt loss of previously learned information when a model is trained on new data. “post-trained LLMs tend to suffer from catastrophic forgetting at the tails of the pre-training data distribution”
  • Conditional distribution: A probability distribution over an outcome given an observed context or condition. “we require that the high-temperature versions of the conditional distributions produced by the post-training model should match the high-temperature versions of the pre-training ones.”
  • Contraction mechanism: A process that reduces differences between distributions as a transformation is applied. “Temperature scaling as a contraction mechanism”
  • Cross-entropy: A loss measuring the discrepancy between a target probability distribution and a model’s predicted distribution. “Eq.~\eqref{eq:normal_loss} computes the cross-entropy between the model's predicted distribution and the target distributions”
  • Data adaptation: The process of adapting a model trained on one distribution or domain to another target domain. “We proceed to post-training experiments, beginning with domain adaptation”
  • Data mixture fine-tuning: Fine-tuning that combines examples from the original pre-training distribution with examples from a target distribution. “data-mixing (where we split training updates between the pre-training domain and the target domain)”
  • Data-efficient fine-tuning: Fine-tuning designed to achieve strong performance using relatively few training examples. “Data-Efficient Supervised Fine-tuning via Temperature Matching”
  • Empirical distribution: A distribution constructed from a finite sample, assigning probability according to observed data frequencies. “We denote this empirical distribution with p^n1\hat p_{n_1}.”
  • Fisher information matrix: A matrix describing the curvature of a likelihood objective and the information that data provide about model parameters. “FF is the Fisher information matrix controlling the curvature of the first term in the loss function.”
  • Frozen teacher: A teacher model whose parameters are kept fixed while a student model is trained. “the teacher $\theta^*_{\mathrm{pre}$ is frozen”
  • Full support: A probability distribution that assigns nonzero probability to every possible outcome. “For any two distributions p,qp, q that have full support”
  • Generative training: Training a model to represent or produce samples from a data distribution. “Typically, the success of the generative training depends on the size of n1n_1.”
  • Identifiability: The property that model parameters or a distribution can be uniquely determined from observable data. “The theorem shows that the distribution is identifiable from high-temperature data.”
  • Instruction tuning: Fine-tuning a LLM to follow natural-language instructions. “We start with pre-trained base models, ranging from $1.7$B to $14$B params, and we fine-tune them on the Dolci-Instruct-SFT”
  • Knowledge distillation: A training method in which a student model learns to reproduce the output distribution of a teacher model. “T=1T=1 to knowledge distillation.”
  • Kronecker product: A matrix operation that produces a block matrix from two input matrices or vectors. “⊗\otimes is the Kronecker product”
  • Label smoothing: A regularization technique that replaces one-hot target labels with softened probability distributions. “Ambient SFT outperforms other regularization methods.”
  • LLM: A large neural network trained on extensive text data to model and generate language. “The development of state-of-the-art LLMs”
  • Log-linear model: A probabilistic model whose log-probabilities are linear functions of feature representations. “Ambient SFT analysis under a log-linear model”
  • Logit: An unnormalized real-valued score assigned to a possible output before normalization into probabilities. “outputs logits for each potential token in the vocabulary”
  • Log-normalizer: The logarithm of the normalization factor that converts exponentiated scores into probabilities. “the logarithm of its denominator”
  • Maximum likelihood: A parameter-estimation principle that selects parameters maximizing the probability of the observed data. “the three terms inside the minimum being ρ(0,T)\rho(0,T), lim⁡λ→∞ρ(λ,T)\lim_{\lambda\to\infty}\rho(\lambda,T) and the best T=1T=1 run.”
  • Negative log-likelihood: The negative logarithm of the probability assigned to observed data, commonly used as a training loss. “The standard training objective targets the minimization of the population negative log-likelihood”
  • Oracle model: An idealized model assumed to provide access to an otherwise unavailable target distribution or prediction. “Imagine having access to an oracle LLM that can generate the high-quality post-training data distribution”
  • Overfitting: The degradation of generalization caused by fitting training-specific patterns rather than the underlying distribution. “Ambient SFT mitigates the overfitting typically observed when applying Supervised Fine-Tuning (SFT) to small datasets.”
  • Perplexity: An exponential transformation of average negative log-likelihood used to measure language-model prediction quality. “For News, the relative improvement in perplexity over the best baseline reaches 26.7%26.7\%”
  • Population objective: A loss defined as an expectation over the underlying data distribution rather than a finite dataset. “Let $R_T(\theta)=\sum_{i=1}{l}\mathbb E_{x_{<i}\sim\mu_i}”
  • Post-training: Training performed after pre-training to adapt a LLM to instructions, domains, alignment, or reasoning tasks. “This severe bottleneck arises because post-training requires extraordinarily high-quality data”
  • Pre-training distribution: The broad data distribution from which a model’s initial training corpus is drawn. “the tails of the pre-training data distribution”
  • Regularization: A method of constraining model training to improve generalization or prevent undesirable parameter changes. “a second term, which we call Temperature Matching, that regularizes the post-trained network”
  • Risk expansion: An asymptotic approximation expressing estimation error through bias, variance, and higher-order terms. “The next theorem quantifies how these quantities affect the estimation error.”
  • Sampling temperature: A scalar that controls the sharpness or randomness of a model’s output distribution. “known as the sampling temperature”
  • Spearman rank correlation: A statistic measuring the monotonic association between two ranked variables. “this heuristic gives a Spearman rank correlation of ρ=−0.90\rho=-0.90”
  • Supervised Fine-Tuning (SFT): Training a pre-trained model on labeled examples, typically using observed next-token targets. “Supervised Fine-Tuning (SFT) is typically applied to datasets significantly smaller than those used for pre-training”
  • Synthetic data: Artificially generated examples used for training or evaluation. “we use it to produce synthetic data at different temperatures as before.”
  • Temperature Matching: The loss that encourages a student model to match a frozen teacher’s temperature-scaled conditional distributions. “We refer to the full objective of Eq.~\eqref{eq:tm-objective} as Ambient SFT and to its second term as Temperature Matching.”
  • Temperature scaling: The modification of a model’s output distribution by dividing logits by a temperature parameter. “Adjusting the temperature.”
  • Tempered distribution: A probability distribution obtained by applying temperature scaling to another distribution. “Prefixes sampled from the tempered teacher are a special case”
  • Token embedding: A vector representation assigned to a token for use in a neural or statistical model. “Let ϕ:V→Rd\phi: V \to \mathbb R^d be a fixed token embedding”
  • Vanilla SFT: Ordinary supervised fine-tuning without the proposed temperature-matching regularizer. “Ambient SFT improves on Vanilla SFT on 7/8 tasks”
  • Variance: The component of estimation error caused by sensitivity to the particular sample used for training. “+\underbrace{\tfrac1n\operatorname{tr}!\big((F+\lambda H_T){-1}F(F+\lambda H_T){-1}\big)}_{\text{variance}”
  • Zero-shot loss: The loss measured on a target domain before the model has been fine-tuned on that domain. “a cheap and reliable predictor of the benefit is the model's perplexity on the target domain before fine-tuning.”

Open Problems

We found no open problems mentioned in this paper.

Tweets

Sign up for free to view the 5 tweets with 380 likes about this paper.