Skip to main content
QUICK REVIEW

[Paper Review] CG-BERT: Conditional Text Generation with BERT for Generalized Few-shot Intent Detection

Congying Xia, Chenwei Zhang|arXiv (Cornell University)|Apr 4, 2020
Topic ModelingComputer Science37 references35 citations
TL;DR

CG-BERT introduces a conditional text generation approach that uses CVAE and BERT to model utterance distributions per intent, enabling generation of diverse examples for novel intents and improving generalized few-shot intent detection (GFSID).

ABSTRACT

In this paper, we formulate a more realistic and difficult problem setup for the intent detection task in natural language understanding, namely Generalized Few-Shot Intent Detection (GFSID). GFSID aims to discriminate a joint label space consisting of both existing intents which have enough labeled data and novel intents which only have a few examples for each class. To approach this problem, we propose a novel model, Conditional Text Generation with BERT (CG-BERT). CG-BERT effectively leverages a large pre-trained language model to generate text conditioned on the intent label. By modeling the utterance distribution with variational inference, CG-BERT can generate diverse utterances for the novel intents even with only a few utterances available. Experimental results show that CG-BERT achieves state-of-the-art performance on the GFSID task with 1-shot and 5-shot settings on two real-world datasets.

Motivation & Objective

  • Motivate and address Generalized Few-Shot Intent Detection (GFSID), where the label space includes both existing intents with abundant data and novel intents with few examples.
  • Propose CG-BERT to model and sample from the utterance distribution conditioned on intents, enabling pseudo-label generation for novel intents.
  • Augment training data with generated utterances and fine-tune a BERT classifier to achieve better joint label space discrimination.

Proposed method

  • Represent input as an intent–utterance pair fed into a BERT-based CVAE to learn p(z|x,y).
  • Encode x and y with a 6-layer encoder from BERT-base to obtain latent z with Gaussian q(z|x,y).
  • Decode using a conditioned left-to-right transformer with a specialized attention mask to generate x from z and y, mitigating latent-variable collapse.
  • Train with ELBO loss: L = -KL(q(z|x,y)||p(z|y)) + E_{q}[log p(x|z,y)].
  • Generate novel-intent utterances by sampling z from p(z|y) and decoding, then deduplicate with training data for augmentation.
  • Fine-tune a BERT classifier on the augmented dataset to perform GFSID.

Experimental results

Research questions

  • RQ1Can CG-BERT effectively model a diverse utterance distribution conditioned on intents to generate useful examples for novel intents in GFSID?
  • RQ2Does augmenting training data with CG-BERT-generated utterances improve overall, seen, and novel-intent accuracies in a joint label space?
  • RQ3How does CG-BERT compare to strong FSL baselines and text-generation baselines on real-world GFSID datasets?
  • RQ4Do generated utterances exhibit diversity and syntactic quality that aid classifier learning?

Key findings

  • CG-BERT achieves state-of-the-art performance on SNIPS-NLU and NLU-Evaluation Data in 1-shot and 5-shot GFSID settings.
  • CG-BERT markedly improves novel-intent accuracy and harmonic mean by generating high-quality diverse utterances for novel intents.
  • Compared to baselines, CG-BERT provides consistent gains by jointly training on seen and novel intents, leveraging CVAE-based diversity.
  • Generated utterances are quantitatively more diverse (higher new n-grams) and qualitatively rated high in syntax quality and intent coherency.
  • t-SNE visualizations show CG-BERT-generated novel-intent utterances form a diverse and well-separated cluster from seen intents, unlike fixed-feature oversampling baselines.

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.