Manuscript Offprint

arXiv:2608.30703

SingProbe Technical Report

Sing Team

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Sing Team

AI Security Lab, Ant Group

https://github.com/inclusionAI/SingProbe

https://huggingface.co/collections/inclusionAI/singprobe

Figure

Efficiency (extra overhead % vs. base model, lower is better)

Figure 1: Effectiveness–efficiency trade-off of guardrail models. Efficiency (x) is the extra inference latency of a guard over the base-model-only serving baseline. We use Ling-3.0-flash as the base model. A non-streaming guard is invoked once after the complete response has been generated, whereas a streaming guard is invoked at every generation step. Effectiveness (y-axis) is measured as the average of the guard’s Query F1 and Response F1 across the evaluated benchmarks.

Abstract

Runtime guardrails are essential for reliable large language model (LLM) deployment, yet existing approaches typically rely on independent, external models that introduce additional inference cost, delayed safety signals, and a capacity mismatch with increasingly capable base models. To address these issues, we introduce SingProbe, a lightweight intrinsic runtime guard that directly reuses hidden states produced during LLM inference and operates alongside autoregressive decoding. Within a unified framework, SingProbe continuously predicts query intent, response safety, and hallucination risk at the token level with negligible additional guardrail inference overhead, offering a "free-lunch" solution. We further introduce SingStreamBench, a benchmark designed to assess whether streaming guardrails remain inactive on benign prefixes while promptly detecting emerging unsafe content. Extensive experiments show that SingProbe achieves competitive or superior performance compared with substantially larger standalone guardrails and specialized hallucination detectors, with only ≈\approx2M parameters and <0.5%< 0.5\% extra overhead. Beyond passive detection, we also show that SingProbe scores can anticipate future generation risk and guide constrained safe decoding. We further extend this paradigm to medical generation through SingProbe-Med, which selectively activates risk-directed decoding interventions only when clinically relevant risks emerge. Together, these results demonstrate that internal model representations provide an effective and efficient interface for generation-time monitoring and control.

1 Introduction

As LLMs are increasingly deployed in diverse real-world applications, unsafe, harmful, or unreliable generations can directly affect users and downstream systems (Ma et al., 2026). This concern becomes more pronounced as models are integrated into increasingly open-ended and automated workflows, including emerging agentic applications (Fawzy et al., 2026; Luo et al., 2025). Runtime safeguards (i.e., guardrails) are therefore essential for detecting and mitigating risky model behavior during inference, and have become a critical component of reliable LLM deployment (Group, 2026; Inan et al., 2023; Lin et al., 2026; Qi et al., 2026; Wu et al., 2024). Guardrails monitor interactions between users and models, identify potential risks, and provide signals for interventions such as refusal or regeneration (Cunningham et al., 2026; Han et al., 2024; Sharma et al., 2025). Effective guardrails should account for both sides of an interaction: harmful behavior may originate from a malicious user intent, or emerge within an otherwise benign response as generation unfolds (Zhao et al., 2025a). Moreover, reliable deployment requires monitoring not only harmful content but also potential hallucinations that may undermine the factual reliability of model responses (Huang et al., 2025; Luo et al., 2024).

These requirements motivate a unified guardrail capable of continuously perceiving query intent, response safety, and hallucination risk throughout generation.

Despite their importance, existing LLM guardrails suffer from several key limitations that hinder their practical deployment.

  1. Independent guardrail inference. Most guardrails operate as separate, independent models (Inan et al., 2023; Zhao et al., 2025a), introducing additional model parameters and deployment complexity. Existing streaming guardrails also compute semantic representations of the generated content from scratch, leaving the LLM's intermediate representations unexploited. This results in redundant computation and additional communication and synchronization overhead throughout decoding.

  2. Delayed safety signals. Conventional guardrails typically assess safety only after the complete response has been generated, preventing timely intervention during generation. To amortize the cost of independent guardrail inference, streaming systems often inspect outputs at the chunk level, delaying safety signals until sufficient content has accumulated and limiting fine-grained intervention.

  3. Limited guardrail capacity. Existing guardrails are often substantially smaller than the LLMs they monitor. As such, there exists a capacity mismatch that may limit their ability to understand complex outputs and make reliable safety judgments, particularly in long-horizon agentic tasks. As LLMs increasingly support million-token contexts, matching their long-context understanding with a separate guardrail becomes increasingly challenging.

Together, these limitations create a fundamental trade-off between detection effectiveness and computational efficiency, constraining the scaling of guardrail models: improving detection capability generally comes at the cost of higher inference and deployment overhead, while efficiency requirements limit model capacity and monitoring granularity.

To overcome this effectiveness-efficiency trade-off, we draw inspiration from recent findings that LLM hidden states encode safety-discriminative signals, yet these signals may fail to prevent harmful generations due to insufficient safety generation ability or jailbreak-induced suppression (Ding et al., 2025; Zhao et al., 2025b). This motivates us to directly reuse the model's hidden states for intrinsic safety classification. Building on this insight, we introduce SingProbe (i.e., Safety in Generation Probe), an intrinsic safety and hallucination detection model integrated into the models. SingProbe directly consumes the hidden states produced during model inference and operates alongside language-model decoding, avoiding repeated text encoding and separate guardrail inference. Within a unified framework, it supports query intent classification, response safety classification, and response hallucination detection. By producing continuously updated predictions throughout generation, SingProbe enables fine-grained, token-level monitoring of safety and hallucination risks with negligible additional inference overhead. For practical deployment, we further integrate SingProbe into

SGLang 1^{1} (Zheng et al., 2024) and vLLM 2^{2} (Kwon et al., 2023), enabling token generation and guardrail scoring within a unified serving pipeline. This system-level integration removes the need to deploy and coordinate a separate guardrail service, reduces cross-service communication, and allows token-level guardrail signals to share SGLang's inference infrastructure, thereby simplifying scalable deployment.

To enable systematic evaluation of generation-time safety monitoring, we further introduce SingStreamBench, a streaming safety benchmark that explicitly evaluates whether a guardrail can remain inactive on benign prefixes and respond promptly once unsafe content emerges. Across comprehensive evaluations of query-intent classification, response safety, streaming detection, hallucination detection, and benign false-positive robustness, SingProbe achieves competitive or superior performance compared with substantially larger standalone guardrails and specialized hallucination detectors.

Beyond passive detection, we further study SingProbe as a generation-time control signal, including online monitoring under free autoregressive generation and SingProbe-guided constrained decoding, demonstrating that its token-level risk scores can also support safer generation decisions. We additionally extend this paradigm to the medical domain with SingProbe-Med, where token-level internal-state signals determine when a medical-risk intervention should be activated. By applying contrastive decoding only to risk-relevant suffixes, SingProbe-Med enables selective, on-demand correction while avoiding continuous intervention on benign generations.

References (58)