Retrieval-style In-context Learning for Few-shot Hierarchical Text Classification
Authors:
Open Access
- 30 September 2024
- journal article
- research article
- Published by MIT Press in Transactions of the Association for Computational Linguistics
- Vol. 12, 1214-1231
Abstract
Hierarchical text classification (HTC) is an important task with broad applications, and few-shot HTC has gained increasing interest recently. While in-context learning (ICL) with large language models (LLMs) has achieved significant success in few-shot learning, it is not as effective for HTC because of the expansive hierarchical label sets and extremely ambiguous labels. In this work, we introduce the first ICL-based framework with LLM for few-shot HTC. We exploit a retrieval database to identify relevant demonstrations, and an iterative policy to manage multi-layer hierarchical labels. Particularly, we equip the retrieval database with HTC label-aware representations for the input texts, which is achieved by continual training on a pretrained language model with masked language modeling (MLM), layer-wise classification (CLS, specifically for HTC), and a novel divergent contrastive learning (DCL, mainly for adjacent semantically similar labels) objective. Experimental results on three benchmark datasets demonstrate superior performance of our method, and we can achieve state-of-the-art results in few-shot HTC.Keywords
All Related Versions
This publication has 41 references indexed in Scilit:
- Hierarchical Text Classification as Sub-hierarchy Sequence GenerationProceedings of the AAAI Conference on Artificial Intelligence, 2023
- Label-Correction Capsule Network for Hierarchical Text ClassificationIEEE/ACM Transactions on Audio, Speech, and Language Processing, 2023
- CEHMR: Curriculum learning enhanced hierarchical multi-label classification for medication recommendationArtificial Intelligence in Medicine, 2023
- XRR: Extreme multi-label text classification with candidate retrieving and deep rankingInformation Sciences, 2022
- ContrastNet: A Contrastive Learning Framework for Few-Shot Text ClassificationProceedings of the AAAI Conference on Artificial Intelligence, 2022
- LA-HCN: Label-based Attention for Hierarchical Multi-label Text Classification Neural NetworkExpert Systems with Applications, 2022
- An analysis of hierarchical text classification using word embeddingsInformation Sciences, 2019
- HDLTex: Hierarchical Deep Learning for Text Classification2017
- DeepMeSH: deep semantic representation for improving large-scale MeSH indexingBioinformatics, 2016
- Multi-label learning with millions of labels2013