COLD Decoding: Energy-based Constrained Text Generation with Langevin
Dynamics
- URL: http://arxiv.org/abs/2202.11705v1
- Date: Wed, 23 Feb 2022 18:59:27 GMT
- Title: COLD Decoding: Energy-based Constrained Text Generation with Langevin
Dynamics
- Authors: Lianhui Qin, Sean Welleck, Daniel Khashabi, Yejin Choi
- Abstract summary: Cold decoding is a flexible framework that can be applied directly to off-the-shelf left-to-right language models.
Our experiments on constrained generation tasks point to the effectiveness of our approach, both in terms of automatic and human evaluation.
- Score: 69.8062252611486
- License: http://creativecommons.org/licenses/by/4.0/
- Abstract: Many applications of text generation require incorporating different
constraints to control the semantics or style of generated text. These
constraints can be hard (e.g., ensuring certain keywords are included in the
output) and soft (e.g., contextualizing the output with the left- or right-hand
context). In this paper, we present Energy-based Constrained Decoding with
Langevin Dynamics (COLD), a decoding framework which unifies constrained
generation as specifying constraints through an energy function, then
performing efficient differentiable reasoning over the constraints through
gradient-based sampling. COLD decoding is a flexible framework that can be
applied directly to off-the-shelf left-to-right language models without the
need for any task-specific fine-tuning, as demonstrated through three
challenging text generation applications: lexically-constrained generation,
abductive reasoning, and counterfactual reasoning. Our experiments on these
constrained generation tasks point to the effectiveness of our approach, both
in terms of automatic and human evaluation.
Related papers
- Intertwining CP and NLP: The Generation of Unreasonably Constrained Sentences [49.86129209397701]
This paper presents the Constraints First Framework to remedy this issue.
It is solved by a constraint programming method that combines linguistic properties with more classical constraints.
The effectiveness of this approach is demonstrated by tackling a new more tediously constrained text generation problem.
arXiv Detail & Related papers (2024-06-15T17:40:49Z) - Toward Unified Controllable Text Generation via Regular Expression
Instruction [56.68753672187368]
Our paper introduces Regular Expression Instruction (REI), which utilizes an instruction-based mechanism to fully exploit regular expressions' advantages to uniformly model diverse constraints.
Our method only requires fine-tuning on medium-scale language models or few-shot, in-context learning on large language models, and requires no further adjustment when applied to various constraint combinations.
arXiv Detail & Related papers (2023-09-19T09:05:14Z) - Controlled Text Generation with Natural Language Instructions [74.88938055638636]
InstructCTG is a controlled text generation framework that incorporates different constraints.
We first extract the underlying constraints of natural texts through a combination of off-the-shelf NLP tools and simple verbalizes.
By prepending natural language descriptions of the constraints and a few demonstrations, we fine-tune a pre-trained language model to incorporate various types of constraints.
arXiv Detail & Related papers (2023-04-27T15:56:34Z) - Tractable Control for Autoregressive Language Generation [82.79160918147852]
We propose to use tractable probabilistic models (TPMs) to impose lexical constraints in autoregressive text generation models.
We show that GeLaTo achieves state-of-the-art performance on challenging benchmarks for constrained text generation.
Our work opens up new avenues for controlling large language models and also motivates the development of more expressive TPMs.
arXiv Detail & Related papers (2023-04-15T00:19:44Z) - Constrained Sampling from Language Models via Langevin Dynamics in
Embedding Spaces [34.375537557235724]
We propose a sampling procedure that combines the log-likelihood of the language model with arbitrary differentiable constraints into a single energy function.
We evaluate our approach on different text generation tasks with soft and hard constraints as well as their combinations with competitive results for toxicity avoidance, sentiment control, and keyword-guided generation.
arXiv Detail & Related papers (2022-05-25T08:09:03Z) - NeuroLogic Decoding: (Un)supervised Neural Text Generation with
Predicate Logic Constraints [75.66980495245926]
Conditional text generation often requires lexical constraints, i.e., which words should or shouldn't be included in the output text.
We propose NeuroLogic Decoding, a simple yet effective algorithm that enables neural language models -- supervised or not -- to generate fluent text.
Our results suggest the limit of large-scale neural networks for fine-grained controllable generation and the promise of inference-time algorithms.
arXiv Detail & Related papers (2020-10-24T11:55:22Z)
This list is automatically generated from the titles and abstracts of the papers in this site.
This site does not guarantee the quality of this site (including all information) and is not responsible for any consequences.