Module release_cadence
Expand description
Release-cadence analysis — inter-release gap statistics from git tags.
§What it measures
Tags are a proxy for releases, not deployments. A team that cuts hotfix tags frequently will show short gaps; a team with long-lived release branches will show large gaps. The trend signal (accelerating / stable / slowing) helps detect drift in release velocity over time without requiring any external ticketing or deployment data.
§Algorithm
- Fetch all tags via
Repo::tags(sorted ascending by date). - Filter to names matching
opts.release_tag_glob(defaultv*). - Compute
days_since_prevfor each tag as the float difference between consecutive tag dates. The first tag hasNone. - Compute summary statistics over the gap series:
- median (middle gap for odd N; average of two middle for even N).
- IQR (Q3 − Q1; P75 − P25 by linear interpolation).
- trend: sign of the ordinary-least-squares slope fitted to the
gap sequence (x = 0-based index, y = days), judged relative to the
repo’s own median gap (see [
TREND_SLOPE_FRACTION]) rather than an absolute day count — a slope whose magnitude exceedsTREND_SLOPE_FRACTION * medianis a meaningful trend: positive →"slowing", negative →"accelerating", within the threshold →"stable". Scale-relative because a fixed absolute cutoff conflates a yearly-cadence repo with a two-day-cadence one — the same 1-day slope drift is noise for the former and a real trend for the latter. See [classify_trend].
- Emit per-tag rows sorted by date ascending, then a synthetic
tag = "__summary__"row carrying median, IQR, and trend in thedays_since_prevfield (median) and thedatefield (IQR as a formatted string) andtrendfield. SeeReleaseCadenceRowdocs.
Structs§
- Release
Cadence Row - One tag in the release timeline, plus a synthetic summary row.
Functions§
- run_
release_ cadence - Run the release-cadence analysis.