TRACE: Trajectory Return Attribution and Contrastive Erasure for Multi-Turn Safety
cs.AI
Submitted: 2026-10-01
Updated: 2026-10-01
Code: https://github.com/tatsu-lab/stanford_alpaca
License: http://creativecommons.org/licenses/by/4.0/
The gist: Safety-aligned large language models (LLMs) often refuse a harmful request but comply once the same goal is spread over several turns.
Terminology
Abstract
Safety-aligned large language models (LLMs) often refuse a harmful request but comply once the same goal is spread over several turns. Preference objectives score whole responses to single prompts, so their training loss alone cannot control risk on unseen histories. Our analysis gives sufficient conditions under which suppression at supervised single-turn contexts yields a bound on multi-turn trajectory risk. The bound accounts for coverage, transfer slack, and leakage, and characterizes contraction relative to a base-policy risk budget evaluated on the trained policy's contexts. TRACE (Trajectory Return Attribution and Contrastive Erasure) turns this principle into a token-level objective. On the safe response, each token is weighted by the discounted return of a refusal-attributable advantage. The advantage compares a frozen reference model with its refusal-ablated copy, allowing earlier response tokens to receive credit from later refusal-related evidence. At high-gap positions on rejected responses, TRACE combines the observed token with policy-selected alternatives in the erasure target. A gradient-norm penalty replaces the retain set. Across five open-weight models and seven multi-turn attacks, TRACE gives the lowest attack success rate (ASR) in all 35 model and attack pairs, while the model utility evaluated on MMLU and HellaSwag drop by at most 1.23 points. Source code can be found in the supplemental material.
Sources
- Training a Helpful and Harmless Assistant with Reinforcement Learning from Human Feedback
- SafeDialBench: A Fine-Grained Safety Evaluation Benchmark for Large Language Models in Multi-Turn Dialogues with Diverse Jailbreak Attacks
- KTO: Model Alignment as Prospect Theoretic Optimization
- Gemma 3 Technical Report
- The Llama 3 Herd of Models
- Measuring Massive Multitask Language Understanding
- Safety Tax: Safety Alignment Makes Your Large Reasoning Models Less Reasonable
- SafeDPO: A Simple Approach to Direct Preference Optimization with Enhanced Safety
- LLM Defenses Are Not Robust to Multi-Turn Human Jailbreaks Yet
- HarmBench: A Standardized Evaluation Framework for Automated Red Teaming and Robust Refusal
- Mitigating the Safety Alignment Tax with Null-Space Constrained Policy Optimization
- Advantage-Weighted Regression: Simple and Scalable Off-Policy Reinforcement Learning
- X-Teaming: Multi-Turn Jailbreaks and Defenses with Adaptive Multi-Agents
- LLMs know their vulnerabilities: Uncover Safety Gaps through Natural Distribution Shifts
- Diverse Preference Learning for Capabilities and Alignment
- MultiBreak: A Scalable and Diverse Multi-turn Jailbreak Benchmark for Evaluating LLM Safety
- Qwen3.5-Omni Technical Report
- Multi-Turn Jailbreaks Are Simpler Than They Seem
- Negative Preference Optimization: From Catastrophic Collapse to Effective Unlearning
- Improving Safety Alignment via Balanced Direct Preference Optimization
Related papers
- MAVEN-T: Reinforced Heterogeneous Distillation for Real-Time Multi-Agent Trajectory Prediction
- Model Discovery Agent: LLM-assisted Bayesian experiment design for data-efficient discovery of mechanistic world models
- Agents' Last Exam
- The Clinician's Veto: Navigating Trust, Liability, and Uncertainty in Autonomous AI Prescribing
- MindHelper: Closed-Loop Embodied Mental-State Reasoning for Precision Intervention
- Incumbent Advantage: Brand Bias and Cognitive Manipulation Dynamics in LLM Recommendation Systems