Diagnose, Localize, Align: A Full-Stack Framework for Reliable LLM Multi-Agent Systems under Instruction Conflicts

Guancheng Wan, Leixin Sun, Mengting Li · DOI

TL;DR

This paper introduces a novel three-stage framework (Diagnose, Localize, Align) to improve the reliability of LLM-based multi-agent systems (MAS) when faced with conflicting instructions. By precisely identifying where and how agents fail to adhere to hierarchical rules, their method surgically fine-tunes only the critical parts of the model, leading to significant improvements in instruction compliance without full model retraining.

What Problem Does This Paper Address?

Large Language Model (LLM)-powered multi-agent systems (MAS) are becoming increasingly sophisticated, capable of complex collaborative reasoning and task execution. However, deploying these systems in critical applications is hampered by a fundamental issue: instruction conflicts. These arise when an agent receives competing instructions, such as a user request that contradicts a system-level rule. Current evaluation metrics, like task success rate (pass@k), are too coarse; they mask these subtle, micro-level failures in hierarchical compliance. This leaves us without a clear understanding of why agents fail or how to fix them. The authors aim to bridge this gap by providing a systematic way to diagnose, pinpoint, and repair these role adherence failures in MAS.

Methods

The paper proposes a three-stage "full-stack" framework:

  1. Diagnose (CRAS - Contextualized Role Adherence Score): This is a novel, query-wise metric that goes beyond simple task success. CRAS breaks down role adherence into four measurable dimensions:
  2. Goal Alignment (GA): Does the agent's action advance the sub-goals?
  3. Role Consistency (RC): Does the agent maintain its persona and reasoning style?
  4. Knowledge Boundary Adherence (KBA): Does the agent stay within its knowledge scope and admit ignorance?
  5. Constraint Compliance (CC): Does the agent follow explicit rules? CRAS uses a rubric-driven approach to provide fine-grained, reproducible scores, offering a much clearer diagnostic signal than macro metrics.

  6. Localize: To find where in the model these conflicts are resolved, the authors analyze attention patterns. By comparing attention maps between "normal" (non-conflicting) and "conflict" inputs, they identify "conflict-sensitive" attention heads. Their analysis reveals that these heads tend to cluster in the middle layers of the transformer, suggesting a specific region responsible for arbitration.

  7. Align (SAIL - Surgical Alignment of Instruction Layers): Based on the localization findings, SAIL applies a targeted fine-tuning approach. It uses Low-Rank Adaptation (LoRA) adapters, but only on the identified "focal" layers in the middle depth. Crucially, the training objective is a token-weighted Direct Preference Optimization (DPO) that prioritizes learning from tokens that were most influenced by these focal attention heads. This "surgical" approach ensures that only the parts of the model responsible for arbitration are updated, preserving general capabilities.

Datasets

The paper utilizes existing benchmarks for evaluation, including:

  • Task Diversity: MMLU, SciBench, GPQA, MedQA.
  • MAS Frameworks: Dylan, MacNet, AutoGen, SelfConsistency.

Additionally, they construct a conflict-detector dataset specifically for the localization stage. This dataset is designed to create direct, irreconcilable contradictions between system and user messages across seven cognitive dimensions (e.g., Perfect Alignment, Ambiguous Instructions, False Premises). This dataset is crucial for training the model to recognize and handle these conflicts.

Key Insights and Ideas

  • Micro-level failures are masked by macro metrics: The most significant insight is that standard MAS evaluation metrics fail to capture the nuanced ways agents break rules under instruction conflicts. CRAS provides a much-needed granular view.
  • Conflict resolution is localized: The finding that attention heads responsible for resolving instruction conflicts are concentrated in the middle layers is a key discovery. This localization is critical for enabling efficient, targeted fine-tuning.
  • Surgical fine-tuning is effective: By focusing updates only on these identified "focal" layers, SAIL achieves significant improvements in instruction compliance without the computational cost or risk of catastrophic forgetting associated with full-model fine-tuning.
  • Attention drift is a powerful diagnostic: Analyzing attention patterns provides a direct window into the model's internal arbitration mechanisms, offering a principled way to understand and address failures.

Key Results

  • SAIL significantly improves instruction hierarchy compliance across various MAS frameworks and datasets.
  • On MedQA with AutoGen, SAIL achieved a +5.60% increase in accuracy.
  • On MMLU with Dylan, SAIL showed gains of +1.75% ACC and +1.16 CRAS.
  • The method consistently improves performance without full-model fine-tuning, demonstrating efficiency.
  • Ablation studies confirm the effectiveness of each component: CRAS for diagnosis, conflict-driven layer targeting for localization, and token-weighted DPO for alignment.

Limitations and Future Work

  • Context-dependent synergy: The paper notes that the synergy between SAIL and base frameworks can be context-dependent, with some MAS frameworks showing degradation on certain datasets.
  • Hyperparameter sensitivity: While the paper validates 1e-5 as a suitable learning rate and rank 8 for LoRA, it acknowledges that these hyperparameters are critical for the fine-tuning process.
  • Future Work: The authors believe their work provides a pathway for aligning LLM MAS at scale and suggests extending focalized alignment to agents with long-horizon, multi-role coordination. They also highlight the potential for this approach to be applied to other areas where fine-grained control and understanding of internal model mechanisms are crucial.

Summary updated

BibTeX
@misc{wan2025diagnose,
  author = {Guancheng Wan and Leixin Sun and Mengting Li},
  title = {{Diagnose, Localize, Align: A Full-Stack Framework for Reliable LLM Multi-Agent Systems under Instruction Conflicts}},
  year = {2025},
  eprint = {2509.23188},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2509.23188},
}
Figure