Navigating Prompt Complexity for Zero-Shot Classification: A Study of Large Language Models in Computational Social Science

Yida Mu, Ben P. Wu, William Thorne, Ambrose Robinson, Nikolaos Aletras, Carolina Scarton, Kalina Bontcheva, Xingyi Song

Abstract

Instruction-tuned Large Language Models (LLMs) have exhibited impressive language understanding and the capacity to generate responses that follow specific prompts. However, due to the computational demands associated with training these models, their applications often adopt a zero-shot setting. In this paper, we evaluate the zero-shot performance of two publicly accessible LLMs, ChatGPT and OpenAssistant, in the context of six Computational Social Science classification tasks, while also investigating the effects of various prompting strategies. Our experiments investigate the impact of prompt complexity, including the effect of incorporating label definitions into the prompt; use of synonyms for label names; and the influence of integrating past memories during foundation model training. The findings indicate that in a zero-shot setting, current LLMs are unable to match the performance of smaller, fine-tuned baseline transformer models (such as BERT-large). Additionally, we find that different prompting strategies can significantly affect classification accuracy, with variations in accuracy and F1 scores exceeding 10%.

Introduction

Computational Social Science (CSS) involves analyzing social media for complex, often subjective phenomena like sarcasm, hate speech, and rumor propagation. Traditionally, this requires training specialized models on laboriously labeled data. The emergence of instruction-tuned Large Language Models (LLMs) offers a potential "zero-shot" alternative, where a model is asked to classify text without task-specific training. This study investigates whether these general-purpose models can truly replace specialized, fine-tuned baselines in the nuanced domain of social media analysis.

Methodology

The researchers evaluated two primary LLMs: GPT-3.5-turbo (proprietary) and OpenAssistant-LLaMA (30B, open-source). These were compared against a weak Logistic Regression baseline and a strong, fully fine-tuned BERT-large model. The study utilized six diverse English-language datasets covering complaints, vaccine stance, bragging, rumor stance, sarcasm, and hate speech.

To explore the impact of prompt engineering, four distinct strategies were developed:

  • Basic: A simple instruction (e.g., "Identify if this tweet is bragging").
  • Task and Label Description (T/L Desc): Incorporating formal definitions of categories from original research papers.
  • Few-sample: Providing one labeled example per class.
  • Memory Recall: Mentioning the specific academic paper title associated with the dataset to test if the model could "recall" the task from its training data.
Figure 1: Examples of the four prompting strategies applied across different CSS tasks.

Key Results

The experimental results revealed a significant performance gap between zero-shot LLMs and fine-tuned models. Despite their massive scale, the zero-shot LLMs were unable to match the performance of the fine-tuned BERT-large model in four out of the six classification tasks. For instance, in the Bragging task, BERT-large achieved 91.3% accuracy, while the best GPT configuration reached only 84.9%.

Furthermore, the choice of prompting strategy proved critical. Variations in accuracy and F1 scores exceeded 10% depending on the prompt used, highlighting the inherent "brittleness" of zero-shot classification. Generally, GPT-3.5 consistently outperformed LLaMA-OA across most tasks and prompt settings.

Figure 5: Comparative performance of Logistic Regression, BERT-large, and various LLM prompting strategies across all six CSS datasets.

Discussion: The "Less is More" Paradox

A counter-intuitive finding of this study is that increasing prompt complexity—such as adding detailed definitions or few-shot examples—often degraded performance. This "Less is More" paradox suggests that additional information can introduce noise, causing models to over-focus on specific keywords rather than the underlying human intent. Simple, direct prompts often yielded the most stable and accurate results.

Additionally, the models exhibited high label sensitivity. Replacing a label like "Complaint" with synonyms such as "Grievance" or "Criticism" led to significant performance swings. The study also found evidence of data leakage; when prompted with academic paper titles, models could recall specific task details, suggesting their zero-shot performance may be partially inflated by exposure to benchmark descriptions during pre-training.

Conclusion and Future Work

While LLMs are powerful tools for language understanding, this study demonstrates that for specialized CSS tasks, fine-tuned models like BERT-large remain the superior choice. Zero-shot LLMs are highly sensitive to prompt wording and often struggle with the added complexity of detailed instructions. Future research will explore more advanced techniques such as Chain-of-Thought prompting and the performance of even larger models like GPT-4 to see if they can bridge the gap with fine-tuned baselines.

Summary updated

BibTeX
@inproceedings{mu2024navigating,
  author = {Yida Mu and Ben P. Wu and William Thorne and Ambrose Robinson and Nikolaos Aletras and Carolina Scarton and Kalina Bontcheva and Xingyi Song},
  title = {{Navigating Prompt Complexity for Zero-Shot Classification: A Study of Large Language Models in Computational Social Science}},
  booktitle = {International Conference on Computational Linguistics},
  year = {2024},
  url = {https://openreview.net/forum?id=rWyB9h80jM},
}
Figure