content-contradiction¶
Detect likely contradictions within instruction files using keyword-pair heuristics
| Severity | warning (auto) |
| Autofix | - |
| Since | v0.7.0 |
| Category | Content Intelligence |
Why¶
When two instructions in the same file contradict each other, the model must pick one and discard the other — silently. The choice is unpredictable and context-dependent, so the losing instruction is effectively deleted from the agent's behavior without anyone noticing.
Examples¶
Bad:
Good:
Write focused tests for critical paths — prioritize coverage of public
API boundaries over internal helpers.
How to fix¶
Resolve the contradiction by choosing the more specific instruction, or merge both into a single statement with appropriate context. If both are valid in different situations, add explicit conditions. A coding agent can rewrite contradictory pairs automatically.
Configuration¶
Research Basis¶
Detects likely contradictions within instruction files using keyword-pair heuristics (e.g., "move fast and iterate quickly" vs. "write comprehensive tests for every change").
Contradictory instructions force the model to resolve an impossible constraint at inference time. Research shows this produces "numerous logical errors" — the model doesn't fail gracefully, it fails silently by picking one interpretation non-deterministically.
The DIM-Bench benchmark (2025) tested all major models and found "no LLM demonstrates complete robustness against instructional distractions." Contradictions are the most damaging form of distraction because they create instructions that cannot be simultaneously satisfied.
References:
- When Prompts Go Wrong: Evaluating Code Model Robustness to Contradictory Task Descriptions (arXiv:2507.20439, Jul 2025) — Contradictions yield RIR >80% for GPT-4
- LLMs can be easily Confused by Instructional Distractions (arXiv:2502.04362, Feb 2025) — DIM-Bench: no model is robust to conflicting instructions
- Wallace et al., The Instruction Hierarchy (arXiv:2404.13208, OpenAI, Apr 2024) — Models struggle with conflicting instructions across privilege levels
Run skillsaw explain content-contradiction to see this documentation and the rule's effective configuration in your terminal.