Improving Semantic Control in Discrete Latent Spaces with Transformer Quantized Variational Autoencoders

Yingji Zhang, Danilo S. Carvalho, Marco Valentino, Ian Pratt-Hartmann, Andre Freitas
2/1/2024
12 citations
cs.CL
transformer-attention

Official code: SnowYJ/T5VQVAE (2 stars, Python, last commit 2025-01-24).

Abstract

Achieving precise semantic control over the latent spaces of Variational AutoEncoders (VAEs) holds significant value for downstream tasks in NLP as the underlying generative mechanisms could be better localised, explained and improved upon. Recent research, however, has struggled to achieve consistent results, primarily due to the inevitable loss of semantic information in the variational bottleneck and limited control over the decoding mechanism.

Show full abstract

To overcome these challenges, we investigate discrete latent spaces in Vector Quantized Variational AutoEncoders (VQVAEs) to improve semantic control and generation in Transformer-based VAEs. In particular, We propose T5VQVAE, a novel model that leverages the controllability of VQVAEs to guide the self-attention mechanism in T5 at the token-level, exploiting its full generalization capabilities. Experimental results indicate that T5VQVAE outperforms existing state-of-the-art VAE models, including Optimus, in terms of controllability and preservation of semantic information across different tasks such as auto-encoding of sentences and mathematical expressions, text transfer, and inference. Moreover, T5VQVAE exhibits improved inference capabilities, suggesting potential applications for downstream natural language and symbolic reasoning tasks.

View on arXivView PDF

Code Implementations(1)

SnowYJ/T5VQVAEOfficial100%

Improving Semantic Control in Discrete Latent Spaces with Transformer Quantized Variational Autoencoders

20Python, ShellNov 22, 20231 years ago
language-modelvae-pytorchvqvae

Similar Papers

Cite this paper

@article{zhang2024improving,
  title  = {Improving Semantic Control in Discrete Latent Spaces with Transformer Quantized Variational Autoencoders},
  author = {Yingji Zhang and Danilo S. Carvalho and Marco Valentino and Ian Pratt-Hartmann and Andre Freitas},
  year   = {2024},
  eprint = {2402.00723},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2402.00723v1}
}

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/2402.00723.svg)](https://codeofpaper.com/paper/2402.00723)

Discussion