用对比学习提升大模型双向推理能力,解决只懂单向模式的问题。
Using Contrastive Learning to Improve Two-Way Reasoning in Large Language Models: The Obfuscation Task as a Case Study
- 通过对比训练,让模型在正反方向上都具备推理能力。
- 实验显示,新方法使逆向推理性能显著提升,且不损失正向能力。
- 适合研究模型理解深度或开发更智能AI系统的学者参考。
本研究探讨大语言模型是否真正理解概念,还是仅依赖模式识别。作者提出双向推理作为测试真理解的指标:模型应能在未显式训练逆向任务的情况下,自然完成双向变换。例如,将 userIndex 变为 i 后,也能推断出 i 代表用户索引。实验发现,模型在正向任务微调后,反而严重丧失双向推理能力,称为认知专业化。为此,作者提出对比微调(CFT),使用三类样本:语义保持的正例、语义不同的负例,以及正向混淆样本。该方法促进深层理解而非表面模式匹配,使逆向能力自然发展。实验表明,CFT成功实现双向推理,在保持正向性能的同时大幅提升逆向表现。结论认为,双向推理既是评估真理解的理论框架,也是构建更强大AI系统的实用训练策略。
原文摘要 · Abstract (English)
This research addresses a fundamental question in AI: whether large language models truly understand concepts or simply recognize patterns. The authors propose bidirectional reasoning,the ability to apply transformations in both directions without being explicitly trained on the reverse direction, as a test for genuine understanding. They argue that true comprehension should naturally allow reversibility. For example, a model that can change a variable name like userIndex to i should also be able to infer that i represents a user index without reverse training. The researchers tested current language models and discovered what they term cognitive specialization: when models are fine-tuned on forward tasks, their performance on those tasks improves, but their ability to reason bidirectionally becomes significantly worse. To address this issue, they developed Contrastive Fine-Tuning (CFT), which trains models using three types of examples: positive examples that maintain semantic meaning, negative examples with different semantics, and forward-direction obfuscation examples. This approach aims to develop deeper understanding rather than surface-level pattern recognition and allows reverse capabilities to develop naturally without explicit reverse training. Their experiments demonstrated that CFT successfully achieved bidirectional reasoning, enabling strong reverse performance while maintaining forward task capabilities. The authors conclude that bidirectional reasoning serves both as a theoretical framework for assessing genuine understanding and as a practical training approach for developing more capable AI systems.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。