Abstract
Zero-shot text classification is a powerful tool for natural language processing but is notoriously sensitive to prompt engineering and the choice of "verbalizers" (label words). This paper introduces LABELDESCTRAINING (LDT), a novel approach that fine-tunes models on a curated set of label descriptions—such as dictionary definitions and synonyms—instead of traditional labeled documents. LDT achieves substantial accuracy improvements of 17-19% absolute over standard zero-shot baselines and demonstrates superior robustness to domain shifts and prompt variations.
Introduction
The current state-of-the-art for zero-shot classification typically employs a "pattern-verbalizer" approach. For instance, to classify news, a model might process the prompt "The topic of this news is [MASK]" and predict whether the masked token corresponds to "Sports" or "Business." However, this method faces two critical challenges: extreme instability based on minor prompt changes and significant performance degradation when applied to out-of-distribution data.
To address these issues, the authors propose training models on the meaning of labels. By bridging the gap between pure zero-shot learning and full supervision, LDT leverages the semantic knowledge embedded in label descriptions to create more robust classifiers.
Methodology: LABELDESCTRAINING
The core of the LDT approach is the construction of LABELDESC datasets. Unlike standard datasets that pair documents with labels, LABELDESC pairs semantic descriptions with their corresponding labels.
Data Curation
Descriptions are gathered from four primary sources:
- Related Terms: Synonyms and high-relevance keywords.
- Dictionary Definitions: Sourced from standard references like Dictionary.com.
- Encyclopedia Entries: Introductory sentences from Wikipedia.
- Templates: Hand-crafted phrases representing the label's sentiment or category.
The model (e.g., RoBERTa) is fine-tuned using these descriptions with the same pattern-verbalizer objective used during inference. This allows the model to internalize the semantic boundaries of each class before encountering real-world test data.
Experimental Setup
The method was evaluated across diverse tasks:
- Topic Classification: AGNews, Yahoo Answers, and DBPedia.
- Sentiment Classification: SST-2, SST-5, Yelp-2, Yelp-5, IMDB, and Amazon Reviews.
To ensure a true zero-shot evaluation, all hyperparameters were tuned on a separate dataset, 20 Newsgroups (20NG), which was not used in the final evaluation.
Results and Discussion
LDT consistently outperformed standard zero-shot baselines across all tested datasets.
Key Findings
- Performance Gains: LDT improved accuracy by an average of 17.5% for RoBERTa-base and 18.9% for RoBERTa-large.
- Robustness to Prompts: The standard deviation of performance across different prompt patterns decreased significantly, making the model less sensitive to specific phrasing.
- Efficiency vs. Few-Shot Learning: Remarkably, LDT often outperformed few-shot supervised learning. As shown in the results, training on a handful of label descriptions was frequently more effective than training on hundreds of labeled examples from a different domain.
- Competitive with Large Models: A RoBERTa-large model (355M parameters) using LDT outperformed GPT-3.5 (
text-davinci-003, 175B parameters) on several benchmarks, including AGNews and DBPedia.
Conclusion and Future Work
LABELDESCTRAINING demonstrates that teaching models the concepts behind labels is a highly effective strategy for zero-shot classification. While the current method requires some manual curation of definitions, it offers a scalable and robust alternative to traditional prompt engineering. Future research may explore automating the description retrieval process and extending this framework to more complex tasks like Natural Language Inference (NLI).
Summary updated