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, and contradictory retrieved documents produce unpredictable outputs. This Skill provides detection patterns, mitigation frameworks, and Python tooling to identify and fix these failures before they cascade. ## Core Features & Use Cases - Five Degradation Patterns: Recognize and mitigate lost-in-middle, context poisoning, distraction, confusion, and clash with specific detection signals and recovery procedures for each. - Health Analysis Toolkit: Run composite context health checks combining attention distribution, poisoning detection, and utilization metrics via the included Python scripts. - Four-Bucket Mitigation Framework: Apply Write, Select, Compress, and Isolate strategies matched to the active degradation pattern. - Use Case: An agent's output quality drops after 40K tokens of conversation. Use this Skill to measure attention distribution, detect that key instructions sit in the degraded middle region, and restructure context placement before compaction triggers. ## Quick Start Ask the agent to analyze the current conversation context for degradation symptoms and recommend mitigation strategies using the context-degradation skill.