Divide and Translate: Compositional First-Order Logic Translation and Verification for Complex Logical Reasoning

Hyun Ryu, Gyeongman Kim, Hyemin S. Lee, Eunho Yang

TL;DR

Large Language Models (LLMs) often stumble when translating complex natural language into formal logic, leading to reasoning failures in neurosymbolic systems. CLOVER (Compositional First-Order Logic Translation and Verification) solves this by breaking down convoluted sentences into atomic parts, translating them incrementally, and using a symbolic SAT solver to "cross-examine" the results. This approach achieves new state-of-the-art performance across seven logical reasoning benchmarks, particularly excelling on high-complexity tasks where traditional methods collapse.

The Translation Bottleneck in Neurosymbolic AI

Neurosymbolic AI—combining the linguistic prowess of LLMs with the rigorous precision of symbolic solvers (like Z3)—is a highly promising path for complex logical reasoning. In these systems, the LLM acts as a "translator," turning a natural language word problem into First-Order Logic (FOL) formulas. A sound symbolic solver then processes these formulas to find a mathematically certain answer.

However, there is a major bottleneck: translation is hard. When a sentence becomes logically dense (e.g., "The Sales division is toured on two consecutive days, and on no other days"), LLMs often fail to capture the nuances. They produce formulas that are either syntactically broken or logically inaccurate. Previous state-of-the-art methods like Logic-LM attempt to translate entire problems in one go. This leads to a "semantic gap" where the model loses track of complex dependencies, causing performance to drop off a cliff as logical complexity increases.

Translation accuracy vs. complexity and the divide-and-translate concept

The CLOVER Framework

To resolve this limitation, the authors introduce CLOVER, which treats translation as a multi-step construction process rather than a single intuitive leap. The framework consists of three main stages:

The CLOVER pipeline: Compositional Translation and SAT-based Verification

1. Logical Dependency Parsing

Instead of relying on a standard grammar tree, the model parses a sentence into a newly defined "logical dependency structure." It identifies logic units (atomic facts), couplers (conjunctions or merges), and dependents (modifiers that rely on other units).

2. Component Accumulation & Sequential Translation

The system starts with the simplest atomic subsentence and gradually adds components. At each step, the LLM translates the growing sentence into FOL. By the time it reaches the full, complex sentence, it has a reliable "trail" of simpler, successful translations to build upon. This compositionality mimics human thought—we build a mental model of a core fact and then layer on the constraints, rather than digesting a 50-word logical rule all at once.

3. SAT-Based Verification

Because an LLM might generate multiple plausible-looking formulas for a single sentence, CLOVER uses two verification algorithms to ensure reliability:

  • Logical Consistency: It groups formulas that are mathematically equivalent (using an SAT solver) and selects the most frequent, logically consistent group.
  • Disproving by Counter-Interpretation: The SAT solver generates a "counter-example"—a specific scenario where two candidate formulas disagree. The LLM is then prompted to act as a semantic judge: "In this specific scenario, does the original English sentence hold true?" This brilliantly bridges the gap between rigid symbols and fuzzy natural language, allowing the system to prune incorrect logical interpretations.

Experimental Setup and Key Results

The researchers evaluated CLOVER on seven diverse benchmarks, including AR-LSAT (analytical reasoning from the Law School Admission Test), ZebraLogic (complex logic grid puzzles), FOLIO, ProofWriter, and various BigBench tasks. They also introduced AR-LSAT-annotated, a new subset manually annotated to specifically measure formula-level translation accuracy.

CLOVER significantly outperformed previous neurosymbolic and pure-LLM baselines:

  • Massive Accuracy Gains: Performance on AR-LSAT jumped from 42.4% (Logic-LM) to 62.8%. On ZebraLogic, it improved from 45.4% to 75.4%.
  • Execution Reliability: On AR-LSAT, CLOVER’s ability to generate executable and correct programs reached 78.3%, compared to just 51.3% for the previous state-of-the-art.
  • Error Reduction: Error analysis showed that while previous models were plagued by "logic errors" (failing to capture the correct meaning), CLOVER effectively solved the core semantic translation problem. Its remaining errors shifted almost entirely to "preprocessing" (minor formatting or setup issues).

Limitations and Future Work

While highly effective, CLOVER's rigorous approach comes with trade-offs:

  • Inference Cost: CLOVER is more computationally expensive than direct translation. Because it requires multiple LLM calls for parsing, accumulation, and verification, the cost per problem on AR-LSAT was roughly $0.30, compared to $0.08 for Logic-LM.
  • Theory Generation Dependency: The system still relies on an initial "theory" (defining the sorts and functions) generated by the LLM. If the model fails to define the basic vocabulary of the problem correctly at the very start, subsequent steps cannot recover.

Future work may focus on optimizing the number of LLM calls to reduce inference costs or extending the framework to handle even more expressive logics beyond standard First-Order Logic.

Summary updated

BibTeX
@inproceedings{ryu2025divide,
  author = {Hyun Ryu and Gyeongman Kim and Hyemin S. Lee and Eunho Yang},
  title = {{Divide and Translate: Compositional First-Order Logic Translation and Verification for Complex Logical Reasoning}},
  booktitle = {International Conference on Learning Representations},
  year = {2025},
  url = {https://openreview.net/forum?id=09FiNmvNMw},
}
Figure