PRISM: Calibrated Prior-Risk Integration for Safe and Useful Test-Time Alignment

Yiqi Deng, Ruixi Liu, Jiahao Hu, Guoai Xu


Abstract
This paper investigates the problem of safety alignment in large language models (LLMs) during the testing phase, particularly under jailbreaking attacks. Previous methods typically rely on identifying malicious request intentions or adjusting the LLM’s decoding strategy to inject safe behavior. However, this often leads to over-rejection, limiting their practical application. To address this, we propose an innovative framework called Prior-Risk Integration for Safe Mixture decoding (PRISM). Specifically, PRISM first uses a lightweight semantic risk evaluator to calculate the prior probability of harmfulness at the prompt level, and then continuously tracks the cumulative risk signal provided by a safety evaluator during the generation process. By comprehensively considering these two types of risks, PRISM adaptively mixes the base model’s probability distribution with a safety preference distribution, triggering a rejection response only when both the prompt prior probability and the generation risk are sufficiently high. Extensive experiments validate the effectiveness of PRISM in resisting jailbreaking attacks and its practicality. Across five jailbreaking attack methods and three neutral datasets, PRISM demonstrates superior performance compared to other baseline methods.
Anthology ID:
2026.findings-emnlp.1190
Volume:
Findings of the Association for Computational Linguistics: EMNLP 2026
Month:
October
Year:
2026
Address:
Budapest, Hungary
Editors:
Hung-Yi Lee, Sunipa Dev, Jessy Li, Desmond Elliott
Venue:
Findings
SIG:
SIGDAT
Publisher:
Association for Computational Linguistics
Note:
Pages:
25128–25144
Language:
URL:
https://aclanthology.org/2026.findings-emnlp.1190/
DOI:
10.18653/2026.findings-emnlp.1190
Bibkey:
Cite (ACL):
Yiqi Deng, Ruixi Liu, Jiahao Hu, and Guoai Xu. 2026. PRISM: Calibrated Prior-Risk Integration for Safe and Useful Test-Time Alignment. In Findings of the Association for Computational Linguistics: EMNLP 2026, pages 25128–25144, Budapest, Hungary. Association for Computational Linguistics.
Cite (Informal):
PRISM: Calibrated Prior-Risk Integration for Safe and Useful Test-Time Alignment (Deng et al., Findings 2026)
Copy Citation:
PDF:
https://aclanthology.org/2026.findings-emnlp.1190.pdf