cs.LGNov 8, 2026

Chatter Attack: Resource Consumption Attack for Large Language Models

Authors: Yibo Miao, Yichuan Cao, Xiao-Shan Gao, Yinpeng Dong

Organizations: T-STAR Lab, College of AI, Tsinghua University, Beijing 100084, China · State Key Laboratory of Math. Sci., Academy of Mathematics and Systems Science, Chinese Academy of Sciences, Beijing 100190, China · Shanghai Qi Zhi Institute

Abstract

LLMs are powerful but incur substantial inference cost, which can be exploited by malicious users to induce overly long outputs, increasing latency and operational expense. Prior resource consumption attacks either coerce repetition or suppress the end-of-sequence token by lowering its logit value. However, with autoregressive, sampling-based generation, the search space grows exponentially with length and small deviations or unstable trajectories can derail optimization, limiting attack effectiveness and stability. To address this issue, we introduce Chatter Attack, a novel class of resource consumption attacks that optimize adversarial prompts to induce predefined short target phrases, thereby avoiding search-space explosion while still eliciting long responses. Specifically, Chatter Attack triggers self-doubt using short doubt-inducing phrases as the target, and sustains this state throughout generation via inference attention loss and global entropy loss. To extend to black-box settings, we further propose a novel Bayesian Prompt Optimization (BPO) method, which models the objective function globally by constructing a discrete token kernel, efficiently exploring the entire search space using prior information. Extensive experiments across multiple models and datasets show that our method outperforms baselines, with maximum response length increases to 31.5×\times, and revealing practical resource-depletion risks for real-world LLM inference services.

Figures & tables

Appendix figures & tables16 assets

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. Diffusion LLMs are Natural Adversaries for any LLM

    Oct 31, 2025David Lüdke, Tom Wollschläger, Paul Ungermann +2Adversarial Prompt GenerationAdversarial Attacks on LLMs

  2. Inference Cost Attacks for Retrieval-Augmented Large Language Models

    May 31, 2026Chengliang Liu, Liangbo Ning, Yujuan Ding +1Retrieval-Augmented GenerationAdversarial Attacks