Any-Depth Alignment: Unlocking Innate Safety Alignment of LLMs to Any-Depth
On the map: LLM alignment / RLHF / preference optimisation → Safety alignment and jailbreak attacks
also in 1 more
Abstract (arXiv)
Large Language Models (LLMs) exhibit strong but shallow alignment: they directly refuse harmful queries when a refusal is expected at the very start of an assistant turn, yet this protection collapses once a harmful continuation is underway (either through the adversarial attacks or via harmful assistant-prefill attacks). This raises a fundamental question: Can the innate shallow alignment in LLMs be unlocked to ensure safety at arbitrary generation depths? To achieve this goal, we propose Any-Depth Alignment (ADA), an effective inference-time defense with negligible overhead. ADA is built based on our observation that alignment is concentrated in the assistant header tokens through repeated use in shallow-refusal training, and these tokens possess the model's strong alignment priors. By reintroducing these tokens mid-stream, ADA induces the model to reassess harmfulness and recover refusals at any point in generation. Across diverse open-source model families (Llama, Gemma, Mistral, Qwen, DeepSeek, and gpt-oss), ADA achieves robust safety performance without requiring any changes to the base model's parameters. It secures a near-100% refusal rate against challenging adversarial prefill attacks ranging from dozens to thousands of tokens. Furthermore, ADA reduces the average success rate of prominent adversarial prompt attacks (such as GCG, AutoDAN, PAIR, and TAP) to below 3%. This is all accomplished while preserving utility on benign tasks with minimal over-refusal. ADA maintains this resilience even after the base model undergoes subsequent instruction tuning (benign or adversarial).
Key facts. Cited by 3 papers in the map (data through 14 Oct 2026). Placed in Safety alignment and jailbreak attacks, one of 10 directions in LLM alignment / RLHF / preference optimisation. Builds on 44 of its 54 references that are in the map. First posted on arXiv 20 Oct 2025.
Builds on
44 of 54 references.
Closest ancestors · 6
Same direction, newest first
- 2025From Judgment to Interference: Early Stopping LLM Harmful Outputs via Streaming Content Monitoring11 Jun
- 2025The Geometry of Refusal in Large Language Models: Concept Cones and Representational Independence24 Feb
- 2024Safety Alignment Should Be Made More Than Just a Few Tokens Deep10 Jun
- 2023Fine-tuning Aligned Language Models Compromises Safety, Even When Users Do Not Intend To!5 Oct
- 2023AutoDAN: Generating Stealthy Jailbreak Prompts on Aligned Large Language Models3 Oct
- 2023Universal and Transferable Adversarial Attacks on Aligned Language Models27 Jul
Other references · 38
- 2017Attention Is All You Needcited by 60,361
- 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,399
- 2020Language Models are Few-Shot Learnerscited by 32,419
- 2024The Llama 3 Herd of Modelscited by 14,715
- 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 13,028
- 2022Chain-of-Thought Prompting Elicits Reasoning in Large Language Modelscited by 12,459
- 2021Training Verifiers to Solve Math Word Problemscited by 10,109
- 2021Evaluating Large Language Models Trained on Codecited by 8,320
- 2020Measuring Massive Multitask Language Understandingcited by 7,963
- 2025DeepSeek-R1: Incentivizing Reasoning Capability in LLMs via Reinforcement Learningcited by 6,330
- 2021Measuring Mathematical Problem Solving With the MATH Datasetcited by 5,371
- 2023SWE-bench: Can Language Models Resolve Real-World GitHub Issues?cited by 3,373
26 more
- 2023GPQA: A Graduate-Level Google-Proof Q&A Benchmarkcited by 2,879
- 2023FlashAttention-2: Faster Attention with Better Parallelism and Work Partitioningcited by 2,598
- 2024Gemma 2: Improving Open Language Models at a Practical Sizecited by 1,998
- 2022Challenging BIG-Bench Tasks and Whether Chain-of-Thought Can Solve Themcited by 1,807
- 2023Jailbreaking Black Box Large Language Models in Twenty Queriescited by 1,420
- 2023Llama Guard: LLM-based Input-Output Safeguard for Human-AI Conversationscited by 1,207
- 2024Refusal in Language Models Is Mediated by a Single Directioncited by 1,032
- 2023Tree of Attacks: Jailbreaking Black-Box LLMs Automaticallycited by 672
- 2024WildChat: 1M ChatGPT Interaction Logs in the Wildcited by 629
- 2024JailbreakBench: An Open Robustness Benchmark for Jailbreaking Large Language Modelscited by 536
- 2023XSTest: A Test Suite for Identifying Exaggerated Safety Behaviours in Large Language Modelscited by 505
- 2024WildGuard: Open One-Stop Moderation Tools for Safety Risks, Jailbreaks, and Refusals of LLMscited by 496
- 2024Jailbreaking Leading Safety-Aligned LLMs with Simple Adaptive Attackscited by 486
- 2024Measuring short-form factuality in large language modelscited by 373
- 2024SafeDecoding: Defending against Jailbreak Attacks via Safety-Aware Decodingcited by 247
- 2023LLM Self Defense: By Self Examination, LLMs Know They Are Being Trickedcited by 244
- 2024ShieldGemma: Generative AI Content Moderation Based on Gemmacited by 243
- 2024WildTeaming at Scale: From In-the-Wild Jailbreaks to (Adversarially) Safer Language Modelscited by 223
- 2024Latent Adversarial Training Improves Robustness to Persistent Harmful Behaviors in LLMscited by 173
- 2025Emergent Misalignment: Narrow finetuning can produce broadly misaligned LLMscited by 172
- 2024AEGIS: Online Adaptive AI Content Safety Moderation with Ensemble of LLM Expertscited by 136
- 2025LLMs Encode Harmfulness and Refusal Separatelycited by 88
- 2025UDora: A Unified Red Teaming Framework against LLM Agents by Dynamically Hijacking Their Own Reasoningcited by 21
- 2025Investigating task-specific prompts and sparse autoencoders for activation monitoringcited by 15
- 2025Learning Safety Constraints for Large Language Modelscited by 13
- 2025The Geometry of Harmfulness in LLMs through Subconcept Probingcited by 7
Built on by
Citing papers per year: 2026: 3.
3 papers.
- 2026LLM Safety From Within: Detecting Harmful Content with Internal Representationscited by 11
- 2026Breaking Refusal in the First Half: A Mechanistic Study of the Prefill Jailbreakcited by 0
- 2026Beyond Refusal Patterns: Safe-Role Internalization for Robust and Generalizable LLM Safety Alignmentcited by 0
- 2026Beyond Refusal Patterns: Safe-Role Internalization for Robust and Generalizable LLM Safety Alignment4 Oct 2026
- 2026Breaking Refusal in the First Half: A Mechanistic Study of the Prefill Jailbreak14 Jul 2026
- 2026LLM Safety From Within: Detecting Harmful Content with Internal Representations20 Apr 2026
Similar, not cited
Close in wording, no citation either way
- 2025Safety Alignment Depth in Large Language Models: A Markov Chain Perspective
- 2026LLMs Can Unlearn Refusal with Only 1,000 Benign Samples
- 2026Fail-Closed Alignment for Large Language Models
- 2026Inference-Time Vulnerability Beyond Shallow Safety: Alignment Along Generation Trajectories
- 2025EASE: Practical and Efficient Safety Alignment for Small Language Models
- 2026LASA: Language-Agnostic Semantic Alignment at the Semantic Bottleneck for LLM Safety
- 2026Safety at One Shot: Patching Fine-Tuned LLMs with A Single Instance
- 2024Safety Layers in Aligned Large Language Models: The Key to LLM Security