Source-linked AI summary

Rationale-Augmented Ensembles in Language Models

Xuezhi Wang, Jason Wei, Dale Schuurmans, Quoc Le, Ed Chi, Denny Zhou

arXiv:2207.00747v1cs.CL

TL;DR

Manually written rationales in few-shot prompting may be sub-optimal, leaving their reliability in that setting unclear. The paper proposes rationale-augmented ensembles that sample and aggregate rationales, finding that output-space sampling is a key component of improved performance across tasks. The approach also applies to common NLP tasks and requires only a few human-written seed rationales.

  • Problem

    Manually written rationales used in few-shot prompting may be sub-optimal, and it remains unclear whether rationales can be reliably useful in few-shot in-context learning.

    Source: §1 · p. 1
  • Method

    The framework samples rationales as an additional latent variable and aggregates rationale-answer outputs, with output-space sampling as a central component.

    Source: §2.2 · pp. 4–5
  • Results

    Rationale-augmented ensembles reliably outperform standard and rationale-based prompting across a wide range of natural language tasks and alternative language models.

    Source: §5 · p. 10
  • Takeaways & Limitations

    The framework extends to common NLP tasks, including tasks without explicit intermediate steps, and can use few human-written rationales without fine-tuning or auxiliary datasets.

    Source: §1 · p. 2

    The method still requires human-written seed rationales, whose style can influence generated rationales, so some seed diversity appears important.

    Source: §5 · p. 10

Abstract

from arXiv · show

Recent research has shown that rationales, or step-by-step chains of thought, can be used to improve performance in multi-step reasoning tasks. We reconsider rationale-augmented prompting for few-shot in-context learning, where (input -> output) prompts are expanded to (input, rationale -> output) prompts. For rationale-augmented prompting we demonstrate how existing approaches, which rely on manual prompt engineering, are subject to sub-optimal rationales that may harm performance. To mitigate this brittleness, we propose a unified framework of rationale-augmented ensembles, where we identify rationale sampling in the output space as the key component to robustly improve performance. This framework is general and can easily be extended to common natural language processing tasks, even those that do not traditionally leverage intermediate steps, such as question answering, word sense disambiguation, and sentiment analysis. We demonstrate that rationale-augmented ensembles achieve more accurate and interpretable results than existing prompting approaches--including standard prompting without rationales and rationale-based chain-of-thought prompting--while simultaneously improving interpretability of model predictions through the associated rationales.

1 Introduction

The paper studies why manually supplied rationales can be unreliable in few-shot in-context learning and proposes rationale-augmented ensembles to address that brittleness. It reports improved performance across varied NLP tasks, including tasks that do not typically require explicit intermediate steps.

1 Introduction

  • Manually written rationales may be sub-optimal for a task, and adding them can produce large performance variance or hurt few-shot results.The paper frames rationale quality as a source of sensitivity when prompts expand from input-output pairs to input-rationale-output prompts.Source: §1 · p. 1
  • Rationale-augmented ensembles aggregate across multiple rationales, with self-consistency, prompt-order ensembling, and input-rationale ensembling as approaches.The approaches introduce rationale randomness through output sampling, prompt order, or model-generated rationales in the input.Source: §1 · pp. 1–2
  • Output-space rationale sampling is central to ensemble performance, which reliably exceeds existing rationale-based few-shot and zero-shot prompting across varied NLP tasks.When human-written rationales hurt performance, the ensembles outperform standard few-shot prompting on most tasks.Source: §1 · p. 2
  • The framework improves few-shot learning on question answering, word sense disambiguation, sentiment analysis, and paraphrase identification, even when explicit intermediate steps may not be necessary.It uses few human-written rationales and does not require fine-tuning, verifiers, calibrators, or auxiliary datasets.Source: §1 · p. 2

2 Rationale-Augmented Ensembles in Language Models

The section examines how rationale quality affects few-shot performance, then introduces rationale-augmented ensembles as a way to aggregate across rationales. It describes strategies that vary where rationale randomness enters and identifies output-space sampling as especially important.

2.1 Optimality of the rationales in few-shot learning.

  • The sensitivity study uses K=4 to 6 exemplars and replaces each exemplar’s rationale in turn with a model-generated sample while holding the others fixed.It samples 1,024 rationales per exemplar and keeps those whose final answer matches the ground truth.Source: §2.1 · p. 3
  • Human-written rationales do not always improve over no-rationale prompts, and sampled rationale choices produce substantial performance variance.On e-SNLI, WiC, and SST-2, written-rationale prompts perform significantly worse than standard few-shot prompting without rationales.Source: §2.1 · p. 3, Figure 2 · p. 3
  • Model-generated rationales can provide diverse, reasonable ways to address a question, and rationale examples extend to tasks without explicit intermediate steps.The examples include human-written and PaLM-540B-generated rationales.Source: §2.1 · p. 3, Table 1 · p. 4

2.2 Rationale-augmented ensembles

  • A rationale-augmented ensemble treats rationales as a sampleable latent variable that is ultimately marginalized out, with strategies varying where sampling occurs.The described strategies include decoder sampling with a fixed prompt, permuting exemplar order, and replacing human-written input rationales with model-generated ones.Source: §2.2 · p. 4
  • Output-space rationale sampling is the key performance component across ensembling approaches, regardless of how the input or prompt varies.The framework couples rationale and answer generation, then uses a plurality vote for the final answer.Source: §2.2 · p. 5

3 Experiments

Experiments compare rationale-augmented ensembles with standard and rationale-based prompting across NLP tasks, language models, and prompt settings. Output-space sampling is the central component associated with more reliable performance gains; additional studies test robustness to exemplar counts, templates, and rationale sources.

3.1 Experiment setup

  • The experiments use PaLM-540B and GPT-3 in few-shot settings without fine-tuning, with ensembles of 40 outputs sampled at temperature 0.7.Additional studies find performance gains over standard and chain-of-thought prompting across K values and three templates, and stable gains with crowd-sourced or author-supplied rationales.Source: §3.1 · pp. 5–6, §3.4 · pp. 8–9

3.2 Results

  • Output-sampled ensembles outperform output-greedy versions for almost every task, regardless of whether input prompts also vary.The authors identify output-space rationale sampling as more important to performance than the particular ensembling strategy.Source: §3.2 · p. 6
  • Rationale-augmented ensembles reliably outperform standard and rationale-based prompting in most tasks, although standard prompting remains strongest on MNLI-m/mm, SST-2, and QQP.The authors conjecture that these tasks’ questions and answers may be frequent in pretraining, allowing memorization to perform well.Source: §3.2 · p. 6
  • Across NLI tasks, output-sampled ensembles outperform chain-of-thought prompting in every case and standard prompting except MNLI.On e-SNLI, RTE, and MNLI, chain-of-thought prompting performs worse than standard prompting.Source: §3.2 · p. 6, Table 3 · p. 7
  • In question answering, output-sampled ensembles beat standard and chain-of-thought prompting in both BoolQ settings and achieve higher HotpotQA EM and F1 than both baselines.The HotpotQA evaluation uses the closed-book setting; the BoolQ evaluations include question-only and question-plus-passage settings.Source: §3.2 · pp. 6–7, Table 4 · p. 7
  • On SST-2 and QQP, output-sampled ensembles close the gap associated with manual rationales; on WiC, ARC, and GSM8K, they outperform standard and chain-of-thought prompting.These comparisons cover tasks where explicit intermediate steps might not be necessary as well as word-sense, reasoning, and arithmetic tasks.Source: §3.2 · p. 7, Table 6 · p. 8

4 Related work

Related work studies rationale extraction and training, manually written rationale prompts, and other sources of prompting sensitivity. This paper’s approach is distinguished by focusing on few-shot learning without additional training or hand-tuning of rationales.

Rationalization and interpretability in NLP

  • Rationale extraction and supervised rationale training often rely on task-specific methods, human annotations, or added training data, unlike this few-shot approach without fine-tuning.The related work also describes prompting-based dataset augmentation and rationale-augmented training as closer to the fine-tuning setting.Source: §4 · p. 9
  • Unlike hand-tuned rationale prompting, rationale-augmented ensembling automatically samples rationales from the language model to address potentially suboptimal manual rationales.Prior work reports that hand-tuned explanations can improve performance substantially.Source: §4 · p. 9

Prompt optimization and ensembles in language models

  • Prompt order, task verbalization, label distribution, and rationale choice can all affect final task performance.The related work also describes explanation trees with SAT and NLI verification, retrieved knowledge for commonsense reasoning, and retrieval of prompts similar to the target question.Source: §4 · p. 10

Learn to execute programs with intermediate computations

  • Program-synthesis work also uses intermediate steps, including line-by-line prediction of program states to improve execution prediction accuracy.Other cited work pre-trains language models as program executors to improve reasoning task performance.Source: §4 · p. 10

5 Conclusion

Rationale-augmented ensembles use diverse sampled rationales to improve performance and interpretability across natural language tasks. Human-written seed rationales remain necessary and can bias the generated rationales.

5 Conclusion

  • Rationale-augmented ensembles reliably outperform standard prompting and rationale-based few-shot prompting across a wide range of tasks and language models.The paper also reports more accurate and interpretable natural language processing results overall.Source: §5 · p. 10
  • Human-written seed rationales remain necessary and can bias generated rationales, making diversity among seed examples important.Generated rationales may follow patterns in the seeds; for example, similar seed phrasing can lead to similar patterns in generated rationales.Source: §5 · p. 10
  • The authors hope the study motivates research into model responses to exemplar variation and more robust, autonomous prompt generation.Source: §5 · p. 10

A.1 Full Sets of Prompts

The appendix catalogs few-shot exemplar prompts across several task families, from RTE, ARC, and NLI to question answering, WiC, SST-2, and QQP.

A.1 Full Sets of Prompts

Loading 2207.00747v1…