context-engineering

Configures rules files and curates context layers for AI coding agents.

Updated Jul 1, 2026
One-click install
npx skills add https://github.com/raishoemi/traffic-sim-v2 --skill context-engineering-raishoemi
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: context-engineering
Source: https://github.com/raishoemi/traffic-sim-v2/tree/main/.github/skills/context-engineering
Command: npx skills add https://github.com/raishoemi/traffic-sim-v2 --skill context-engineering-raishoemi

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? AI coding agents produce inconsistent output when they lack the right context: they hallucinate APIs, ignore project conventions, and degrade in quality over long sessions. This Skill provides a structured methodology for curating what the agent sees, when it sees it, and how it is structured. ## Core Features & Use Cases - Five-Level Context Hierarchy: Organizes context from persistent rules files (CLAUDE.md, .cursorrules, AGENTS.md) down to transient conversation history, with templates for each level. - Context Packing Strategies: Provides the Brain Dump, Selective Include, and Hierarchical Summary patterns for loading task-relevant context without flooding the agent. - Confusion Management: Defines explicit patterns for surfacing spec conflicts, missing requirements, and inline planning instead of silently guessing. - Use Case: When starting a new feature in a React + TypeScript project, use this Skill to write a CLAUDE.md rules file covering tech stack, commands, and conventions, then load only the relevant spec section and source files for the task. ## Quick Start Set up a CLAUDE.md rules file for my project covering the tech stack, build commands, code conventions, and boundaries before we start the next feature.

Frequently Asked Questions about context-engineering

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set up a CLAUDE.md rules file for my project?

Create a CLAUDE.md at the project root covering tech stack, build and test commands, code conventions, and boundaries such as never committing secrets. Include one short example of a well-written component so the agent follows your style.

How much context should I give an AI coding agent per task?

Aim for under 2,000 lines of focused context per task. Loading more than 5,000 lines of non-task-specific content causes the agent to lose focus, so include only relevant source files, the applicable spec section, and one pattern example.

What is the difference between CLAUDE.md, .cursorrules, and AGENTS.md?

They are equivalent persistent rules files for different tools: CLAUDE.md for Claude Code, .cursorrules or .cursor/rules for Cursor, .windsurfrules for Windsurf, AGENTS.md for OpenAI Codex, and .github/copilot-instructions.md for GitHub Copilot.

Why does agent output quality degrade in long conversations?

Long conversations accumulate stale context, causing the agent to reference outdated patterns or deleted code. Start fresh sessions when switching major features, summarize progress periodically, and compact context before critical work.

What should an agent do when the spec conflicts with existing code?

The agent should surface the conflict explicitly with options rather than silently picking one interpretation. It should present the conflicting sources, list possible approaches, and ask which direction to take before proceeding.