TL;DR
This paper introduces RE2, a simple yet effective prompting technique that significantly boosts the reasoning abilities of Large Language Models (LLMs) by having them "re-read" the question. By processing the question twice, RE2 enables a more "bidirectional" understanding, leading to improved performance across various reasoning tasks and LLMs.
What Problem Does This Paper Address?
Large Language Models (LLMs) have shown remarkable capabilities in understanding and generating text, but they often struggle with complex reasoning tasks. While many existing methods focus on eliciting reasoning processes during the output generation (like Chain-of-Thought), this paper highlights a crucial gap: the understanding of the input question itself. Standard decoder-only LLMs, with their unidirectional attention mechanisms, have a limited view of the question, potentially hindering their ability to grasp its full meaning and nuances. This limitation can lead to suboptimal reasoning performance.
Methods
The core contribution of this paper is the RE2 (Re-Reading) prompting strategy. Instead of just processing the input question once, RE2 involves presenting the question to the LLM twice. This "re-reading" operation is designed to enhance the model's comprehension of the input.
Here's how it works:
- Input Repetition: The original question is fed into the LLM, followed by the same question again.
- "Bidirectional" Understanding: For unidirectional decoder-only LLMs, this second pass allows tokens in the re-read question to attend to tokens from the first pass. This creates a more holistic, "bidirectional" understanding of the question, similar to how humans might re-read a problem to ensure they grasp all details.
- Compatibility: RE2 is designed to be a "plug-and-play" module, meaning it can be seamlessly integrated with existing prompting methods like Chain-of-Thought (CoT), Plan-and-Solve (PS), and Program-Aided Language Models (PAL).
Datasets
The paper evaluates RE2 on a comprehensive set of benchmarks across three categories:
- Arithmetic Reasoning: GSM8K, SVAMP, ASDiv, AQUA, AddSub, MultiArith, SingleEQ.
- Commonsense Reasoning: CSQA, StrategyQA, ARC (ARC-e and ARC-c).
- Symbolic Reasoning: Date Understanding, Coinflip.
These benchmarks span 14 datasets and involved over 112 experiments.
Key Insights and Ideas
- Human-like Strategy: RE2 mimics the human cognitive strategy of re-reading to improve comprehension, suggesting that LLMs can benefit from similar approaches.
- Input-Centric Improvement: Unlike many methods that focus on output generation, RE2 targets the input understanding phase, which is fundamental to accurate reasoning.
- "Bidirectional" Attention: The re-reading process effectively simulates a bidirectional attention mechanism in unidirectional LLMs, allowing for a richer understanding of the question's context and dependencies.
- Generality and Compatibility: RE2 is remarkably versatile, working well with different LLMs (including instruction-tuned and non-instruction-tuned models), various prompting strategies (CoT, PS, PAL), and even ensemble methods like self-consistency.
Key Results
RE2 consistently demonstrated performance improvements across a wide range of experiments:
- Overall Improvement: In almost all scenarios, LLMs with RE2 achieved enhanced reasoning performance compared to their vanilla counterparts.
- Specific Gains: For instance, davinci-003 with Vanilla+RE2 showed average improvements of 3.81, 2.51, and 1.85 in arithmetic, commonsense, and symbolic tasks, respectively. CoT+RE2 further boosted performance with average gains of 2.22, 1.23, and 5.25 in the same categories.
- ChatGPT Exception: A notable exception was observed with vanilla ChatGPT in a few scenarios, where RE2 sometimes led to a slight performance drop. The authors hypothesize this might be due to ChatGPT's prior exposure to CoT-like outputs during instruction fine-tuning, where explicit prompting might disrupt learned patterns. However, even in these cases, RE2 often still improved upon the vanilla baseline.
- Efficiency: RE2 only marginally increased inference time and GPU memory usage, even with longer inputs, due to optimizations in modern LLMs.
- Optimal Re-reads: Experiments showed that re-reading the question 2-3 times yielded the best results, with further repetitions potentially leading to diminishing returns or even negative impacts.
Limitations and Future Work
- Theoretical Analysis: The paper primarily relies on empirical studies. Future work could include more theoretical analyses to provide a stronger foundation for RE2's effectiveness.
- Inference Efficiency: While marginal, RE2 does increase input length, which can slightly reduce inference efficiency for very long questions.
- Broader Applications: The authors suggest exploring RE2's versatility in other contexts beyond reasoning, such as multi-turn dialogue and multi-modal reasoning applications. They also plan to investigate its effectiveness with more advanced LLMs and explore more complex re-reading strategies.
Summary updated