Controllable Natural Language Generation with Contrastive Prefixes

02/27/2022
by   Jing Qian, et al.
9

To guide the generation of large pretrained language models (LM), previous work has focused on directly fine-tuning the language model or utilizing an attribute discriminator. In this work, we propose a novel lightweight framework for controllable GPT2 generation, which utilizes a set of small attribute-specific vectors, called prefixes, to steer natural language generation. Different from prefix-tuning, where each prefix is trained independently, we take the relationship among prefixes into consideration and train multiple prefixes simultaneously. We propose a novel supervised method and also an unsupervised method to train the prefixes for single-aspect control while the combination of these two methods can achieve multi-aspect control. Experimental results on both single-aspect and multi-aspect control show that our methods can guide generation towards the desired attributes while keeping high linguistic quality.

READ FULL TEXT
research
01/25/2023

Language Model Detoxification in Dialogue with Contextualized Stance Control

To reduce the toxic degeneration in a pretrained Language Model (LM), pr...
research
09/14/2020

GeDi: Generative Discriminator Guided Sequence Generation

Class-conditional language models (CC-LMs) can be used to generate natur...
research
10/06/2022

A Distributional Lens for Multi-Aspect Controllable Text Generation

Multi-aspect controllable text generation is a more challenging and prac...
research
06/20/2023

On Compositionality and Improved Training of NADO

NeurAlly-Decomposed Oracle (NADO) is a powerful approach for controllabl...
research
12/10/2020

Towards Neural Programming Interfaces

It is notoriously difficult to control the behavior of artificial neural...
research
05/12/2022

Sampling with Attribute-Related Information for Controlling Language Models

The dominant approaches for controlling language models are based on fin...
research
05/04/2023

Semantic Space Grounded Weighted Decoding for Multi-Attribute Controllable Dialogue Generation

Controlling chatbot utterance generation with multiple attributes such a...

Please sign up or login with your details

Forgot password? Click here to reset