LGMT: A Tool for Testing the Logical Reasoning Reliability of LLMs
Abstract
Large Language Models (LLMs) increasingly serve as reasoning components in modern software systems, yet a model that answers a logical query correctly can contradict itself when the same problem is restated in an equivalent form. Static benchmarks evaluate queries in isolation and therefore fail to expose such inconsistencies. To address this limitation, we present LGMT, an open-source tool that detects reasoning inconsistencies through metamorphic relations grounded in first-order logic. Given a source test case in premise-conclusion form, LGMT generates logically equivalent follow-up cases and checks whether the model's entailment predictions agree across the pair, without ground-truth labels. The tool provides 20 built-in metamorphic relations, supports custom ones verified by the Z3 theorem prover, and runs from a CLI or a web studio, including an offline mock mode requiring no API key. Across six widely used LLMs on a bundled benchmark of 3,091 metamorphic groups, LGMT reveals inconsistency rates ranging from 20.84% to 29.44%. LGMT is publicly available on GitHub at https://github.com/MaxwelsDonc/lgmt-tool, with a demonstration video at https://youtu.be/gou4opptu1U.
Create a lesson
Related papers
Temporal Logic Tensor Networks: Foundations of Temporal Reasoning in Neural Networks
Shared title terminologycs.AIEdjard Mota, Artur d'Avila Garcez, Maria Azevedo et al.
Collective Emergent Alignment: Measuring and Amplifying Interaction-Induced Reasoning Alignment in Multi-Agent LLMs
Shared title terminologycs.AIBoxuan Wang, Zhuoyun Li, Sarvapali D. Ramchurn et al.
Direct Pass@k Optimization for Thought Pruning: Balancing Quality and Diversity in Test-Time Reasoning
Shared title terminologycs.AIMahdi Salmani, Adel Javanmard, Devansh Gupta et al.
SAE-Audit: Clinical-Trial Prediction via Inference-Time Optimization of Black-Box LLMs Audited by Sparse Autoencoder Evidence
Shared title terminologycs.AIJunbo Shen
Do You Even Know What I Want? Improving LLMs Ability to Detect Hidden User Intent
Shared title terminologycs.AIKelsey Sikes, Sarath Sreedharan
Learning from Another Angle: Rotation-Based Test-Time Training for Multimodal Large Language Models
Shared title terminologycs.AIChangyu Liu, Fei Zhao, Yiyang Liu et al.