Context Engineering in Action - A complete multi-agent AI development system for GitHub Copilot and Claude Code
This repository provides a production-ready template for implementing Context Engineering with AI coding assistants. Instead of repeating the same instructions to AI every time, you build a persistent "knowledge system" that makes AI understand your project, follow your conventions, and work like a real development team.
User: "Write an Angular component"
AI: *writes basic component*
User: "Don't forget standalone"
AI: *modifies*
User: "And signals"
AI: *modifies*
User: "And the new control flow"
... 😫 (repeat forever)
Pre-defined agent personas with persistent context that remember your conventions:
# Frontend Developer Agent
## CORE PRINCIPLES
- Standalone components only - no NgModules
- Control flow: Use @if, @for, @switch
- Signals: Prefer input(), output(), viewChild()
- Change detection: OnPush requiredNow the AI gets it right from the first try! ✨
This template implements a multi-agent orchestration system where specialized AI agents collaborate like a real development team:
┌─────────────────────────────────────────────────────────────┐
│ /orchestrate "task" │
└─────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 🪃 Orchestrator: Analyze task type, create TASK_ID │
└─────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 📋 Project Manager: Create requirements & acceptance │
│ criteria in BDD format │
└─────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ ✋ USER VALIDATION: "APPROVED" or Feedback │
└─────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 🏗️ Software Architect: Evidence-based architecture design │
│ (No hallucinated APIs - everything verified!) │
└─────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ ✋ USER VALIDATION: "APPROVED" or Feedback │
└─────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 👥 Team Leader: Decompose into atomic tasks │
│ MODE 1: Create tasks.md │
│ MODE 2: Assign → Verify → Commit (loop) │
│ MODE 3: Final verification │
└─────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 💻 Developer(s): Implement assigned tasks with git commits │
└─────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 🧪 QA Phase: Testing + Code Review (user choice) │
└─────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 🎉 COMPLETE: All deliverables in task-tracking/TASK_ID/ │
└─────────────────────────────────────────────────────────────┘
.
├── .claude/ # Claude Code configuration
│ ├── agents/ # Agent persona definitions
│ │ ├── software-architect.md
│ │ ├── team-leader.md
│ │ ├── frontend-developer.md
│ │ ├── backend-developer.md
│ │ ├── project-manager.md
│ │ ├── senior-tester.md
│ │ ├── code-logic-reviewer.md
│ │ ├── code-style-reviewer.md
│ │ ├── researcher-expert.md
│ │ ├── ui-ux-designer.md
│ │ └── modernization-detector.md
│ └── commands/ # Custom slash commands
│ ├── orchestrate.md # Main workflow command
│ ├── orchestrate-help.md
│ ├── review-code.md
│ ├── review-logic.md
│ └── review-security.md
│
├── .github/ # GitHub Copilot configuration
│ ├── chatmodes/ # VS Code Copilot Chat personas
│ │ ├── workflow-orchestrator.chatmode.md
│ │ ├── software-architect.chatmode.md
│ │ ├── team-leader.chatmode.md
│ │ ├── frontend-developer.chatmode.md
│ │ ├── backend-developer.chatmode.md
│ │ ├── business-analyst.chatmode.md
│ │ ├── product-manager.chatmode.md
│ │ ├── senior-tester.chatmode.md
│ │ ├── code-reviewer.chatmode.md
│ │ ├── researcher-expert.chatmode.md
│ │ ├── ui-ux-designer.chatmode.md
│ │ └── modernization-detector.chatmode.md
│ ├── prompts/ # Phase-specific workflow prompts
│ │ ├── orchestrate.prompt.md
│ │ ├── phase1-project-manager.prompt.md
│ │ ├── phase2-researcher-expert.prompt.md
│ │ ├── phase3-ui-ux-designer.prompt.md
│ │ ├── phase4-software-architect.prompt.md
│ │ ├── phase5a-team-leader-mode1.prompt.md
│ │ ├── phase5b-team-leader-mode2.prompt.md
│ │ ├── phase5c-team-leader-mode3.prompt.md
│ │ ├── phase6-be-developer.prompt.md
│ │ ├── phase6-fe-developer.prompt.md
│ │ ├── phase7-code-reviewer.prompt.md
│ │ ├── phase8-modernization-detector.prompt.md
│ │ └── validation-gate.prompt.md
│ └── copilot-instructions.md # Global Copilot instructions
│
├── task-tracking/ # Generated task artifacts (created during use)
│ └── TASK_2025_XXX/ # Each task gets a folder
│ ├── context.md
│ ├── task-description.md
│ ├── implementation-plan.md
│ ├── tasks.md
│ └── ...
│
└── README.md # You are here!
-
Copy the
.claudefolder to your project root:cp -r .claude /path/to/your/project/
-
Create a
task-trackingfolder in your project root:mkdir task-tracking
-
Start a workflow:
/orchestrate "Add user authentication feature"
-
Copy the
.githubfolder to your project root:cp -r .github /path/to/your/project/
-
Create a
task-trackingfolder in your project root:mkdir task-tracking
-
Open VS Code and use Copilot Chat with the workflow orchestrator chatmode
-
Start a workflow:
/orchestrate "Add user authentication feature"
The .claude and .github folders are designed to work together. Copy both to get the full experience with either tool!
Each agent has a distinct personality and responsibility:
Role: Coordinates the entire workflow
- Analyzes task type (FEATURE, BUGFIX, REFACTORING, etc.)
- Creates task tracking structure
- Manages agent handoffs
Role: Requirements specialist
- Creates SMART requirements
- Writes BDD acceptance criteria
- Validates scope
Role: Evidence-based designer
- Key Principle: "Investigation, not assumption"
- Verifies every API exists in the codebase
- Creates implementation plans with file:line citations
- Anti-Hallucination Protocol: Never proposes unverified patterns
Role: Task orchestration & verification
- MODE 1: Decomposes plans into atomic tasks
- MODE 2: Assigns tasks, verifies completion
- MODE 3: Final verification
- Golden Rule: "Don't trust - VERIFY"
Role: Implementation specialists
- Follow established patterns from codebase
- Create git commits for each task
- Focus on real implementation (no stubs!)
Role: Quality assurance
- Creates test plans
- Verifies acceptance criteria
- Documents test results
Role: Code quality guardians
- Style reviewer (patterns, conventions)
- Logic reviewer (business logic, edge cases)
| Prompt Engineering | Context Engineering |
|---|---|
| One simple prompt | Complete information system |
| For single LLM call | For multi-agent systems |
| No memory | Full memory management |
| No tools | Clear tool definitions |
| No validation | Defined quality gates |
Every decision must be backed by evidence:
❌ AI might generate:
@Property({ primary: true }) // This doesn't exist!
✅ Our system requires:
// Investigation: Read entity.decorator.ts:145
@Neo4jEntity('User') // ✓ Verified at line 145❌ WRONG:
Task: "Implement entire landing page"
Result: AI claims it's done but 3/7 sections missing
✅ CORRECT:
Task 1: "Create HeroSection component"
Task 2: "Create AboutSection component"
...
→ Each task verified separately with git commits!The system pauses at key points for user approval:
- After Requirements (Project Manager output)
- After Architecture (Software Architect output)
- QA Choice (Which quality checks to run)
| Metric | Without Context Engineering | With This System |
|---|---|---|
| Hallucinated APIs | Many 😭 | Zero ✅ |
| Incomplete Tasks | 40%+ | <5% |
| Context Loss | Every conversation | Never |
| User Control | Minimal | Full |
| Traceability | None | Complete |
This template is featured in our comprehensive video tutorial: "How to Build a Complete AI Development System: The Art of Context Engineering"
📺 Watch the video (Coming soon)
The video covers:
- What is Context Engineering and why it matters
- Setting up the multi-agent workflow
- How each agent works
- Real-world demonstration
- Best practices and anti-patterns
We welcome contributions! See CONTRIBUTING.md for guidelines.
- New agent personas for different domains
- Improved prompts for specific frameworks
- Translations to other languages
- Integration guides for other AI tools
- Bug fixes and improvements
- Context Engineering Guide
- Context Engineering for AI Agents
- LangChain: The Rise of Context Engineering
"Prompt engineering is dead. Long live context engineering." — Andrej Karpathy
"Context engineering is the next phase, where you architect the full context, which in many cases requires going beyond simple prompting into more rigorous methods." — Prompt Engineering Guide
MIT License - see LICENSE for details.
If this template helps you build better AI workflows, please give it a star! ⭐
Built with ❤️ by Hive Academy