ACL Findings2024
Mind Your Format: Towards Consistent Evaluation of In-Context Learning Improvements
Anton Voronov, Lena Wolf, Max Ryabinin
Abstract
Large language models demonstrate a remarkable capability for learning to solve new tasks from a few examples. The prompt template, or the way the input examples are formatted to obtain the prompt, is an important yet often overlooked aspect of in-context learning. In this work, we conduct a comprehensive study of the template format's influence on the in-context learning performance. We evaluate the impact of the prompt template across 21 models (from 770M to 70B parameters) and 4 standard classification datasets. We show that a poor choice of the template can reduce the performance of the strongest models and inference methods to a random guess level. More importantly, the best templates do not transfer between different setups and even between models of the same family. Our findings show that the currently prevalent approach to evaluation, which ignores template selection, may give misleading results due to different templates in different works. As a first step towards mitigating this issue, we propose Template Ensembles that aggregate model predictions across several templates. This simple test-time augmentation boosts average performance while being robust to the choice of random set of templates.
Demonstrations (x, y) ("Worst film ever", 1) ("Awesome, I like it", 0) v I : text: x v O : target: C[y] C = (positive, negative) Intra-sep: " "; inter-sep: "" Templates v I : input: x v O : It was C[y].
Ask Lune
Ask anything. The answer quotes the paper.
Lune reads all of it and the papers around it, then shows you the passages behind every answer.
Lune answers from
the full paper · 26 top-tier papers that cite it · related work
Free to start. No credit card required.
Cited by top-tier papers26
- tinyBenchmarks: evaluating LLMs with fewer examplesFelipe Maia Polo, Lucas Weber, Leshem Choshen, Yuekai Sun et al.ICML 2024 · 212 citations
- Understanding the Prompt SensitivityYang Liu, Chenhui ChuACL 2026 · 192 citations
- TabDPT: Scaling Tabular Foundation Models on Real DataJunwei Ma, Valentin Thomas, Rasa Hosseinzadeh, Alex Labach et al.NeurIPS 2025 · 118 citations
- Efficient multi-prompt evaluation of LLMsFelipe Maia Polo, Ronald Xu, Lucas Weber, Mírian Silva et al.NeurIPS 2024 · 93 citations
- ContextNav: Towards Agentic Multimodal In-Context LearningHonghao Fu, Yuan Ouyang, Kai-Wei Chang, Yiwei Wang et al.ICLR 2026 · 14 citations
Builds on19
- Calibrate Before Use: Improving Few-shot Performance of Language ModelsZihao Zhao, Eric Wallace, Shi Feng, Dan Klein et al.ICML 2021 · 1,843 citations
- Pythia: A Suite for Analyzing Large Language Models Across Training and ScalingStella Biderman, Hailey Schoelkopf, Quentin Gregory Anthony, Herbie Bradley et al.ICML 2023 · 1,822 citations
- Fantastically Ordered Prompts and Where to Find Them: Overcoming Few-Shot Prompt Order SensitivityYao Lu, Max Bartolo, Alastair Moore, Sebastian Riedel et al.ACL 2022 · 1,494 citations
- AutoPrompt: Eliciting Knowledge from Language Models with Automatically Generated PromptsTaylor Shin, Yasaman Razeghi, Robert L. Logan IV, Eric Wallace et al.EMNLP 2020 · 1,162 citations
- An Explanation of In-context Learning as Implicit Bayesian InferenceSang Michael Xie, Aditi Raghunathan, Percy Liang, Tengyu MaICLR 2022 · 1,030 citations
Related papers
- Large Language Models Might Not Care What You Are Saying: Prompt Format Beats DescriptionsChenming Tang, Zhixiang Wang, Hao Sun, Yunfang WuEMNLP Findings 2025 · 2 citations
- Towards Informative Few-Shot Prompt with Maximum Information Gain for In-Context LearningHongfu Liu, Ye WangEMNLP Findings 2023 · 7 citations
- In-context Examples Selection for Machine TranslationSweta Agrawal, Chunting Zhou, Mike Lewis, Luke Zettlemoyer et al.ACL Findings 2023 · 78 citations
- PrExMe! Large Scale Prompt Exploration of Open Source LLMs for Machine Translation and Summarization EvaluationChristoph Leiter, Steffen EgerEMNLP 2024 · 5 citations
- S2LPP: Small-to-Large Prompt Prediction across LLMsLiang Cheng, Tianyi Li, Zhaowei Wang, Mark SteedmanEMNLP Findings 2025 · 1 citation
