Skip to main content
QUICK REVIEW

[Paper Review] Exploiting Cloze Questions for Few Shot Text Classification and Natural Language Inference

Timo Schick, Hinrich Schütze|arXiv (Cornell University)|Jan 21, 2020
Topic ModelingComputer Science15 citations
TL;DR

This paper introduces Pattern-Exploiting Training (PET), a semi-supervised method that reformulates few-shot text classification and natural language inference tasks into cloze-style questions using natural language patterns and verbalizers. By fine-tuning a pretrained language model on these patterns, PET generates soft labels for large unlabeled datasets, which are then used to train a final classifier—achieving state-of-the-art performance in low-resource settings across multiple languages and tasks.

ABSTRACT

Some NLP tasks can be solved in a fully unsupervised fashion by providing a pretrained language model with "task descriptions" in natural language (e.g., Radford et al., 2019). While this approach underperforms its supervised counterpart, we show in this work that the two ideas can be combined: We introduce Pattern-Exploiting Training (PET), a semi-supervised training procedure that reformulates input examples as cloze-style phrases to help language models understand a given task. These phrases are then used to assign soft labels to a large set of unlabeled examples. Finally, standard supervised training is performed on the resulting training set. For several tasks and languages, PET outperforms supervised training and strong semi-supervised approaches in low-resource settings by a large margin.

Motivation & Objective

  • Address the challenge of poor performance in few-shot NLP tasks due to limited labeled data.
  • Overcome the difficulty of generalizing from only a few labeled examples by incorporating task descriptions.
  • Develop a semi-supervised method that leverages unlabeled data effectively using pretrained language models.
  • Improve few-shot learning performance by combining supervised fine-tuning with pattern-based knowledge distillation from PLMs.

Proposed method

  • Define multiple cloze-style patterns (e.g., 'This was the best pizza I’ve ever had. It was ____') to express task semantics.
  • Use verbalizers to map class labels to plausible fill-in-the-blank completions (e.g., 'great' → '1', 'bad' → '-1').
  • Fine-tune a pretrained language model on each pattern-verbalizer pair using the small labeled set.
  • Ensemble the fine-tuned models to predict soft labels on a large unlabeled dataset.
  • Train a final classifier on the soft-labeled dataset using standard supervised learning.
  • Introduce iPET, an iterative variant that gradually increases the training set size across generations.

Experimental results

Research questions

  • RQ1Can cloze-style patterns improve few-shot text classification and natural language inference when combined with supervised fine-tuning?
  • RQ2How does PET compare to supervised training and strong semi-supervised baselines in low-resource settings?
  • RQ3Does the iterative refinement process (iPET) lead to consistent performance gains over multiple generations?
  • RQ4To what extent does the performance gain of PET stem from unlabeled data versus the pattern-based knowledge distillation?
  • RQ5How sensitive is PET to the choice of patterns, and can ensemble or distillation mitigate poor-performing patterns?

Key findings

  • PET significantly outperforms standard supervised fine-tuning and strong semi-supervised baselines on few-shot text classification and natural language inference tasks.
  • For a 10-example training set, PET achieves an average accuracy of 85.6% on AG’s News and 83.2% on Yelp, surpassing supervised baselines by over 10 percentage points.
  • The iterative variant iPET improves performance across all generations, with the final model achieving 88.1% accuracy on AG’s News when trained over four generations.
  • Knowledge distillation reduces the final classifier size while improving accuracy, showing that soft labels are more effective than hard labels from individual models.
  • Even with a single pattern, PET outperforms the best individual pattern, demonstrating that ensemble learning mitigates pattern-specific weaknesses.
  • In-domain pretraining does not fully explain PET’s gains, as PET still outperforms supervised models even when both are fine-tuned on the same in-domain data.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.