Abstract
Modifying specific attributes of a sentence, such as sentiment or tense, while preserving its core content is a significant challenge in natural language processing, especially in the absence of parallel training data. This paper introduces a novel RNN-based Encoder-Decoder architecture that utilizes an interpolated reconstruction loss and a joint adversarial discriminator. This approach prevents the model from falling into "vacuous mappings" and ensures that generated text remains fluent and contextually relevant. Experimental results on sentiment transfer and multi-attribute control tasks demonstrate that the proposed model significantly outperforms existing state-of-the-art methods in both attribute accuracy and content preservation.
Introduction
While style transfer has achieved remarkable success in computer vision, its application to natural language remains difficult due to the discrete and sequential nature of text. Changing a single word can drastically alter a sentence's grammar or meaning. The primary challenge addressed here is attribute-conditional text generation without parallel data. For instance, rewriting a negative review into a positive one while keeping specific details intact is difficult without paired examples. Previous models often suffered from "vacuous mappings," where the target attribute is achieved at the total expense of the original content.
Methods
The authors propose an RNN-based Encoder-Decoder architecture designed to disentangle content from style through three key mechanisms:
- Interpolated Reconstruction Loss: To ensure content preservation, the model uses an interpolated loss. Instead of simple auto-encoding, which can lead to trivial copying, the model fuses the latent representation of the original sentence with that of a back-translated version using a Bernoulli random variable. This forces the decoder to rely on a mixed representation, preventing the "copying" shortcut and acting as feature-space data augmentation.
- Adversarial Loss with a Joint Discriminator: A single projection discriminator is employed to evaluate the joint distribution of the generated sentence and its attribute labels. This is more scalable than training separate discriminators for each attribute, allowing the model to control multiple attributes simultaneously.
- Hard-Sampling: Unlike "soft-sampling" methods that pass probability distributions, this model uses discrete "hard-sampling" during training. This eliminates the discrepancy between training and inference, leading to significantly improved fluency and content retention.
Key Results
The model was evaluated on sentiment transfer (Yelp and IMDB reviews), monolingual translation (Shakespearean to Modern English), and multi-attribute control (BookCorpus).
As shown in the results, the model outperforms prior state-of-the-art baselines (Ctrl-gen and Cross-align) across all metrics. On Yelp reviews, it achieved high attribute accuracy and superior content preservation (BLEU scores). Furthermore, the model demonstrated high precision in multi-attribute control, reaching 98% accuracy for mood and tense and 97% for negation. In semi-supervised settings, combining paired and unpaired data improved translation performance by over 2 BLEU points compared to purely supervised baselines.
Key Insights
- Interpolation as a Regularizer: By forcing the decoder to work with a mix of latent spaces, the model is prevented from "cheating" via simple copying, leading to a more robust disentanglement of content and style.
- Scalability of Joint Discriminators: Modeling the joint distribution of sentences and attributes is more data-efficient and allows the framework to scale to complex, multi-attribute generation tasks.
- Fluency through Hard-Sampling: The transition from soft to hard sampling during training is crucial for reducing the train/test mismatch, resulting in more natural and fluent generated text.
Limitations and Future Work
While the model excels at categorical attribute changes, global structural modifications—such as changing a sentence from active to passive voice—remain challenging. Such transformations often require significant reordering of subject-verb-object structures, which can occasionally distort the underlying content. Future research will explore extending this framework to handle continuous attribute values and more complex syntactic transformations.
Summary updated