mlsanityData to 14 Oct 2026

Metamorphic Testing of Large Language Models for Natural Language Processing

arXiv 2511.02108 ↗First posted 3 Nov 2025cs.SE cs.AIcited by 12

Not on the map. Why?

Abstract (arXiv)

Using large language models (LLMs) to perform natural language processing (NLP) tasks has become increasingly pervasive in recent times. The versatile nature of LLMs makes them applicable to a wide range of such tasks. While the performance of recent LLMs is generally outstanding, several studies have shown that they can often produce incorrect results. Automatically identifying these faulty behaviors is extremely useful for improving the effectiveness of LLMs. One obstacle to this is the limited availability of labeled datasets, which necessitates an oracle to determine the correctness of LLM behaviors. Metamorphic testing (MT) is a popular testing approach that alleviates this oracle problem. At the core of MT are metamorphic relations (MRs), which define relationships between the outputs of related inputs. MT can expose faulty behaviors without the need for explicit oracles (e.g., labeled datasets). This paper presents the most comprehensive study of MT for LLMs to date. We conducted a literature review and collected 191 MRs for NLP tasks. We implemented a representative subset (36 MRs) to conduct a series of experiments with three popular LLMs, running approximately 560,000 metamorphic tests. The results shed light on the capabilities and opportunities of MT for LLMs, as well as its limitations.

Key facts. Cited by 12 papers in the map (data through 14 Oct 2026). Builds on 51 of its 102 references that are in the map. First posted on arXiv 3 Nov 2025.

Builds on

51 of 102 references.

References · 51

  1. 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,399
  2. 2023A Survey of Large Language Modelscited by 2,576
  3. 2015A large annotated corpus for learning natural language inferencecited by 1,847
  4. 2018Know What You Don't Know: Unanswerable Questions for SQuADcited by 1,554
  5. 2023A Survey on Evaluation of Large Language Modelscited by 1,242
  6. 2020Beyond Accuracy: Behavioral Testing of NLP models with CheckListcited by 1,006
  7. 2022Ignore Previous Prompt: Attack Techniques For Language Modelscited by 832
  8. 2021Measuring and Improving Consistency in Pretrained Language Modelscited by 364
  9. 2023Multi-step Jailbreaking Privacy Attacks on ChatGPTcited by 333
  10. 2023PromptRobust: Towards Evaluating the Robustness of Large Language Models on Adversarial Promptscited by 226
  11. 2023Software Testing with Large Language Models: Survey, Landscape, and Visioncited by 166
  12. 2023No More Manual Tests? Evaluating and Improving ChatGPT for Unit Test Generationcited by 82
38 more
  1. 2020Metamorphic Testing: A New Approach for Generating Next Test Casescited by 75
  2. 2024Automated Unit Test Improvement using Large Language Models at Metacited by 75
  3. 2023Unleashing the potential of prompt engineering for large language modelscited by 72
  4. 2022Revisiting DocRED -- Addressing the False Negative Problem in Relation Extractioncited by 57
  5. 2023Using Large Language Models to Generate JUnit Tests: An Empirical Studycited by 53
  6. 2023In ChatGPT We Trust? Measuring and Characterizing the Reliability of ChatGPTcited by 37
  7. 2019Automatic Testing and Improvement of Machine Translationcited by 36
  8. 2019Structure-Invariant Testing for Machine Translationcited by 28
  9. 2024Fine Tuning LLM for Enterprise: Practical Guidelines and Recommendationscited by 28
  10. 2025Hallucination Detection in Large Language Models with Metamorphic Relationscited by 24
  11. 2023MTTM: Metamorphic Testing for Textual Content Moderation Softwarecited by 22
  12. 2023Scaling Down to Scale Up: A Cost-Benefit Analysis of Replacing OpenAI's LLM with Open Source SLMs in Productioncited by 21
  13. 2020Testing Machine Translation via Referential Transparencycited by 20
  14. 2023METAL: Metamorphic Testing Framework for Analyzing Large-Language Model Qualitiescited by 20
  15. 2022Threats to Pre-trained Language Models: Survey and Taxonomycited by 19
  16. 2023PolicyGPT: Automated Analysis of Privacy Policies with Large Language Modelscited by 16
  17. 2022AEON: A Method for Automatic Evaluation of NLP Test Casescited by 15
  18. 2024Drowzee: Metamorphic Testing for Fact-Conflicting Hallucination Detection in Large Language Modelscited by 14
  19. 2023Generating Valid and Natural Adversarial Examples with Large Language Modelscited by 12
  20. 2024Open LLMs are Necessary for Current Private Adaptations and Outperform their Closed Alternativescited by 12
  21. 2024Towards Generating Executable Metamorphic Relations Using Large Language Modelscited by 7
  22. 2024MORTAR: Multi-turn Metamorphic Testing for LLM-based Dialogue Systemscited by 7
  23. 2023Can ChatGPT advance software testing intelligence? An experience report on metamorphic testingcited by 6
  24. 2024MR-Adopt: Automatic Deduction of Input Transformation Function for Metamorphic Testingcited by 6
  25. 2022Systematicity, Compositionality and Transitivity of Deep NLP Models: a Metamorphic Testing Perspectivecited by 5
  26. 2023MR-Scout: Automated Synthesis of Metamorphic Relations from Existing Test Casescited by 5
  27. 2018Quality Assurance of Bioinformatics Software: A Case Study of Testing a Biomedical Text Processing Tool Using Metamorphic Testingcited by 4
  28. 2023Word Closure-Based Metamorphic Testing for Machine Translationcited by 4
  29. 2023GenMorph: Automatically Generating Metamorphic Relations via Genetic Programmingcited by 4
  30. 2023Automated Testing and Improvement of Named Entity Recognition Systemscited by 3
  31. 2023On the Potential and Limitations of Few-Shot In-Context Learning to Generate Metamorphic Specifications for Tax Preparation Softwarecited by 3
  32. 2024Identifying the Achilles' Heel: An Iterative Method for Dynamically Uncovering Factual Errors in Large Language Modelscited by 3
  33. 2024An Empirical Study on Large Language Models in Accuracy and Robustness under Chinese Industrial Scenarioscited by 3
  34. 2023Intergenerational Test Generation for Natural Language Processing Applicationscited by 2
  35. 2023Retromorphic Testing: A New Approach to the Test Oracle Problemcited by 2
  36. 2024Machine Translation Testing via Syntactic Tree Pruningcited by 2
  37. 2024Persona-centric Metamorphic Relation guided Robustness Evaluation for Multi-turn Dialogue Modellingcited by 2
  38. 2025Detecting LLM Fact-conflicting Hallucinations Enhanced by Temporal-logic-based Reasoningcited by 2

50 most cited of 51 All 51 (JSON)

Built on by

Cited by year (2026 to 14 Oct)

Citing papers per year: 2026: 12.

12 papers.