[论文解读] $ ext{C}^2 ext{P}$: Featuring Large Language Models with Causal Reasoning
本文提出了一种名为因果提示链(Causal Chain of Prompting, C2P)的新框架,该框架通过提取并利用邻接矩阵作为贝叶斯网络中因果有向无环图(DAG)的代理,使大型语言模型(LLMs)能够自主执行因果推理。在仅使用六个示例的 few-shot 学习设置下,使用 C2P 的 GPT-4 Turbo 在推理准确率上相比最先进模型提升了超过 33%,显著提高了在医疗、经济和环境科学等多样化领域中因果推理任务的性能。
Causal reasoning is one of the primary bottlenecks that Large Language Models (LLMs) must overcome to attain human-level intelligence. Recent studies indicate that LLMs display near-random performance on reasoning tasks. To address this, we introduce the Causal Chain of Prompting ($ ext{C}^2 ext{P}$), a reasoning framework that aims to equip current LLMs with causal reasoning capabilities as the first framework of its kind operating autonomously without relying on external tools or modules during both the causal learning and reasoning phases. To evaluate the performance of $ ext{C}^2 ext{P}$, we first demonstrate that reasoning accuracy improved by over $30.7\%$ and $25.9\%$ for GPT-4 Turbo and LLaMA 3.1, respectively, when using our framework, compared to the same models without $ ext{C}^2 ext{P}$ on a synthetic benchmark dataset. Then, using few-shot learning of the same LLMs with $ ext{C}^2 ext{P}$, the reasoning accuracy increased by more than $20.05\%$ and $20.89\%$, respectively, with as few as ten examples, compared to the corresponding LLMs without $ ext{C}^2 ext{P}$ on the same dataset. To evaluate $ ext{C}^2 ext{P}$ in realistic scenarios, we utilized another benchmark dataset containing natural stories across various fields, including healthcare, medicine, economics, education, social sciences, environmental science, and marketing. The results show improved reasoning when $ ext{C}^2 ext{P}$ is applied, compared to cases where our framework is not used, which often leads to random and hallucinated responses. By showing the improved performance of few-shot learned GPT-4 Turbo and LLaMA 3.1 with $ ext{C}^2 ext{P}$, we demonstrate the generalizability of our framework.
研究动机与目标
- 解决 LLMs 的根本瓶颈——尽管其能够生成看似合理的相关性,但缺乏真正的因果推理能力。
- 克服现有因果推理框架中 LLMs 对外部工具或模块的依赖。
- 使 LLMs 在训练或微调过程中学习并应用因果推理,而无需专门的架构设计。
- 提升在复杂因果推理任务中的表现,包括直接因果关系与共同原因关系,在医疗、经济和环境科学等现实世界领域中。
- 证明即使是最少的 few-shot 示例(如仅六例)在 C2P 框架引导下,也能显著提升因果推理的准确率。
提出的方法
- 从因果推理任务的前提中提取邻接矩阵,将其视为贝叶斯框架中因果有向无环图(DAG)的代理。
- 利用邻接矩阵对变量之间的因果关系进行编码,使 LLM 能够在无需外部因果模型的情况下推理因果结构。
- 将 C2P 框架整合到 LLM 的训练或微调过程中,将因果推理能力直接嵌入模型的参数空间。
- 采用精心构建的 few-shot 提示示例,展示因果推理链,从而实现对未见因果查询的零样本或 few-shot 泛化。
- 在 C2P 框架内利用思维链提示(chain-of-thought prompting),引导模型对邻接矩阵中编码的因果结构进行逐步推理。
- 利用邻接矩阵支持 d-分离推理,以增强对复杂因果依赖关系的推理能力。
实验结果
研究问题
- RQ1LLMs 是否能够在不依赖外部工具或模块的情况下实现准确的因果推理?
- RQ2简单的邻接矩阵表示在多大程度上可作为完整因果 DAG 的替代品,以支持 LLM 中的因果推理?
- RQ3C2P 框架在仅使用极少示例的 few-shot 学习场景中,对提升因果推理准确率的效率如何?
- RQ4C2P 是否能增强 LLM 在复杂因果任务(如识别共同原因或间接因果效应)中的表现?
- RQ5在微调过程中集成 C2P 是否能显著提升模型在跨领域真实世界因果推理问题中的泛化能力?
主要发现
- 在仅使用六个 few-shot 示例的情况下,C2P 使 GPT-4 Turbo 相较于最先进模型在因果推理准确率上提升超过 33%。
- 该框架显著提升了在各类领域(如医疗、经济和环境科学)中因果推理任务的表现,包括直接因果与共同原因问题。
- 即使上下文 token 数量有限,C2P 也能通过邻接矩阵编码因果结构,实现对复杂因果查询的准确推理。
- 该方法在需要干预或反事实推理的场景下,优于现有方法如 CAUSALCoT 和 CARE-CA。
- 使用 C2P 结构化示例进行微调,显著提升了因果理解能力,即使在较小模型中也表现出明显改进,表明其具有广泛适用性。
- 该框架在处理间接因果推理方面表现出稳健性,但准确率仍低于直接因果关系,提示在 d-分离集成方面仍有进一步优化空间。
阅读本论文
在 Nubint 阅读器中打开原文,边读边就任意段落提问。
在 Nubint 中阅读本论文本解读由 AI 根据论文原文生成,引用前请核对原文。