In-Context Learning for Text Classification with Many Labels
In-context learning (ICL) using large language models for tasks with many labels is challenging due to the limited context window, which makes it difficult to fit a sufficient number of examples in the prompt. In this paper, we use a pre-trained dense retrieval model to bypass this limitation, giving the model only a partial view of the full label space for each inference call. Testing with recent open-source LLMs (OPT, LLaMA), we set new state of the art performance in few-shot settings for three common intent classification datasets, with no finetuning. We also surpass fine-tuned performance on fine-grained sentiment classification in certain cases. We analyze the performance across number of in-context examples and different model scales, showing that larger models are necessary to effectively and consistently make use of larger context lengths for ICL. By running several ablations, we analyze the model's use of: a) the similarity of the in-context examples to the current input, b) the semantic content of the class names, and c) the correct correspondence between examples and labels. We demonstrate that all three are needed to varying degrees depending on the domain, contrary to certain recent works.
Code (0)
등록된 구현이 없습니다.
Tasks
ClassificationIn-Context Learningintent-classificationIntent ClassificationRetrievalSentiment AnalysisSentiment Classificationtext-classificationText ClassificationSimilar Papers 제목 키워드 기반
Context Unlocks Emotions: Text-based Emotion Classification Dataset Auditing with Large Language Models
The lack of contextual information in text data can make the annotation process of text-based emotion classification datasets challenging. As a result, such datasets often contain labels that fail to consider all the rel…
Emotion ClassificationSpatial-context-aware deep neural network for multi-class image classification
Multi-label image classification is a fundamental but challenging task in computer vision. Over the past few decades, solutions exploring relationships between semantic labels have made great progress. However, the under…
Classificationimage-classificationImage ClassificationMulti-Label Image ClassificationML-Net: multi-label classification of biomedical texts with deep neural networks
In multi-label text classification, each textual document can be assigned with one or more labels. Due to this nature, the multi-label text classification task is often considered to be more challenging compared to the b…
BenchmarkingClassificationFeature EngineeringGeneral Classification+5Scaling Laws for Many-Shot In-Context Learning with Self-Generated Annotations
The high cost of obtaining high-quality annotated data for in-context learning (ICL) has motivated the development of methods that use self-generated annotations in place of ground-truth labels. While these approaches ha…
In-Context LearningAttentionXML: Label Tree-based Attention-Aware Deep Model for High-Performance Extreme Multi-Label Text Classification
Extreme multi-label text classification (XMTC) is an important problem in the era of big data, for tagging a given text with the most relevant multiple labels from an extremely large-scale label set. XMTC can be found in…
General ClassificationMulti-Label Text ClassificationNews AnnotationProduct Categorization+2