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

利用神经符号表示提升大语言模型的基于规则推理能力

Improving Rule-based Reasoning in LLMs using Neurosymbolic Representations

School of Computer Science, University of Waterloo, Waterloo, Canada(计算机科学学院,滑铁卢大学,滑铁卢,加拿大);Centre for Theoretical Neuroscience, University of Waterloo(理论神经科学中心,滑铁卢大学)

Varun Dhanraj, Chris Eliasmith

AI总结:

针对大语言模型规则遵循类推理任务表现不佳的问题,提出神经符号表示增强方法,通过神经符号向量空间计算、结果与原隐藏状态融合,在不损失其他任务性能的前提下大幅提升数学推理表现。

摘要:

大语言模型(LLMs)在可靠解决推理任务方面仍面临挑战,尤其是数学推理中常见的需要精确遵循规则的任务。本文提出一种新型神经符号方法,通过将隐藏状态编码为神经符号向量,使问题求解可在神经符号向量空间内开展,以此提升LLM的推理能力。该方法会将输出结果解码后与原始隐藏状态融合,显著提升模型在数值推理任务上的表现。通过借助神经符号表示卸载计算,该方法提升了推理的效率、可靠性与可解释性。实验结果显示,相较于思维链提示和有监督微调(LoRA)方法,该方法在一系列数学推理任务上的交叉熵损失平均降低88.6%,正确求解的题目数量提升至15.4倍,且不会降低模型在其他任务上的性能。我们的代码已开源在https://github.com/vdhanraj/Neurosymbolic-LLM。

英文摘要:

Large language models (LLMs) continue to face challenges in reliably solving reasoning tasks, particularly those that require precise rule following, as often found in mathematical reasoning. This paper introduces a novel neurosymbolic method that improves LLM reasoning by encoding hidden states into neurosymbolic vectors, enabling problem-solving within a neurosymbolic vector space. The results are decoded and merged with the original hidden state, significantly boosting the model's performance on numerical reasoning tasks. By offloading computation through neurosymbolic representations, this method enhances efficiency, reliability, and interpretability. Experimental results demonstrate an average of 88.6% lower cross-entropy loss and 15.4 times more problems correctly solved on a suite of mathematical reasoning tasks compared to chain-of-thought prompting and supervised fine-tuning (LoRA), without degrading performance on other tasks. We make our code available at: https://github.com/vdhanraj/Neurosymbolic-LLM.

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

↑