context-engineering

Dynamic context injection, mode switching (dev/review/research), selective loading, and strategic compaction for token optimization.

509 stars

Best use case

context-engineering is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Dynamic context injection, mode switching (dev/review/research), selective loading, and strategic compaction for token optimization.

Teams using context-engineering should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/context-engineering/SKILL.md --create-dirs "https://raw.githubusercontent.com/a5c-ai/babysitter/main/library/methodologies/everything-claude-code/skills/context-engineering/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/context-engineering/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How context-engineering Compares

Feature / Agentcontext-engineeringStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Dynamic context injection, mode switching (dev/review/research), selective loading, and strategic compaction for token optimization.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Context Engineering

## Overview

Context management methodology adapted from the Everything Claude Code project. Optimizes context window usage through dynamic injection, mode switching, selective loading, and strategic compaction.

## Context Modes

### Dev Mode
- Load: architecture docs, active code files, test files, recent changes
- Skip: historical discussions, completed milestones, research notes
- Priority: implementation speed

### Review Mode
- Load: code diff, coding standards, security rules, test coverage
- Skip: architecture docs, planning notes, research
- Priority: thoroughness and accuracy

### Research Mode
- Load: requirements, existing patterns, external research, alternatives
- Skip: implementation details, test files, CI configs
- Priority: breadth of information

## Dynamic Injection
- Detect project context automatically (language, framework, tools)
- Load relevant skills based on detected context
- Inject domain-specific patterns and conventions
- Adjust tool allowlists per context mode

## Selective Loading
- Load only files relevant to the current task
- Use glob patterns to scope file reading
- Prioritize recently modified files
- Skip binary files and generated code

## Strategic Compaction
- Monitor context token usage
- Suggest compression for resolved/completed items
- Archive to memory files (activeContext, patterns, progress)
- Pre-compaction state preservation
- Automated compaction triggers at token thresholds

## Cross-Platform Detection
- Package manager: npm (package-lock.json), pnpm (pnpm-lock.yaml), yarn (yarn.lock), bun (bun.lockb)
- Language: TypeScript (tsconfig.json), Go (go.mod), Python (pyproject.toml), Java (pom.xml)
- Test runner: vitest, jest, pytest, go test
- CI/CD: GitHub Actions, Dockerfile, docker-compose

## When to Use

- Session initialization (detect context)
- Before each phase (inject relevant context)
- Token budget warnings (strategic compaction)
- Mode transitions (dev to review to research)

## Agents Used

- Used by all agents indirectly through context detection
- `context-engineering` agent for explicit compaction analysis

Related Skills

Ghidra/IDA Reverse Engineering Skill

509
from a5c-ai/babysitter

Deep integration with Ghidra and IDA Pro for binary analysis and reverse engineering

music-prompt-engineering

509
from a5c-ai/babysitter

Optimize and format prompts specifically for AI music generation platforms like Suno and Udio, including platform-specific syntax and tag optimization

video-prompt-engineering

509
from a5c-ai/babysitter

Optimize prompts for AI video generation platforms including Sora, Runway, Pika, and Kling

engineering-report-generator

509
from a5c-ai/babysitter

Engineering report generation skill for standard technical reports and calculation sheets

requirements-engineering

509
from a5c-ai/babysitter

Automotive requirements management and traceability expertise

Feature Engineering Optimizer

509
from a5c-ai/babysitter

Optimizes feature engineering pipelines and feature store configurations

context-preservation

509
from a5c-ai/babysitter

State capture and restore across context window compactions. Monitors usage thresholds and serializes quality, task, and spec state for seamless continuation.

Context Management

509
from a5c-ai/babysitter

Project context loading, isolation, and persistent state management across CCPM sessions.

process-builder

509
from a5c-ai/babysitter

Scaffold new babysitter process definitions following SDK patterns, proper structure, and best practices. Guides the 3-phase workflow from research to implementation.

Workflow & Productivity

babysitter

509
from a5c-ai/babysitter

Orchestrate via @babysitter. Use this skill when asked to babysit a run, orchestrate a process or whenever it is called explicitly. (babysit, babysitter, orchestrate, orchestrate a run, workflow, etc.)

yolo

509
from a5c-ai/babysitter

Run Babysitter autonomously with minimal manual interruption.

user-install

509
from a5c-ai/babysitter

Install the user-level Babysitter Codex setup.