用少量语言解释修正模型错误,提升推理准确性。
FLEx: Language Modeling with Few-shot Language Explanations
- 通过聚类选典型错误,用解释纠正并生成提示前缀。
- 在三个数据集上减少83%的链式思考残留错误。
- 适合需要高可靠推理但标注成本高的场景。
语言模型在数学解题到开放域问答等任务中表现优异,但仍会重复犯错。自然语言解释有助于纠错,但大规模收集困难,尤其在需专家标注的领域。为此,我们提出FLEx(Few-shot Language Explanations),利用少量解释性示例改进模型行为。FLEx通过嵌入聚类选取代表性错误,验证解释的有效性,并将解释归纳为推理时前置的提示前缀,从而引导模型避免类似错误,无需修改模型权重。我们在CounterBench、GSM8K和ReasonIF上评估FLEx,结果表明其在所有三个数据集上均优于链式思考(CoT)提示,最多可减少83%的CoT剩余错误。
原文摘要 · Abstract (English)
Language models have become effective at a wide range of tasks, from math problem solving to open-domain question answering. However, they still make mistakes, and these mistakes are often repeated across related queries. Natural language explanations can help correct these errors, but collecting them at scale may be infeasible, particularly in domains where expert annotators are required. To address this issue, we introduce FLEx ($\textbf{F}$ew-shot $\textbf{L}$anguage $\textbf{Ex}$planations), a method for improving model behavior using a small number of explanatory examples. FLEx selects representative model errors using embedding-based clustering, verifies that the associated explanations correct those errors, and summarizes them into a prompt prefix that is prepended at inference-time. This summary guides the model to avoid similar errors on new inputs, without modifying model weights. We evaluate FLEx on CounterBench, GSM8K, and ReasonIF. We find that FLEx consistently outperforms chain-of-thought (CoT) prompting across all three datasets and reduces up to 83\% of CoT's remaining errors.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。