用简单数据技巧让语言模型学会逻辑反推,突破自回归模型的固有缺陷。
Breaking the Reversal Curse in Autoregressive Language Models via Identity Bridge
- 在训练数据中加入身份桥接样本(如'爱丽丝→爱丽丝'),引导模型学习逆向推理。
- 10亿参数模型在反向任务上准确率提升至50%,远高于仅用正向数据训练的接近0%。
- 理论证明梯度下降隐含偏置支持该方法,适合关注逻辑推理与知识泛化的研究者。
自回归大语言模型在复杂任务上表现卓越,但在简单逻辑推理如“反向诅咒”问题上仍失败——当训练数据为正向形式(如‘爱丽丝的丈夫是鲍勃’)时,模型无法在测试中推导出逆向关系(如‘鲍勃的妻子是爱丽丝’)。以往研究认为这是自回归因果模型的根本性局限,即模型倾向于记忆事实而非捕捉高层规则。本文挑战这一观点,提出通过引入简单的身份桥接数据(如‘爱丽丝→爱丽丝’)进行微调,可有效缓解此问题。理论上,我们证明即使单层Transformer在该数据策略下也能打破反向诅咒,源于梯度下降的隐含偏置。实验上,一个10亿参数的预训练模型经此方法微调后,在反向推理任务上达到50%准确率,而仅用正向数据训练时接近0%。本工作为反向诅咒提供了新理论基础,并提供了一种低代价、可解释的路径,促进大模型学习更高层次规则。
原文摘要 · Abstract (English)
Autoregressive large language models (LLMs) have achieved remarkable success in many complex tasks, yet they can still fail in very simple logical reasoning such as the "reversal curse" -- when trained on forward knowledge data of the form "$A \rightarrow B$" (e.g., Alice's husband is Bob), the model is unable to deduce the reversal knowledge "$B \leftarrow A$" (e.g., Bob's wife is Alice) during test. Extensive prior research suggests that this failure is an inherent, fundamental limit of autoregressive causal LLMs, indicating that these models tend to memorize factual-level knowledge rather than capture higher-level rules. In this paper, we challenge this view by showing that this seemingly fundamental limit can be mitigated by slightly tweaking the training data with a simple regularization data recipe called the Identity Bridge of the form "$A \to A$" (e.g., The name of Alice is Alice). Theoretically, we prove that under this recipe, even a one-layer transformer can break the reversal curse by analyzing the implicit bias of gradient descent. Empirically, we show that a 1B pretrained language model finetuned with the proposed data recipe achieves a 50% success rate on reversal tasks, in stark contrast to a near-zero success rate when trained solely on forward-knowledge data. Our work provides a novel theoretical foundation for the reversal curse and offers a principled, low-cost path to encouraging LLMs to learn higher-level rules from data.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。