🤖 AI Summary
This work addresses the limitations of current safety mechanisms in large language models, which predominantly focus on single-turn violation detection and struggle to manage latent, evolving compound risks across multi-turn interactions. To overcome this, the authors propose Recast, a novel framework that elevates safety risk prediction to the dialogue trajectory level. Recast employs dual-scale trajectory retrieval to gather risk evidence from both short-term exchanges and long-term conversation history, integrating compositional risk modeling with a causal temporal encoder to forecast the turn-wise distribution of future safety violations. Experimental results demonstrate that Recast successfully anticipates 88.3% of safety failures across seven risk categories, on average 2.41 turns in advance, with a low false positive rate of 12.3%, thereby achieving significantly improved proactive, cross-turn risk identification.
📝 Abstract
As large language models (LLMs) evolve from standalone assistants into autonomous agents, ensuring their safety requires shifting beyond pointwise risk assessment to understand how risks emerge and unfold over long-horizon trajectories. In multi-turn interactions, malicious intent can be decomposed across seemingly harmless turns and gradually reconstructed through interaction trajectories, eventually resulting in safety failures. Existing safeguards remain largely reactive, detecting manifested violations while lacking the ability to predict latent risk evolution and enable preemptive prevention. To address this limitation, we propose Recast, a safety risk forecasting framework that advances LLM safeguarding beyond turn-level violation detection to trajectory-level risk prediction. Recast first retrieves risk-relevant evidence from both short-term dialogue progression and long-term historical context via a dual-scale trajectory view. It then models compositional risk evolution by capturing the current risk configuration and its temporal dynamics. Finally, a causal temporal encoder learns latent risk evolution patterns and predicts the distribution of future risk emergence turns. Extensive experiments across 7 risk categories show that Recast predicts 88.3% of future safety failures with an average lead time of 2.41 turns, while maintaining a false alarm rate of 12.3%, showcasing the effectiveness of trajectory-level forecasting in identifying emerging risks before safety violations occur.