CAMA: Enhancing Mathematical Reasoning in Large Language Models with Causal Knowledge

2508.02583v2 cs.AI, cs.LG 2025-08-09
Авторы:

Lei Zan, Keli Zhang, Ruichu Cai, Lujia Pan

Резюме на русском

**Резюме** Несмотря на выдающиеся результаты во многих областях, Large Language Models (LLMs) сталкиваются с трудностями при выполнении задач, требующих сложного математического рассуждения. Это ограничение возникает из-за проблем с глубокой структурной зависимостью и недостатком явной структуры в процессе вывода. В статье предлагается **CAMA** (Causal Mathematician) — двухэтапная модель, которая внедряет в LLMs исчерпывающую структуру математической логики. В первой стадии CAMA строит **Mathematical Causal Graph (MCG)**, аккумулируя ключевую информацию из расширенного набора задач с решениями. Этот граф описывает зависимости между знаниями и их причинно-следственными отношениями. Во второй стадии CAMA адаптирует MCG к конкретной задаче, используя выбранные примеры для дополнительной оптимизации. Результаты экспериментов показали, что CAMA улучшает производительность LLMs на задачах математического анализа, демонстрируя преимущество структурированного подхода над неструктурированным. Также оказалось, что учёт ассимметричных связей в графе способствует более существенным улучшениям по сравнению с использованием только симметричных связей.

Abstract

Large Language Models (LLMs) have demonstrated strong performance across a wide range of tasks, yet they still struggle with complex mathematical reasoning, a challenge fundamentally rooted in deep structural dependencies. To address this challenge, we propose \textbf{CA}usal \textbf{MA}thematician (\textbf{CAMA}), a two-stage causal framework that equips LLMs with explicit, reusable mathematical structure. In the learning stage, CAMA first constructs the \textbf{M}athematical \textbf{C}ausal \textbf{G}raph (\textbf{MCG}), a high-level representation of solution strategies, by combining LLM priors with causal discovery algorithms applied to a corpus of question-solution pairs. The resulting MCG encodes essential knowledge points and their causal dependencies. To better align the graph with downstream reasoning tasks, CAMA further refines the MCG through iterative feedback derived from a selected subset of the question-solution pairs. In the reasoning stage, given a new question, CAMA dynamically extracts a task-relevant subgraph from the MCG, conditioned on both the question content and the LLM's intermediate reasoning trace. This subgraph, which encodes the most pertinent knowledge points and their causal dependencies, is then injected back into the LLM to guide its reasoning process. Empirical results on real-world datasets show that CAMA significantly improves LLM performance on challenging mathematical problems. Furthermore, our experiments demonstrate that structured guidance consistently outperforms unstructured alternatives, and that incorporating asymmetric causal relationships yields greater improvements than using symmetric associations alone.

Ссылки и действия