# Agile Epic Management Guide

## What is an Epic?

An epic is a large body of work that can be broken down into smaller user stories. Epics often span multiple teams, multiple sprints, and multiple releases.

## Epic Characteristics

- **Large Scope**: Represents significant functionality or business value
- **Long Duration**: Typically takes multiple sprints to complete
- **Multiple Stories**: Contains 10-100+ user stories
- **Business Value**: Delivers measurable business outcomes
- **Cross-Functional**: Often involves multiple teams and disciplines

## Epic Lifecycle

### 1. Identification
- Identify business needs and opportunities
- Align with product vision and roadmap
- Prioritize based on strategic value

### 2. Definition
- Write clear epic title and description
- Define success criteria and metrics
- Identify key stakeholders
- Estimate high-level effort

### 3. Decomposition
- Break down into user stories
- Identify dependencies and risks
- Create initial backlog
- Refine with development team

### 4. Execution
- Prioritize stories for sprints
- Track progress regularly
- Manage dependencies
- Communicate status to stakeholders

### 5. Completion
- Validate business outcomes
- Conduct retrospective
- Document lessons learned
- Celebrate success

## Epic vs User Story vs Task

| Aspect | Epic | User Story | Task |
|--------|------|------------|------|
| **Scope** | Large feature | User functionality | Technical work |
| **Duration** | Multiple sprints | 1 sprint | Hours/days |
| **Size** | 10-100+ stories | 1-10 tasks | Small unit |
| **Detail** | High-level | Medium detail | Very detailed |
| **Estimation** | T-shirt sizes | Story points | Hours |

## Best Practices for Epic Management

### Writing Effective Epics

1. **Clear Title**: Use descriptive, business-oriented names
   - ❌ "Improve login"
   - ✅ "Single Sign-On Integration for Enterprise Customers"

2. **Comprehensive Description**: Include context, goals, and constraints
   - Business objectives
   - User benefits
   - Technical considerations
   - Success metrics

3. **Success Criteria**: Define measurable outcomes
   - "Increase conversion rate by 15%"
   - "Reduce support tickets by 30%"
   - "Achieve 99.9% uptime"

### Epic Decomposition

**Approach**: Break down epics using the "Slice the cake" method

1. **By User Role**: Different user types
2. **By Workflow**: Different steps in a process
3. **By Business Rule**: Different scenarios/rules
4. **By Technical Component**: Different system parts
5. **By Data Type**: Different data entities

**Example**: Payment Processing Epic
- User Role: Customer payment, Admin refunds, Finance reporting
- Workflow: Payment initiation, Processing, Confirmation, Receipt
- Business Rule: Credit card, PayPal, Bank transfer
- Technical: API integration, UI components, Database

### Epic Prioritization

Use **Weighted Shortest Job First (WSJF)** formula:

```
WSJF = (Cost of Delay) / (Job Duration)
```

Factors:
- **User-Business Value**: How much value does this deliver?
- **Time Criticality**: How time-sensitive is this?
- **Risk Reduction**: How much risk does this mitigate?
- **Opportunity Enablement**: What future opportunities does this enable?

### Epic Tracking

**Key Metrics to Track:**
- **Completion Percentage**: (Completed Stories / Total Stories) × 100
- **Burnup Chart**: Progress toward epic completion
- **Velocity**: Stories completed per sprint
- **Blockers**: Issues preventing progress
- **Scope Change**: Stories added/removed

## Tools and Techniques

### Story Mapping
Visual technique to break down epics into user stories:

```
User Activities → User Steps → User Stories
```

### Impact Mapping
Strategic planning technique:

```
WHY (Goal) → WHO (Actors) → HOW (Impacts) → WHAT (Deliverables)
```

### Epic Canvas
Visual template for epic definition:

```
[Epic Title]
- Problem Statement
- Business Goals
- User Benefits
- Success Metrics
- Key Stories
- Dependencies
- Risks
- Stakeholders
```

## Common Pitfalls and Solutions

| Pitfall | Solution |
|---------|----------|
| **Epic too large** | Break into smaller epics or features |
| **Poorly defined scope** | Conduct discovery workshops |
| **Lack of stakeholder alignment** | Regular review meetings |
| **Inadequate decomposition** | Involve development team early |
| **Scope creep** | Strict change control process |
| **Poor progress tracking** | Use visual management tools |

## Integration with Product Owner Assistant Skill

The `product-owner-assistant` skill implements these best practices:

```bash
# Create well-structured epic
skill product-owner-assistant create-epic arcodange dance-lessons-coach \
  "User Authentication System" \
  "Implement comprehensive authentication system with OAuth, JWT, and session management to improve security and user experience. Success criteria: 99% login success rate, <1s authentication time, support for 5+ identity providers." \
  "epic,authentication,security,high-priority"

# Break down into user stories
skill product-owner-assistant create-story arcodange dance-lessons-coach 42 \
  "OAuth 2.0 Integration" \
  "As a user, I want to login with Google/GitHub so I can use existing accounts..." \
  "story,authentication,oauth"

skill product-owner-assistant create-story arcodange dance-lessons-coach 42 \
  "JWT Token Management" \
  "As a developer, I need secure JWT implementation for stateless authentication..." \
  "story,authentication,jwt,backend"

# Track progress
skill product-owner-assistant epic-progress arcodange dance-lessons-coach 42
```

## Resources

- [SAFe Epic Definition](https://www.scaledagileframework.com/epic/)
- [Atlassian Epic Guide](https://www.atlassian.com/agile/project-management/epics)
- [Mike Cohn's User Stories Applied](https://www.mountaingoatsoftware.com/books/user-stories-applied)
- [Impact Mapping](https://www.impactmapping.org/)

This guide provides the foundation for effective epic management using the Product Owner Assistant skill.