MetricPrompt: Prompting Model as a Relevance Metric for Few-shot Text Classification

Hongyuan Dong, Weinan Zhang, Wanxiang Che
6/15/2023
cs.CL

No official code found. Best implementation: Dousia/MetricPrompt (19 stars, last commit 2024-08-10).

Abstract

Prompting methods have shown impressive performance in a variety of text mining tasks and applications, especially few-shot ones. Despite the promising prospects, the performance of prompting model largely depends on the design of prompt template and verbalizer. In this work, we propose MetricPrompt, which eases verbalizer design difficulty by reformulating few-shot text classification task into text pair relevance estimation task. MetricPrompt adopts prompting model as the relevance metric, further bridging the gap between Pre-trained Language Model's (PLM) pre-training objective and text classification task, making possible PLM's smooth adaption. Taking a training sample and a query one simultaneously, MetricPrompt captures cross-sample relevance information for accurate relevance estimation. We conduct experiments on three widely used text classification datasets across four few-shot settings. Results show that MetricPrompt outperforms manual verbalizer and other automatic verbalizer design methods across all few-shot settings, achieving new state-of-the-art (SOTA) performance.

View on arXivView PDF

Code Implementations(1)

Dousia/MetricPromptCommunity100%

Code for KDD 2023 long paper: MetricPrompt: Prompting Model as a Relevance Metric for Few-Shot Text Classification

192Shell, PythonMay 26, 20232 years ago

Similar Papers

Cite this paper

@article{dong2023metricprompt,
  title  = {MetricPrompt: Prompting Model as a Relevance Metric for Few-shot Text Classification},
  author = {Hongyuan Dong and Weinan Zhang and Wanxiang Che},
  year   = {2023},
  eprint = {2306.08892},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2306.08892v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2306.08892.svg)](https://codeofpaper.com/paper/2306.08892)

Discussion