TL;DR
DASE (Dual-Cycle Adversarial Self-Evolution) is a training-free framework that hardens role-playing LLMs against jailbreaks without sacrificing their persona. By pitting an automated attacker against a defender in a co-evolutionary "arms race," the system distills adversarial failures into a hierarchical knowledge base that guides safer, more authentic character responses at inference time.
What Problem Does This Paper Address?
Large Language Models (LLMs) are increasingly used as Role-Playing Agents (RPAs), but they face a fundamental "safety-consistency trade-off." To stay in character—especially for "edgy" or villainous personas—models often bypass their internal safety guardrails, a phenomenon known as "jailbreak by immersion."
Existing defenses usually rely on Supervised Fine-Tuning (SFT) or Reinforcement Learning (RL), which have three major drawbacks:
- High Cost: Retraining models for every new persona or attack strategy is computationally expensive.
- Fragility: Optimization-based defenses often fail to generalize to unseen personas or novel, sophisticated attacks.
- Black-Box Incompatibility: Most frontier models (like GPT-4 or Kimi) are closed-weight; users cannot fine-tune them, making gradient-based defenses impossible.
Methods
The authors introduce DASE, a training-free framework that treats safety as a dynamic boundary rather than a static parameter constraint. It operates through two coupled cycles:
- Persona-Targeted Attacker Cycle: An agent that synthesizes progressively stronger jailbreak prompts tailored to a specific character's traits and narrative background.
- Role-Playing Defender Cycle: Instead of updating weights, this agent maintains a Hierarchical Knowledge Base (HKB). When the attacker finds a "blind spot," the system performs a "semantic update"—using an LLM to add, modify, or merge natural language rules in the HKB.
The HKB is structured into three tiers:
- Tier 1: Global Experience: Universal safety protocols.
- Tier 2: Personalized Experience: Role-specific instructions on how to refuse harmful requests in character (e.g., a villain refusing a request by mocking the user's "boring" idea).
- Tier 3: Golden Exemplars: A repository of safe, high-fidelity few-shot examples for In-Context Learning (ICL).
At inference time, the Defender retrieves relevant bits from this hierarchy to construct a prompt that guides the base LLM to stay safe and in character.
Datasets
The authors evaluated DASE across several rigorous benchmarks:
- Safety Benchmarks: AdvBench (harmful instructions), HEx-PHI (11 categories of safety risks), and BeaverTails (QA pairs).
- Jailbreak Attacks: AIM (persona-based), Cipher (cryptographic), and CodeChameleon (code-encapsulation).
- Role-Playing: RoleBench, focusing on 10 diverse roles ranging from Stephen Hawking to Deadpool.
Key Insights and Ideas
- Semantic Gradients: DASE replaces numerical gradient updates with natural language updates. This makes the defense entirely model-agnostic and applicable to any black-box API.
- Safety-Consistency Synergy: The paper argues that safety and persona fidelity don't have to be at odds. By teaching a model how a specific character would safely refuse a request (e.g., Freddy Krueger calling a user a "meat sack" while refusing to provide a poison recipe), the framework actually improves role immersion while closing safety gaps.
- Knowledge Portability: A surprising finding was "Safety Distillation." A knowledge base evolved using a stronger model (like GPT-5.2) can be plugged into a weaker model (like Kimi-K2) to significantly boost its jailbreak resistance, acting as a "safety patch."
Key Results
DASE achieved consistent gains over both massive-scale base models and state-of-the-art training-based methods (like SaRFT):
- Superior Performance: DASE[Kimi-K2] outperformed the best training-based configuration by 6.73 points in RoleBench fidelity and 33.03 points in average jailbreak defense.
- Hardening Proprietary Models: It boosted Kimi-K2’s defense against Cipher attacks from 85.50% to 95.75% and improved GPT-5.2’s resistance to CodeChameleon attacks to a perfect 100%.
- Breaking the Trade-off: As shown in Figure 1, DASE simultaneously improves role fidelity, general safety, and jailbreak resistance, whereas non-evolving models typically struggle to balance all three.
Limitations and Future Work
- Inference Latency: The process of retrieving and composing structured knowledge from the HKB adds overhead to the inference pipeline.
- Judge Dependency: The quality of the self-evolution depends heavily on the "Multi-Dimension Judge" model used to evaluate failures. If the judge is flawed, the evolved rules may be less effective.
- Future Directions: The authors suggest exploring more complex multi-turn adversarial scenarios and scaling the framework to even more diverse and niche personas.
Summary updated