Reward-Augmented Decoding: Efficient Controlled Text Generation With a Unidirectional Reward Model

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Deng, Haikang, Raffel, Colin
Format: Preprint
Published: 2023
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866929196099436544
author Deng, Haikang
Raffel, Colin
author_facet Deng, Haikang
Raffel, Colin
contents While large language models have proven effective in a huge range of downstream applications, they often generate text that is problematic or lacks a desired attribute. In this paper, we introduce Reward-Augmented Decoding (RAD), a text generation procedure that uses a small unidirectional reward model to encourage a language model to generate text that has certain properties. Specifically, RAD uses the reward model to score generations as they are produced and rescales sampling probabilities to favor high-reward tokens. By using a unidirectional reward model, RAD can cache activations from prior generation steps to decrease computational overhead. Through experiments on generating non-toxic and sentiment-controlled text, we demonstrate that RAD performs best among methods that change only the generation procedure and matches the performance of state-of-the-art methods that involve re-training the language model. We further validate that RAD is effective on very large language models while incurring a minimal computational overhead.
format Preprint
id arxiv_https___arxiv_org_abs_2310_09520
institution arXiv
publishDate 2023
record_format arxiv
spellingShingle Reward-Augmented Decoding: Efficient Controlled Text Generation With a Unidirectional Reward Model
Deng, Haikang
Raffel, Colin
Computation and Language
While large language models have proven effective in a huge range of downstream applications, they often generate text that is problematic or lacks a desired attribute. In this paper, we introduce Reward-Augmented Decoding (RAD), a text generation procedure that uses a small unidirectional reward model to encourage a language model to generate text that has certain properties. Specifically, RAD uses the reward model to score generations as they are produced and rescales sampling probabilities to favor high-reward tokens. By using a unidirectional reward model, RAD can cache activations from prior generation steps to decrease computational overhead. Through experiments on generating non-toxic and sentiment-controlled text, we demonstrate that RAD performs best among methods that change only the generation procedure and matches the performance of state-of-the-art methods that involve re-training the language model. We further validate that RAD is effective on very large language models while incurring a minimal computational overhead.
title Reward-Augmented Decoding: Efficient Controlled Text Generation With a Unidirectional Reward Model
topic Computation and Language
url https://arxiv.org/abs/2310.09520