BadThink让大模型在推理时过度思考,悄无声息增加计算开销。
BadThink: Triggered Overthinking Attacks on Chain-of-Thought Reasoning in Large Language Models
- 用精心设计的触发词诱导模型生成冗长推理链。
- 在MATH-500数据集上使推理长度提升超17倍。
- 攻击隐蔽性强,适合研究模型安全与对抗防御者阅读。
Chain-of-Thought(CoT)提示显著提升了大语言模型的推理能力,但也带来了计算效率的新攻击面。本文提出BadThink,首个旨在诱发CoT模型‘过度思考’行为的后门攻击,同时保持隐蔽性。当被精心设计的触发提示激活时,BadThink会操纵模型生成过长且冗余的推理过程,最终输出保持一致但推理链大幅膨胀。这种隐性攻击导致计算成本和推理时间显著上升,常规输出评估难以检测。我们通过基于中毒微调的策略实现该攻击,采用新型基于LLM的迭代优化过程生成高度自然的中毒数据。实验在多个前沿模型和推理任务上验证,BadThink持续提升推理链长度,在MATH-500数据集上实现超过17倍的增长,且具备强鲁棒性和隐蔽性。本工作揭示了推理效率可被隐蔽操控的关键漏洞,展示了一类针对CoT系统的新型复杂攻击。
原文摘要 · Abstract (English)
Recent advances in Chain-of-Thought (CoT) prompting have substantially improved the reasoning capabilities of large language models (LLMs), but have also introduced their computational efficiency as a new attack surface. In this paper, we propose BadThink, the first backdoor attack designed to deliberately induce "overthinking" behavior in CoT-enabled LLMs while ensuring stealth. When activated by carefully crafted trigger prompts, BadThink manipulates the model to generate inflated reasoning traces - producing unnecessarily redundant thought processes while preserving the consistency of final outputs. This subtle attack vector creates a covert form of performance degradation that significantly increases computational costs and inference time while remaining difficult to detect through conventional output evaluation methods. We implement this attack through a sophisticated poisoning-based fine-tuning strategy, employing a novel LLM-based iterative optimization process to embed the behavior by generating highly naturalistic poisoned data. Our experiments on multiple state-of-the-art models and reasoning tasks show that BadThink consistently increases reasoning trace lengths - achieving an over 17x increase on the MATH-500 dataset - while remaining stealthy and robust. This work reveals a critical, previously unexplored vulnerability where reasoning efficiency can be covertly manipulated, demonstrating a new class of sophisticated attacks against CoT-enabled systems.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。