LLMs can implicitly learn from mistakes in-context
Learning from mistakes is a fundamental feature of human intelligence. Previous work has shown that Large Language Models (LLMs) can also learn from incorrect answers when provided with a comprehensive rationale detailing why an answer is wrong or how to correct it. In this work, we examine whether LLMs can learn from mistakes in mathematical reasoning tasks when these explanations are not provided. We investigate if LLMs are able to implicitly infer such rationales simply from observing both incorrect and correct answers. Surprisingly, we find that LLMs perform better, on average, when rationales are eliminated from the context and incorrect answers are simply shown alongside correct ones. This approach also substantially outperforms chain-ofthought prompting in our evaluations. We show that these results are consistent across LLMs of different sizes and varying reasoning abilities. Further, we carry out an in-depth analysis, and show that prompting with both wrong and correct answers leads to greater performance and better generalisation than introducing additional, more diverse question-answer pairs into the context.
Introduction. A crucial aspect of human cognition is the ability to learn from mistakes (Metcalfe, 2017). Analogously, LLMs have been shown to benefit from observing incorrect answers in their context (Madaan et al., 2024; Shinn et al., 2024) and even their training data (An et al., 2023; Paul et al., 2024), provided
Discussion / Conclusion. Our results demonstrate that LLMs perform better across several mathematical reasoning tasks when they are prompted for implicit learning, even over CoT prompting and providing the models with additional information through rationales. To minimise any risk that spurious correlations may be influencing these results, here we provide further, in-depth analysis of our findings, their robustness and implications.
Lines of inquiry this paper opens 24
Research framings built by reading the notes related to this paper — the questions it feeds into.
Do base models contain latent reasoning that training can unlock?- Why do single examples trigger large reasoning improvements in models?
- Can models learn to select exemplars based on reasoning skills rather than complexity?
- How does a single training example trigger phase transitions in reasoning output?
- Can a single correct example seed exponential improvement in mathematical reasoning?
- How can one training example improve reasoning across thousands of unseen problems?
- Why does reasoning training improve math but hurt knowledge tasks?
- How do single training examples activate reasoning capabilities in language models?
- Can explicit numerical signals override learned linguistic defaults in fine-tuned models?
- Why does keyword priming require only three training exposures to establish?
- How tight should a textual learning rate be before it prevents skill escape?
- Does selecting examples from multiple complexity levels outperform selecting only high-quality examples?
- Why does curriculum learning with tight budgets beat fixed-budget approaches?
- Does partial trace guidance work better than curriculum learning for hard problems?
- Can solution traces substitute for process-level reward signals in math reasoning?
- Why do medical and mathematical tasks require fundamentally different model capabilities?
- Do models with unfilled memorization capacity appear to generalize falsely?