CREATE/REPLAN Epics from scope (3-7 Epics). Batch Preview + Auto-extraction. Decompose-First Pattern. Auto-discovers team ID.
Paths: File paths (
shared/,references/,../ln-*) are relative to skills repo root. If not found at CWD, locate this SKILL.md directory and go up one level for repo root.
Universal Epic management coordinator that handles both creation and replanning through scope decomposition.
Coordinates Epic creation (CREATE) and replanning (REPLAN) from scope decomposition, producing 3-7 Linear Projects with batch preview, auto-extraction from docs/HTML, and Decompose-First Pattern.
This skill should be used when:
Output: 3-7 Linear Projects (logical domains/modules)
Key principle: ALWAYS analyze scope and build IDEAL Epic plan FIRST, THEN check existing Epics to determine mode:
Rationale: Ensures consistent Epic decomposition based on current scope requirements, independent of existing Epic structure (which may be outdated or suboptimal).
MANDATORY READ: Load shared/references/numbering_conventions.md for Epic 0 rules, when to use it, and Linear numbering.
| Input | Required | Source | Description |
|---|---|---|---|
scopeDoc | Yes | args, project docs, user | Scope document for Epic decomposition |
Resolution: Epic Resolution Chain (adapted: scope doc discovery). Fallback: IF no scope doc found → AskUserQuestion: "What should be decomposed into Epics?"
MANDATORY READ: Load shared/references/tools_config_guide.md, shared/references/storage_mode_detection.md, shared/references/input_resolution_pattern.md
Extract: task_provider = Task Management → Provider
Objective: Gather all necessary context before Epic decomposition.
Step 0: Resolve scopeDoc (per input_resolution_pattern.md, adapted for scope):
docs/project/requirements.md exists → use as scope sourcedocs/requirements.md exists → use as scope sourceStep 1: Load Configuration
Auto-discovers Team ID and Next Epic Number from docs/tasks/kanban_board.md:
MANDATORY READ: Load CLAUDE.md — sections "Configuration Auto-Discovery" and "Linear Integration".
Step 2: Project Research
Objective: Research project documentation AND frontend code to understand context BEFORE asking user questions.
Process:
Document Scan:
Glob to find: docs/requirements.md, docs/architecture.md, docs/tech_stack.mdRead to load found documentsFrontend Code Scan (if applicable):
Glob to find: **/*.html, src/**/*.html, public/**/*.html, templates/**/*.htmlRead to load HTML files<nav>, <a href> links reveal feature areas<h1>, <title> tags reveal feature namesExample HTML extraction:
<nav>
<a href="/products">Products</a>
<a href="/cart">Shopping Cart</a>
<a href="/checkout">Checkout</a>
</nav>
<!-- Reveals domains: Product Catalog, Shopping Cart, Payment -->
Extract key information from docs + HTML:
Combine findings:
Fallback: If docs AND HTML missing → Skip to Phase 2, will ask user basic questions
Step 3: Infrastructure Epic Decision
Objective: Determine if Infrastructure Epic (Epic 0) should be proposed.
Criteria for Infrastructure Epic:
✅ PROPOSE Infrastructure Epic (Epic 0) if ANY of:
docs/infrastructure.md found, no Epic "Infrastructure" in kanban_board.md Epic Story Counters)❌ DO NOT propose if:
docs/infrastructure.md)Decision: Store YES/NO decision for use in Phase 2
Output from Phase 1:
Objective: Identify logical domains and build Epic structure inline.
Process:
Step 1: Auto-identify Domains
Use research context from Phase 1 Step 2:
Fallback: If no docs/HTML → Ask user basic questions (scope, objectives, functional areas)
Step 2: Build Epic List (inline)
IF Infrastructure needed (from Phase 1 Step 3):
numbering_conventions.md §Epic 0 Content TemplateELSE:
Step 3: Determine Epic Count
Step 4: Show Proposed Epic Structure (USER CONTROL POINT 1)
Display identified Epics with initiative-internal indexes:
📋 Proposed Epic Structure:
Epic 0: Infrastructure & Operations
Epic 1: User Management
Epic 2: Product Catalog
Epic 3: Shopping Cart
Epic 4: Payment Processing
Epic 5: Order Management
Total: 6 Epics
Type "confirm" to proceed, or modify the list
Step 5: User Confirmation
Output: Approved Epic list (Epic 0-N or Epic 1-N) ready for next phase
Context: Structured quality check before creating Epics ensures scope clarity and prevents rework during Story decomposition.
For each proposed Epic, validate 5 criteria:
| # | Criterion | PASS | FAIL |
|---|---|---|---|
| 1 | Scope clarity | Clear In/Out boundaries | Vague or overlapping with other Epics |
| 2 | Success criteria | Measurable ("<200ms", ">98%") | Vague ("fast", "reliable") |
| 3 | Risk documentation | Dependencies/blockers identified | Risks section empty or generic |
| 4 | Balance | Similar scope size across Epics (±30%) | One Epic has 80% of work |
| 5 | Independence | No circular Epic dependencies | Epics block each other |
Quality Score = count of PASS criteria (0-5)
Objective: Determine CREATE vs REPLAN mode.
Query kanban_board.md and task provider for existing Epics:
list_projects(team=teamId) to cross-check
ELSE: Glob("docs/tasks/epics/*/epic.md") to list file-based EpicsDecision Point:
Trigger: Phase 3 determined Count = 0 (CREATE MODE)
Objective: Prepare all Epic documents before batch preview.
Step 1: Auto-extract Information for ALL Domains
For EACH domain (from Phase 2), extract answers to 5 key questions from project documentation:
Q1: Business goal - Why this Epic/domain matters
Q2: Key features in scope - 3-5 bullet points of capabilities
Q3: Out of scope - Prevent scope creep
Q4: Success criteria - Measurable outcomes
Q5: Known risks (Optional) - Blockers, dependencies
If extraction incomplete:
Step 2: Generate ALL Epic Documents
For EACH domain, generate complete Epic document using epic_template_universal.md:
Epic indexing:
Linear Title (will be created in Phase 5a):
Sections: Goal, Scope In/Out, Success Criteria, Dependencies, Risks & Mitigations, Architecture Impact, Phases
Use extracted information from Step 1 for all sections
Output: All Epic documents ready (Epic 0-N), indexed within initiative
Trigger: Phase 4 completed preparation
Objective: Show preview, get confirmation, create all Epics in Linear.
Step 1: Show Batch Preview (USER CONTROL POINT 2)
Display ALL generated Epics with initiative-internal indexes:
📋 Epic Batch Preview (6 Epics to create)
═══════════════════════════════════════════════
Epic 0: Infrastructure & Operations
═══════════════════════════════════════════════
Goal: Establish foundational infrastructure, deployment pipeline, and operational capabilities to support all business Epics
Scope In:
- Logging and error handling framework
- Monitoring and alerting system
- CI/CD pipeline (GitHub Actions)
- Security baseline (secrets management, encryption)
- Performance optimization (caching, rate limiting)
Scope Out:
- Application-specific business logic
- User-facing features
- Domain-specific integrations
Success Criteria:
- All deployments automated via CI/CD (<10 min deployment time)
- System uptime ≥99.9%
- API response time <200ms (p95)
- Security audit passed
═══════════════════════════════════════════════
Epic 1: User Management
═══════════════════════════════════════════════
Goal: Enable users to register, authenticate, and manage their accounts securely
Scope In:
- User registration with email verification
- Login/logout with JWT authentication
- Password reset flow
- Profile management
Scope Out:
- Social login (OAuth) - planned for Epic 5
- Multi-factor authentication - future version
- User roles and permissions - part of Epic 3
Success Criteria:
- User registration <2 seconds
- Login success rate >98%
- Password reset completion rate >90%
[... all other Epics ...]
───────────────────────────────────────────────
Total: 6 Epics (Epic 0: Infrastructure, Epic 1-5: Business domains)
Type "confirm" to create all Epics in Linear
Step 2: User Confirmation
Step 3: Create All Epics
For EACH Epic (in sequential order for numbering consistency):
Get Next Epic Number:
Create Epic (provider-dependent):
IF task_provider == "linear":
save_project({name: "Epic {N}: {Title}", description: epic_markdown, team: teamId, state: "planned"})ELSE (file mode):
mkdir -p docs/tasks/epics/epic-{N}-{slug}/stories/Write("docs/tasks/epics/epic-{N}-{slug}/epic.md") with Epic markdown + file headers (**Status:** Backlog, **Created:** {date})Update kanban_board.md:
Epic {N} | - | US001 | - | EPN_01- [Epic {N}: Title](link) - BacklogCollect URL (Linear mode) or file path (file mode)
Step 4: Display Summary
✅ Created 6 Epics for initiative
Epics created:
- Epic 11: Infrastructure & Operations (Epic 0 index) [link]
- Epic 12: User Management (Epic 1 index) [link]
- Epic 13: Product Catalog (Epic 2 index) [link]
- Epic 14: Shopping Cart (Epic 3 index) [link]
- Epic 15: Payment Processing (Epic 4 index) [link]
- Epic 16: Order Management (Epic 5 index) [link]
Next Epic Number updated to: 17
Next Steps:
1. Use ln-220-story-coordinator to create Stories for each Epic (run 6 times)
2. OR use ln-200-scope-decomposer to automate Epic + Story creation
Output: Created Epic URLs + summary
TodoWrite format: Add Phase 1-5a todos + one todo per Epic + kanban update. Mark in_progress/completed.
Trigger: Phase 3 determined Count ≥ 1 (REPLAN MODE)
Full workflow: MANDATORY READ: Load references/replan_workflow.md for complete REPLAN process.
Summary:
docs/tasks/epics/*/epic.md)Constraints: Never auto-update/archive Epics with Stories In Progress. Never delete (use archived). Always require confirmation.
Before completing work, verify ALL checkpoints:
✅ Discovery Complete (Phase 1):
✅ Scope Analysis Complete (Phase 2):
✅ Existing Epics Checked (Phase 3):
✅ Epic Preparation Complete (Phase 4 - CREATE only):
✅ Epic Creation Complete (Phase 5a - CREATE only):
✅ Epic Replan Complete (Phase 5b - REPLAN only):
references/replan_workflow.md for full checklistOutput: List of Linear Project URLs (Epic {N}: {Title}) + Next Epic Number value
Request: "Create epics for e-commerce platform"
Flow: Phase 1 (discover Team ID=Product, Next=11, scan docs+HTML) → Phase 2 (identify 6 domains: Infrastructure, User, Products, Cart, Payment, Orders) → Phase 3 (count=0 → CREATE) → Phase 4 (auto-extract Q1-Q5, generate docs) → Phase 5a (preview, confirm, create in Linear: Epic 11-16)
Result: 6 Epics created (Epic 0-5 internal indexes, Epic 11-16 Linear titles)
MANDATORY READ: Load shared/references/meta_analysis_protocol.md
Skill type: planning-coordinator. Run after all phases complete. Output to chat using the planning-coordinator format.
shared/references/tools_config_guide.mdshared/references/storage_mode_detection.mdshared/references/problem_solving.mdshared/references/orchestrator_pattern.mdshared/references/auto_discovery_pattern.mdshared/references/decompose_first_pattern.mdshared/references/numbering_conventions.md (Epic 0 reserved, Linear numbering)shared/references/linear_creation_workflow.mdshared/templates/linear_integration.md)Version: 7.0.0 Last Updated: 2025-11-20