Jailbreak attempts and harmful prompts remain a challenge for the safe deployment of large language models. We study whether contrastively learned representations can support safety detection without training an additional downstream classifier. We propose Jailbreak Detection with Prototype Inference (JDPI), which uses binary safety labels to construct harmful and benign prototypes and makes predictions from relative prototype distances. JDPI uses only binary safety labels for encoder adaptation, prototype construction, and validation. In our setup, it uses fewer labeled examples than the classifier baseline (Method A) by avoiding the separate split used to train the downstream classifier. Across four benchmarks covering different input formats, contrastive fine-tuning improves JDPI's detection accuracy by 9.1-18.0 percentage points. Using the same encoder, JDPI achieves slightly higher ROC-AUC on one benchmark and stays within 0.017 of the baseline across all four. With dataset-specific adaptation, JDPI exceeds the released Llama Guard 3-8B baseline by 0.173-0.310 in ROC-AUC across the four benchmarks. In multi-turn replay on TomGibbs, JDPI uses accumulated user history as the conversation unfolds, achieving higher conversation-level accuracy than when it uses the current turn alone. Across 12 directed transfers, JDPI outperforms the classifier by an average of 1.59 percentage points in accuracy, demonstrating stronger cross-dataset robustness.
Turning Logic Against Itself : Probing Model Defenses Through Contrastive Questions
Ubiquitous Knowledge Processing Lab (UKP Lab), Department of Computer Science and Hessian Center for AI (hessian.AI), Technical University of Darmstadt(德累斯顿技术大学计算机科学系、海斯堡人工智能中心(hessian.AI)、通用知识处理实验室(UKP Lab))
针对推理驱动的隐蔽越狱漏洞,本文提出 POATE 对比推理攻击,并设计 Intent-Aware CoT 与 Reverse Thinking CoT 以检测恶意意图、拒绝有害输出。
KFCNet: Knowledge Filtering and Contrastive Learning Network for Generative Commonsense Reasoning
School of Computing and Information Systems, The University of Melbourne(墨尔本大学计算与信息系统学院);Microsoft Research Asia(微软亚洲研究院);Microsoft(微软)
预先训练的语言模型已经在广泛的自然语言处理(NLP)任务中取得了实质性的进展,但已经被证明对于具有高质量输出要求的自然语言生成任务具有局限性,例如常识生成和广告关键字生成。在这项工作中,我们提出了一种新的知识过滤和对比学习网络(KFCNet),参考外部知识,并取得更好的生成性能。具体来说,我们提出了一个基于BERT的过滤器模型,以消除低质量的候选人,并分别应用对比学习的编码器和解码器中的每一个,在一个通用的编码器-解码器架构。编码器对比模块有助于在编码过程中捕获全局目标语义,解码器对比模块在学习一般特征的同时增强检索到的原型的实用性。在CommonGen基准测试上进行的大量实验表明,我们的模型远远优于先前的最先进水平:BLEU-4为+6.6点(42.5 vs. 35.9),SPICE为+3.7点(33.3 vs. 29.6),CIDER为+1.3点(18.3 vs. 17.0)。我们进一步验证了所提出的对比模块在广告关键词生成上的有效性,并表明我们的模型具有潜在的商业价值。
Causal Front-Door Adjustment for Robust Jailbreak Attacks on LLMs
Institute of Software Chinese Academy of Sciences, Beijing, China(中国科学院软件研究所);University of Chinese Academy of Sciences, Beijing, China(中国科学院大学);Institute of Information Engineering Chinese Academy of Sciences, Beijing, China(中国科学院信息工程研究所);Hong Kong University of Science and Technology, China, Hong Kong, China(香港科学与技术大学)
Simple-Sampling and Hard-Mixup with Prototypes to Rebalance Contrastive Learning for Text Classification
College of Computer Science and Technology, Jilin University(吉林大学计算机科学与技术学院);Department of Information Engineering and Computer Science, University of Trento(特伦托大学信息工程与计算机科学系)
WildTeaming at Scale: From In-the-Wild Jailbreaks to (Adversarially) Safer Language Models
Allen Institute for Artificial Intelligence(艾伦人工智能研究所);Seoul National University(首尔大学);Carnegie Mellon University(卡内基梅隆大学);University of Washington(华盛顿大学)
PAST-TIDE: Prototype-Anchored Statement Tuning with Topic-Invariant Normalization for Stance Detection
Department of Computer Science and Engineering, Khulna University of Engineering & Technology(库尔纳工程技术大学计算机科学与工程系);Department of Electrical and Computer Engineering, University of Waterloo(滑铁卢大学电气与计算机工程系);Department of Machine Learning, Mohamed bin Zayed University of Artificial Intelligence(穆罕默德·本·扎耶德人工智能大学机器学习系)