Conditional and Modal Reasoning in Large Language Models

Wesley H. Holliday, Matthew Mandelkern, Cedegao E. Zhang
1/30/2024
18 citations
cs.CLcs.AIcs.LO

Official code: wesholliday/llm-logic (13 stars, MIT, last commit 2025-05-31). 1 more implementation below.

Abstract

The reasoning abilities of large language models (LLMs) are the topic of a growing body of research in AI and cognitive science. In this paper, we probe the extent to which twenty-nine LLMs are able to distinguish logically correct inferences from logically fallacious ones.

Show full abstract

We focus on inference patterns involving conditionals (e.g., 'If Ann has a queen, then Bob has a jack') and epistemic modals (e.g., 'Ann might have an ace', 'Bob must have a king'). These inferences have been of special interest to logicians, philosophers, and linguists, since they play a central role in the fundamental human ability to reason about distal possibilities. Assessing LLMs on these inferences is thus highly relevant to the question of how much the reasoning abilities of LLMs match those of humans. All the LLMs we tested make some basic mistakes with conditionals or modals, though zero-shot chain-of-thought prompting helps them make fewer mistakes. Even the best performing LLMs make basic errors in modal reasoning, display logically inconsistent judgments across inference patterns involving epistemic modals and conditionals, and give answers about complex conditional inferences that do not match reported human judgments. These results highlight gaps in basic logical reasoning in today's LLMs.

View on arXivView PDF

Code Implementations(2)

Code implementations of this paper
RepositoryTypeStarsLanguageLicenseLast commit
wesholliday/llm-logicOfficial13–MIT2025-05-31
fatemeshahrokhshahi/llm-reasoningCommunity0PythonMIT2025-06-26
MIT

Supplementary material for the EMNLP 2024 paper "Conditional and Modal Reasoning in Large Language Models" by Wesley H. Holliday, Matthew Mandelkern, and Cedegao E. Zhang

130Feb 1, 20241 years agoMIT
MIT

Chain of Logic prompting method for conditional and modal reasoning in Large Language Models

00PythonJun 20, 20251 years agoMIT

Similar Papers

Cite this paper

@article{holliday2024conditional,
  title  = {Conditional and Modal Reasoning in Large Language Models},
  author = {Wesley H. Holliday and Matthew Mandelkern and Cedegao E. Zhang},
  year   = {2024},
  eprint = {2401.17169},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2401.17169v4}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2401.17169.svg)](https://codeofpaper.com/paper/2401.17169)

Discussion