Abstract
Stance detection holds great potential for enhancing the quality of online political discussions, as it has shown to be useful for summarizing discussions, detecting misinformation, and evaluating opinion distributions. Usually, transformer-based models are used directly for stance detection, which require large amounts of data. However, the broad range of debate questions in online political discussion creates a variety of possible scenarios that the model is faced with and thus makes data acquisition for model training difficult. In this work, we show how to leverage LLM-generated synthetic data to train and improve stance detection agents for online political discussions: (i) We generate synthetic data for specific debate questions by prompting a Mistral-7B model and show that fine-tuning with the generated synthetic data can substantially improve the performance of stance detection. (ii) We examine the impact of combining synthetic data with the most informative samples from an unlabelled dataset. First, we use the synthetic data to select the most informative samples, second, we combine both these samples and the synthetic data for fine-tuning. This approach reduces labelling effort and consistently surpasses the performance of the baseline model that is trained with fully labeled data. Overall, we show in comprehensive experiments that LLM-generated data greatly improves stance detection performance for online political discussions.
Introduction
Stance detection—the task of automatically determining if a person is "for" or "against" a specific topic—is a critical component for improving online political discourse. It enables automated summarization of complex debates, helps moderators identify toxicity, and ensures the representation of diverse viewpoints. However, two major hurdles impede its widespread application. First, political topics are incredibly diverse; training a model to understand a specific debate (e.g., Swiss healthcare policy) requires thousands of labeled examples, which are expensive and slow to collect. Second, while Large Language Models (LLMs) like GPT-4 or Mistral are highly capable at text generation, they can be inconsistent, biased, or vulnerable to adversarial attacks when used directly as classifiers in live environments.
This research proposes a "best of both worlds" approach: leveraging the creative power of LLMs in an offline environment to generate synthetic training data for smaller, more stable "traditional" models like BERT. These models are faster, more consistent, and easier to deploy in production settings.
Methodology
The proposed pipeline treats the LLM as a sophisticated data augmentor rather than the final classifier. The process involves three key stages:
- Synthetic Generation: Researchers used Mistral-7B to generate "favor" and "against" comments for specific political questions. To leverage the LLM's superior reasoning in English while targeting German-language debates, a translation model (NLLB-300M) was used to bridge the languages.
- Fine-tuning BERT: Instead of direct LLM classification, the generated synthetic data was used to fine-tune a BERT model, providing it with a clear signal of what constitutes a pro or con stance.
- Synthetic Query By Committee (SQBC): This novel approach uses synthetic data as a "reference distribution." By analyzing where real, unlabelled comments sit in relation to the synthetic clusters, the system identifies the most informative samples—those where the model is most uncertain. These ambiguous samples are then prioritized for human labeling in an Active Learning framework.
Experimental Setup
The study utilized the X-Stance dataset, a comprehensive multilingual collection of over 48,000 comments from Swiss election candidates across 140 policy questions. For robust evaluation, the authors selected 10 specific questions reflecting a wide variety of topics and data distributions (balanced vs. unbalanced).
Key Results and Discussion
The experiments demonstrate that synthetic data acts as a powerful prior that "smoothens" the decision boundary for the classifier. It provides a clean, canonical version of stances, making the model more robust to the messy, emotional outliers found in real-world human comments.
Key findings include:
- Synthetic Only Performance: Fine-tuning BERT on only 1,000 synthetic samples (with zero real human labels) achieved an F1-score of 0.723, nearly matching models trained on entire human-labeled datasets.
- Surpassing the Gold Standard: By combining synthetic data with the SQBC active learning strategy, the researchers surpassed the performance of the baseline model trained on all true labels, while requiring only 25% of the original manual labeling effort.
- Efficiency: Generating 1,000 synthetic samples takes approximately 3 hours on an A100 GPU, while the subsequent BERT fine-tuning takes less than a minute, making the approach highly practical for resource-constrained organizations.
Conclusion
This work provides a blueprint for building high-performing stance detection tools for niche topics without the need for massive labeling budgets. While future work will look toward more "generalist" models that handle multiple topics simultaneously, the current results prove that LLM-generated synthetic data can effectively bridge the data gap in political discourse analysis. By using LLMs as "synthetic data factories," researchers can train specialized models that are both more accurate and more efficient than those relying solely on human-labeled data.
Summary updated