Deloitte at #SMM4H 2024: Can GPT-4 Detect COVID-19 Tweets Annotated by Itself? (2024)

Abstract: The advent of Large Language Models (LLMs) such as Generative Pre-trained Transformers (GPT-4) mark a transformative era in Natural Language Generation (NLG). These models demonstrate the ability to generate coherent text that closely resembles human-authored content. They are easily accessible and have become invaluable tools in handling various text-based tasks, such as data annotation, report generation, and question answering. In this paper, we investigate GPT-4’s ability to discern between data it has annotated and data annotated by humans, specifically within the context of tweets in the medical domain. Through experimental analysis, we observe GPT-4 outperform other state-of-the-art models. The dataset used in this study was provided by the SMM4H (Social Media Mining for Health Research and Applications) shared task. Our model achieved an accuracy of 0.51, securing a second rank in the shared task.

heading: 1 Introduction
text: The field of Natural Language Generation (NLG) is undergoing a significant transformation driven by the emergence of LLMs like GPT-4 (OpenAI, 2023), and many other Large Language Models. These models are capable of generating text of human-level quality for a wide range of applications, such as data annotation (Tan et al., 2024), medical question answering (Kung et al., 2023), conversation response generation (Mousavi et al., 2023), and code auto-completion (Tang et al., 2023). Notably, the ability of these models to learn without extensive training data (zero-shot learning) or with just a few examples (few-shot learning), simplifies their integration into various language generation applications.
While the LLMs demonstrate the ability to understand the context and generate coherent humanlike responses, they do not have a true understanding of what they are producing (Li et al., 2023;
Turpin et al., 2023). This could potentially lead to adverse consequences when used in downstream applications. For example, consider an application of a LLM tasked with summarizing a medicinal drug datasheet inadvertently produces wrong dosage information. This generation of plausible but false content (referred as hallucination (Bang et al., 2023; Ji et al., 2023)), can unintentionally spread misinformation, false narratives, fake news, and spam. Similarly, the use of LLMs in data annotation has sparked a debate within the research community due to potential issues like inherent biases and hallucinations associated with these models (Yao et al., 2024; Bogdanov et al., 2024). Motivated by these challenges, the automatic detection of AI-generated outputs has emerged as an active area of research.
The detection of data annotations generated by LLMs closely resembles the process of identifying AI-generated text, which aims to distinguish between human-authored and machine-generated content (Abburi et al., 2023b,a). In this paper, we explore methodologies utilized for AI-generated text detection, with a particular emphasis on zeroshot detection techniques, and examine the synergies between these two areas. The AI-generated text detection methods predominantly involve the analysis of outputs from LLMs utilizing features such as entropy, log-probability scores, and perplexity (Wu et al., 2023; Yang et al., 2023a; Bao et al., 2023; Hans et al., 2024) to distinguish between human-written and machine-generated content. Building upon this foundation, DetectGPT (Mitchell et al., 2023) introduced the concept of analyzing negative log probability curvature, identifying a distinct pattern in AI-generated text. Subsequent advancements, such as DNA-GPT (Yang et al., 2023b), improved performance by analyzing the divergence of n-grams between the original text and LLM-prompted versions.
While zero-shot detection methods are effective,
79
their success often rely on direct access to the internal mechanisms of the specific LLM that generated the text. However, the underlying architecture and weights of many LLMs, including OpenAI’s GPT4, are not publicly available. As a result, these techniques often depend on a substitute LLM, presumed to have mechanisms similar to the proprietary model. The reliance on a proxy LLM may limit the robustness and generalizability of zeroshot detection in various scenarios.

heading: 2 GPT-4 as AI-annotated detector
text: While GPT-4 has exhibited proficiency in various Natural Language Processing (NLP) tasks, its potential for distinguishing between human-annotated and AI-annotated data remains largely untapped. In this study, we explore the effectiveness of GPT-4 in distinguishing between tweets it annotated and those annotated by humans in the medical domain. Our experimental analysis indicates that GPT-4 outperform other state-of-the-art models in detecting AI-annotated data.

heading: 2.1 Dataset
text: We use a dataset provided by the SMM4H shared task. The dataset consists of both human annotated (human) and GPT-4 annotated (generated) tweets detailing COVID-19 symptoms written in Latin American Spanish. In total 3,682 tweets were available for training and 2,110 tweets were available for testing. More details about the dataset can be found in the SMM4H overview paper (Xu et al., 2024).

heading: 2.2 Choice of prompt and experimental settings
text: We experimented with various prompts to identify the most effective one for label prediction. Our findings indicated that complex prompts often caused GPT-4 to generate incorrect labels. Therefore, we chose a simpler prompt, which resulted in better performance. The chosen prompt is as follows:
"Imagine you’re a data annotation expert. You’re presented with a tweet containing a description of potential COVID-19 symptoms. This tweet has already been annotated as containing COVID-19 symptoms, but you don’t know if that is annotated by a human expert or AI model. Your task is to analyze the tweet to determine
whether the initial annotation of ‘contains COVID19 symptoms’ was made by a human expert or by an AI model. Can you determine the source of the label (human or generated)? Answer in a single word, predicted label should be one of ‘human’ or
‘generated’. text : {text} prediction:{}"
Each tweet is passed to the prompt as {text}. Since this task involves classifying whether the given text is annotated by human or AI in a zeroshot setting, we do not fine-tune the model. Instead, we directly prompt GPT-4 to classify the test samples annotated by ‘human’ or ‘generated’. To limit randomness in the model’s output, which is crucial for classification accuracy, we set the temperature parameter to 0.

heading: 3 Results
text: To assess the performance of our approach in the zero-shot setting, we curated three distinct evaluation sets – Set 1, Set 2, and Set 3 as shown in Table 1. Each set consisted of 690 samples, randomly selected from the training data, to avoid overlap.
We conducted a comparative evaluation of our GPT-4-based approach against multiple zero-shot detection models. The two most effective baselines methods we identified were: 1) Binoculars (Hans et al., 2024), which compares the perplexity and cross-perplexity of two closely related language models to identify AI-generated text; and 2) FastDetectGPT (Bao et al., 2023), which utilizes conditional probability curvature to efficiently detect AI
content, particularly from models like GPT. Table 2 provides a comparative performance analysis of the baselines and our approach across the three distinct evaluation sets. Despite our GPT4 prompting-based approach consistently achieving the highest Acc and Fmac across each of the sets, the top scores did not exceed 0.5. This highlights the significant challenge posed by AI annotation detection, especially for tweets in the medical domain. Nevertheless, we used GPT-4 prompting to generate the predictions on the test set (predictions are uploaded to codalab), resulting in accuracy 0.51, which placed our team in second place in the shared task.

heading: 4 Conclusion
text: In this paper, we investigated the potential of GPT4 to detect tweets annotated by itself in zero-shot setting. Our experiments highlighted the complexity of this task, particularly for short texts in the medical domain, achieving an accuracy of 0.51. For future work, we aim to improve the model’s performance by incorporating the reasoning behind its predictions. By using this reasoning as additional input, we aim to enhance the model’s ability to differentiate between data annotations predicted by LLM and those annotated by human experts.

heading: A List of prompts explored
text: 1. "Imagine you’re a data annotation expert specializing in identifying the origin of annotations on social media posts. You are presented with a tweet that has been annotated as "contains COVID-19 symptoms. Your task is to analyze the tweet and determine whether this annotation was made by a human expert or generated by an AI model. Please follow these steps to make your determination: 1.Content Analysis: Examine the language and structure of the tweet. Consider the complexity, coherence, and nuance in describing COVID-19 symptoms. Evaluate the specificity and accuracy of the symptoms mentioned. Human experts tend to provide precise and medically accurate descriptions, whereas AI models might be more general or formulaic. 2.Annotation Style: Assess the style and quality of the annotation itself. Human annotations often reflect domain expertise and may include subtle contextual understanding.
Look for patterns typical of AI-generated annotations, such as repetitive phrasing, lack of deep contextual insight, or overly broad categories. 3.Consistency and Commonality: Compare the tweet with common patterns and characteristics known from human annotations versus AI-generated annotations. Humans may show more variability and adaptability in their descriptions. Based on your analysis, provide your prediction on whether the annotation was made by a human expert or generated by an AI model. Answer in a single word, predicted label should be one of ‘human’ or ‘generated’. text : {text} prediction:{}"
2. "Imagine you’re a data annotation expert specializing in identifying the origin of annotations on social media posts. You are presented with a tweet that has been annotated as ‘contains COVID-19 symptoms.’ Your task is to analyze the tweet and determine whether this annotation was made by a human expert or generated by an AI model. Answer in a single word, predicted label should be one of ‘human’ or ‘generated’. text : {text} prediction:{}"
3. "You are a GPT4 data annotation expert. Given a text, predict who annotated the text: human or AI. Predicted label should be one of ‘human’ or ‘generated’. text : {text} prediction:{}"

heading: Future Work
text: For future work, we aim to improve the model’s performance by incorporating the reasoning behind its predictions. By using this reasoning as additional input, we aim to enhance the model’s ability to differentiate between data annotations predicted by LLM and those annotated by human experts