Year: 2026
Type: conference-paper
Abstract: As Large Language Models (LLMs) grow increasingly powerful, ensuring their safety and alignment with human values remains a critical challenge.Ideally, LLMs should provide informative responses while avoiding harmful or sensitive disclosures.However, current alignment strategies, reliant on binary refusal (e.g., rejecting prompts or coarse filtering), lack nuance.This leads to overcensorship, failure to detect subtle harm (like withholding public medication information due to misuse concerns), and difficulty with mixed or context-dependent sensitivities, often overcensoring benign content.To overcome these challenges, we introduce HIDDENGUARD, a novel framework for fine-grained, safe generation in LLMs.HIDDENGUARD incorporates PRISM (Representation Router for In-Stream Moderation), which operates alongside the LLM to enable real-time, token-level detection and redaction of harmful content by leveraging intermediate hidden states.This fine-grained approach allows for more nuanced, contextaware moderation, enabling the model to generate informative responses while selectively redacting or replacing sensitive information, rather than outright refusal.We also contribute a comprehensive dataset with token-level finegrained annotations of potentially harmful information across diverse contexts.Our experiments demonstrate that HIDDENGUARD achieves over 90% in F 1 score for detecting and redacting harmful content while preserving the overall utility and informativeness of the model's responses.
Language: English
Subfield: Artificial Intelligence
Field: Computer Science
Domain: Physical Sciences
Open Access status: hybrid
Awards: G1907283378, G2706053043, G8808570173
OpenAlex ID: W7166861970
