Metrics
Every metric that appears in the Colony Cloud dashboard is listed here with its canonical definition, calculation method, and unit. Tooltip copy in the dashboard is sourced from the same registry (packages/shared/src/metric-definitions.ts) and must match this page exactly.
Pipeline Throughput
Section titled “Pipeline Throughput”Issue-level throughput, cycle time, and quality metrics reported across the selected dashboard window (7 d or 30 d).
| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| Open Issues | All pipeline issues currently being tracked, excluding terminal and paused states. | Count of issues in any state except done and paused. Source: live state counts polled at 3 s cadence. | count |
| In-flight | Issues actively progressing through the pipeline — all non-terminal, non-blocked, non-paused states. Canonical Pipeline scope. | Sum of counts for states: analyzing, planning, ready-for-dev, in-review, changes-requested, merge-pending, waiting-for-subtasks. | count |
| In Progress | Issues shown in the Insights dashboard ‘In Progress’ column — a narrower slice than the Pipeline in-flight count. | Sum of counts for states: dependency-blocked, failure-blocked, waiting-for-subtasks. Intentionally narrower than the Pipeline in-flight scope to reflect the Insights view of active-but-stalled work. | count |
| Blocked | Issues that cannot progress without external intervention. | Sum of counts for states: dependency-blocked, failure-blocked, needs-clarification. | count |
| Awaiting Review | Issues where Colony has opened a PR and is waiting for a human code review. | Count of issues in state human-review-ready. | count |
| Throughput | Number of issues completed (PR merged to the default branch) within the selected window. | Count of issues that transitioned to done state within the window. Source: v1_issue_lifecycle view, issuesCompletedByDay aggregated. | count |
| Cycle Time | Median elapsed time from issue creation to PR merge across issues completed in the selected window. | PERCENTILE_CONT(0.5) WITHIN GROUP (ORDER BY (minutes_issue_to_first_pr + minutes_pr_to_merge)) for issues reaching done state in the window (see the // MetricId: cycle-time anchor in pipeline-metrics-routes.ts). | minutes |
| Success Rate | Percentage of resolved issues that merged successfully, where resolution is defined as merged or paused in the selected window. | Actual SQL: success_count / total_resolved where total_resolved = merged + paused in the window (see the // MetricId: success-rate anchor in pipeline-metrics-routes.ts), expressed as a percentage. Source: weekOverWeek.successRate.current. | percent |
| Review Pass Rate | Fraction of merged PRs that passed code review on the first submission without a changes-requested cycle. | first_pass_approvals / total_merged_prs for the selected window. Source: v1_pr_events, reviewPassRate field. | ratio |
| Time to First PR | Median elapsed time from issue creation to the first PR opened for that issue. | PERCENTILE_CONT(0.5) of (first_pr_opened_at - issue_created_at) for issues in the window. Source: medianTimeToFirstPrMs field. | ms |
| Avg Review Cycles | Average number of review rounds (each changes-requested transition counts as one cycle) before a PR is approved. | AVG(changes_requested_count) per PR for merged PRs in the window. Source: avgReviewCyclesPerPr field. | count |
| PR Revert Rate | Fraction of merged PRs that were subsequently reverted within the tracking window. | reverted_pr_count / total_merged_prs for the selected window. Source: prRevertRate field. | ratio |
| Agent Attribution | Share of merged PRs handled by Colony agents versus human contributors in the selected window. | agent_pr_count / total_merged_prs for the window, split into agent % and human %. Source: /pipeline/attribution API. | ratio |
| Autonomous Merge Rate | Fraction of merged issues completed end-to-end by Colony with no human commits and no changes-requested review cycle. | autonomousIssues / mergedIssues for the selected window, where autonomous = first_pr_merged_at in window AND no changes-requested cycle (MAX(review_cycle_count) = 0 in v1_pr_events) AND all PRs agent-authored (BOOL_AND(effective_is_agent) in v1_agent_attribution). Source: /pipeline/autonomy API, ratePct field. | percent |
LLM token spend tracked at org level for today or a selected window.
| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| Cost today | LLM token spend by Colony agents since midnight UTC today. | Sum of cost_events.amount_usd for the current calendar day (UTC). Source: Cloud DB, refreshed on each poll. | usd |
| Cost | Total LLM token spend across all Colony agents for the selected time window (24h / 7d / 30d / lifetime). | Sum of cost_events.amount_usd within the selected window. Source: /pipeline/cost-summary API (last24hUsd, last7dUsd, last30dUsd, lifetimeUsd fields). | usd |
Queue / DLQ
Section titled “Queue / DLQ”Task queue depth and dead-letter queue health at the org level.
| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| DLQ depth | Number of messages in the dead-letter queue — tasks that failed all retry attempts and require manual resolution. | Count of unresolved rows in the dead_letters table. Source: /api/dead-letters endpoint. | count |
| Pending tasks | Number of pipeline tasks queued but not yet assigned to a Worker. | Count of tasks in the pipeline_tasks table with status pending. Source: /api/queue/depth endpoint, pendingTaskCount field. | count |
| Avg queue wait | Mean elapsed time since task creation for all current pending work tasks. | AVG(waitTimeMs) across pending tasks returned by GET /pipeline/task-queue. | ms |
| Oldest pending age | Elapsed time since the oldest pending task was enqueued. | MAX(waitTimeMs) for tasks with status='pending' in the current result set. | ms |
| Est. duration | Median (p50) historical execution time for tasks of this type in this repository, based on completed work tasks from the last 7 days. | PERCENTILE_CONT(0.5) of (completed_at - claimed_at) in seconds from v1_task_duration_distribution, grouped by (repo_id, executor_ref) over a trailing 7-day window. Only shown when the sample count is ≥ 5. Source: GET /pipeline/task-queue, estimatedDurationMs field per task. Tasks with no history show —. | ms |
| Projected drain | Sum of estimated execution durations for all pending tasks that have historical duration data, giving a rough lower-bound on how long the queue will take to clear. | Sum of estimatedDurationMs across pending tasks where the estimate is non-null. Tasks with no history are excluded from the sum; the hint is hidden when no pending task has an estimate. Source: GET /pipeline/task-queue response. | ms |
| Write queue | Combined count of pending and failed GitHub write projections (label swaps, comments, PR operations) across all repos in the org. | Count of vcs_projections rows with status 'pending' or 'failed' joined to repos belonging to this org. Source: /api/queue/depth endpoint, vcsWriteQueueDepth and vcsWriteQueueFailed fields. | count |
Workers & SI Tracks
Section titled “Workers & SI Tracks”Point-in-time counts for Workers and self-improvement tracks.
| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| Worker count | Number of Colony Worker containers currently registered and reporting heartbeats to the Cloud API. | Count of rows in org_workers with a recent heartbeat. Each Worker handles one pipeline issue at a time. Source: /api/workers endpoint. | count |
| SI Tracks count | Number of self-improvement tracks configured across all repos in the org. | Count of si_tracks rows for the org. A track is overdue if now - last_run_at > cooldown_minutes. Source: /api/si-tracks endpoint. | count |
| Cadence / cooldown | How often a track may run — either a cooldown interval or a fixed cron schedule. | Cooldown tracks re-run once now - last_run_at > cooldown_minutes (stored as cooldownMinutes). Cron tracks run on a fixed schedule defined by a cron expression (stored as cronExpr). Source: /api/si-tracks endpoint, cadenceKind and cooldownMinutes/cronExpr fields. | — |
Retrospectives
Section titled “Retrospectives”Planned-vs-actual analysis over completed issues.
| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| Plan Drift Rate | Fraction of completed issues in the window where the number of files Colony actually touched differed from the number it planned. | (touchedMore + touchedFewer) / totalRetrospectivesWithFileData over the window, from the issue_retrospectives planned-vs-actual file sets. | ratio |
| Outcome Distribution | Share of completed issues by outcome classification (e.g. success / partial / failure) over the window. | COUNT(*) GROUP BY outcome_classification over retrospectives in the window. | count |
Rolling Health KPIs
Section titled “Rolling Health KPIs”Regression-guard signals sourced from pipeline_health_kpis, compared against a rolling baseline window. These are per-repo metrics.
| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| Block Rate | Fraction of issues in the rolling window that transitioned to a blocked state (dependency-blocked or needs-clarification), relative to all issues active in that window. | blocked_count / total_issues over the rolling window from pipeline_health_kpis, compared against a baseline window mean. Regresses when the rate rises — a higher block rate signals increasing pipeline impedance. | ratio |
| Failure-Blocked Rate | Fraction of issues in the rolling window that entered the failure-blocked state (test failures, CI errors, or build failures), relative to all issues active in that window. | failure_blocked_count / total_issues over the rolling window from pipeline_health_kpis, compared against a baseline window mean. Regresses when the rate rises — more CI failures indicate systematic test or build instability. | ratio |
| Mean Cost / Issue | Mean LLM token spend (in USD) per issue completed in the rolling window, tracking cost efficiency of the autonomous pipeline. | AVG(cost_usd_per_issue) for completed issues in the rolling window from pipeline_health_kpis, compared against a baseline window mean. Regresses when the mean rises — increasing per-issue cost indicates the pipeline requires more LLM work per deliverable. | usd |
| Mean Turns / Issue | Mean number of agent turns (LLM round-trips) consumed per issue completed in the rolling window, measuring implementation efficiency. | AVG(turns_per_issue) for completed issues in the rolling window from pipeline_health_kpis, compared against a baseline window mean. Regresses when the mean rises — more turns per issue signals increased difficulty or iterative rework. | count |
| Reimplement Loop Rate | Fraction of issues in the rolling window that triggered a re-implementation cycle (via the /colony:reimplement slash command or automatic re-queue after repeated failure), relative to all issues active in that window. | reimplement_loop_count / total_issues over the rolling window from pipeline_health_kpis, compared against a baseline window mean. Regresses when the rate rises — repeated re-implementations indicate systematic failure in planning or initial development quality. | ratio |
| Dead Letter Rate | Fraction of terminal issues in the rolling window that ended in the dead-letter queue — all retry attempts exhausted without resolution — relative to all terminal issues in that window. | dead_letter_count / terminal_count over the rolling window from pipeline_health_kpis, compared against a baseline window mean. Regresses when the rate rises — more dead-lettered issues indicate the pipeline is unable to autonomously resolve an increasing share of work. | ratio |
Weekly Reliability
Section titled “Weekly Reliability”Per-repo digest metrics computed over the 7-day rolling window. Rendered in the weekly-reliability card on the Digest Notifications settings page — not on the Current Status tab.
| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| Completed | Count of distinct issues that reached ‘done’ state in the 7-day window for this repository. | Count of issues with a done transition in state_transitions within the 7-day window. Source: GET /pipeline/weekly-reliability, completedCount field. | count |
| Recovered | Count of issues that entered a failure or blocked state and subsequently reached completion in the 7-day window. | Count of issues that transitioned through failure-blocked or dependency-blocked and also reached done within the window. Source: GET /pipeline/weekly-reliability, recoveredCount field. | count |
| Cycle p50 | Median (p50) cycle time from first pipeline transition to issue completion, measured in seconds over the 7-day window. | PERCENTILE_CONT(0.5) of (done_at - first_transition_at) in seconds for issues completing in the window. Source: GET /pipeline/weekly-reliability, cycleTime.p50Seconds field. Null when no issues completed. | seconds |
| Cycle p90 | Ninetieth-percentile (p90) cycle time from first pipeline transition to issue completion, measured in seconds over the 7-day window. | PERCENTILE_CONT(0.9) of (done_at - first_transition_at) in seconds for issues completing in the window. Source: GET /pipeline/weekly-reliability, cycleTime.p90Seconds field. Null when no issues completed. | seconds |
| Dead letters | Count of dead-letter events — tasks that exhausted all retry attempts without resolution — generated for this repository in the 7-day window. | Count of rows in dead_letter_transitions for this repo within the window. Source: GET /pipeline/weekly-reliability, deadLetters.count field. | count |
| Retry budget | Retry budget consumption: the number of retry-attempt rows (tasksRetried) and cumulative attempt-index sum (totalRetriesConsumed) across all work tasks in the 7-day window. | Aggregated from work_tasks within the window: tasksRetried = COUNT(*) FILTER (WHERE attempt_count > 0) (the number of times a retry has been attempted; attempt_count is 0-based per migration 055 — 0 = first attempt, each retry inserts a new row); totalRetriesConsumed = SUM(attempt_count) (sum of per-row attempt indices — a weighted retry-pressure measure that over-counts the literal retry-attempt count for multi-retry chains; e.g. a chain with rows at attempt_count 0,1,2 yields totalRetriesConsumed=3 while tasksRetried=2). Source: GET /pipeline/weekly-reliability, retryBudget field. | count |
| Fleet degraded time | Total seconds the fleet spent in degraded mode — at least one Worker reporting a degraded state — during the 7-day window. | Sum of clamped period durations from worker_degraded_periods: EXTRACT(EPOCH) of each interval clamped to the 7-day window, fleet-wide (no tenant scoping), mirroring OSS getWorkerDegradedSeconds. Source: GET /pipeline/weekly-reliability, degradedSeconds field. | seconds |
Cost by Model
Section titled “Cost by Model”Per-model LLM spend and execution quality signals for the selected window.
| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| Model Spend Share | Fraction of total org LLM spend attributable to this model in the selected window. | model_cost / SUM(model_cost) OVER () for cost_events in the window, grouped by model. Source: /pipeline/cost-by-model API, totalCostUsd relative to window total. | percent |
| Max-Turns Rate by Model | Fraction of invocations for this model that hit the agent turn limit, indicating tasks that exceeded the model’s context or reasoning budget. | COUNT(*) FILTER (WHERE is_max_turns = true) / COUNT(*) for execution_telemetry in the window, grouped by model. Source: /pipeline/cost-by-model API, maxTurnsRate field. | percent |
| No-Progress Rate by Model | Fraction of invocations for this model that produced no meaningful code progress, indicating effort consumed without output. | COUNT(*) FILTER (WHERE is_no_progress = true) / COUNT(*) for execution_telemetry in the window, grouped by model. Source: /pipeline/cost-by-model API, noProgressRate field. | percent |
Strategy
Section titled “Strategy”| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| Charter risk envelope (max_auto_size) | The largest track size the Strategist may apply automatically without operator approval, as set in the active strategy charter. | Read from the envelope.max_auto_size field on GET /api/strategy/:owner/:repo/charter. Possible values: small, medium, large, epic. Changes require an explicit charter upsert by an operator. | count |
| Strategy snapshot status | The lifecycle status of a Strategist-proposed strategy snapshot. | Read from the status field on StrategySnapshot returned by GET /api/strategy/:owner/:repo/snapshots. Transitions: proposed → approved → active → superseded. A snapshot must be approved by an operator before it becomes active. | count |
| Automatic weekly proposals | Whether the Strategist runs automatically each week for this repository. | Read from GET /api/strategy/:owner/:repo/automation. When enabled, the Strategist enqueues one strategy proposal per ISO week boundary for repos with an active charter. Cadence is weekly and can be toggled here per repository. | count |
Per-issue SLA tracking based on configured warn_after_minutes thresholds.
| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| SLA breach | An issue has spent longer in its current pipeline state than the configured warn_after_minutes threshold. | elapsed = now - stateEnteredAt in minutes; breached when elapsed ≥ warn_after_minutes[state]. Threshold is set per state in the Pipeline Config SLA Thresholds section. | minutes |
Data Consistency
Section titled “Data Consistency”Cross-store audit findings that surface drift between Postgres pipeline state, dependency edges, SI linkage, and projected GitHub labels.
| Metric | Definition | Calculation | Unit |
|---|---|---|---|
| Data Consistency Findings | Count of unresolved data-consistency audit findings across the org — issues where Postgres pipeline state, dependency edges, SI linkage, or projected GitHub labels have drifted out of agreement. | Count of unresolved findings grouped by kind: stale_blocked, stale_subtask_edge, orphan_missing_from_pg, si_linkage_gap, label_drift. Source: GET /pipeline/consistency. | count |
| Stale Blocked | Issues with is_blocked = true and state != 'done' but no active depends_on dependency edge — the blocked flag is stranded with no actual dependency blocking the issue. | Queries pipeline_issues for is_blocked = true AND state != 'done' with NOT EXISTS an issue_dependencies row where dep_type = 'depends_on' AND status = 'active'. Source: GET /pipeline/consistency, stale_blocked findings. | count |
| Stale Subtask Edge | Active subtask dependency edges whose parent epic has reached done state — dangling edges not cleaned up when the epic completed. | Queries issue_dependencies for dep_type = 'subtask' AND status = 'active', joined to pipeline_issues for the parent epic where state = 'done'. Grouped one finding per epic. Source: GET /pipeline/consistency, stale_subtask_edge findings. | count |
| Orphan (missing from Postgres) | Open GitHub issues that have no corresponding row in pipeline_issues — visible on GitHub but not yet ingested into the pipeline. | Compares open GitHub issue numbers against pipeline_issues for the repo; issues absent from Postgres are flagged. Requires a live GitHub API call — this detector is deferred/optional in Cloud. Source: GET /pipeline/consistency, orphan_missing_from_pg findings. | count |
| SI Linkage Gap | Self-improvement issues in si_issues whose pipeline issue reached done but completed_at is still NULL — the SI completion event was not recorded. | Queries si_issues joined to pipeline_issues where pi.state = 'done' AND si.completed_at IS NULL. Source: GET /pipeline/consistency, si_linkage_gap findings. | count |
| Label Drift | Issues where the Postgres authoritative state (state, is_blocked, is_paused) disagrees with the projected GitHub labels stored in pipeline_issues.labels — done issues excluded. | Queries pipeline_issues where state != 'done' and at least one label disagrees: stateToLabel(state) not in labels, is_blocked mismatches labels.includes(BLOCKED_LABEL), or is_paused mismatches labels.includes(PAUSED_LABEL). Source: GET /pipeline/consistency, label_drift findings. | count |