Large Language Models as an Indirect Reasoner: Contrapositive and Contradiction for Automated Reasoning

Paper · arXiv 2402.03667 · Published February 6, 2024
Novel LLM Architectures

Recently, increasing attention has been drawn to improve the ability of Large Language Models (LLMs) to perform complex reasoning. However, previous methods, such as Chain-of-Thought and Self- Consistency, mainly follow Direct Reasoning (DR) frameworks, so they will meet difficulty in solving numerous real-world tasks which can hardly be solved via DR. Therefore, to strengthen the reasoning power of LLMs, this paper proposes a novel Indirect Reasoning (IR) method that employs the logic of contrapositives and contradictions to tackle IR tasks such as factual reasoning and mathematic proof. Specifically, our methodology comprises two steps. Firstly, we leverage the logical equivalence of contrapositive to augment the data and rules to enhance the comprehensibility of LLMs. Secondly, we design a set of prompt templates to trigger LLMs to conduct IR based on proof by contradiction that is logically equivalent to the original DR process. Our IR method is simple yet effective and can be straightforwardly integrated with existing DR methods to further boost the reasoning abilities of LLMs.

Introduction. Recently, pre-trained Large Language Models (LLMs) Wang et al (2022a); Brown et al (2020); Chowdhery et al (2023) have shown great success in various tasks related to language comprehension Touvron et al (2023); Heilbron et al (2022), content generation Liu et al (2023); Agossah et al (2023), and logical reasoning Kojima et al (2022); Wei et al (2022) due to their remarkable ability to infer from the context in zeroshot or few-shot way. This allows the LLMs to generalize well to unseen tasks. Among all the abilities, reasoning ability is perhaps one of the most important aspects for determining the performance of LLMs. To this end, Wei et al (2022) proposed Chain-of-Thought (CoT) prompting to encourage LLMs to explain their reasoning processes by appending some intermediate steps required to reach the answer in the prompt, and this explanation of the reasoning process often leads to improved results.

Discussion / Conclusion. In this paper, we propose an indirect reasoning method to enhance the reasoning power of LLMs by tailored prompts. Indirect reasoning can well compensate for problems which are not directly derivable from known conditions and rules. We validate the effectiveness of the indirect reasoning method in factual reasoning and mathematic proof tasks, and the results well confirm the usefulness of the proposed indirect reasoning strategy. Considering that the IR in this paper only involves the simple thoughts of contrapositive and contradiction, in the future, we can explore the possibility of integrating other more complex logical laws to make LLMs further improve their reasoning skills.