- Version: 2.0
Analyzes development velocity, cycle time, and quality metrics from story data.
/plugin marketplace add ninthspace/claude-code-marketplace/plugin install sdd@ninthspace-marketplacePurpose: Analyze completed and in-progress stories to understand development patterns, velocity trends, bottlenecks, and generate actionable insights.
Syntax: /sdd:story-metrics [period]
| Parameter | Type | Required | Default | Description | Validation |
|---|---|---|---|---|---|
| period | string | No | "all" | Time period to analyze (week, month, quarter, all) | One of: week, month, quarter, all |
/docs/stories/backlog/ - Stories not started/docs/stories/development/ - Active stories/docs/stories/review/ - Stories in review/docs/stories/qa/ - Stories in testing/docs/stories/completed/ - Finished storiesSCAN all story directories for .md files
PARSE each story file to extract:
FILTER by period if specified:
CALCULATE time in each stage:
COUNT completed stories per time period
CALCULATE average cycle time (start to completion)
COMPUTE throughput (stories per week)
GENERATE trend analysis:
DISPLAY velocity metrics:
š VELOCITY METRICS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Current Period: [Date range]
- Stories completed: [count]
- Average cycle time: [X] days
- Throughput: [X] stories/week
Trend (Last 4 Weeks):
Week 1: āāāāāāāā 8 stories
Week 2: āāāāāā 6 stories
Week 3: āāāāāāāāā 9 stories
Week 4: āāāāāāā 7 stories
Status: [ā Trending up | ā Trending down | ā Stable]
CALCULATE average time per stage:
IDENTIFY outliers:
DETECT bottlenecks:
DISPLAY cycle time analysis:
ā±ļø CYCLE TIME ANALYSIS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Average by Stage:
- Development: [X] days
- Review: [X] hours
- QA: [X] hours
- Total: [X] days
Outliers:
- Fastest: [STORY-ID] - [X] days
- Slowest: [STORY-ID] - [X] days
Bottlenecks:
- [Stage]: [X]% above average
CALCULATE first-time pass rate:
COUNT bugs by stage:
ANALYZE test coverage:
COMPUTE rollback rate:
DISPLAY quality metrics:
šÆ QUALITY METRICS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Pass Rate:
- First-time pass: [X]%
- Average rework cycles: [X]
Bug Detection:
- Avg bugs in review: [X]
- Avg bugs in QA: [X]
- Production incidents: [count]
Testing:
- Avg test cases: [X]
- Coverage target met: [X]%
Stability:
- Rollback rate: [X]%
CATEGORIZE stories by cycle time:
CALCULATE distribution percentages
GENERATE visual distribution chart
PROVIDE sizing recommendation
DISPLAY size distribution:
š STORY SIZE DISTRIBUTION
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Small (1-2 days): āāāāāāāā 40% ([count] stories)
Medium (3-5 days): āāāāāā 30% ([count] stories)
Large (5+ days): āāāāāā 30% ([count] stories)
Recommendation:
[Break down large stories | Continue current sizing | Adjust estimation]
EXTRACT technologies from technical notes
COUNT usage frequency across stories
IDENTIFY new technology additions
TRACK adoption dates
DISPLAY tech stack usage:
š§ TECH STACK USAGE
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Most Used:
- [Technology]: [X] stories
- [Framework]: [X] stories
- [Library]: [X] stories
Recent Additions:
- [New Tech]: Added [date]
- [New Tool]: Added [date]
ANALYZE completion patterns:
IDENTIFY common blockers:
DISPLAY development patterns:
š DEVELOPMENT PATTERNS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Productivity:
- Most productive day: [Day]
- Peak completion time: [Time range]
- Avg stories/week: [X]
Common Blockers:
- [Blocker type]: [X] occurrences
- [Blocker type]: [X] occurrences
CALCULATE velocity-based projections:
ANALYZE work-in-progress:
DISPLAY projections:
š® PROJECTIONS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
At Current Velocity:
- Next week: [X] stories (±[Y])
- Next month: [X] stories (±[Y])
Capacity:
- Current WIP: [X] stories
- Optimal WIP limit: [X] stories
- Capacity utilization: [X]%
ANALYZE metrics for improvement opportunities
GENERATE specific, actionable recommendations:
PRIORITIZE recommendations by impact
DISPLAY recommendations:
š” RECOMMENDATIONS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
High Impact:
1. [Specific improvement with metric basis]
2. [Process optimization with expected gain]
3. [Tool suggestion with benefit]
Quick Wins:
- [Low-effort, high-value change]
- [Simple process tweak]
COMPILE all metrics into summary dashboard
CALCULATE trend indicators:
EXTRACT top insights from data
GENERATE action items
DISPLAY complete dashboard:
š METRICS DASHBOARD
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Period: [Date range]
Generated: [Date and time]
HEADLINES:
⢠Velocity: [ā Trending up | ā Trending down | ā Stable] ([X]%)
⢠Quality: [Improving | Declining | Stable] ([X]%)
⢠Efficiency: [X]% [improvement | decline] over last period
KEY INSIGHTS:
⢠[Data-driven insight 1]
⢠[Data-driven insight 2]
⢠[Data-driven insight 3]
ACTION ITEMS:
⢠[Prioritized action 1]
⢠[Prioritized action 2]
NEXT REVIEW: [Suggested date]
OFFER export option:
š¾ Export metrics to /metrics/[date].md? (y/n)
/metrics/[date].md - Saved metrics report with timestampš METRICS DASHBOARD
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Period: [Start Date] to [End Date]
Generated: [Timestamp]
š VELOCITY METRICS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Current Period:
- Stories completed: [count]
- Average cycle time: [X] days
- Throughput: [X] stories/week
Trend (Last 4 Weeks):
Week 1: āāāāāāāā 8 stories
Week 2: āāāāāā 6 stories
Week 3: āāāāāāāāā 9 stories
Week 4: āāāāāāā 7 stories
Status: ā Trending up (15%)
ā±ļø CYCLE TIME ANALYSIS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Average by Stage:
- Development: [X] days
- Review: [X] hours
- QA: [X] hours
- Total: [X] days
Outliers:
- Fastest: [STORY-ID] - [X] days
- Slowest: [STORY-ID] - [X] days
Bottlenecks:
- [Stage]: [X]% above average
šÆ QUALITY METRICS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Pass Rate:
- First-time pass: [X]%
- Average rework cycles: [X]
Bug Detection:
- Avg bugs in review: [X]
- Avg bugs in QA: [X]
- Production incidents: [count]
Testing:
- Avg test cases: [X]
- Coverage target met: [X]%
Stability:
- Rollback rate: [X]%
š STORY SIZE DISTRIBUTION
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Small (1-2 days): āāāāāāāā 40% ([count])
Medium (3-5 days): āāāāāā 30% ([count])
Large (5+ days): āāāāāā 30% ([count])
Recommendation: [Sizing guidance]
š§ TECH STACK USAGE
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Most Used:
- [Technology]: [X] stories
- [Framework]: [X] stories
Recent Additions:
- [New Tech]: Added [date]
š DEVELOPMENT PATTERNS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Productivity:
- Most productive day: [Day]
- Peak completion time: [Time range]
- Avg stories/week: [X]
Common Blockers:
- [Blocker]: [X] occurrences
š® PROJECTIONS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
At Current Velocity:
- Next week: [X] stories (±[Y])
- Next month: [X] stories (±[Y])
Capacity:
- Current WIP: [X] stories
- Optimal WIP limit: [X]
- Utilization: [X]%
š” RECOMMENDATIONS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
High Impact:
1. [Specific improvement]
2. [Process optimization]
3. [Tool suggestion]
Quick Wins:
- [Low-effort improvement]
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
INPUT:
/sdd:story-metrics
OUTPUT:
ā Scanning story directories...
ā Found 45 stories across all stages
ā Analyzing velocity, cycle time, and quality...
š METRICS DASHBOARD
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Period: All Time (Jan 1, 2025 - Oct 1, 2025)
Generated: Oct 1, 2025 at 2:30 PM
š VELOCITY METRICS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Current Period:
- Stories completed: 42
- Average cycle time: 4.2 days
- Throughput: 6.8 stories/week
Trend (Last 4 Weeks):
Week 1: āāāāāāāā 8 stories
Week 2: āāāāāā 6 stories
Week 3: āāāāāāāāā 9 stories
Week 4: āāāāāāā 7 stories
Status: ā Trending up (12%)
[Additional sections...]
š¾ Export metrics to /metrics/2025-10-01.md? (y/n)
INPUT:
/sdd:story-metrics month
OUTPUT:
ā Scanning story directories...
ā Found 28 stories in last 30 days
ā Analyzing September 2025 data...
š METRICS DASHBOARD
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Period: Sep 1, 2025 - Sep 30, 2025
Generated: Oct 1, 2025 at 2:30 PM
š VELOCITY METRICS
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Current Period:
- Stories completed: 28
- Average cycle time: 3.8 days
- Throughput: 7.0 stories/week
Status: ā Trending up (18% vs August)
[Additional sections...]
INPUT:
/sdd:story-metrics week
OUTPUT:
ā Scanning story directories...
ā No stories found in last 7 days
ā ļø INSUFFICIENT DATA
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
No completed stories found in the specified period.
Suggestions:
- Try a longer period: /sdd:story-metrics month
- Check if stories are marked as completed
- Verify story dates are set correctly
Current WIP:
- Development: 2 stories
- Review: 1 story
- QA: 1 story
/sdd:project-init/sdd:story-patterns - Identify recurring patterns in stories/sdd:story-tech-debt - Analyze technical debt from stories/sdd:project-status - View current story statuses/sdd:story-list - List stories with filters