arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2501.00759cs.CLcs.AI
收藏

增强Transformer以实现可泛化的一阶逻辑蕴含

Enhancing Transformers for Generalizable First-Order Logical Entailment

Department of Computer Science and Engineering, HKUST, Hong Kong SAR, China(香港科技大学计算机科学与工程系);Department of Computer Science and Engineering, Beihang University, Beijing, China(北航计算机科学与工程系);Department of Mathematical Sciences, Tsinghua University, Beijing, China(清华大学数学科学系)

Tianshi Zheng, Jiazheng Wang, Zihao Wang, Jiaxin Bai, Hang Yin, Zheye Deng, Yangqiu Song, Jianxin Li

AI总结:

本文研究了Transformer的可泛化一阶逻辑推理能力,揭示了以往架构设计中位置编码的不匹配问题,并提出逻辑感知架构TEGA以显著提升其在一阶逻辑蕴含任务上的性能。

摘要:

Transformer作为基础深度学习架构,已展现出强大的推理能力。本文研究了Transformer凭借其参数化知识所具备的可泛化一阶逻辑推理能力,以及如何对其进行改进。Transformer的一阶推理能力进一步通过其能否进行一阶逻辑蕴含来刻画,并通过其在回答知识图谱查询中的表现进行定量测量。我们建立了分布外泛化研究中探讨的两种分布偏移与知识图谱查询回答任务中讨论的未见知识和查询设置之间的联系,从而使得刻画细粒度泛化性成为可能。我们在综合数据集上的结果表明,Transformer的表现优于此前专为该任务设计的方法,并提供了关于输入查询语法、词元嵌入和Transformer架构对其推理能力影响的详细实证证据。有趣的是,我们的结果揭示了以往实践中位置编码与Transformer架构其他设计选择的不匹配。受此启发,我们提出了TEGA,这是一种逻辑感知架构,能够显著提升在可泛化一阶逻辑蕴含上的性能。

英文摘要:

Transformers, as the fundamental deep learning architecture, have demonstrated great capability in reasoning. This paper studies the generalizable first-order logical reasoning ability of transformers with their parameterized knowledge and how to improve it. Transformers' capability of first-order reasoning is further captured by whether they can conduct first-order logical entailment, which is quantitatively measured by their performance in answering knowledge graph queries. We establish the connections between (1) two types of distribution shifts studied in out-of-distribution generalization and (2) unseen knowledge and query settings discussed in the task of knowledge graph query answering, which makes it possible to characterize the fine-grained generalizability. Results on our comprehensive dataset showed that transformers \textit{outperform} previous methods designed particularly for this task and provided detailed empirical evidence about the impact of the input query syntax, token embedding, and transformer architectures on their reasoning capability. Interestingly, our results revealed the mismatch of positional encoding and other design choices of transformer architectures in previous practices. Motivated by this, we propose TEGA, a logic-aware architecture that significantly improves the performance in generalizable first-order logical entailment.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑