What problem does it solve? Long-running LLM agents silently degrade as context grows: critical instructions get lost in the middle of the window, hallucinated facts poison downstream reasoning, irrelevant documents dilute attention, and contradictory sources cause unpredictable outputs. This Skill provides detection signals, thresholds, and mitigation strategies for these five failure patterns. ## Core Features & Use Cases - Pattern Diagnosis: Identify lost-in-middle, poisoning, distraction, confusion, and clash failures using concrete detection signals and empirical benchmarks. - Health Analysis Scripts: Run the included Python detector to measure attention distribution, flag at-risk critical content, detect poisoning indicators, and compute a composite context health score. - Mitigation Framework: Apply the Write/Select/Compress/Isolate strategies with placement rules, compaction triggers, and recovery procedures for poisoned context. - Use Case: An agent that worked well for 10 turns starts ignoring instructions at turn 30. Use this Skill to check context utilization, detect whether key constraints sit in the degraded middle region, and trigger compaction before the performance cliff. ## Quick Start Ask the agent to analyze the current conversation context for degradation symptoms and recommend mitigation steps using the context-degradation skill.