Not All Large Language Models (LLMs) Succumb to the "Reversal Curse": A Comparative Study of Deductive Logical Reasoning in BERT and GPT Models

AI-generated keywords: Language models deductive logical reasoning BERT GPT LLaMA model

AI-generated Key Points

  • Study aimed to compare deductive logical reasoning capabilities of BERT and GPT
  • Focus on addressing the "Reversal Curse" and its impact on logical deduction
  • Utilized existing dataset from LLaMA model, adapted it for training and testing with BERT
  • Dataset created by generating new fictitious names using ChatGPT and substituting them into prompts
  • 900 prompts with positive and negative labels
  • Trained and tested on reverse direction using different name-description pairs for fairness in comparison
  • Fine-tuned vanilla pretrained BERT model (bert-base-cased) for text classification tasks
  • Measured accuracy in distinguishing between positive and negative prompts
  • Explored BERT's abilities in mastering set operations like intersection and union
  • Trained encoder and decoder models on two sets, evaluated performance on three newly created sets involving various combinations of union and intersection operations
  • Encoder and decoder models excelled in scenarios involving two sets but faced difficulties with operations involving three sets
  • Choosing between BERT or GPT should depend on specific task requirements
  • Leveraging their respective strengths can lead to more effective results
Also access our AI generated: Comprehensive summary, Lay summary, Blog-like article; or ask questions about this paper to our AI assistant.

Authors: Jingye Yang, Da Wu, Kai Wang

License: CC BY 4.0

Abstract: The "Reversal Curse" refers to the scenario where auto-regressive decoder large language models (LLMs), such as ChatGPT, trained on "A is B" fail to learn "B is A", demonstrating a basic failure of logical deduction. This raises a red flag in the use of GPT models for certain general tasks such as constructing knowledge graphs, considering their adherence to this symmetric principle. In our study, we examined a bidirectional LLM, BERT, and found that it is immune to the reversal curse. Driven by ongoing efforts to construct biomedical knowledge graphs with LLMs, we also embarked on evaluating more complex but essential deductive reasoning capabilities. This process included first training encoder and decoder language models to master the intersection ($\cap$) and union ($\cup$) operations on two sets and then moving on to assess their capability to infer different combinations of union ($\cup$) and intersection ($\cap$) operations on three newly created sets. The findings showed that while both encoder and decoder language models, trained for tasks involving two sets (union/intersection), were proficient in such scenarios, they encountered difficulties when dealing with operations that included three sets (various combinations of union and intersection). Our research highlights the distinct characteristics of encoder and decoder models in simple and complex logical reasoning. In practice, the choice between BERT and GPT should be guided by the specific requirements and nature of the task at hand, leveraging their respective strengths in bidirectional context comprehension and sequence prediction.

Submitted to arXiv on 06 Dec. 2023

Ask questions about this paper to our AI assistant

You can also chat with multiple papers at once here.

AI assistant instructions?

Results of the summarizing process for the arXiv paper: 2312.03633v1

The study aimed to compare the deductive logical reasoning capabilities of two large language models (LLMs), BERT and GPT. Specifically, it focused on addressing the "Reversal Curse" and its impact on logical deduction. To conduct their analysis, the researchers utilized an existing dataset from the LLaMA model and prepared it for training and testing with BERT. The dataset was adapted by creating new fictitious names using ChatGPT and randomly substituting them into positive prompts. This resulted in 900 prompts with both positive and negative labels. To ensure fairness in comparison, the researchers also trained and tested on the reverse direction using different name-description pairs. They fine-tuned a vanilla pretrained BERT model (bert-base-cased) specifically for text classification tasks and measured accuracy based on its ability to distinguish between positive and negative prompts. In addition to comparing BERT's performance with GPT in deductive reasoning tasks, the researchers also explored its abilities in mastering set operations such as intersection and union. They trained encoder and decoder models on two sets and evaluated their performance on three newly created sets involving various combinations of union and intersection operations. The findings revealed that while both encoder and decoder models excelled in scenarios involving two sets, they encountered difficulties when dealing with operations involving three sets. This highlights the distinct characteristics of these models in simple versus complex logical reasoning tasks. In conclusion, this study emphasizes that choosing between BERT or GPT should depend on the specific requirements of the task at hand. Leveraging their respective strengths in bidirectional context comprehension and sequence prediction can lead to more effective results.
Created on 23 Jan. 2024

Assess the quality of the AI-generated content by voting

Score: 0

Why do we need votes?

Votes are used to determine whether we need to re-run our summarizing tools. If the count reaches -10, our tools can be restarted.

The previous summary was created more than a year ago and can be re-run (if necessary) by clicking on the Run button below.

Look for similar papers (in beta version)

By clicking on the button above, our algorithm will scan all papers in our database to find the closest based on the contents of the full papers and not just on metadata. Please note that it only works for papers that we have generated summaries for and you can rerun it from time to time to get a more accurate result while our database grows.

Disclaimer: The AI-based summarization tool and virtual assistant provided on this website may not always provide accurate and complete summaries or responses. We encourage you to carefully review and evaluate the generated content to ensure its quality and relevance to your needs.