agentsclimarketplace

Context engineering

Skill Amey-Thakur/AI-SKILLS/skills/llm-engineering/context-engineering

Assemble what goes into an LLM's context on each call: selecting, ordering, and formatting the right information. Use when deciding what to put in a prompt or debugging why a model ignores or misuses provided information.From its SKILL.md

Install
npx -y skills add Amey-Thakur/AI-SKILLS --skill context-engineering

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • 29 days oldThe repository was created 29 days ago. New is not bad, but a brand new repository carrying a familiar-sounding name is the shape a typosquat arrives in, and there has been no time for anyone else to find a problem with it.
  • 4 stars4 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

3.0 KB, 608 tokens by cl100k_base, as published. Nobody here has run it

Context engineering

The model can only use what is in its context, and it uses that content better or worse depending on what else is there and where. Context engineering is the discipline of assembling each call's context so the right information is present, findable, and not buried.

Method

  1. Select for relevance, ruthlessly. More context is not better: irrelevant content dilutes attention and invites the model to latch onto the wrong thing. Include what the current decision needs, and cut the rest. Retrieval, tool results, and history each earn their place or get trimmed (see context-window-management for the budget).
  2. Order by importance and position effects. Models attend most to the start and end of context. Put the instructions and role up front, the immediate task and freshest data near the end, and reference material in the middle. Verify with your own layout when correctness depends on mid-context content; long-context recall degrades under load (see llm-eval-design).
  3. Structure and delimit clearly. Separate instructions from data from examples with clear markers; label retrieved sources; use consistent formatting the model can parse. Ambiguity about which text is instruction versus data is also the injection surface (see llm-guardrails: treat retrieved and tool content as untrusted).
  4. Compress information-dense inputs. A 50KB tool result is usually 500 tokens of decision-relevant content in a payload; summarize or extract before it enters context. Tables, logs, and documents get distilled to what the task needs, not pasted raw.
  5. Keep stable content stable for caching. Put the fixed parts (system prompt, tool definitions, few-shot examples) first and unchanging so prompt caching can reuse them (see prompt-caching); vary only the tail. This shapes both cost and latency.
  6. Ground the model in its sources. For factual work, put the retrieved evidence in context and instruct the model to answer from it and cite it, so it grounds rather than confabulates (see rag-pipeline, embeddings-selection). Provided-but-ignored context usually means it was buried, unlabeled, or contradicted by something else present.

Boundaries

  • Context engineering assembles what the model sees; it does not fix a model that lacks the capability, or a retrieval layer returning the wrong documents (see rag-pipeline for that half).
  • Bigger context windows do not remove this work: cost rises with tokens, and attention quality drops before the hard limit, so selection still pays at every window size.
  • Within-call context assembly is distinct from cross-session memory (what to persist and recall between conversations: see agent-memory).

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 326,144. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.