mlsanityData to 7 Oct 2026

Can Large Language Models Learn Formal Logic? A Data-Driven Training and Evaluation Framework

arXiv 2504.20213 ↗First posted 28 Apr 2025cs.LG cs.AIcited by 4

On the map: LLM reasoning → Reasoning benchmarks and evaluation

Abstract (arXiv)

This paper investigates the logical reasoning capabilities of large language models (LLMs). For a precisely defined yet tractable formulation, we choose the conceptually simple but technically complex task of constructing proofs in Boolean logic. A trained LLM receives as input a set of assumptions and a goal, and produces as output a proof that formally derives the goal from the assumptions. Incorrect proofs are caught by an automated proof checker. A critical obstacle for training is the scarcity of real-world proofs. We propose an efficient, randomized procedure for synthesizing valid proofs and introduce Template Transformation, a data augmentation technique that enhances the model's ability to handle complex logical expressions. The central evaluation question is whether an LLM has indeed learned to reason. We propose tests to measure the reasoning ability of a black-box LLM. By these measures, experiments demonstrate strong reasoning capabilities for assertions with short proofs, which decline with proof complexity. Notably, template transformation improves accuracy even for smaller models, suggesting its effectiveness across model scales.

Key facts. Cited by 4 papers in the map (data through 7 Oct 2026). Placed in Reasoning benchmarks and evaluation, one of 17 directions in LLM reasoning. Builds on 14 of its 24 references that are in the map. First posted on arXiv 28 Apr 2025.

Builds on

14 of 24 references.

Closest ancestors · 5

Same direction, newest first

  1. 2024Enhancing Reasoning Capabilities of LLMs via Principled Synthetic Logic Corpus19 Nov
  2. 2024LogicBench: Towards Systematic Evaluation of Logical Reasoning Ability of Large Language Models23 Apr
  3. 2023GLoRE: Evaluating Logical Reasoning of Large Language Models13 Oct
  4. 2023Learning Deductive Reasoning from Synthetic Corpus based on Formal Logic11 Aug
  5. 2023Testing the General Deductive Reasoning Capacity of Large Language Models Using OOD Examples24 May

Other references · 9

  1. 2024The Llama 3 Herd of Modelscited by 14,192
  2. 2022Chain-of-Thought Prompting Elicits Reasoning in Large Language Modelscited by 12,302
  3. 2023Tree of Thoughts: Deliberate Problem Solving with Large Language Modelscited by 3,155
  4. 2023LeanDojo: Theorem Proving with Retrieval-Augmented Language Modelscited by 414
  5. 2020Generative Language Modeling for Automated Theorem Provingcited by 379
  6. 2022Exploring Length Generalization in Large Language Modelscited by 204
  7. 2019On the Turing Completeness of Modern Neural Network Architecturescited by 129
  8. 2023What Formal Languages Can Transformers Express? A Surveycited by 120
  9. 2020On the Computational Power of Transformers and its Implications in Sequence Modelingcited by 85

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2025: 3; 2026: 1.

4 papers.

Similar, not cited

Close in wording, no citation either way

  1. 2025Large Language Models Meet Symbolic Provers for Logical Reasoning Evaluation
  2. 2025PCRLLM: Proof-Carrying Reasoning with Large Language Models under Stepwise Logical Constraints
  3. 2026LogicSkills: A Structured Benchmark for Formal Reasoning in Large Language Models
  4. 2026Pushing the Boundaries of Natural Reasoning: Interleaved Bonus from Formal-Logic Verification
  5. 2026QMFOL: Benchmarking Large Language Model Reasoning via Quantifiable Monadic First-Order Logic Test Case Generation
  6. 2024Exploring the Role of Reasoning Structures for Constructing Proofs in Multi-Step Natural Language Reasoning with Large Language Models
  7. 2024Proof of Thought : Neurosymbolic Program Synthesis allows Robust and Interpretable Reasoning
  8. 2022Selection-Inference: Exploiting Large Language Models for Interpretable Logical Reasoning