FLARE: Faithful Logic-Aided Reasoning and Exploration

Erik Arakelyan, Pasquale Minervini, Pat Verga, Patrick S. H. Lewis, Isabelle Augenstein

Introduction

Large Language Models (LLMs) have demonstrated remarkable capabilities in multi-step reasoning through techniques like Chain-of-Thought (CoT). However, a persistent challenge remains: unfaithfulness. This occurs when a model's final answer does not logically follow from its intermediate steps, or when it "hallucinates" facts to support a predetermined conclusion. While neuro-symbolic methods—where LLMs generate code for external solvers—offer a potential solution, they are often too rigid to handle the nuances and "fuzzy" logic inherent in natural language.

FLARE (Faithful Logic-Aided Reasoning and Exploration) addresses this by enabling LLMs to stay faithful to their own logic through a simulated execution framework that combines symbolic rigor with linguistic flexibility.

The FLARE Framework

FLARE introduces a modular, four-stage pipeline designed to formalize and verify reasoning steps before reaching a conclusion:

  1. Plan Generation: The LLM develops a natural language strategy and analyzes the problem requirements.
  2. Code Generation: The model translates the plan into Prolog, a logic programming language. This involves defining specific "facts" and "relations" (rules) that govern the problem space.
  3. Simulated Search: Instead of relying on an external engine, the LLM is prompted to simulate the execution trace of the Prolog code. It mimics a depth-first search, documenting rule calls, path exploration, and backtracking.
  4. Final Answer: The model synthesizes the plan, the code, and the simulated trace to produce the final result.
The FLARE pipeline: from natural language planning to simulated Prolog execution.

By simulating code execution rather than strictly compiling it, FLARE allows the model to navigate common-sense nuances that a rigid symbolic solver might reject as syntax or logic errors.

Experimental Evaluation

The researchers evaluated FLARE across 12 diverse benchmarks, including:

  • Math Word Problems: GSM8K, SVAMP, MultiArith, ASDiv, and AQuA.
  • Multi-hop QA: StrategyQA and BIG-Bench subsets (Date and Sports Understanding).
  • Relation and Logic Inference: CLUTRR (family trees), PrOntoQA, LogicalDeduction, and AR-LSAT.

Key Results and Performance

FLARE achieved State-of-the-Art (SOTA) results on 7 out of 9 general reasoning benchmarks and all 3 logic benchmarks tested. On average, the framework demonstrated a 28% performance increase over standard CoT and a 16% increase over Faithful CoT (which utilizes external solvers).

Performance comparison of FLARE against Chain-of-Thought (CoT) and Faithful CoT (F-CoT) across multiple reasoning benchmarks.

Beyond raw accuracy, the study revealed critical insights into model behavior:

  • Faithfulness Correlates with Accuracy: There is a strong positive correlation between how closely a model's simulated search matches a real logic solver (measured via ROUGE-Lsum) and its likelihood of reaching the correct answer.
  • Structural Hallucinations: By comparing generated code to the simulated trace, researchers can identify specific failure points, such as the use of "hallucinated" facts not present in the code or sub-optimal reasoning where the model fails to apply its own defined rules.
  • Trace Analysis: Successful reasoning traces showed an 18.1% increase in unique emergent facts and an 8.6% higher overlap between code-defined rules and the actual execution path compared to failed attempts.

Discussion and Future Work

While FLARE significantly improves reasoning faithfulness, it is not without limitations. As a sequential pipeline, errors in the initial planning or coding stages can cascade through the simulation. Additionally, the framework remains sensitive to prompt phrasing, and extremely deep search trees may challenge the model's context window.

Future research will focus on "self-refinement" loops, allowing the model to detect internal inconsistencies during simulation and autonomously correct its code or plan to improve reliability.

Summary updated

BibTeX
@misc{arakelyan2024flare,
  author = {Erik Arakelyan and Pasquale Minervini and Pat Verga and Patrick S. H. Lewis and Isabelle Augenstein},
  title = {{FLARE: Faithful Logic-Aided Reasoning and Exploration}},
  year = {2024},
  eprint = {2410.11900},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2410.11900},
}
Figure