addyosmani avatar

Context Engineering

Most agent problems trace back to context. This skill gives you a framework for feeding Claude the right information at the right time: rules files for project conventions, selective spec loading instead of dumping everything, relevant source files before editing, and clean error messages when things break. The hierarchy diagram alone (rules → specs → source → errors → history) is worth internalizing. Best part is the confusion management section, which teaches the agent to surface conflicts instead of guessing. Use this when starting a project, when output quality drops, or when the agent starts hallucinating APIs that don't exist.

skills.sh installs
71.1K
GitHub stars
114.6K
last updated
Aug 21, 2026

Install

$ npx -y skills add addyosmani/agent-skills --skill context-engineering --agent claude-code

Installs into .claude/skills of the current project.

Files

Context Engineering

Overview

Feed agents the right information at the right time. Context is the single biggest lever for agent output quality — too little and the agent hallucinates, too much and it loses focus. Context engineering is the practice of deliberately curating what the agent sees, when it sees it, and how it's structured.

When to Use

  • Starting a new coding session
  • Agent output quality is declining (wrong patterns, hallucinated APIs, ignoring conventions)
  • Switching between different parts of a codebase
  • Setting up a new project for AI-assisted development
  • The agent is not following project conventions

The Context Hierarchy

Structure context from most persistent to most transient:

Sponsors

Details

Repository
github.com/addyosmani/agent-skills
Categories
Code Review & Quality, AI & Agent Building
First seen
Apr 16, 2026

More from addyosmani/agent-skills

All 25
1addyosmani avatardoubt-driven-developmentaddyosmani/agent-skillsSubjects every non-trivial decision to a fresh-context adversarial review before it stands. Use when correctness matters more than speed, when working in unfami65.8Kskills.sh installs
2insforge avatarinsforge-debuginsforge/insforge-skillsUse when diagnosing problems in an InsForge project — reactive failures (SDK error object, HTTP 4xx/5xx, gateway timeout 502/503/504, edge function failure or t61.2Kskills.sh installs
3heygen-com avatarseam-craftheygen-com/hyperframesRender-correctness doctrine for scene-to-scene seams in HyperFrames launch videos — the prerequisites that make transitions composite correctly on the master ti61.1Kskills.sh installs
4heygen-com avataroversized-cursorheygen-com/hyperframesHouse-style oversized macOS cursor technique for HyperFrames launch videos. Load whenever a scene involves cursors or a pointer-led action, when kicking off a U60.7Kskills.sh installs
5useosint avataris-this-photo-realuseosint/skillsVerify whether an image or video is authentic, original and correctly captioned — provenance checks, error level analysis, noise and JPEG compression analysis, 58.3Kskills.sh installs
6useosint avatarfind-the-original-imageuseosint/skillsReverse image search across Yandex, Google Lens, Bing Visual Search, TinEye and Baidu to find where a picture came from and who published it first. Use when rev56.6Kskills.sh installs