LatentExplainer: Explaining Latent Representations in Deep Generative Models with Multimodal Large Language Models

Mengdan Zhu, Raasikh Kanjiani, Jiahui Lu, Andrew Choi, Qirui Ye, Liang Zhao

TL;DR

This paper introduces LatentExplainer, a novel framework that automatically generates human-understandable explanations for the latent variables within deep generative models. By leveraging multimodal large language models (MLLMs) and incorporating inductive biases, LatentExplainer significantly improves the interpretability of these complex models, addressing a key challenge in explainable AI.

What Problem Does This Paper Address?

Deep generative models, like VAEs and diffusion models, are powerful tools for creating realistic data. They achieve this by learning to represent complex data distributions in a lower-dimensional "latent space." However, understanding what each dimension or "latent variable" in this space actually represents is a major hurdle. This "black box" nature makes it difficult to debug models, control their outputs precisely, or trust their generated content. Existing methods for explaining these latent variables are often manual, rely on predefined concepts, or struggle to align with the inherent "inductive biases" (rules or assumptions) that guide how these models learn. LatentExplainer aims to bridge this gap by providing an automated, semantically rich, and bias-aware explanation system.

Methods

LatentExplainer employs a three-pronged approach:

  1. Inductive-Bias-Guided Data Manipulation: The core idea is to perturb individual latent variables and observe the resulting changes in generated data (e.g., images). This is done by translating mathematical formulas representing inductive biases (like disentanglement, combination, or conditional biases) into specific instructions for manipulating the latent space. These manipulations generate sequences of data samples that highlight the effect of a single latent variable.
  2. Automatic Prompt Generation: To make these observations understandable to an MLLM, the framework automatically generates textual prompts. These prompts combine the observed data manipulations with the original inductive bias formulas, translated into natural language using a symbol-to-word mapping. This ensures the MLLM receives context that aligns with the model's underlying assumptions.
  3. Uncertainty-Aware Explanation Generation: To ensure the quality and reliability of the explanations, LatentExplainer incorporates an uncertainty quantification step. It generates multiple explanations from the MLLM for the same latent variable and then selects the most consistent one based on pairwise similarity. This helps filter out less reliable explanations and provides a confidence score, allowing the system to declare "No clear explanation" when appropriate.

Datasets

The paper evaluates LatentExplainer on a variety of datasets commonly used for generative models:

  • Image Datasets: CelebA-HQ (celebrity faces), AFHQ (animal faces - cats, dogs, wild animals), LSUN-Church (church buildings), 3DShapes (synthetic 3D objects), and dSprites (2D shapes).
  • These datasets are used with both VAE and diffusion models to test the framework's generalizability across different generative architectures and data modalities.

Key Insights and Ideas

  • Inductive Biases are Crucial for Meaningful Explanations: The research strongly suggests that simply observing data changes isn't enough. Aligning explanations with the model's inherent inductive biases (e.g., disentanglement) is key to generating semantically accurate and useful interpretations of latent variables.
  • MLLMs as Explanation Engines: Leveraging the advanced understanding and generation capabilities of MLLMs (like GPT-40, Gemini, and Claude) is a powerful way to translate complex latent space manipulations into human-readable text.
  • Uncertainty Quantification is Essential for Reliability: Automatically assessing the confidence of an explanation is vital. This prevents the generation of misleading or nonsensical interpretations and helps identify truly uninterpretable latent dimensions.
  • A Unified Framework for Diverse Biases: LatentExplainer demonstrates a flexible approach that can handle different types of inductive biases, making it applicable to a wide range of generative models.

Key Results

  • Significant Performance Gains: LatentExplainer consistently and substantially improves explanation quality across various MLLMs, generative models, and datasets. For instance, on CelebA-HQ with GPT-40, BLEU scores improved by nearly 2x, and similar gains were observed for ROUGE-L and SPICE.
  • Ablation Studies Highlight Component Importance: Removing the inductive bias prompting component led to a significant drop in performance, underscoring its critical role. Removing uncertainty quantification also decreased performance, though to a lesser extent, indicating its importance for refinement.
  • Qualitative Improvements: Visualizations show that explanations generated with inductive bias prompts are more structured, accurate, and capture the intended semantic meaning, whereas explanations without them often result in "no clear explanation" or incorrect interpretations.

Limitations and Future Work

  • "No Clear Explanation" as a Valid Output: The framework acknowledges that not all latent variables are inherently interpretable. The uncertainty-aware mechanism correctly identifies and flags these as "No clear explanation," which is itself a valuable insight.
  • Reliance on MLLM Capabilities: The quality of explanations is inherently tied to the capabilities of the underlying MLLM. Future work could explore how to further enhance MLLM performance in this specific task.
  • Generalizing to More Complex Biases: While the paper covers three common inductive biases, future research could extend the framework to handle more intricate or novel bias formulations.
  • Broader Applications: The authors suggest that this framework could be extended to other areas of explainable AI beyond latent variable interpretation.

Summary updated

BibTeX
@inproceedings{zhu2025latentexplainer,
  author = {Mengdan Zhu and Raasikh Kanjiani and Jiahui Lu and Andrew Choi and Qirui Ye and Liang Zhao},
  title = {{LatentExplainer: Explaining Latent Representations in Deep Generative Models with Multimodal Large Language Models}},
  booktitle = {ACM International Conference on Information and Knowledge Management},
  year = {2025},
  doi = {10.1145/3746252.3761318},
}
Figure