Multi-aspect controllable text generation aims to generate fluent sentences that possess multiple desired attributes simultaneously. Traditional methods either combine many operators in the decoding stage, often with costly iteration or search in the discrete text space, or train separate controllers for each aspect, resulting in a degeneration of text quality due to the discrepancy between different aspects. To address these limitations, we introduce a novel approach for multi-aspect control, namely MacLaSa, that estimates compact latent space for multiple aspects and performs efficient sampling with a robust sampler based on ordinary differential equations (ODEs). To eliminate the domain gaps between different aspects, we utilize a Variational Autoencoder (VAE) network to map text sequences from varying data sources into close latent representations. The estimated latent space enables the formulation of joint energy-based models (EBMs) and the plugging in of arbitrary attribute discriminators to achieve multi-aspect control. Afterwards, we draw latent vector samples with an ODE-based sampler and feed sampled examples to the VAE decoder to produce target text sequences. Experimental results demonstrate that MacLaSa outperforms several strong baselines on attribute relevance and textual quality while maintaining a high inference speed.
翻译:论文摘要:多属性可控文本生成旨在生成同时具备多个期望属性的流畅句子。传统方法要么在解码阶段组合多个算子,通常需要在离散文本空间中进行昂贵的迭代或搜索;要么为每个属性训练独立的控制器,导致因不同属性间差异而出现文本质量退化。为解决这些局限,我们提出一种面向多属性控制的新方法——MacLaSa,该方法通过估计多属性的紧凑隐空间,并利用基于常微分方程(ODE)的鲁棒采样器进行高效采样。为消除不同属性间的领域差距,我们采用变分自编码器(VAE)网络将来自不同数据源的文本序列映射至相近的隐表示。所估计的隐空间支持构建联合能量模型(EBM),并可接入任意属性判别器以实现多属性控制。随后,我们通过基于ODE的采样器抽取隐向量样本,并将采样结果输入VAE解码器以生成目标文本序列。实验结果表明,MacLaSa在保持高推理速度的同时,在属性关联性和文本质量方面均优于多个强基线模型。