A Block Metropolis-Hastings Sampler for Controllable Energy-based Text Generation
Not on the map. Why?
Abstract (arXiv)
Recent work has shown that energy-based language modeling is an effective framework for controllable text generation because it enables flexible integration of arbitrary discriminators. However, because energy-based LMs are globally normalized, approximate techniques like Metropolis-Hastings (MH) are required for inference. Past work has largely explored simple proposal distributions that modify a single token at a time, like in Gibbs sampling. In this paper, we develop a novel MH sampler that, in contrast, proposes re-writes of the entire sequence in each step via iterative prompting of a large language model. Our new sampler (a) allows for more efficient and accurate sampling from a target distribution and (b) allows generation length to be determined through the sampling procedure rather than fixed in advance, as past work has required. We perform experiments on two controlled generation tasks, showing both downstream performance gains and more accurate target distribution sampling in comparison with single-token proposal techniques.
Key facts. Cited by 5 papers in the map (data through 7 Oct 2026). Builds on 39 of its 46 references that are in the map. First posted on arXiv 7 Dec 2023.
Builds on
39 of 46 references.
References · 39
- 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,204
- 2020Language Models are Few-Shot Learnerscited by 32,199
- 2019RoBERTa: A Robustly Optimized BERT Pretraining Approachcited by 13,266
- 2019BERTScore: Evaluating Text Generation with BERTcited by 5,462
- 2022Scaling Instruction-Finetuned Language Modelscited by 2,997
- 2019Fine-Tuning Language Models from Human Preferencescited by 2,124
- 2020Don't Stop Pretraining: Adapt Language Models to Domains and Taskscited by 1,548
- 2020RealToxicityPrompts: Evaluating Neural Toxic Degeneration in Language Modelscited by 1,235
- 2019Plug and Play Language Models: A Simple Approach to Controlled Text Generationcited by 793
- 2019CTRL: A Conditional Transformer Language Model for Controllable Generationcited by 754
- 2020GeDi: Generative Discriminator Guided Sequence Generationcited by 377
- 2021FUDGE: Controlled Text Generation With Future Discriminatorscited by 374
27 more
- 2021Annotators with Attitudes: How Annotator Beliefs And Identities Bias Toxic Language Detectioncited by 258
- 2017Style Transfer from Non-Parallel Text by Cross-Alignmentcited by 246
- 2018Dear Sir or Madam, May I introduce the GYAFC Dataset: Corpus, Benchmarks and Metrics for Formality Style Transfercited by 209
- 2020Reformulating Unsupervised Style Transfer as Paraphrase Generationcited by 181
- 2022COLD Decoding: Energy-based Constrained Text Generation with Langevin Dynamicscited by 159
- 2017Controlling Linguistic Style Aspects in Neural Language Generationcited by 147
- 2018Phrase-Based & Neural Unsupervised Machine Translationcited by 138
- 2020A Distributional Approach to Controlled Text Generationcited by 117
- 2021A Recipe For Arbitrary Text Style Transfer with Large Language Modelscited by 107
- 2021Detoxifying Language Models Risks Marginalizing Minority Voicescited by 106
- 2020Residual Energy-Based Models for Text Generationcited by 95
- 2017Generating Sentences by Editing Prototypescited by 88
- 2021Break-It-Fix-It: Unsupervised Learning for Program Repaircited by 71
- 2020A Probabilistic Formulation of Unsupervised Text Style Transfercited by 70
- 2021Controlled Text Generation as Continuous Optimization with Multiple Constraintscited by 70
- 2022Mix and Match: Learning-free Controllable Text Generation using Energy Language Modelscited by 66
- 2022Gradient-Based Constrained Sampling from Language Modelscited by 64
- 2015Structured Prediction Energy Networkscited by 59
- 2021Just Say No: Analyzing the Stance of Neural Dialogue Generation in Offensive Contextscited by 56
- 2020Exploring Controllable Text Generation Techniquescited by 55
- 2021XFORMAL: A Benchmark for Multilingual Formality Style Transfercited by 51
- 2021Exposing the Implicit Energy Networks behind Masked Language Models via Metropolis--Hastingscited by 37
- 2022EdiT5: Semi-Autoregressive Text-Editing with T5 Warm-Startcited by 35
- 2021Efficient Hierarchical Domain Adaptation for Pretrained Language Modelscited by 32
- 2020Plug and Play Autoencoders for Conditional Text Generationcited by 26
- 2019Global Autoregressive Models for Data-Efficient Sequence Learningcited by 15
- 2021Style Pooling: Automatic Text Style Obfuscation for Improved Classification Fairnesscited by 12
Built on by
Citing papers per year: 2024: 3; 2025: 1; 2026: 1.
5 papers.
- 2024COLD-Attack: Jailbreaking LLMs with Stealthiness and Controllabilitycited by 162
- 2024QUEST: Quality-Aware Metropolis-Hastings Sampling for Machine Translationcited by 16
- 2025Constrained Discrete Diffusioncited by 16
- 2024Local and Global Decoding in Text Generationcited by 4
- 2026Explore Broadly, Reason Sharply: Push Small Models toward the Frontier via Samplingcited by 0
- 2026Explore Broadly, Reason Sharply: Push Small Models toward the Frontier via Sampling29 Sep 2026
- 2025Constrained Discrete Diffusion12 Mar 2025
- 2024Local and Global Decoding in Text Generation14 Oct 2024
- 2024QUEST: Quality-Aware Metropolis-Hastings Sampling for Machine Translation28 May 2024
- 2024COLD-Attack: Jailbreaking LLMs with Stealthiness and Controllability13 Feb 2024