Agent skill · jamditis

context-engineering-fundamentals

Manages attention and evidence in long agent sessions. Use for lost instructions, dropped evidence, or large multi-agent contexts.

What it needs

About 2k tokens when loaded.

What this skill does

Context engineering fundamentals Context engineering is the practice of managing an LLM's limited attention budget. Use this skill to keep instructions, evidence, and state available during long work. Core concept Context windows are constrained by attention mechanics, not only token capacity. A large context limit does not guarantee equal use of every item. The lost-in-middle effect The "Lost in the Middle" experiments show that retrieval quality can change with information position. The result depends on the model, task, context length, and number of documents. Position Common test result ---------- -------------------- Beginning Often easier to retrieve Middle Can be harder to retrieve End Often benefits from recency Implication: Keep critical constraints easy to find and repeat them near the decision that uses them. Do not assume position alone predicts recall. Context degradation patterns 1. Lost-in-middle Information in the middle of long context gets lower attention weight. Mitigation: Structure with explicit sections. Put critical constraints at start AND end. 2. Context poisoning Errors compound when incorrect information enters context (from tool outputs, summaries, or earlier mistakes). Mitigation: Validate intermediate outputs. Don't blindly trust previous responses. 3. Context distraction Irrelevant information forces attention allocation away from relevant content. Models can't "skip" irrelevant context. Mitigation: Be selective about what goes into context. More isn't better. 4. Context confusion Multiple task types or conflicting instructions create ambiguous responses. Mitigation: One task per interaction when possible. Clear task boundaries. 5. Context clash Contradictory information from multiple sources causes derailing conflicts. Mitigation: Resolve contradictions explicitly before asking Claude to use the information. Measure before compressing Do not use a fixed token threshold to decide when context is reliable. …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills jamditis/context-engineering-fundamentals

View the source on GitHub

Browse the @skills marketplace