Improving Diversity in Language Models: When Temperature Fails, Change the Loss

Alexandre Verine, Florian Le Bronnec, Kunhao Zheng, Alexandre Allauzen, Yann Chevaleyre +1 more
8/13/2025
cs.CLcs.LG

No confident code implementation found for this paper. 5 possible matches can be shown below.

Abstract

Increasing diversity in language models is a challenging yet essential objective. A common approach is to raise the decoding temperature. In this work, we investigate this approach through a simplistic yet common case to provide insights into why decreasing temperature can improve quality (Precision), while increasing it often fails to boost coverage (Recall). Our analysis reveals that for a model to be effectively tunable through temperature adjustments, it must be trained toward coverage. To address this, we propose rethinking loss functions in language models by leveraging the Precision-Recall framework. Our results demonstrate that this approach achieves a substantially better trade-off between Precision and Recall than merely combining negative log-likelihood training with temperature scaling. These findings offer a pathway toward more versatile and robust language modeling techniques.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 5 weaker matches are hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{verine2025improving,
  title  = {Improving Diversity in Language Models: When Temperature Fails, Change the Loss},
  author = {Alexandre Verine and Florian Le Bronnec and Kunhao Zheng and Alexandre Allauzen and Yann Chevaleyre and Benjamin Negrevergne},
  year   = {2025},
  eprint = {2508.09654},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2508.09654v1},
  journal = {ICML 2025 2025}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2508.09654.svg)](https://codeofpaper.com/paper/2508.09654)

Discussion