mlsanityData to 7 Oct 2026

GlitchProber: Advancing Effective Detection and Mitigation of Glitch Tokens in Large Language Models

arXiv 2408.04905 ↗First posted 9 Aug 2024cs.CL cs.AIcited by 3

Not on the map. Why?

Abstract (arXiv)

Large language models (LLMs) have achieved unprecedented success in the field of natural language processing. However, the black-box nature of their internal mechanisms has brought many concerns about their trustworthiness and interpretability. Recent research has discovered a class of abnormal tokens in the model's vocabulary space and named them "glitch tokens". Those tokens, once included in the input, may induce the model to produce incorrect, irrelevant, or even harmful results, drastically undermining the reliability and practicality of LLMs. In this work, we aim to enhance the understanding of glitch tokens and propose techniques for their detection and mitigation. We first reveal the characteristic features induced by glitch tokens on LLMs, which are evidenced by significant deviations in the distributions of attention patterns and dynamic information from intermediate model layers. Based on the insights, we develop GlitchProber, a tool for efficient glitch token detection and mitigation. GlitchProber utilizes small-scale sampling, principal component analysis for accelerated feature extraction, and a simple classifier for efficient vocabulary screening. Taking one step further, GlitchProber rectifies abnormal model intermediate layer values to mitigate the destructive effects of glitch tokens. Evaluated on five mainstream open-source LLMs, GlitchProber demonstrates higher efficiency, precision, and recall compared to existing approaches, with an average F1 score of 0.86 and an average repair rate of 50.06%. GlitchProber unveils a novel path to address the challenges posed by glitch tokens and inspires future research toward more robust and interpretable LLMs.

Key facts. Cited by 3 papers in the map (data through 7 Oct 2026). Builds on 14 of its 40 references that are in the map. First posted on arXiv 9 Aug 2024.

Builds on

14 of 40 references.

References · 14

  1. 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 12,865
  2. 2021Training Verifiers to Solve Math Word Problemscited by 9,743
  3. 2020Measuring Massive Multitask Language Understandingcited by 7,768
  4. 2020Rethinking Attention with Performerscited by 1,584
  5. 2023Prompt Injection attack against LLM-integrated Applicationscited by 568
  6. 2021Pay Attention to MLPscited by 367
  7. 2023MasterKey: Automated Jailbreak Across Multiple Large Language Model Chatbotscited by 172
  8. 2024Pandora: Jailbreak GPTs by Retrieval Augmented Generation Poisoningcited by 62
  9. 2024Tokenization Matters! Degrading Large Language Models through Challenging Their Tokenizationcited by 32
  10. 2024Glitch Tokens in Large Language Models: Categorization Taxonomy and Effective Detectioncited by 27
  11. 2024Digger: Detecting Copyright Content Mis-usage in Large Language Model Trainingcited by 24
  12. 2020Simplified Self-Attention for Transformer-based End-to-End Speech Recognitioncited by 20
2 more
  1. 2024Uncovering Logit Suppression Vulnerabilities in LLM Safety Alignmentcited by 16
  2. 2024MeTMaP: Metamorphic Testing for Detecting False Vector Matching Problems in LLM Augmented Generationcited by 4

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2024: 1; 2025: 1; 2026: 1.

3 papers.