ci-triage

ci-triage is a command for Claude Code from openshift-online/gcp-hcp. It costs 16 tokens per session (452 once invoked), scanned A, original, Apache-2.0.

A command that checks a pull request's continuous-integration (CI) tests, which automatically verify code changes. It finds blocking failures, fixes them, and retests flaky checks.

In plain words
What is it for?
Use it to diagnose and fix lint, build, unit-test, verification, or security failures, and to rerun flaky end-to-end or integration tests. It can make one pass or keep checking until the pull request is green.
Why use it?
It removes the manual work of reading CI logs, deciding which failures matter, and rerunning unreliable tests.

Command for Claude Code

Written for Claude Code: user-invocable in frontmatter.

Part of the gcp-hcp plugin — 4 skills, 2 commands, 2 agents shipped together

Good fit Use it to diagnose and fix lint, build, unit-test, verification, or security failures, and to rerun flaky end-to-end or integration tests. It can make one pass or keep checking until the pull request is green.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/openshift-online/gcp-hcp/ci-triage
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/openshift-online/gcp-hcp

Made for: Claude Code.

Or install gcp-hcp, the plugin that ships this one along with the rest of its 4 skills, 2 commands, 2 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ci-triage

README.md
[![agentmods](https://agentmods.dev/badge/commands/openshift-online/gcp-hcp/ci-triage/github.svg)](https://agentmods.dev/commands/openshift-online/gcp-hcp/ci-triage)
Your own site
<a href="https://agentmods.dev/commands/openshift-online/gcp-hcp/ci-triage"><img src="https://agentmods.dev/badge/commands/openshift-online/gcp-hcp/ci-triage/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ci-triage

Your own site · 80×15
<a href="https://agentmods.dev/commands/openshift-online/gcp-hcp/ci-triage"><img src="https://agentmods.dev/badge/commands/openshift-online/gcp-hcp/ci-triage.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 16 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 452 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00016 $0.00452
Opus 5 $0.00008 $0.00226
Sonnet 5 $0.00003 $0.00090
Haiku 4.5 $0.00002 $0.00045

Measured 9d ago against content hash f53187564e1c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

ci-triage scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

claude-plugin/gcp-hcp/commands/ci-triage.md · 45 lines

What it actually says

Invoke the ci-triage agent using the Task tool with subagent_type="ci-triage".

Pass the following context to the agent:

  • PR number: Parse from $ARGUMENTS if provided, otherwise detect from current branch
  • Execution mode: If $ARGUMENTS contains "watch", "until green", "until all pass", or "keep trying", use watch mode

What It Does

  1. Fetches all CI check statuses
  2. Dynamically classifies checks into Tier 1 (blocking) and Tier 2 (e2e/integration)
  3. If Tier 1 tests fail (verify, unit, lint, build, security):
    • Analyzes logs to find root cause
    • Fixes the issues locally
    • Commits and pushes the fix
  4. If only Tier 2 (e2e/integration) tests fail:
    • Checks if failures are flaky (infrastructure issues, timeouts)
    • If flaky, triggers retests using the repo-appropriate mechanism
    • If real failure, reports details for investigation

Execution Modes

Single Pass (default): Run once, fix/retest, report status

Watch Mode: Run continuously until all tests pass

  • Polls CI status every 2-3 minutes
  • Automatically fixes new failures and retests flaky tests
  • Exits when all green or max iterations (10) reached

Examples

/gcp-hcp:ci-triage                          # Single pass on current branch's PR
/gcp-hcp:ci-triage 7631                     # Single pass on PR #7631
/gcp-hcp:ci-triage 7631 watch until green   # Watch mode until all pass
/gcp-hcp:ci-triage run until all pass       # Watch mode on current PR

$ARGUMENTS

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 45 lines · 16 tokens per session scan A f53187564e1c

Subscribe to this mod's changes

ci-triage is a command published in the GitHub repository openshift-online/gcp-hcp (2 stars, last pushed yesterday), licensed Apache-2.0. It adds 16 tokens to every session and 452 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.