Package Exports
- @champpaba/claude-agent-kit
- @champpaba/claude-agent-kit/bin/cli.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@champpaba/claude-agent-kit) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Claude Agent Kit
๐ค Multi-Agent Implementation Engine - The perfect companion for OpenSpec spec-driven development
๐ฏ What is this?
Claude Agent Kit picks up where OpenSpec planning ends.
While OpenSpec handles alignment (Draft Proposal โ Review & Align), Claude Agent Kit handles implementation (Implement Tasks โ Archive & Update) with specialized AI agents.
The Complete Workflow
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ OpenSpec Planning โ
โ (Spec-Driven Development for AI Coding Assistants) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ
Generates: proposal.md + tasks.md
โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Claude Agent Kit Implementation โ
โ (Multi-Agent Execution with 6 Specialists) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ
Completes: All tasks with quality gates๐ How They Work Together
| Stage | Tool | What Happens | Output |
|---|---|---|---|
| 1. Draft Proposal | OpenSpec | Human requests change, AI scaffolds structure | proposal.md + tasks.md |
| 2. Review & Align | OpenSpec | Team iterates until consensus | Approved specs |
| 2.5. Page Planning | Claude Agent Kit | (UI tasks only) Generate content & component plan | page-plan.md |
| 3. Setup Context | Claude Agent Kit | Classify tasks, generate workflow | workflow.md |
| 4. Implement Tasks | Claude Agent Kit | 6 specialized agents execute work | Working code + tests |
| 5. Archive & Update | OpenSpec | Merge changes back to specs | Updated specs/ |
What OpenSpec Generates
proposal.md - Business case and scope
# Change Proposal: User Authentication System
## Motivation
Users need secure login functionality...
## Scope
- Email/password authentication
- JWT token generation
- Protected routes middlewaretasks.md - Implementation checklist
## Database Setup
- [ ] Create User model with email, password fields
- [ ] Add unique constraint on email
## Backend Implementation
- [ ] POST /api/auth/login endpoint
- [ ] Password hashing with bcrypt
- [ ] JWT token generation
## Frontend Implementation
- [ ] Login form component
- [ ] Form validation
- [ ] Token storageWhat Claude Agent Kit Does
Input: Reads proposal.md + tasks.md from OpenSpec
Process:
/pageplan(UI tasks only) - Generate content & component reuse plan/csetup {change-id}- Analyze tasks, classify by agent, generate workflow/cdev {change-id}- Execute with 6 specialized agents in phases:- Phase 1: UI with mock data (uxui-frontend)
- Phase 2: Real API + database (backend + database, parallel)
- Phase 2.5: Validate contracts (integration)
- Phase 3: Connect UI to API (frontend)
- Phase 4: Tests + bug fixes (test-debug)
Output: Working implementation ready for review
๐จ NEW: Page Planning for UI Tasks
Problem: Before /pageplan, agents would:
- โ Create duplicate components (3 different Navbar components!)
- โ Use inconsistent colors (
#0d7276on landing,#4f46e5on dashboard) - โ Generate lorem ipsum instead of real content
- โ Waste time searching for components during implementation
Solution: /pageplan command analyzes BEFORE implementing
How It Works
# Step 1: OpenSpec generates tasks
User: "Build landing page for TOEIC app"
โ Creates: openspec/changes/landing-page/proposal.md + tasks.md
# Step 2: Generate page plan (NEW!)
User: /pageplan @prd.md @project_brief.md
# What it does:
# 1. Reads user-specified files (PRD, brief)
# 2. Reads proposal.md (technical architecture)
# 3. Reads STYLE_GUIDE.md (visual design)
# 4. Searches existing components (Navbar, Footer, etc.)
# 5. AI drafts real content from PRD
# 6. Generates: openspec/changes/landing-page/page-plan.mdpage-plan.md Output
# Page Plan: Landing Page
## 1. Component Plan
๐ Reuse: Navbar, Footer (found in codebase)
โ
New Shared: (none)
โ
New Specific: HeroSection, FeatureGrid, TestimonialCarousel
## 2. Page Structure
<Layout>
<Navbar /> {/* Reuse */}
<HeroSection /> {/* New - see content below */}
<FeatureGrid />
<TestimonialCarousel />
<Footer /> {/* Reuse */}
</Layout>
## 3. Assets to Prepare
- [ ] hero-image.jpg (1920x1080)
- [ ] logo.svg (200x60)
- [ ] feature-icons (3x 24x24 SVG)
## 4. Content Draft (AI-Generated - Please Review & Edit)
**Headline:** "Master TOEIC with AI-Powered Tests"
**Subheadline:** "Experience exam-quality questions with instant AI scoring"
**CTA:** "Start Free Test"
**Features:**
- Real TOEIC-style questions
- Instant AI scoring
- Progress tracking dashboardStep 3: User Prepares
- โ Review content draft (edit as needed)
- โ Prepare assets (images, icons)
- โ
Approve
page-plan.md
Step 4: Implementation
/csetup landing-page
/cdev landing-page
# uxui-frontend agent automatically:
# - STEP 0.5: Reads page-plan.md โ
# - STEP 3: SKIP component search (already done!) โก 25% faster
# - Uses: Real content from page-plan
# - Reuses: Navbar, Footer (no duplicates)
# - Creates: HeroSection, FeatureGrid, TestimonialCarousel
# - Applies: Colors/spacing from STYLE_GUIDE.mdBenefits
| Before (No page-plan) | After (With page-plan) |
|---|---|
| โ Agent searches during implementation | โ Search done once upfront (25% faster) |
| โ Duplicate components created | โ Clear reuse plan |
| โ Lorem ipsum content | โ Real content from PRD |
| โ Missing assets mid-work | โ Asset checklist prepared |
| โ Inconsistent design | โ Synced with STYLE_GUIDE |
| โ Agent guesses structure | โ Clear component hierarchy |
When to Use /pageplan
โ
Use for:
- Landing pages
- Dashboards
- Multi-section UI pages
- Any task with multiple components
โ Skip for:
- Backend API endpoints
- Database schemas
- Single-component tasks
- Non-UI work๐ค The 6 Specialized Agents
| Agent | Color | Responsibility | Phase |
|---|---|---|---|
| uxui-frontend | ๐ต Blue | Design UI components with mock data | 1 |
| backend | ๐ฃ Purple | Create API endpoints with validation | 2 |
| database | ๐ฉท Pink | Design schemas, migrations, queries | 2 |
| integration | ๐ Orange | Validate API contracts before connecting | 2.5 |
| frontend | ๐ข Green | Connect UI to backend APIs | 3 |
| test-debug | ๐ด Red | Run tests and fix bugs (max 3-4 iterations) | 1,3,4 |
Each agent:
- โ Auto-discovers your project context (tech stack, best practices)
- โ Follows framework-specific patterns from Context7 MCP
- โ Maintains design consistency across the codebase
- โ Reports progress with detailed logging
- โ Smart auto-proceed: Eliminates double confirmations when user approves workflow
๐ฆ Installation
npm install -g @champpaba/claude-agent-kitAlternative Package Managers
# Using pnpm
pnpm add -g @champpaba/claude-agent-kit
# Using yarn
yarn global add @champpaba/claude-agent-kit๐ Quick Start (with OpenSpec)
Step 1: OpenSpec Planning
# In your OpenSpec-enabled project
cd my-app
# Draft a change proposal (OpenSpec handles this)
"I want to build a landing page for my TOEIC app"
# โ Generates: openspec/changes/landing-page/proposal.md + tasks.mdStep 2: Initialize Claude Agent Kit
# Initialize the agent system
cak init
# Setup project context (detects tech stack)
# In Claude Code:
/psetupStep 3: Generate Page Plan (UI tasks only)
# In Claude Code:
/pageplan @prd.md @project_brief.md
# โ Generates: openspec/changes/landing-page/page-plan.md
# โ Review content, prepare assetsStep 4: Setup Change Context
/csetup landing-pageWhat happens:
- Reads
openspec/changes/landing-page/proposal.md(business context) - Reads
openspec/changes/landing-page/tasks.md(implementation checklist) - Reads
openspec/changes/landing-page/page-plan.md(if exists - content plan) - Classifies tasks by agent (database, backend, frontend, etc.)
- Generates
workflow.md(execution plan)
Step 5: Execute Implementation
/cdev landing-pageWhat happens:
- Phase 1: uxui-frontend reads
page-plan.mdโ creates UI with real content - Phase 2: backend + database create APIs + models (parallel, if needed)
- Phase 2.5: integration validates API contracts
- Phase 3: frontend connects UI to APIs (if needed)
- Phase 4: test-debug runs tests, fixes bugs
Step 6: Monitor Progress
# View detailed progress
/cview landing-page
# Quick status check
/cstatus landing-page
# โ Phase 1/4 - UI Implementation (100%)๐ฏ Complete Workflow Examples
Workflow A: UI Feature (with /pageplan)
# 1. OpenSpec Planning
User: "Build landing page for TOEIC app"
โ Creates: proposal.md + tasks.md
# 2. Page Planning (NEW!)
/pageplan @prd.md @project_brief.md
โ Creates: page-plan.md
โ User reviews content & prepares assets
# 3. Setup Context
/csetup landing-page
โ Reads: proposal.md, tasks.md, page-plan.md
โ Generates: workflow.md
# 4. Implementation
/cdev landing-page
โ uxui-frontend reads page-plan.md (STEP 0.5)
โ Skips redundant component search
โ Uses real content + reuse plan
โ 25% faster implementation
# 5. Monitor
/cview landing-pageWorkflow B: Backend Feature (skip /pageplan)
# 1. OpenSpec Planning
User: "Add payment processing API"
โ Creates: proposal.md + tasks.md
# 2. Setup Context (skip /pageplan - not UI work)
/csetup payment-api
# 3. Implementation
/cdev payment-api
โ Phase 2: backend + database agents (parallel)
โ Phase 2.5: integration validates contracts
โ Phase 3: frontend connects (if UI exists)
โ Phase 4: test-debug validates
# 4. Monitor
/cview payment-apiWorkflow C: Full-Stack Feature (with /pageplan)
# 1. OpenSpec Planning
User: "Build user authentication system"
โ Creates: proposal.md + tasks.md
# 2. Page Planning (for login UI only)
/pageplan @prd.md
โ Creates: page-plan.md (login form content + components)
# 3. Setup Context
/csetup auth-system
# 4. Implementation
/cdev auth-system
โ Phase 1: uxui-frontend (login form, reads page-plan.md)
โ Phase 2: backend (POST /api/auth/login) + database (User model)
โ Phase 2.5: integration (validate contract)
โ Phase 3: frontend (connect form to API)
โ Phase 4: test-debug (E2E tests)
# 5. Monitor
/cview auth-system๐ Project Structure After Init
your-project/
โโโ openspec/
โ โโโ specs/ # Source of truth (OpenSpec)
โ โโโ changes/
โ โโโ landing-page/
โ โโโ proposal.md โ OpenSpec generates
โ โโโ tasks.md โ OpenSpec generates
โ โโโ page-plan.md โ /pageplan generates (UI tasks)
โ โโโ workflow.md โ /csetup generates
โ โโโ flags.json โ /cdev tracks progress
โ
โโโ design-system/
โ โโโ STYLE_GUIDE.md โ /designsetup generates
โ
โโโ .claude/
โโโ CLAUDE.md # Navigation guide
โ
โโโ agents/ # 6 specialized agents
โ โโโ 01-integration.md
โ โโโ 02-uxui-frontend.md
โ โโโ 03-test-debug.md
โ โโโ 04-frontend.md
โ โโโ 05-backend.md
โ โโโ 06-database.md
โ
โโโ commands/ # Slash commands
โ โโโ designsetup.md # Generate style guide
โ โโโ pageplan.md # Generate page plan (NEW!)
โ โโโ psetup.md # Project setup
โ โโโ csetup.md # Change setup
โ โโโ cdev.md # Change development
โ โโโ cview.md # View progress
โ โโโ cstatus.md # Quick status
โ
โโโ contexts/
โ โโโ design/ # Design foundation
โ โโโ patterns/ # Universal patterns
โ โโโ domain/ # Project context
โ
โโโ lib/ # Implementation logic
โโโ agent-executor.md
โโโ tdd-classifier.md
โโโ flags-updater.md
โโโ agent-router.md๐ฏ Why Use Claude Agent Kit?
Without Claude Agent Kit (Manual Implementation)
โ You manually interpret tasks.md
โ You context-switch between frontend/backend/database
โ You might forget edge cases or tests
โ Inconsistent code patterns across features
โ No systematic error handling
โ Duplicate components everywhere
โ Lorem ipsum content in UIWith Claude Agent Kit
โ
Agents auto-classify and execute tasks
โ
Each agent focuses on its specialty
โ
Built-in validation gates (integration agent)
โ
Consistent patterns via auto-discovery
โ
Automatic retry with escalation
โ
Component reuse plan (/pageplan)
โ
Real content from PRD
โ
25% faster UI implementation๐ Key Features
โ Seamless OpenSpec Integration
- Reads
proposal.mdfor business context - Parses
tasks.mdfor implementation checklist - Generates
page-plan.mdfor UI tasks (NEW!) - Tracks progress in
flags.json - Updates completion status back to OpenSpec
โ Auto-Generated Best Practices
Uses Context7 MCP to fetch latest framework docs:
/psetup
# โ Detects: Next.js 15, React 18, Prisma 6
# โ Generates: .claude/contexts/domain/{project}/best-practices/
# - nextjs-15.md
# - react-18.md
# - prisma-6.mdโ 3-Level Project Indexing
Agents auto-discover context:
1. Read: domain/index.md โ Get current project
2. Read: domain/{project}/README.md โ Get tech stack
3. Read: domain/{project}/best-practices/index.md โ Load patternsโ Design Foundation
Universal design principles:
- Color theory (WCAG AAA contrast)
- Typography scales
- 8px spacing grid (8, 16, 24, 32, 40, 48px)
- 4-level shadow system
- Box thinking framework
- Accessibility (WCAG 2.1 AA)
โ Quality Gates
- TDD for critical paths (auth, payments, data transforms)
- Test-alongside for simple code (CRUD, UI components)
- Max 3-4 retry iterations before escalation
- Integration validation before connecting UI to API
- Smart auto-proceed (eliminate redundant confirmations, 25% faster)
๐ง CLI Commands
cak init
Initialize agent system in current project
cak init
cak init --force # Overwrite existing .claude/Creates:
.claude/folder with 6 agents- Slash commands (
/psetup,/csetup,/cdev, etc.) - Universal patterns & design foundation
cak update
Update to latest agent templates
cak update
cak update --backup # Create .claude.backup/ firstWhat it does:
- Updates all template files to latest version
- Preserves your customizations in
domain/ - Creates backup before updating (with
--backupflag)
cak --version
Show version number
cak --version
# โ 1.0.0cak --help
Display help information
cak --help๐ Workflow Commands (in Claude Code)
/designsetup - Generate style guide (one-time)
/designsetupAuto-detects from:
reference/folder โ Extract design from HTML/screenshots- Existing codebase โ Reverse engineer patterns
- AI generation โ Modern best practices
Creates: design-system/STYLE_GUIDE.md
/pageplan - Generate page plan (UI tasks only) ๐
/pageplan @prd.md @project_brief.mdWhat it does:
- Reads user-specified files (PRD, brief)
- Reads
proposal.md+STYLE_GUIDE.md - Searches existing components
- AI drafts real content from PRD
- Generates asset checklist
Creates: page-plan.md
- Component reuse plan (๐ Reuse vs โ New)
- Page structure (component hierarchy)
- Assets to prepare (images, icons)
- Content draft (headlines, descriptions)
/psetup - Setup project (one-time)
/psetupWhat it does:
- Detects tech stack (Next.js, React, Prisma, etc.)
- Creates
domain/{project}/README.md - Generates best practices via Context7 MCP
/csetup {change-id} - Setup change context
/csetup landing-pageWhat it does:
- Reads
proposal.md(business context) - Reads
tasks.md(implementation checklist) - Reads
page-plan.md(if exists - UI content plan) - Classifies tasks by agent
- Generates
workflow.md(execution plan)
/cdev {change-id} - Execute implementation
/cdev landing-page
# Or with explicit approval
"เธฅเธธเธขเนเธฅเธข" # Continue without confirmation promptsWhat it does:
- Runs agents in phases (1 โ 2 โ 2.5 โ 3 โ 4)
- uxui-frontend auto-reads
page-plan.md(STEP 0.5) - Auto-proceed: Detects user approval ("continue", "เธฅเธธเธขเนเธฅเธข") and eliminates redundant confirmation prompts
- Updates
flags.json(progress tracking) - Reports completion status
Auto-Proceed Feature:
- When you say "continue", "proceed", "yes", or "เธฅเธธเธขเนเธฅเธข", Main Claude auto-responds to agent questions
- 50-90% fewer confirmations (1x per workflow instead of 2x per phase)
- 25% faster execution (no waiting for redundant approvals)
/cview {change-id} - View detailed progress
/cview landing-pageShows:
- Completed/pending tasks
- Agent activity log
- Current phase
- Error messages (if any)
/cstatus {change-id} - Quick status
/cstatus landing-page
# โ Phase 2/4 - Backend Implementation (75%)๐จ Design System Integration
Auto-Generate Style Guide
/designsetupDetection priority:
- reference/ folder (HTML/screenshots) โ Extract design style
- Existing codebase (>10 components) โ Reverse engineer patterns
- AI generation โ Modern best practices
Output: design-system/STYLE_GUIDE.md
17 Comprehensive Sections:
- Overview
- Design Philosophy
- Color Palette (HEX codes, usage, Tailwind classes)
- Typography (headings, body, weights)
- Spacing System (4px/8px grid)
- Component Styles (Button, Card, Input, Badge, etc.)
- Shadows & Elevation
- Animations & Transitions
- Border Styles
- Border Radius
- Opacity & Transparency
- Z-Index Layers
- Responsive Breakpoints
- CSS Variables / Tailwind Theme (Design Tokens)
- Layout Patterns
- Example Component Reference (React + Tailwind code)
- Additional Sections (Best Practices, Accessibility, Icon System)
Agents automatically use STYLE_GUIDE.md for:
- Color palette (no hardcoded colors)
- Spacing scale (consistent gaps/padding)
- Typography (font hierarchy)
- Component patterns (reuse before create)
๐งช Testing Philosophy
Agents follow TDD classification:
| Code Type | Approach | Example |
|---|---|---|
| Critical paths | TDD (Red-Green-Refactor) | Auth logic, payments, calculations |
| Simple code | Test-alongside | CRUD, UI components, config |
Test-debug agent:
- Runs tests automatically after implementation
- Fixes bugs (max 3-4 iterations)
- Escalates if stuck (reports to user)
๐ง Supported Tech Stacks
Agents auto-detect your stack via Context7 MCP:
Frontend:
- Next.js, React, Vue, Svelte, Angular
Backend:
- FastAPI, Express, NestJS, Django, Flask, Next.js API Routes
Database:
- Prisma, SQLAlchemy, TypeORM, Drizzle
Testing:
- Vitest, Jest, Pytest, Playwright
๐ Usage Examples
Example 1: Simple UI Task (with /pageplan)
# In Claude Code
"Build a user profile page with edit functionality"
# If it's a UI task, optionally run:
/pageplan @prd.md
# Then execute:
/csetup profile-page
/cdev profile-pageClaude will:
- Read
task-classification.md - Select agents:
uxui-frontendโbackendโfrontendโtest-debug - uxui-frontend reads
page-plan.md(if exists) - Execute in sequence
- Report completion
Example 2: Complex Multi-Agent Workflow (OpenSpec)
Using OpenSpec workflow:
# 1. OpenSpec generates proposal + tasks
"I want to add a dashboard with analytics"
# โ proposal.md + tasks.md created
# 2. Generate page plan
/pageplan @prd.md @analytics_spec.md
# 3. Setup change context
/csetup analytics-dashboard
# 4. Start development
/cdev analytics-dashboard
# 5. View progress
/cview analytics-dashboardThis follows a structured 4-phase approach:
- Phase 1: UI with mock data (uxui-frontend reads page-plan.md)
- Phase 2: Real API + database (backend + database)
- Phase 2.5: Validate contracts (integration)
- Phase 3: Connect UI to API (frontend)
- Phase 4: Tests + bug fixes (test-debug)
๐ Updating to Latest Version
Method 1: Update the npm package
npm update -g @champpaba/claude-agent-kitMethod 2: Update template in project
cd your-project
cak update --backupThis will:
- Create backup at
.claude.backup/ - Update all template files
- Preserve your customizations in
domain/
๐ฏ Customization
Add Project-Specific Context
After running cak init, add your own context files:
mkdir -p .claude/contexts/domain/my-projectExample: E-commerce checkout flow
<!-- .claude/contexts/domain/my-project/checkout-flow.md -->
# Checkout Flow
## Steps
1. Cart review
2. Shipping address
3. Payment method
4. Order confirmation
## Business Rules
- Free shipping over $50
- Tax calculation by state
- Inventory check before paymentAgents will auto-discover and use these patterns.
๐ Ecosystem
Claude Agent Kit works with:
| Tool | Purpose | Integration |
|---|---|---|
| OpenSpec | Spec-driven planning | Reads proposal.md + tasks.md |
| Context7 MCP | Always-updated docs | Auto-generates best practices |
| Claude Code | AI coding assistant | Execution environment |
๐ค Contributing
We welcome contributions!
- Report bugs: GitHub Issues
- Feature requests: Discussions
- Pull requests: Follow CONTRIBUTING.md
๐ License
MIT License - see LICENSE
๐ Credits
Built with:
- OpenSpec - Spec-driven development framework
- Claude Code - AI coding assistant
- Context7 MCP - Always up-to-date library docs
๐ What's New in v1.4.1
Feature: Intelligent Auto-Proceed - Eliminate Double Confirmations ๐
Smart Approval Detection
Problem Solved:
- Before: Agent asks "Proceed?" โ Main Claude asks user again (redundant!)
- User frustration: "I already said 'เธฅเธธเธขเนเธฅเธข', why ask twice?"
Solution Implemented:
- โ Main Claude detects user approval keywords ("continue", "proceed", "yes", "เธฅเธธเธขเนเธฅเธข")
- โ Passes approval context to agents in prompt
- โ Auto-responds to agent questions without re-prompting user
- โ Backward compatible: Manual approval mode still available
Results:
- 50-90% fewer confirmations (1x per workflow vs 2x per phase)
- 25% faster execution (no waiting for redundant approvals)
- Better UX (approve once, system handles the rest)
- Lean implementation (80 lines, 1 file, +0.1% context)
How It Works
# Before v1.4.1 (Double confirmation โ)
User: "เธฅเธธเธขเนเธฅเธข"
Main: Calls uxui-frontend agent
Agent: "Pre-work done. Proceed?"
Main: "Agent is asking... Proceed? (yes/no)" โ Asks user again!
User: "Why ask twice?"
# After v1.4.1 (Smart auto-proceed โ
)
User: "เธฅเธธเธขเนเธฅเธข"
Main: Detects approval โ auto_proceed = true
Agent: "Pre-work done. Proceed?"
Main: "YES, proceed immediately" โ Answers agent directly!
Agent: Continues work...Auto-Proceed Trigger Words
These keywords enable auto-proceed mode:
- โ
/cdevcommand (implicit approval for all phases) - โ "continue", "proceed", "yes"
- โ "เธฅเธธเธขเนเธฅเธข" (Thai: "go ahead")
๐ What's New in v1.4.0
Major Update: Context Optimization & DRY Consolidation
Token Efficiency Improvements
Problem Solved:
- Before v1.4.0: Same documentation duplicated across 6 agent files + CLAUDE.md
- Package Manager warnings: 360 lines duplicated 6x
- Context Loading Strategy: 1,200 lines duplicated 6x
- TDD Workflow examples: 1,200 lines duplicated 3x
- Handoff templates: 900 lines duplicated 6x
- Documentation policies: 480 lines duplicated 6x
- CLAUDE.md: 890 lines mixing navigation + detailed guides
Solution Implemented:
- โ Created consolidated lib files (context-loading-protocol.md, handoff-protocol.md, tdd-workflow.md)
- โ Extracted detailed guides from CLAUDE.md to lib/detailed-guides/
- โ Applied consistent reference pattern: Brief summary + "โ See: path" + agent-specific additions
- โ Maintained 100% content quality (all information preserved)
Results:
- All 6 agents: 6,796 โ 4,749 lines (-2,047, -30.1% reduction)
- CLAUDE.md: 890 โ 163 lines (-727, -81.7% reduction)
- Grand Total: 7,686 โ 4,912 lines (-2,774, -36.1% reduction)
- Token savings: ~36% reduction in total context size
- Speed improvement: Faster agent loading and execution
- Maintainability: Single source of truth for shared documentation
New Consolidated Documentation Structure
Created in v1.4.0:
.claude/lib/
โโโ context-loading-protocol.md # Universal context loading strategy
โโโ handoff-protocol.md # Agent handoff templates
โโโ tdd-workflow.md # TDD workflow examples
โโโ detailed-guides/
โโโ best-practices-system.md # How best practices work
โโโ context-optimization.md # Token optimization strategy
โโโ page-planning.md # /pageplan command guide
โโโ taskmaster-analysis.md # 6-dimension task analysis
โโโ design-system.md # Style guide generation
โโโ agent-system.md # Agent overview & workflowBenefits for Users
For Developers:
- โก 36% faster context loading
- ๐ Cleaner, easier-to-navigate documentation
- ๐ฏ CLAUDE.md is now a pure navigation hub (163 lines)
- ๐ Detailed guides are modular and focused
For Claude Agents:
- ๐ Faster startup (less context to load)
- ๐พ More token budget for actual work
- ๐ Single source of truth (no conflicting info)
- ๐ Easier maintenance (update once, apply everywhere)
Migration Notes
No breaking changes! All existing workflows continue to work:
- โ
/psetup,/csetup,/cdevcommands unchanged - โ Agent behavior unchanged (same quality, faster execution)
- โ All features from v1.1-1.3 preserved
- โ
Existing projects can update with
cak update
New Reference Pattern: Agents now use lightweight references instead of duplicating full documentation:
## Context Loading Strategy
**โ See:** `.claude/lib/context-loading-protocol.md` for complete protocol
**Agent-Specific Additions (frontend):**
### State Management Libraries
...Upgrading to v1.4.1
# Update npm package
npm update -g @champpaba/claude-agent-kit
# Update template in your project (creates backup)
cd your-project
cak update --backupWhat's New:
- โ Auto-proceed feature (eliminate double confirmations)
- โ 50-90% fewer approval prompts
- โ 25% faster workflow execution
- โ All v1.4.0 features (context optimization, DRY consolidation)
All your customizations in .claude/contexts/domain/ are preserved!
๐ Changelog
v1.4.1 (2025-11-06)
Feature: Intelligent Auto-Proceed - Eliminate Double Confirmations
Added:
- Auto-proceed approval context in agent prompts
- Smart detection of user approval keywords ("continue", "proceed", "yes", "เธฅเธธเธขเนเธฅเธข")
- Agent question handling logic (auto-respond vs ask user)
- Auto-proceed decision tree in agent-executor.md
Improved:
- User experience: 50-90% fewer confirmation prompts
- Execution speed: 25% faster (no waiting for redundant approvals)
- Workflow clarity: User approves once, system handles agent interactions
Technical Details:
- Modified:
.claude/lib/agent-executor.md(+80 lines) - Implementation: Lean solution (1 file, 0.1% context increase)
- Backward compatible: Manual approval mode still available
When It Activates:
- User runs
/cdevcommand (implicit approval) - User says "continue", "proceed", "yes", "เธฅเธธเธขเนเธฅเธข" (explicit approval)
Before:
User approves โ Agent asks โ Main asks user again โAfter:
User approves โ Agent asks โ Main answers directly โ
v1.4.0 (2025-11-05)
Major: Context Optimization & DRY Consolidation
Added:
- New consolidated lib files:
context-loading-protocol.md,handoff-protocol.md,tdd-workflow.md - New detailed guides folder:
lib/detailed-guides/(6 focused guides) - Reference pattern across all agents (Brief summary โ See: path โ Additions)
Changed:
- All 6 agents refactored: 30.1% size reduction (6,796 โ 4,749 lines)
- CLAUDE.md refactored: 81.7% size reduction (890 โ 163 lines, pure navigation hub)
- Documentation structure: Moved detailed content to modular lib files
Performance:
- 36% total context reduction (7,686 โ 4,912 lines)
- Faster agent loading and execution
- More token budget available for actual work
Improved:
- Maintainability: Single source of truth for shared docs
- Discoverability: Clear navigation in CLAUDE.md
- Modularity: Detailed guides in separate files
- Consistency: Same content quality, zero duplication
v1.3.0 (2025-10-30)
Feature: TaskMaster-style Intelligent Task Analysis
Added:
- 6-dimension task analysis in
/csetup:- Complexity scoring (1-10)
- Dependency detection (auto-detects blocks/blocked-by)
- Risk assessment (LOW/MEDIUM/HIGH with mitigation)
- Research requirements (auto-generates queries)
- Subtask breakdown (complex tasks โ smaller steps)
- Priority ranking (CRITICAL โ LOW, scored 0-100)
- Task analyzer implementation:
.claude/lib/task-analyzer.md - Enhanced phases.md with metadata, time buffers, research phases
Improved:
- Time estimates with automatic buffers (+41% average)
- Research phases auto-added for new tech/libraries
- Dependency order in workflow execution
- Risk mitigation strategies per task
Inspired by: claude-task-master
v1.2.0 (2025-10-27)
Feature: Context Optimization - 70% Token Reduction
Added:
- 3-tier loading strategy: STYLE_TOKENS.json (500) โ design-context.md (1K) โ STYLE_GUIDE.md (5K)
- Document loader protocol:
.claude/lib/document-loader.md - Lightweight design tokens:
design-system/STYLE_TOKENS.json
Improved:
- Token usage: ~20K โ ~4.7K (70% reduction for design system)
- Speed: 3-4x faster command execution
- Consistency: Enforced design tokens, no random colors
v1.1.1 (2025-10-25)
Patch: Minor Fixes
Fixed:
- Template path correction:
template/.claudeโ.claude - Documentation typos and formatting
v1.1.0 (2025-10-24)
Feature: Enhanced Implementation Logic
Added:
- Implementation logic overview:
lib/README.md - Agent executor with retry & escalation:
lib/agent-executor.md - TDD classifier logic:
lib/tdd-classifier.md - Progress tracking protocol:
lib/flags-updater.md - Mandatory agent routing:
lib/agent-router.md - Shared agent discovery flow:
contexts/patterns/agent-discovery.md
v1.0.0 (2025-10-20)
Initial Release: Multi-Agent Template
Core Features:
- 6 specialized agents (integration, uxui-frontend, test-debug, frontend, backend, database)
- OpenSpec integration (
/csetup,/cdev,/cview,/cstatus) - Auto-generated best practices via Context7 MCP
- 3-level project indexing (domain โ project โ best-practices)
- Design foundation (color theory, spacing, typography)
/designsetupcommand (auto-generate style guide)/pageplancommand (UI content & component planning)- Universal patterns (logging, testing, error-handling, TDD)
- CLI:
cak init,cak update
๐ Links
- npm Package: https://www.npmjs.com/package/@champpaba/claude-agent-kit
- GitHub: https://github.com/ChampPABA/claude-multi-agent-template
- OpenSpec: https://github.com/Fission-AI/OpenSpec
- Issues: https://github.com/ChampPABA/claude-multi-agent-template/issues
๐ก Quick Tips
- Run
/designsetupFIRST - Ensures visual consistency from day 1 - Use
/pageplanfor UI tasks - 25% faster implementation, better content - Review
page-plan.mdbefore/cdev- Edit content, prepare assets - Setup Context7 MCP - Agents get latest framework docs automatically
- Use OpenSpec for complex features - Better alignment before implementation
- Monitor with
/cview- See exactly what agents are doing - Always use
--backupwhen updating - Protects your customizations
๐ Complete Flow Summary
1๏ธโฃ OpenSpec Planning
โ proposal.md + tasks.md
2๏ธโฃ Generate Style Guide (one-time)
/designsetup
โ STYLE_GUIDE.md
3๏ธโฃ Setup Project (one-time)
/psetup
โ domain/{project}/best-practices/
4๏ธโฃ Generate Page Plan (UI tasks only)
/pageplan @prd.md
โ page-plan.md (content + component plan)
5๏ธโฃ Setup Change Context
/csetup {change-id}
โ workflow.md
6๏ธโฃ Execute Implementation
/cdev {change-id}
โ Working code + tests
7๏ธโฃ Monitor Progress
/cview {change-id}
โ Detailed progress report
8๏ธโฃ OpenSpec Archive & Update
โ Merge to specs/Ready to implement with confidence? ๐
# Install globally
npm install -g @champpaba/claude-agent-kit
# Initialize in your project
cd your-project
cak init
# Setup project context
/psetup
# Generate style guide (optional but recommended)
/designsetup
# Start building (after OpenSpec planning)
/pageplan @prd.md # UI tasks only
/csetup your-feature
/cdev your-featureLet specialized agents handle implementation while you focus on specs and architecture!