ratchet-metrics

Reports delivery loop health metrics from GitHub issue timelines using gh CLI.

2|Updated Jun 13, 2026
One-click install
npx skills add https://github.com/praveenvijayan/Ratchet --skill ratchet-metrics-praveenvijayan
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ratchet-metrics
Source: https://github.com/praveenvijayan/Ratchet/tree/main/plugin/skills/ratchet-metrics
Command: npx skills add https://github.com/praveenvijayan/Ratchet --skill ratchet-metrics-praveenvijayan

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve? Teams running a GitHub-native agent delivery loop lack visibility into whether work is actually flowing — how long issues take from ready to merged, how often PRs bounce back for rework, and where the queue is piling up. This Skill answers those questions with a read-only report built from existing GitHub data. ## Core Features & Use Cases - Cycle Time Measurement: Computes median time from an issue reaching state:ready to being closed via merge. - Rework & Stale-Claim Tracking: Reports the share of completed issues that passed through state:changes-requested and counts stale-claim sweeps that requeued abandoned work. - Queue Depth by State: Tallies open issues across state:* labels to expose bottlenecks. - Use Case: A maintainer suspects reviews are the bottleneck. Running the report shows queue depth concentrated in state:in-review, confirming the stall is human review rather than agent execution. ## Quick Start Ask the agent to run the ratchet metrics report to check whether the delivery loop is healthy and where work is stalling.

Frequently Asked Questions about ratchet-metrics

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I measure cycle time for GitHub issues?

Run the ratchet-metrics script from the repo root with a GitHub token set. It reads issue timelines via the gh CLI and reports the median time from an issue reaching state:ready to being closed as completed.

How to track rework rate in a GitHub-based delivery workflow?

The script counts completed issues that passed through the state:changes-requested label at least once and reports that share as the rework rate, using only issue timeline data from GitHub.

Does this metrics report modify my GitHub issues or labels?

No. The report is strictly read-only — it issues GET requests only and never creates, edits, labels, branches, commits, or closes anything. It uses your existing gh auth or a GITHUB_PAT token.

What are the requirements to run the GitHub metrics script?

You need gh CLI authenticated (or GITHUB_PAT set in .env), Node.js version 20 or newer for global fetch, and the scripts/ratchet-metrics.mjs file present at the repository root.

Why does the metrics report say not enough data?

A not enough data line means the repository is too young or has too few completed issues to compute that metric reliably. It is a valid result, not an error, and you can widen the scan window with METRICS_LIMIT.