Lune

EMNLP Findings2023

Generative Calibration for In-context Learning

Zhongtao Jiang, Yuanzhe Zhang, Cao Liu, Jun Zhao, Kang Liu

摘要

As one of the most exciting features of large language models (LLMs), in-context learning is a mixed blessing. While it allows users to fast-prototype a task solver with only a few training examples, the performance is generally sensitive to various configurations of the prompt such as the choice or order of the training examples. In this paper, we for the first time theoretically and empirically identify that such a paradox is mainly due to the label shift of the in-context model to the data distribution, in which LLMs shift the label marginal p(y) while having a good label conditional p(x|y).

With this understanding, we can simply calibrate the in-context predictive distribution by adjusting the label marginal, which is estimated via Monte-Carlo sampling over the in-context model, i.e., generation of LLMs. We call our approach as generative calibration. We conduct exhaustive experiments with 12 text classification tasks and 12 LLMs scaling from 774M to 33B, generally find that the proposed method greatly and consistently outperforms the ICL as well as state-of-the-art calibration methods, by up to 27% absolute in macro-F1. Meanwhile, the proposed method is also stable under different prompt configurations. 1

问 Lune

尽管问,回答会引用原文。

Lune 会读完全文和相关的 Paper,每个回答都附上所依据的原文段落。

可以从这些问题问起

Lune 的依据

全文 · 引用它的 6 篇顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

引用它的顶会 Paper6

  1. Thermometer: Towards Universal Calibration for Large Language ModelsMaohao Shen, Subhro Das, Kristjan H. Greenewald, Prasanna Sattigeri 等ICML 2024 · 38 次引用
  2. Confidence Calibration of Classifiers with Many ClassesAdrien Le-Coz, Stéphane Herbin, Faouzi AdjedNeurIPS 2024 · 21 次引用
  3. On the In-context Generation of Language ModelsZhongtao Jiang, Yuanzhe Zhang, Kun Luo, Xiaowei Yuan 等EMNLP 2024
  4. The Good, the Bad, and the Debatable: A Survey on the Impacts of Data for In-Context LearningStephanie Schoch, Yangfeng JiEMNLP 2025
  5. Restoring Calibration for Aligned Large Language Models: A Calibration-Aware Fine-Tuning ApproachJiancong Xiao, Bojian Hou, Zhanliang Wang, Ruochen Jin 等ICML 2025

它引用的 Paper24

  1. Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah 等NeurIPS 2020 · 64,255 次引用
  2. Chain-of-Thought Prompting Elicits Reasoning in Large Language ModelsJason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma 等NeurIPS 2022 · 22,562 次引用
  3. Fantastically Ordered Prompts and Where to Find Them: Overcoming Few-Shot Prompt Order SensitivityYao Lu, Max Bartolo, Alastair Moore, Sebastian Riedel 等ACL 2022 · 1,494 次引用
  4. An Explanation of In-context Learning as Implicit Bayesian InferenceSang Michael Xie, Aditi Raghunathan, Percy Liang, Tengyu MaICLR 2022 · 1,030 次引用
  5. Transformers Learn In-Context by Gradient DescentJohannes von Oswald, Eyvind Niklasson, Ettore Randazzo, João Sacramento 等ICML 2023 · 729 次引用

相关 Paper

  1. Mitigating Label Biases for In-context LearningYu Fei, Yifan Hou, Zeming Chen, Antoine BosselutACL 2023 · 24 次引用
  2. Beyond Generation: Leveraging LLM Creativity to Overcome Label Bias in ClassificationXiaoyue Wang, Xin LiuACL Findings 2025
  3. Task Descriptors Help Transformers Learn Linear Models In-ContextRuomin Huang, Rong GeICLR 2025
  4. Batch Calibration: Rethinking Calibration for In-Context Learning and Prompt EngineeringHan Zhou, Xingchen Wan, Lev Proleev, Diana Mincu 等ICLR 2024 · 90 次引用
  5. In-Context Learning Learns Label Relationships but Is Not Conventional LearningJannik Kossen, Yarin Gal, Tom RainforthICLR 2024 · 61 次引用
黄昏的海面,两侧是细线勾勒的悬崖