Reasoning or a Semblance of it? A Diagnostic Study of Transitive Reasoning in LLMs
This paper investigates whether LLaMA 2 and Flan-T5 exhibit genuine transitive reasoning or rely on superficial cues by controlling for word overlaps, pre-trained knowledge, and named entities, revealing that while both models leverage lexical overlaps, Flan-T5 demonstrates greater resilience to knowledge-based manipulations, suggesting a potential role for fine-tuning in developing logical understanding.
Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer
In the rapidly evolving field of artificial intelligence, a specific type of computer program known as a Large Language Model has captured the world's attention. These systems, trained on vast amounts of text from the internet, can write stories, translate languages, and answer complex questions. A central question for scientists studying these machines is whether they truly understand logic or if they are simply mimicking the patterns they have seen before. To test this, researchers look at a fundamental skill called transitive reasoning. In everyday terms, this is the ability to connect two separate pieces of information to reach a new conclusion. For instance, if a person knows that a cat is a type of animal, and that all animals need food, they can logically deduce that a cat needs food without being explicitly told that specific fact. This process requires more than just memory; it demands the ability to weave facts together. The question driving recent research is whether these powerful computer programs are actually performing this mental weaving, or if they are taking a shortcut by spotting familiar words and guessing the answer.
A team of researchers from Heriot-Watt University and the University of Edinburgh set out to investigate this very issue. They focused on two distinct types of language models, one called LLaMA 2 and another called Flan-T5, to see how they handled questions that required connecting two facts. The scientists used two existing collections of questions designed to test this kind of thinking. One collection, known as QASC, presents multiple-choice questions about science that require combining two statements to find the right answer. The other collection, called Bamboogle, contains questions that are tricky enough that a standard internet search engine might get them wrong, forcing the model to rely on its own processing. The researchers wanted to know if the models were genuinely reasoning through the steps or if they were just latching onto specific words, like dates or names, that appeared in both the question and the answer.
To find the truth, the team designed a series of clever experiments where they systematically altered the information given to the models. They started by checking if the models could solve the problems when given the facts and a clear example of how to connect them. Both models performed well under these conditions, but the researchers suspected this might be too easy. They then removed the example of how to connect the facts, leaving the models to figure it out on their own. The results were revealing. The Flan-T5 model, which had been specifically trained on similar reasoning tasks, continued to perform very well even without the example. The LLaMA 2 model, however, struggled significantly without that guidance, suggesting it relied heavily on seeing the pattern of reasoning before it could follow it.
The researchers then took a more drastic approach to see if the models were truly understanding the meaning of the words. They scrambled the order of the words within the facts, turning clear sentences into jumbled, nonsensical strings of text. If the models were truly reasoning about the meaning, this chaos should have made the answers impossible to find. Surprisingly, the models' performance barely dropped. They were still able to pick the correct answer even when the sentences made no grammatical sense. This suggested that the models were not reading the sentences as coherent thoughts. Instead, they were likely scanning for specific keywords that matched the answer choices. When the researchers removed those matching keywords entirely, the models' accuracy plummeted, confirming that they were often just matching words rather than deducing logic.
To rule out the possibility that the models were simply memorizing the answers from their training data, the team turned to the Bamboogle dataset, which contained questions the models had never seen before. Here, they introduced a final, rigorous test. They took the names of people, places, and dates—the specific entities that often appear in the answers—and replaced them with nonsense words. They also scrambled the order of the words in the facts. When the models were faced with these gibberish versions, the LLaMA 2 model failed almost completely. It could not find the answer without the familiar names and dates to guide it. The Flan-T5 model, however, showed a different kind of resilience. While its performance did drop, it remained significantly better than the other model. This suggests that because Flan-T5 was explicitly trained on reasoning tasks, it had developed a more robust ability to follow the logical chain, even when the familiar clues were stripped away.
The study concludes that while large language models can appear to reason, their success often depends on the specific way they were trained and the cues available in the text. For models that have not been specifically fine-tuned on reasoning tasks, the ability to answer complex questions seems to rely heavily on recognizing familiar words and patterns rather than genuine logical deduction. Even when they seem to be thinking step-by-step, they may simply be spotting the right keywords. However, the research suggests that when a model is carefully trained on datasets designed to teach it how to connect facts, it can develop a more genuine capacity for transitive reasoning. This capacity allows it to handle questions even when the usual shortcuts, like recognizable names or dates, are removed. The findings serve as a reminder that high scores on reasoning tests do not always prove a machine understands logic; sometimes, it is just very good at finding the right words.
Drowning in papers in your field?
Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.