Explainable AI in Speaker Recognition -- Making Latent Representations Understandable

Yanze Xu, Wenwu Wang, Mark D. PlumbleyarXiv 2026 · arXiv

TL;DR

This paper uncovers how speaker recognition neural networks naturally organize speaker data within their latent spaces into a semantic hierarchy (from gender down to nationality and individual identity). By introducing a new evaluation framework called Hierarchical Cluster-Class Matching (HCCM) and an interpretable "Liebig score," the authors provide a diagnostic tool to decode and explain the hidden, nested structures inside deep audio embeddings.

What Problem Does This Paper Address?

When a neural network is trained to recognize speakers, it maps voice recordings into a high-dimensional mathematical space (latent representations or embeddings). Previous Explainable AI (XAI) studies usually treated these embeddings as independent, "flat" groups—essentially checking if the network can separate Speaker A from Speaker B.

However, humans organize acoustic knowledge hierarchically (e.g., recognizing a voice as female, then noticing an Irish accent, and finally identifying the specific person). This paper addresses a key gap in XAI: how do we systematically analyze, visualize, and semantically interpret the nested, hierarchical relationships that naturally form within a network's representation space?

Methods

The authors shift the paradigm from flat clustering (like K-means) to hierarchical clustering, utilizing two well-established algorithms: Single-Linkage Clustering (SLINK) and Hierarchical Density-Based Spatial Clustering of Applications with Noise (HDBSCAN).

To make sense of the resulting tree-like cluster structures (dendrograms), they introduce two novel XAI contributions:

  1. Hierarchical Cluster-Class Matching (HCCM): This algorithm automatically performs pairwise matching between the network's clusters and predefined semantic concepts. Crucially, it tests both individual classes (e.g., "UK") and conjunctive classes using AND-logic (e.g., "UK and Male") to see where these concepts sit in the network's hierarchy.
Fig. 2: An illustration of the proposed Hierarchical Cluster- Class Matching (HCCM) method for interpreting hierarchical clusters.
  1. The Liebig Score (L-score): Traditional cluster matching relies on the F-score (the harmonic mean of precision and recall), which can be difficult to interpret. Inspired by Liebig’s Law of the Minimum (which states growth is dictated by the scarcest resource), the L-score is simply the minimum of precision and recall: $$\text{L-score} = \min(\text{precision}, \text{recall})$$ This provides an immediate diagnostic meaning: if a cluster's L-score is limited by a recall of 0.73, you know exactly that the match is bottlenecked because 27% of the target class samples were left out.
Fig. 2: An illustration of the proposed Hierarchical Cluster- Class Matching (HCCM) method for interpreting hierarchical clusters.

Datasets

  • VoxCeleb2: Used to pre-train the underlying speaker recognition network (a ResNet34 architecture optimized with prototypical contrastive loss).
  • VoxCeleb1 (Test Set): Used to extract the embeddings for the XAI analysis. The dataset includes audio annotations across 40 identity-related, 2 gender-related, and 12 nationality-related individual semantic classes, which the authors expanded with 24 conjunctive classes (e.g., "Ireland & Female").

Key Insights and Ideas

  • The Latent Hierarchy of Speech: The network automatically structures its space with demographic properties at the top. Gender forms the absolute root split of the tree, while combinations of nationality and gender emerge as sub-clusters further down.
  • Acoustic and Linguistic Proximity: Under the "Male" branch, the network naturally grouped speakers from Ireland, the UK, and Canada into a shared higher-level cluster before separating them. This reveals that the network inherently captures historical and linguistic acoustic similarities without being explicitly trained to do so.
  • Input Length Dictates Latent Order: The cleaner, more logical hierarchical structures emerged exclusively when analyzing embeddings from longer audio clips (4 seconds vs. 0.2 seconds). This directly mirrors the model's actual performance accuracy, proving that better model generalization goes hand-in-hand with a highly organized latent space.

Key Results

  • SLINK applied to 4-second audio representations yielded the highest alignment with ground-truth metadata.
  • It achieved an overall matching degree of nearly 1.0 for gender and identity divisions, and exceeded 0.6 for nationality divisions.
  • Using the L-score, the authors successfully mapped out perfect matches (such as the "Ireland & Male" cluster achieving a flawless 1.0 precision and recall) and diagnosed flawed clusters (such as a "UK & Female" cluster being limited by a recall of 0.52).

Limitations and Future Work

While the framework successfully maps out high-level demographic metadata, the authors note that speaker embeddings contain far more nuanced acoustic information than just gender and nationality.

As a next step, they plan to collaborate with domain experts in psychology, linguistics, speech pathology, and vocal pedagogy to introduce more granular semantic classes (such as vocal timbre, dialect variations, or pathological traits) to see how deeply the network organizes the finer details of human speech.

Summary updated

Abstract

Neural networks can be trained to learn task-relevant representations from data. Understanding how these networks make decisions falls within the Explainable AI (XAI) domain. This paper proposes to study an XAI topic: analysing, visualising and understanding the unknown organisation of network representations, particularly those a speaker recognition network learns from utterances, for recognising speaker identity. Past studies have employed algorithms (e.g. K-means) to analyse the different ways in which network representations can be naturally grouped into clusters, i.e. to analyse different flat clustering phenomena within the space defined by those representations. In contrast, this work applies two algorithms -- Single-Linkage Clustering (SLINK) and Hierarchical Density-Based Spatial Clustering of Applications with Noise (HDBSCAN) -- to analyse the different ways in which representations from the speaker recognition network can form clusters with hierarchical relationships, i.e., to analyse different hierarchical clustering phenomena within the representation space of the speaker recognition network. Furthermore, an algorithm called Hierarchical Cluster-Class Matching (HCCM) is designed to semantically interpret one of the above hierarchical clustering phenomena analysed using SLINK. Given the clusters representing this phenomenon, HCCM identifies which ones best match individual semantic classes related to gender and nationality (e.g.\ male, female, Ireland, UK) and and-logic conjunctions of these classes (e.g.\ female and Ireland). The Liebig score metric is also proposed within HCCM to quantify the matching quality of each cluster-class pair and diagnose the factor that limits each match.
BibTeX
@misc{xu2026explainable,
  author = {Yanze Xu and Wenwu Wang and Mark D. Plumbley},
  title = {{Explainable AI in Speaker Recognition -- Making Latent Representations Understandable}},
  year = {2026},
  eprint = {2604.23354},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2604.23354},
}

Loading related content...

Figure