Stance detection, also known as stance classification, is a task in natural language processing (NLP) and computational linguistics that uses content analysis and text mining to identify an author's position or stance on a specific subject. The task is most commonly framed as a classification or textual entailment problem over a fixed label set. Applications of stance detection include political discourse analysis, public health monitoring, misinformation identification, and content moderation on social media.
Research interest in the task grew after the release of the SemEval-2016 Task 6 benchmark, the first standardized dataset for stance detection on social media, which established shared evaluation norms for the NLP community. Although historically conflated with sentiment analysis, stance detection has increasingly been recognized as a distinct task of argument mining and opinion mining within NLP.
Methodological approaches have included traditional machine learning and deep learning architectures, as well as large language models due to their ability to generalize across targets and domains.
Early stance detection methods used several features for supervised classification, including n-grams, sentiment lexicons, syntactic relations, and topic-relatedness measures. Support vector machines (SVM) emerged as a dominant baseline, with SVM-based systems consistently competitive across benchmark datasets such as SemEval-2016, where topic-specific SVM models were trained on word and character n-grams. A recurring challenge was that topic-specific features learned on one set of targets did not generalize to unseen ones, with cross-dataset evaluations showing performance drops when models were applied to data outside their training domain.
Deep learning approaches supplanted feature-based methods as the primary methodology in stance detection, driven by the ability to capture semantic and contextual information directly from text without manual feature engineering. Early neural architectures applied to stance detection included convolutional neural networks for extracting local n-gram-like patterns and recurrent models such as LSTMs and bidirectional LSTMs for capturing sequential dependencies across longer contexts.
Transformer architectures, such as BERT and its variants, marked a further shift with contextual word embeddings that improved performance across benchmark datasets such as SemEval-2016. Unlike earlier static embedding models such as Word2Vec and GloVe, which assigned a single fixed vector to each word regardless of context, BERT uses bidirectional self-attention to produce representations that vary depending on surrounding words, enabling more precise modeling of the target-stance relationship. BERT is typically adapted to stance detection through fine-tuning, in which a pretrained model is further trained on a labeled stance dataset, allowing it to leverage broad linguistic knowledge acquired during pretraining while specializing to the classification task. A consistent finding across transformer-based models is that explicitly providing target information alongside the input text improves classification performance, as stance is inherently relational and cannot be reliably inferred from text alone.
A challenge across transformer-based approaches is cross-target generalizability, as models fine-tuned on one set of targets often rely on correlations with target-specific vocabulary and fail to transfer to unseen ones, motivating approaches that inject external contextual knowledge to improve robustness. A particular approach using encoder models is natural language inference (NLI), in which a document is paired with a hypothesis statement and the model predicts whether the document entails that hypothesis, enabling zero-shot and few-shot classification across tasks without additional training.
Ensemble methods combining fine-tuned transformer models with generative large language models have also been explored as a means of leveraging the complementary strengths of discriminative and generative approaches, with voting-based ensembles demonstrating competitive performance on domain-specific stance benchmarks. Smaller open-source encoder models trained on domain-specific NLI data can match or exceed large proprietary generative models for well-defined classification tasks while offering greater computational efficiency.
Large language models (LLMs) have been increasingly employed for stance detection. While encoder models like BERT create dense semantic representations of text that can be fine-tuned for classification, generative models produce text in response to natural-language prompts describing the task.
Generative LLMs are applied to stance detection primarily through prompt engineering, with several strategies developed to improve performance. Standard zero-shot prompting asks the model to assign a label given a task description, while few-shot prompting augments the prompt with labeled examples. Chain-of-thought prompting asks models to reason through intermediate steps before providing a final stance judgment. Chain of Stance is a variation which decomposes stance detection into sequential assertions about context, viewpoint, emotion, and logical consistency before arriving at a conclusion. Agentic and multi-expert frameworks extend this further by assigning specialized reasoning roles to different LLM agents whose outputs are then aggregated by a meta-judge. Retrieval-augmented approaches similarly inject external background knowledge into the reasoning process to handle targets that require up-to-date world knowledge.
Despite strong performance, generative models often cannot be archived for replication, raise concerns about political and demographic bias, and are costly to deploy at scale.
The target method defines the relationship between training and evaluation targets. In-target stance detection is a supervised setting in which models are trained and evaluated on the same target. Cross-target detection relaxes this constraint, training on one set of targets and testing on unseen ones, enabling generalization to new topics without additional annotation. Multi-target stance detection addresses the case where a single text may express positions toward multiple targets simultaneously, posing a more complex structured prediction problem.
Benchmarks like the VAST (Varied Stance), Stanceosaurus, MT-CSD (Multi-Turn Conversation Stance Detection), MmMtCSD (Multimodal Multi-turn Conversation Stance Detection), and ZS-CSD (Zero-Shot Conversational Stance Detection) datasets have been used to evaluate cross-target stance detection tasks.
Zero-shot and few-shot learning have become central to modern stance detection as researchers seek to move beyond task-specific models requiring large labeled datasets.
In zero-shot settings, a model classifies stance toward targets it has never explicitly trained on, typically by framing the task as natural language inference, or using instruction-tuned LLMs with a prompt describing the target and candidate stances.
Few-shot learning extends this by providing a small number of labeled examples, either in-context or via lightweight fine-tuning. This allows the model to adapt to new targets or domains without full retraining.