context-engineering

context-engineering is a skill for Claude Code, Codex from vignesh2027/AI-AGENT-SKILLS. It costs 19 tokens per session (506 once invoked), scanned A, original, MIT.

A method for deciding which information an AI coding agent should receive and how much of it should fit in its limited context window.

In plain words
What is it for?
Selecting relevant files, documents, conversation history, schemas, and instructions when designing agent prompts or working through long tasks.
Why use it?
It reduces irrelevant context that can obscure important code and instructions, while avoiding missing information needed for sound decisions.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Selecting relevant files, documents, conversation history, schemas, and instructions when designing agent prompts or working through long tasks.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/vignesh2027/ai-agent-skills/context-engineering
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add vignesh2027/AI-AGENT-SKILLS --skill context-engineering
Clone the repo
git clone --depth 1 https://github.com/vignesh2027/AI-AGENT-SKILLS

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for context-engineering

README.md
[![agentmods](https://agentmods.dev/badge/skills/vignesh2027/ai-agent-skills/context-engineering/github.svg)](https://agentmods.dev/skills/vignesh2027/ai-agent-skills/context-engineering)
Your own site
<a href="https://agentmods.dev/skills/vignesh2027/ai-agent-skills/context-engineering"><img src="https://agentmods.dev/badge/skills/vignesh2027/ai-agent-skills/context-engineering/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for context-engineering

Your own site · 80×15
<a href="https://agentmods.dev/skills/vignesh2027/ai-agent-skills/context-engineering"><img src="https://agentmods.dev/badge/skills/vignesh2027/ai-agent-skills/context-engineering.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 19 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 506 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00019 $0.00506
Opus 5.5 $0.00008 $0.00202
Sonnet 5.5 $0.00004 $0.00101
Haiku 4.5 $0.00002 $0.00051

Measured 2mo ago against content hash a1c887834e70, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

context-engineering scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/context-engineering/SKILL.md · 59 lines

How it starts

The opening of the file, as written. The whole thing — 59 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Overview

Context is finite. What you put in the context window determines what the agent can reason about. Too much noise → the relevant signal is diluted. Too little context → the agent makes uninformed decisions. This skill manages context deliberately.

When to Use

  • When an agent produces low-quality outputs despite correct instructions
  • When designing a system prompt for a production agent
  • When a long conversation is causing quality degradation
  • When context costs are higher than expected

Process

Step 1: Define the context budget

For your model and use case: how many tokens is your budget? Reserve: 20% for the system prompt, 20% for the output, 60% for the dynamic context (documents, history, tools).

Step 2: Prioritize context by relevance

Include in this order:

  1. Task instructions (always)
  2. The most relevant documents or code (retrieved, not full codebase)
  3. Relevant conversation history (not all history)
  4. Supporting context (schemas, type definitions)

Cut: long documents that contain 1 relevant paragraph, full file contents when only a function is needed, conversation history beyond the last N relevant turns.

Step 3: Structure context for retrieval

Agents pay more attention to the beginning and end of context. Put instructions at the top. Put the most relevant context closest to the task.

Step 4: Use explicit context delimiters

Mark different sections clearly:

<system>Your role and constraints</system>
<documents>Retrieved content</documents>
<task>What to do</task>

This prevents the model from confusing instructions with retrieved data.

Step 5: Compress context aggressively

Summarize long histories. Extract the relevant portions of long documents. Use structured data (JSON, tables) instead of prose where possible.

Step 6: Monitor context quality

Track: output quality vs. context length. If longer context is producing worse results, you have a context quality problem, not a context quantity problem.

Read the full file on GitHub · 59 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 59 lines · 19 tokens per session scan A a1c887834e70

Subscribe to this mod's changes

context-engineering is a skill published in the GitHub repository vignesh2027/AI-AGENT-SKILLS (2 stars, last pushed 2mo ago), licensed MIT. It adds 19 tokens to every session and 506 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

context-engineering compared with skills from other repositories

context-engineering next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
context-engineeringvignesh2027/AI-AGENT-SKILLSSkill22mo agoMITA19Claude Code, Codex
handoffHmbown/CodeWhaleSkill41k6d agoMITA70Claude Code, Codex
auto-memoryQwenLM/qwen-codeSkill29ktodayApache-2.0A29Claude Code, Codex
agent-state-barbojieli/ai-agent-bookSkill57k1mo agoApache-2.0A105Claude Code, Codex
knowledge-orgbojieli/ai-agent-bookSkill57k1mo agoApache-2.0A96Claude Code, Codex
memory-systembojieli/ai-agent-bookSkill57k1mo agoApache-2.0A95Claude Code, Codex
context-compressionbojieli/ai-agent-bookSkill57k1mo agoApache-2.0A92Claude Code, Codex