Level 10 / Project 10 - Executive Metrics Publisher¶
Home: README
Learn Your Way¶
| Read | Build | Watch | Test | Review | Visualize | Try |
|---|---|---|---|---|---|---|
| Concept | This project | — | Quiz | Flashcards | — | — |
Focus¶
- Adapter pattern for normalizing metrics from different sources
- KPI transformation with trend and health analysis
- Pluggable report formatters via Protocol
- Business-meaningful narratives from technical data
Why this project exists¶
Engineering teams track hundreds of metrics, but executives need concise answers: "Are we on track?" This pipeline bridges the gap by transforming raw technical data into business-meaningful KPIs with traffic-light health ratings, trend indicators, and natural-language narratives.
Run (copy/paste)¶
Expected terminal output¶
{
"report_type": "executive_summary",
"overall_health": "yellow",
"kpi_count": 9,
"categories": { "reliability": [...], "velocity": [...], "quality": [...] },
"attention_needed": [...]
}
Alter it (required)¶
- Add a
CostSourcethat tracks cloud spend, cost per request, and budget utilization. - Add a
TrendReportFormatterthat groups KPIs by trend direction (improving/stable/declining). - Add sparkline-style text indicators (up arrow, down arrow, dash) to the narrative.
Break it (required)¶
- Pass a target of 0 to a "higher is better" metric and observe division-by-zero handling.
- Create a KPI with no previous value and verify the trend is STABLE.
- Register no sources and call
publish— verify the report is empty but valid.
Fix it (required)¶
- Add a minimum KPI count validation — report should warn if fewer than 3 KPIs are collected.
- Handle the case where all KPIs are RED — add an "executive alert" section.
- Test both fixes.
Explain it (teach-back)¶
- How does the Adapter pattern normalize metrics from different source systems?
- Why is "lower is better" handled separately from "higher is better" for health ratings?
- What makes a narrative more useful than a raw number for executives?
- How would you extend this to send reports via email or Slack?
Mastery check¶
You can move on when you can: - add a new MetricSource and see it flow through the pipeline, - explain the trend computation logic and its 5% threshold, - interpret the traffic-light health system (green/yellow/red), - describe how DORA metrics (deploy frequency, lead time, MTTR, change failure rate) map to this system.
Related Concepts¶
| ← Prev | Home | Next → |
|---|---|---|