Many-Tier Instruction Hierarchy in LLM Agents
Organizations: Johns Hopkins University
Abstract
Large language model agents receive instructions from many sources-system messages, user prompts, tool outputs, other agents, and more-each carrying different levels of trust and authority. When these instructions conflict, agents must reliably follow the highest-privilege instruction to remain safe and effective. The dominant paradigm, instruction hierarchy (IH), assumes a fixed, small set of privilege levels (typically fewer than five) defined by rigid role labels (e.g., system > user). This is inadequate for real-world agentic settings, where conflicts can arise across far more sources and contexts. In this work, we propose Many-Tier Instruction Hierarchy (ManyIH), a paradigm for resolving instruction conflicts among instructions with arbitrarily many privilege levels. We introduce ManyIH-Bench, the first benchmark for ManyIH. ManyIH-Bench requires models to navigate up to 12 levels of conflicting instructions with varying privileges, comprising 853 agentic tasks (427 coding and 426 instruction-following). ManyIH-Bench composes constraints developed by LLMs and verified by humans to create realistic and difficult test cases spanning 46 real-world agents. Our experiments show that even the current frontier models perform poorly (~40% accuracy) when instruction conflict scales. This work underscores the urgent need for methods that explicitly target fine-grained, scalable instruction conflict resolution in agentic settings.
Figures & tables
| Ordinal Scalar | Scalar Perturbation | ||||||||
| Model | Acc | Acc test | Acc style | Acc | Acc test | Acc style | Overall flip | Test flip | Style flip |
| GPT-5.4 | 8.4 | 0.7 | 8.7 | 4.7 | 1.2 | 4.7 | 16.4 | 3.0 | 16.9 |
| Opus 4.6 | 8.0 | 0.9 | 8.7 | 3.3 | 0.5 | 3.0 | 8.0 | 0.9 | 8.7 |
| Sonnet 4.6 | 2.3 | 0.0 | 3.7 | 1.4 | 0.2 | 1.2 | 12.6 | 1.6 | 13.3 |
| Qwen3.5-122B | 5.9 | 19.9 | 2.1 | 4.0 | 0.7 | 4.5 | 17.1 | 8.2 | 19.0 |
| Qwen3.5-9B | 0.9 | 3.7 | 2.3 | 1.2 | 0.5 | 0.0 | 8.7 | 12.2 | 10.8 |
| Model | Ordinal | Scalar | |
| Gemini 3.1 Pro | 42.7 | 46.8 | 4.1 |
| GPT-5.4 | 39.4 | 34.1 | 5.3 |
| Qwen3.5-397B | 34.1 | 33.3 | 0.8 |
| Opus 4.6 | 33.2 | 28.8 | 4.3 |
| Kimi K2.5 | 32.7 | 32.7 | 0.0 |
| Grok 4.20 | 31.7 | 30.4 | 1.3 |
Appendix figures & tables4 assets
Supplementary material from the paper’s appendix.
Appendix
| Model | Acc | Acc test | Acc style |
| GPT-5.4 | 60.9 | 89.7 | 67.9 |
| Gemini 3.1 Pro | 59.0 | 91.3 | 65.1 |
| Grok 4.20 | 54.1 | 86.2 | 63.0 |
| GPT-5.5 | 53.9 | 91.6 | 58.8 |
| GPT-5.6-sol | 52.5 | 91.3 | 57.9 |
| Opus 4.6 | 51.3 | 92.5 | 56.7 |
| Statistic | Coding | IF |
| General | ||
| Samples | 427 | 426 |
| Source | MBPP ( Austin et al., 2021 ) | AgentIF ( Qi et al., 2025 ) |
| Max privilege levels per sample | 12 | 7 |
| Instruction & Conflict Structure | ||
| Instructions per sample | 12 (fixed) | 19.4 (avg) |
| Statistic | 6 tiers | 8 tiers | 12 tiers |
| Samples | 427 | 427 | 427 |
| Instructions per sample | 6 | 8 | 12 |
| Privilege levels per sample | 6 | 8 | 12 |
| Style groups per sample | 4 | 4 | 4 |
| Winning styles per sample | 6 | 6 | 6 |
| Pairwise conflicts per sample | 0 | 2–4 (avg 3.5) | 7–11 (avg 9.8) |
| Category | Style ID | Instruction |
| indent | indent_2 | Indent using exactly 2 spaces |
| indent_4 | Indent using exactly 4 spaces | |
| indent_tab | Indent using tabs | |
| indent_spaces | Indent using spaces (not tabs) | |
| quotes | quotes_single | Use single quotes for strings |
| quotes_double | Use double quotes for strings |
LLM Agents
Large language model agents use language models to plan, use tools, and act across multi-step tasks and environments.
See all 705 papers