Large Language Models (LLMs) serve as the backbone of modern AI systems, yet they remain susceptible to adversarial jailbreak attacks. Consequently, robust detection of such malicious inputs is paramount for ensuring model safety. Traditional detection methods typically rely on external models trained on fixed, large-scale datasets, which often incur significant computational overhead. While recent methods shift toward leveraging internal safety signals of models to enable more lightweight and efficient detection. However, these methods remain inherently static and struggle to adapt to the evolving nature of jailbreak attacks. Drawing inspiration from the biological immune mechanism, we introduce the Immune Memory Adaptive Guard (IMAG) framework. By distilling and encoding safety patterns into a persistent, evolvable memory bank, IMAG enables adaptive generalization to emerging threats. Specifically, the framework orchestrates three synergistic components: Immune Detection, which employs retrieval for high-efficiency interception of known jailbreak attacks; Active Immunity, which performs proactive behavioral simulation to resolve ambiguous unknown queries; Memory Updating, which integrates validated attack patterns back into the memory bank. This closed-loop architecture transitions LLM defense from rigid filtering to autonomous adaptive mitigation. Extensive evaluations across five representative open-source LLMs demonstrate that our method surpasses state-of-the-art (SOTA) baselines, achieving a superior average detection accuracy of 94\% across diverse and complex attack types.


翻译:大型语言模型(LLMs)作为现代人工智能系统的核心,仍然容易受到对抗性越狱攻击的影响。因此,对这些恶意输入进行鲁棒检测对于确保模型安全至关重要。传统检测方法通常依赖于在固定的大规模数据集上训练的外部模型,这往往带来显著的计算开销。近期的方法则转向利用模型内部的安全信号,以实现更轻量、高效的检测。然而,这些方法本质上仍是静态的,难以适应越狱攻击不断演变的特性。受生物免疫机制的启发,我们提出了免疫记忆自适应防护(IMAG)框架。通过将安全模式提炼并编码到一个持久、可演化的记忆库中,IMAG能够对新兴威胁实现自适应泛化。具体而言,该框架协调三个协同组件:免疫检测,利用检索机制高效拦截已知的越狱攻击;主动免疫,通过主动行为模拟来解析模糊的未知查询;记忆更新,将经过验证的攻击模式整合回记忆库。这种闭环架构将LLM防御从刚性过滤转变为自主自适应缓解。在五个具有代表性的开源LLM上进行的大量评估表明,我们的方法超越了当前最先进的基线模型,在多样且复杂的攻击类型中实现了平均94%的优异检测准确率。

0
下载
关闭预览

相关内容

大语言模型机器遗忘综述
专知会员服务
18+阅读 · 2025年11月2日
综述:面向移动端大语言模型的隐私与安全
专知会员服务
19+阅读 · 2025年9月7日
【新书】大规模语言模型的隐私与安全,
专知会员服务
29+阅读 · 2024年12月4日
大型语言模型网络安全综述
专知会员服务
67+阅读 · 2024年5月12日
大型语言模型在预测和异常检测中的应用综述
专知会员服务
70+阅读 · 2024年2月19日
【2024新书】大型语言模型安全开发者手册,250页pdf
专知会员服务
74+阅读 · 2024年2月12日
通信网络中大型语言模型的后门攻击的综述
专知会员服务
30+阅读 · 2023年9月5日
绝对干货!NLP预训练模型:从transformer到albert
新智元
13+阅读 · 2019年11月10日
自然语言处理中的语言模型预训练方法
PaperWeekly
14+阅读 · 2018年10月21日
原创 | Attention Modeling for Targeted Sentiment
黑龙江大学自然语言处理实验室
25+阅读 · 2017年11月5日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
VIP会员
相关VIP内容
大语言模型机器遗忘综述
专知会员服务
18+阅读 · 2025年11月2日
综述:面向移动端大语言模型的隐私与安全
专知会员服务
19+阅读 · 2025年9月7日
【新书】大规模语言模型的隐私与安全,
专知会员服务
29+阅读 · 2024年12月4日
大型语言模型网络安全综述
专知会员服务
67+阅读 · 2024年5月12日
大型语言模型在预测和异常检测中的应用综述
专知会员服务
70+阅读 · 2024年2月19日
【2024新书】大型语言模型安全开发者手册,250页pdf
专知会员服务
74+阅读 · 2024年2月12日
通信网络中大型语言模型的后门攻击的综述
专知会员服务
30+阅读 · 2023年9月5日
相关基金
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员