MixPoet: Diverse Poetry Generation via Learning Controllable Mixed Latent Space

Xiaoyuan Yi, Ruoyu Li, Cheng Yang, Wenhao Li, Maosong Sun

Abstract

MixPoet is a novel framework designed to address the "boring AI" problem in automated poetry generation by disentangling the model's latent space into controllable subspaces. By learning to "mix" different influence factors—such as a poet’s historical era or life experience—the model generates poems that are significantly more diverse, stylistically distinct, and human-like than previous state-of-the-art models. Experimental results on a newly curated Chinese Quatrain corpus demonstrate that MixPoet achieves superior intra-topic diversity and approaches human-level quality in fluency and aesthetics.

Introduction

While neural networks have become proficient at generating fluent text, they often struggle with diversity, frequently producing "generic content." In poetry generation, this manifests as a model learning a few "safe" patterns and repeating them regardless of the input keyword. This paper identifies two critical types of lacking diversity: inter-topic diversity (poems with different keywords should look different) and intra-topic diversity (the same keyword should produce varied poems).

Human poets achieve this diversity because their writing is shaped by external factors like their historical background (e.g., prosperous vs. war-torn eras) or personal life (e.g., military career vs. rural seclusion). Existing AI models typically ignore these latent influences, leading to repetitive verse. MixPoet addresses this by explicitly modeling these factors within a structured latent space.

Methodology

The core of MixPoet is a Semi-Supervised Conditional Variational Autoencoder (VAE) designed for style disentanglement and controllable generation.

The MixPoet architecture featuring the Encoder, Recognition Network, Prior Networks for factor mixing, and the Decoder.

Latent Space Disentanglement

Instead of a single latent variable, MixPoet splits the latent space into multiple subspaces, each conditioned on a specific influence factor like "Historical Background." This allows the model to couple style with semantics; for instance, a "war" poem from a prosperous era might focus on glory, while one from a troubled era emphasizes sorrow.

Adversarial Training (MixPoet-AUS)

To ensure these subspaces capture distinct styles and remain independent, the authors employ an adversarial discriminator. This forces the model to learn a sophisticated, "universal" latent space that is more flexible than standard Gaussian distributions, allowing for more complex stylistic nuances.

Semi-Supervised Learning and Mixing

Since most historical poems lack explicit labels regarding the poet's life, a classifier "guesses" factors for unlabeled data during training. At inference, users can manually adjust the "mixture" of these factors (e.g., 70% military career, 30% troubled times) to generate hybrid styles that may not even exist in the training data.

Experimental Setup

The researchers introduced the CQCF (Chinese Quatrain Corpus with Factors), a dataset of 49,451 poems labeled with Living Experience (Military, Countryside, or Others) and Historical Background (Prosperous or Troubled). They also utilized the CQC (Chinese Quatrain Corpus), containing 117,392 unlabeled poems, to boost linguistic knowledge via semi-supervised learning.

Results and Discussion

MixPoet was compared against strong baselines like USPG and MRL. In terms of diversity, MixPoet-AUS achieved an intra-topic Jaccard Similarity of 3.73%, vastly outperforming the standard CVAE (38.2%), indicating much higher uniqueness for identical keywords. Human evaluations by experts rated MixPoet significantly higher across Fluency (4.18/5), Coherence (4.10/5), and Aesthetics (4.10/5), approaching the quality of ground-truth human poems.

Latent space visualizations showing (a) the clustering of different factor mixtures in MixPoet-AUS vs MixPoet-IG and (b) the distribution of generated poems relative to human-created ones.

Visualization of the latent space (Figure 5) confirms that MixPoet successfully clusters different factor mixtures, proving the model learned to distinguish between styles like "military" and "countryside" effectively.

Conclusion

MixPoet demonstrates that disentangling and mixing latent factors is a powerful approach for creative text generation. While current factors are discrete (e.g., Military vs. Countryside), future work may explore continuous representations and model the correlations between different factors, such as gender and life experience. The framework holds potential for expansion into other creative domains like story writing or essay generation.

Summary updated

BibTeX
@inproceedings{yi2020mixpoet,
  author = {Xiaoyuan Yi and Ruoyu Li and Cheng Yang and Wenhao Li and Maosong Sun},
  title = {{MixPoet: Diverse Poetry Generation via Learning Controllable Mixed Latent Space}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2020},
  doi = {10.1609/aaai.v34i05.6488},
}
Figure