Metamorphic Testing for Audio Content Moderation Software

Wenxuan Wang, Yongjiang Wu, Junyuan Zhang, Shuqing Li, Yun Peng, Wenting Chen, Shuai Wang, Michael R. LyuarXiv 2025 · DOI

Abstract

As audio-centric platforms grow, so does the challenge of moderating harmful content. This paper introduces MTAM, a metamorphic testing framework designed to uncover vulnerabilities in audio content moderation systems. By applying 14 real-world-inspired perturbations—ranging from signal-level adjustments to linguistic substitutions—MTAM exposes significant weaknesses in major commercial platforms, achieving error finding rates as high as 51%. Furthermore, the study demonstrates that retraining models with this adversarial data can effectively mitigate these bypass vulnerabilities.

Introduction

Audio-centric platforms like TikTok and WhatsApp have become breeding grounds for hate speech, scams, and explicit material. While AI-driven moderation tools are deployed to flag such content, they often suffer from a "blind spot." Malicious actors exploit this by using subtle modifications—such as pitch shifting or background noise—that trick AI systems while remaining intelligible to humans.

This research addresses the "Oracle Problem" in software testing: the difficulty of automatically verifying a moderation system's output for modified audio without constant human intervention. Current testing methodologies often rely on "clean" datasets that fail to represent the messy, intentional bypass attempts encountered in real-world scenarios.

The MTAM Framework

The researchers developed MTAM (Metamorphic Testing for Audio content Moderation) to systematically test these systems. Metamorphic testing evaluates the relationship between inputs and outputs. For instance, if a "toxic" audio clip is modified in a way that preserves its semantic meaning (e.g., increasing volume), the moderation system should consistently label it as toxic. Any discrepancy in this relationship indicates a bug or vulnerability.

MTAM utilizes 14 Metamorphic Relations (MRs) categorized into three distinct levels of complexity:

Categorization of the 14 Metamorphic Relations (MRs) used in MTAM, ranging from basic signal adjustments to complex linguistic changes.
  1. Basic Signal-Level: Fundamental tweaks such as tempo changes, stereo panning, or pitch adjustments.
  2. Compound Signal-Level: Sophisticated audio effects including distortion, echo, reverb, and "bass boost."
  3. Linguistic-Form: Heuristic changes like Homophone Substitution (e.g., replacing a slur with a similar-sounding benign word) or Benign Discontinuity (e.g., inserting pauses to mimic stuttering).

Datasets and Evaluation

To ensure the realism of these MRs, the authors conducted a pilot study of 2,000 audio clips from platforms like YouTube and TikTok. The testing framework was then seeded with diverse datasets across multiple languages and content types.

Overview of the datasets used to seed the MTAM framework, including English and Chinese sources for toxicity, pornography, and spam.

The evaluation utilized a massive generated set of 22,071 perturbed audio clips to stress-test five major commercial APIs (Gladia, Assembly AI, Baidu, Nextdata, and Tencent) and one state-of-the-art academic model.

Key Insights and Results

The study revealed a significant "Human-Clear, AI-Blurred" gap. While humans easily understand semantically equivalent perturbations (like a word spelled out with pauses), speech-to-text engines often fail to categorize them correctly.

Performance of Commercial Systems

MTAM achieved high average Error Finding Rates (EFR) across all tested platforms:

  • Tencent: 51.1%
  • Gladia: 38.6%
  • Baidu: 35.1%
  • Assembly AI: 18.3%
  • Nextdata: 16.7%

Linguistic vulnerabilities, particularly homophone substitution, proved exceptionally effective in Chinese due to the language's tonal nature. While commercial systems often employ rule-based "defenses-in-depth" that make them more robust than pure academic models, they remain highly susceptible to compound audio effects.

Retraining as a Solution

A critical finding of this research is that these vulnerabilities are not permanent. By "fine-tuning" models with a small portion (20%) of MTAM-generated data, the researchers were able to reduce the EFR to nearly 0% for specific perturbations, such as Ring Modulation, without compromising the model's accuracy on standard audio.

Limitations and Future Work

While effective, MTAM currently focuses on English and Chinese; linguistic MRs would need to be adapted for other languages. Additionally, as commercial systems are "black boxes," it is difficult to determine if failures occur at the speech-to-text stage or the text-classification stage. Future work will focus on automated MR generation to keep pace with the evolving tactics of malicious actors in this ongoing cat-and-mouse game of content moderation.

Summary updated

BibTeX
@misc{wang2025metamorphic,
  author = {Wenxuan Wang and Yongjiang Wu and Junyuan Zhang and Shuqing Li and Yun Peng and Wenting Chen and Shuai Wang and Michael R. Lyu},
  title = {{Metamorphic Testing for Audio Content Moderation Software}},
  year = {2025},
  eprint = {2509.24215},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2509.24215},
}
Figure