Logic-LM:通过符号求解器赋能大型语言模型以实现忠实的逻辑推理
Logic-LM: Empowering Large Language Models with Symbolic Solvers for Faithful Logical Reasoning
AI总结:
本文提出Logic-LM框架,通过将大型语言模型与符号求解器结合,把自然语言转化为符号公式进行推理,并引入自我修正模块,在五个逻辑数据集上显著提升了LLM的逻辑推理性能。
摘要:
大型语言模型(LLMs)已展现出类似人类的推理能力,但在处理复杂逻辑问题时仍存在困难。本文提出了一种新颖的框架Logic-LM,它将LLMs与符号求解器相结合以改善逻辑问题求解。我们的方法首先利用LLMs将自然语言问题转化为符号公式。随后,确定性的符号求解器对公式化问题执行推理。我们还引入了自我修正模块,利用符号求解器的错误信息来修正符号形式化。我们在五个逻辑推理数据集上验证了Logic-LM的有效性:ProofWriter、PrOntoQA、FOLIO、LogicalDeduction和AR-LSAT。平均而言,与仅使用LLM和标准提示相比,Logic-LM实现了39.2%的显著性能提升,与使用思维链提示的LLM相比提升了18.4%。我们的研究结果表明,Logic-LM通过将LLMs与符号逻辑相结合,为忠实的逻辑推理提供了一条有前景的途径。代码和数据已在https://github.com/teacherpeterpan/Logic-LLM公开发布。
英文摘要:
Large Language Models (LLMs) have shown human-like reasoning abilities but still struggle with complex logical problems. This paper introduces a novel framework, Logic-LM, which integrates LLMs with symbolic solvers to improve logical problem-solving. Our method first utilizes LLMs to translate a natural language problem into a symbolic formulation. Afterward, a deterministic symbolic solver performs inference on the formulated problem. We also introduce a self-refinement module, which utilizes the symbolic solver's error messages to revise symbolic formalizations. We demonstrate Logic-LM's effectiveness on five logical reasoning datasets: ProofWriter, PrOntoQA, FOLIO, LogicalDeduction, and AR-LSAT. On average, Logic-LM achieves a significant performance boost of 39.2% over using LLM alone with standard prompting and 18.4% over LLM with chain-of-thought prompting. Our findings suggest that Logic-LM, by combining LLMs with symbolic logic, offers a promising avenue for faithful logical reasoning. Code and data are publicly available at https://github.com/teacherpeterpan/Logic-LLM.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。