PCFG-based Natural Language Interface Improves Generalization for Controlled Text Generation

Jingyu Zhang, James Glass, Tianxing He
10/14/2022
cs.CLcs.LG

Official code: jackjyzhang/pcfg-nl-interface (5 stars, Python, last commit 2022-11-02).

Abstract

Existing work on controlled text generation (CTG) assumes a control interface of categorical attributes. In this work, we propose a natural language (NL) interface, where we craft a PCFG to embed the control attributes into natural language commands, and propose variants of existing CTG models that take commands as input.

Show full abstract

In our experiments, we design tailored setups to test model's generalization abilities. We find our PCFG-based command generation approach is effective for handling unseen commands compared to fix-set templates; our proposed NL models can effectively generalize to unseen attributes, a new ability enabled by the NL interface, as well as unseen attribute combinations. Interestingly, we discover that the simple conditional generation approach, enhanced with our proposed NL interface, is a strong baseline in those challenging settings.

View on arXivView PDF

Code Implementations(1)

50Python, ShellOct 11, 20224 years ago

Similar Papers

Cite this paper

@article{zhang2022pcfgbased,
  title  = {PCFG-based Natural Language Interface Improves Generalization for Controlled Text Generation},
  author = {Jingyu Zhang and James Glass and Tianxing He},
  year   = {2022},
  eprint = {2210.07431},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2210.07431}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2210.07431.svg)](https://codeofpaper.com/paper/2210.07431)

Discussion