The emerging capabilities of large language models (LLMs) have sparked concerns about their immediate potential for harmful misuse. The core approach to mitigate these concerns is the detection of harmful queries to the model. Current detection approaches are fallible, and are particularly susceptible to attacks that exploit mismatched generalization of model capabilities (e.g., prompts in low-resource languages or prompts provided in non-text modalities such as image and audio). To tackle this challenge, we propose Omniguard, an approach for detecting harmful prompts across languages and modalities. Our approach (i) identifies internal representations of an LLM/MLLM that are aligned across languages or modalities and then (ii) uses them to build a language-agnostic or modality-agnostic classifier for detecting harmful prompts. Omniguard improves harmful prompt classification accuracy by 11.57\% over the strongest baseline in a multilingual setting, by 20.44\% for image-based prompts, and sets a new SOTA for audio-based prompts. By repurposing embeddings computed during generation, Omniguard is also very efficient ($\approx\!120 \times$ faster than the next fastest baseline). Code and data are available at: https://github.com/vsahil/OmniGuard.


翻译:大型语言模型(LLMs)新兴的能力引发了对其潜在有害滥用的担忧。缓解这些担忧的核心方法是检测对模型的有害查询。当前的检测方法存在缺陷,尤其容易受到利用模型能力泛化不匹配的攻击(例如,使用低资源语言的提示或通过非文本模态如图像和音频提供的提示)。为应对这一挑战,我们提出了Omniguard,一种用于检测跨语言和跨模态有害提示的方法。我们的方法(i)识别LLM/MLLM中在语言或模态间对齐的内部表示,然后(ii)利用这些表示构建语言无关或模态无关的分类器来检测有害提示。在多语言设置中,Omniguard将有害提示分类准确率比最强基线提高了11.57%,对于基于图像的提示提高了20.44%,并为基于音频的提示设定了新的SOTA。通过重用生成过程中计算的嵌入,Omniguard也非常高效(比次快基线快约120倍)。代码和数据可在以下网址获取:https://github.com/vsahil/OmniGuard。

0
下载
关闭预览

相关内容

【ACMMM2025】EvoVLMA: 进化式视觉-语言模型自适应
专知会员服务
15+阅读 · 8月5日
【NeurIPS2024】IPO: 面向视觉-语言模型的可解释提示优化
专知会员服务
22+阅读 · 2024年10月23日
Python图像处理,366页pdf,Image Operators Image Processing in Python
国家自然科学基金
17+阅读 · 2017年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
4+阅读 · 2015年12月31日
国家自然科学基金
29+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
VIP会员
相关基金
国家自然科学基金
17+阅读 · 2017年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
4+阅读 · 2015年12月31日
国家自然科学基金
29+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员