Agent skill

Watch PR

by ayutaz in ayutaz/piper-plus

PR push 直後 / PR 作成後の auto chain (/create-pr のフェーズ 6.2 から発動) / CI 監視 / レビュー対応 / merge 前確認 の文脈で発動。gh pr checks を一度 polling し green / red / pending を集計、 red なら失敗 job のログを fetch して「format drift / test…

MITAuto-check passedDevelopment

Install Watch PR

skills CLI
$ npx skills add ayutaz/piper-plus --skill watch-pr -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install ayutaz/piper-plus watch-pr --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/ayutaz/piper-plus.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/watch-pr .claude/skills/watch-pr && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
watch-pr
GitHub stars
230
Token cost
~2k tokens
SKILL.md length
724 words
Files
1
Skills in repo
20
Repo updated
First seen
Licence
MIT

At a glance

PR push 直後 / PR 作成後の auto chain (/create-pr のフェーズ 6.2 から発動) / CI 監視 / レビュー対応 / merge 前確認 の文脈で発動。gh pr checks を一度 polling し green / red / pending を集計、 red なら失敗 job のログを fetch して「format drift / test…

  • Works in 4 steps: job 名と link を表示 → gh run view --log-failed で失敗 step のログを… → ログを以下の pattern で分類 → …
  • Tasks that involve Pull requests
  • SKILL.md covers 引数, 実行前の確認, 手順 and 継続監視モード, plus 3 more sections
  • Calls gh, git and cargo

What it does

Watch PR is an agent skill from ayutaz/piper-plus. PR push 直後 / PR 作成後の auto chain (/create-pr のフェーズ 6.2 から発動) / CI 監視 / レビュー対応 / merge 前確認 の文脈で発動。gh pr checks を一度 polling し green / red / pending を集計、 red なら失敗 job のログを fetch して「format drift / test fail / build error / flake / contract drift」に分類。 同時に unresolved review thread (人間 / Copilot) も集計し、 安全カテゴリ (stale / Copilot style ノイズ) は /reply-review --auto-safe を auto chain で起動して reply + resolve まで自動完了。 人間 reviewer / blocker 候補は user 判断のため提示のみ。 /loop /watch-pr <PR で継続監視に使える。

Its SKILL.md is about 2k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Pull requests. The repository describes itself as: Multilingual neural TTS (6 languages: JA/EN/ZH/ES/FR/PT, code supports SV) — C++, C, Rust, Go, Python, npm (WASM). VITS + Prosody, streaming, CUDA/CoreML/DirectML. pip install…. The licence is MIT.

When your agent uses it

  • Tasks that involve Pull requests

Example prompts

  • “/watch-pr”

Requirements

  • Pre-approved tools (allowed-tools): Bash(gh pr checks *), Bash(gh pr view *), Bash(gh run view *), Bash(gh api *), Bash(git rev-parse *), Bash(git branch *), Read, Grep, Skill

Workflow steps

4 steps, taken from the first numbered list in SKILL.md.

  1. job 名と link を表示
  2. gh run view --log-failed で失敗 step のログを fetch (最大 100 行)
  3. ログを以下の pattern で分類
  4. 分類別に推奨アクションを提示

What it can do on your machine

Read from SKILL.md and the folder at commit 421d066. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Bash(gh pr checks *)
    • Bash(gh pr view *)
    • Bash(gh run view *)
    • Bash(gh api *)
    • Bash(git rev-parse *)
    • Bash(git branch *)
    • Read
    • Grep
    • Skill

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • gh
    • git
    • cargo
    • dotnet

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use gh and git, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Watch PR loads about 2k tokens when it runs. Until then it costs about 123 tokens; SKILL.md has 724 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~123
When it runs · the whole SKILL.md, loaded when a task matches
~2k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from ayutaz/piper-plus at commit 421d066, republished under its MIT licence (© ayutaz). 724 words, ~1,994 tokens.

Download SKILL.mdSave it as .claude/skills/watch-pr/SKILL.md (or your agent's skills folder).
name
watch-pr
description
PR push 直後 / PR 作成後の auto chain (`/create-pr` のフェーズ 6.2 から発動) / CI 監視 / レビュー対応 / merge 前確認 の文脈で発動。`gh pr checks` を一度 polling し green / red / pending を集計、 red なら失敗 job のログを fetch して「format drift / test fail / build error / flake / contract drift」に分類。 同時に unresolved review thread (人間 / Copilot) も集計し、 安全カテゴリ (stale / Copilot style ノイズ) は `/reply-review --auto-safe` を auto chain で起動して reply + resolve まで自動完了。 人間 reviewer / blocker 候補は user 判断のため提示のみ。 `/loop /watch-pr <PR>` で継続監視に使える。
allowed-tools
Bash(gh pr checks *), Bash(gh pr view *), Bash(gh run view *), Bash(gh api *), Bash(git rev-parse *), Bash(git branch *), Read, Grep, Skill
argument-hint
[pr-number]
disable-model-invocation
false

PR CI Status Watcher

PR の CI checks を 1 回ポーリングして状態を集計する skill。継続監視は /loop と組み合わせる:

text
/loop /watch-pr 489       # 5 分間隔で polling、red/green/timeout で通知
/watch-pr                 # 引数省略時は現在ブランチに紐づく PR を自動検出

引数

  • $1 (任意): PR 番号 (例: 489)。省略時は gh pr view --json number で現在ブランチから自動取得

実行前の確認

  • ブランチ: !git rev-parse --abbrev-ref HEAD
  • 引数: $ARGUMENTS

手順

フェーズ 1: PR 番号の確定

引数 $1 がない場合、現在ブランチに紐づく PR を取得:

bash
PR_NUM=$(gh pr view --json number --jq '.number' 2>/dev/null)

該当 PR がない場合 (= まだ push していない / PR 未作成) は、その旨をユーザーに報告して停止。

フェーズ 2: CI checks の一括取得
bash
gh pr checks "$PR_NUM" --json name,state,conclusion,link --jq '.[]'

各 check は以下の状態のいずれか:

  • state: QUEUED / IN_PROGRESS / COMPLETED
  • conclusion (COMPLETED 時のみ): SUCCESS / FAILURE / CANCELLED / SKIPPED / NEUTRAL / TIMED_OUT / ACTION_REQUIRED
フェーズ 3: 集計とサマリ

以下のテーブルでサマリを表示 (件数は実際の集計値):

text
## PR #<N> CI Status (<HH:MM:SS>)

| State        | Count |
|--------------|-------|
| ✅ Success   | <n>   |
| ❌ Failure   | <n>   |
| 🔁 Pending   | <n>   |
| ⏭️ Skipped   | <n>   |
| ⚠️ Cancelled | <n>   |

Total: <total> checks

判定ルール:

  • All green (failure=0, pending=0, cancelled=0): 「全 N checks green、merge 可能状態」
  • Red (failure ≥ 1): フェーズ 4 へ
  • Pending (queued/in_progress ≥ 1): 「N checks がまだ走行中、再度 polling を推奨」
  • Suspicious skip (cancelled+skipped が 3 件以上連続): silent skip の可能性を警告 (PR #419 事例)
フェーズ 4: 失敗 job の分析 (failure ≥ 1 時のみ)

各失敗 job について:

  1. job 名と link を表示
  2. gh run view <run-id> --log-failed で失敗 step のログを fetch (最大 100 行)
  3. ログを以下の pattern で分類:
    • Format drift: ruff cargo fmt gofmt dotnet format clippy 系のエラー → ローカル pre-commit run --all-files で修復可能
    • Test fail: FAILED assert panicked expected 系 → どのテストかを抽出
    • Build error: error[E0 cannot find undefined reference 系 → コンパイルエラー
    • Flake: timeout network connection reset rate limit 系 → 一過性、retry 推奨
    • Contract drift: MISMATCH OUT OF SYNC byte-for-byte 系 → 該当 check-* skill を案内
  4. 分類別に推奨アクションを提示
フェーズ 5: Unresolved review thread の集計

CI status とは独立で、 review コメント / Copilot 指摘が未解決のまま残っていないか を毎回チェック。 /check-review-backlog --pr <PR> 相当の GraphQL を呼ぶ:

bash
gh api graphql -f query='
query($owner: String!, $name: String!, $number: Int!) {
  repository(owner: $owner, name: $name) {
    pullRequest(number: $number) {
      reviewThreads(first: 50) {
        nodes {
          isResolved
          isOutdated
          comments(first: 1) {
            nodes {
              author { login }
              path
              body
              createdAt
            }
          }
        }
      }
    }
  }
}' -F owner=ayutaz -F name=piper-plus -F number="$PR_NUM" --jq \
'.data.repository.pullRequest.reviewThreads.nodes
 | map(select(.isResolved == false))
 | length, map(select(.isResolved == false))[]'

集計:

  • Unresolved 0 件: review 障害なし、 next phase へ
  • Unresolved ≥ 1 件:
    • reviewer 別 (human / Copilot bot) に分類

    • stale check: 該当 file がそのコメント以降に修正済みか (memory feedback_copilot_stale_review)

    • 提案テーブル形式で表示:

      text
      ## Unresolved Review Threads (#<PR>)
      
      | # | Reviewer | Path | Stale? | 提案 |
      |---|----------|------|--------|------|
      | 1 | Copilot  | src/foo.py:42 | ✓ stale (b7e71c8 以降に更新済) | dismiss / reply |
      | 2 | yousan   | src/bar.rs:88 | new | 修正 → `/reply-review <PR>` |
フェーズ 5.5: 安全カテゴリの自動 reply + resolve (auto-chain)

Unresolved review thread が 1 件以上ある場合、 必ず/reply-review <PR> --auto-safe を Skill tool で chain 起動する。 これにより以下が自動処理される (フェーズ 1.9 参照、 SAFE-stale / SAFE-copilot-style の 2 カテゴリ):

  • SAFE-stale: コメント以降に該当 file が更新済 → 「修正済 (commit <hash>)」 reply + resolve
  • SAFE-copilot-style: Copilot bot の style noise (^Consider (using|renaming)\b 等) → 「style 提案は本 PR の scope 外」 reply + resolve

--auto-safe は SAFE 系のみ実行、 REVIEW-human / REVIEW-copilot-blocker は 内部で dry-run 扱いとなり提示のみ。 これにより:

  • ユーザの介入なく Copilot のノイズコメントと stale 指摘を片付ける
  • 人間 reviewer の本質的な指摘と Copilot の logic / security 指摘は user 判断に残す
  • memory feedback_pr_body_over_comments (PR body 改変ルール) は review thread reply には適用外、 feedback_merge_caution (merge 前確認) も merge ≠ resolve のため抵触しない

skill 呼び出し:

text
Skill({skill: "reply-review", args: "<PR_NUM> --auto-safe"})

戻り値の reply / resolve カウントを次フェーズの判定材料にする。

フェーズ 6: 次のアクション提案
状態推奨アクション
All green + Unresolved 0 (自動 resolve 後含む)/check-pr-ready で最終確認、 user 確認後に merge (gh pr merge --auto 禁止)
All green + REVIEW 残 ≥ 1 (自動処理外)user に judge を促し、 修正コミット後再度 /loop /watch-pr <PR>
Red (format drift)pre-commit run --all-files をローカル実行、修正後 /commit
Red (test fail)該当テストファイル名を提示、/run-tests <scope> で再現
Red (build error)エラーログを示してユーザーに方針確認
Red (flake)gh run rerun <run-id> --failed を提示 (ユーザー確認後実行)
Red (contract drift)/check-pua /check-loanword 等の該当 skill を提示
Pending/loop /watch-pr <PR> で継続監視 (auto-safe は次回 iteration でも走る)
Show full SKILL.md (262 more words)Show less

継続監視モード

ユーザーが「green になるまで監視して」と希望する場合:

text
/loop /watch-pr <PR>

/loop skill が /watch-pr <PR> を再帰的に呼び出す。 各 iteration で本 skill が CI + review thread を両方確認。 終了条件:

iteration の結果アクション
All green + Unresolved 0ユーザーに完了通知して /loop を終了
All green + Unresolved ≥ 1フェーズ 5.5 で /reply-review --auto-safe を chain 起動。 SAFE 系は自動 reply + resolve、 残った REVIEW 系を user に提示して /loop を終了
Red (本物)失敗分析を表示して /loop を終了 (人間判断が必要)
Red (flake のみ)gh run rerun --failed を提案 (確認後実行)、 ループは継続
Pending次の polling 間隔まで sleep (自動 pace は CI 状況で 4-20 分、 cache TTL の都合で IN_PROGRESS 多い時は delaySeconds=270、 落ち着いた状態なら 1200+)。 各 iteration でも review thread の auto-safe chain は走る

SAFE 系 review thread の自動 reply + resolve は本 skill のフェーズ 5.5 で行う。 REVIEW-human / REVIEW-copilot-blocker は memory feedback_pr_body_over_comments / feedback_merge_caution 遵守のため user 判断に委ね、 修正後にユーザが明示的に /reply-review <PR> を起動する形。

注意事項

  • 無限ループ防止: 4 時間以上 pending が続くケースは /loop を終了して人間に確認を促す
  • rate limit: GitHub API は 5000 req/hour、 ポーリング間隔を 1 分未満にしない
  • silent skip: cancelled+skipped が連続 3 以上は path filter による意図的 skip かもしれないが、 PR #419 事例のように baseline が silent に skip されることがあるので警告
  • 失敗ログ取得失敗時: gh run view が 404 を返す場合 (job がまだ完了していない等) はスキップ
  • merge は user-only: 本 skill から gh pr merge を実行することは禁止 (memory feedback_merge_caution に従う)
  • review reply は SAFE 系のみ自動: フェーズ 5.5 で /reply-review --auto-safe を chain 起動。 SAFE-stale / SAFE-copilot-style だけ自動 reply + resolve。 REVIEW-human / REVIEW-copilot-blocker は user 判断のため /reply-review <PR> 明示起動を待つ
  • 自動コード修正は行わない: review 指摘で「コードを直す」 必要があるものは user 判断。 stale (既に修正済) / Copilot ノイズ (style 提案) のみ自動 reply で完結
  • Copilot stale 検出: review コメント以降に同 file が更新済なら stale フラグ付き提示 (memory feedback_copilot_stale_review)。 自動 reply の core ロジック

使用例

text
# 現在ブランチの PR を 1 回チェック
/watch-pr

# PR #489 を 1 回チェック
/watch-pr 489

# 5 分間隔で継続監視 (loop skill が pace 決定)
/loop /watch-pr 489

# 固定 5 分間隔
/loop 5m /watch-pr 489

期待効果

  • ユーザーが 7 ランタイム × ~94 jobs の CI を手動で gh pr checks ポーリングする手間を削減
  • red 時に「どの分類の失敗か」即座に分類することで対応時間を短縮
  • silent skip (PR #419 type) の早期検出

© ayutaz, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .claude/skills/watch-pr of ayutaz/piper-plus.

Open the folder on GitHubat commit 421d066

Compare with similar skills

Watch PR next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Watch PR compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Watch PR this skillayutaz/piper-plus230—~2kAutomated safety check: PassMIT
Finishing a Development Branchobra/superpowers297k5 repos~1.9kAutomated safety check: PassMIT
PR Babysitteropeninterpreter/openinterpreter69k3 repos~4.2kAutomated safety check: PassApache-2.0
Check PRonyx-dot-app/onyx32k2 repos~2.3kAutomated safety check: PassMIT
PR Design DocOpenHands/OpenHands90k—~2.4kAutomated safety check: PassMIT
WooCommerce Code Reviewwoocommerce/woocommerce11k3 repos~1.1kAutomated safety check: PassCustom licence

Similar skills

  • Walks the last step of a branch: confirm tests pass, detect the git environment, ask how to integrate, carry out your choice and clean up the worktree.

    297k GitHub starsUsed in 5 repos~1.9k tokens
    DevelopmentAuto-check passed
  • PR Babysitter

    openinterpreter/openinterpreter

    Watches an open GitHub pull request until it merges, handling review comments, diagnosing CI failures and retrying flaky checks along the way.

    69k GitHub starsUsed in 3 repos~4.2k tokens
    DevelopmentAuto-check passed
  • Check PR

    onyx-dot-app/onyx

    Checks a GitHub, GitLab, or Perforce (p4) pull request (or merge request, or shelved changelist) for unresolved review comments, failing status checks, and incomplete PR descriptions.

    32k GitHub starsUsed in 2 repos~2.3k tokens
    DevelopmentAuto-check passed
  • PR Design Doc

    OpenHands/OpenHands

    For a non-trivial pull request, write a self-contained HTML design doc under the temporary .pr/ directory and link a visibility-appropriate preview in the PR description, so maintainers grasp the…

    90k GitHub stars~2.4k tokensUpdated today
    DevelopmentAuto-check passed
  • WooCommerce Code Review

    woocommerce/woocommerce

    Reviews WooCommerce code changes against the project's standards, flagging backend PHP architecture, naming, documentation, data integrity and testing violations.

    11k GitHub starsUsed in 3 repos~1.1k tokens
    DevelopmentAuto-check passed
  • Record PR Demo

    payloadcms/payload

    A skill your agent uses when a Payload pull request needs a concise visual walkthrough for reviewers.

    45k GitHub stars~1k tokensUpdated today
    DevelopmentAuto-check passed

More from ayutaz/piper-plus

All 20 skills in this repo
  • Skill Health

    ayutaz/piper-plus

    .claude/skills//SKILL.md の frontmatter / referenced script 実在 / trigger 衝突 / .claude/hooks/.sh の executable+shebang を検査する meta-skill。

    230 GitHub stars~626 tokensUpdated today
    Auto-check passed
  • Bump Deps

    ayutaz/piper-plus

    ORT / openjtalk / ruff のような cross-runtime に canonical sync が必要な依存関係を 1 コマンドで bump する read-mostly skill。

    230 GitHub stars~1.2k tokensUpdated today
    Auto-check passed
  • Check Cross Runtime

    ayutaz/piper-plus

    Python canonical (src/pythonrun/piperplus/, src/python/pipertrain/, src/python/g2p/piperplusg2p/) を変更した PR で、 ONNX I/O 以外の追随漏れ (phonemizer / config schema / CLI flag / data 形式 / API 変更) を 7 ランタイム +…

    230 GitHub stars~3.5k tokensUpdated today
    Auto-check passed
  • Check Loanword

    ayutaz/piper-plus

    ZH-EN code-switching loanword の同期と forward-compat を 1 コマンドで検査。zhenloanword.json を編集したり 5 ランタイムのいずれかに新規エントリを追加する前後に呼ぶ。Python source を canonical とし、Rust×2 / Go / C / WASM / C++ の 6 mirror + Python…

    230 GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Check New Runtime Asset

    ayutaz/piper-plus

    新規データアセット (JSON/TOML) を追加した PR で「7 箇所の package metadata 更新が全て揃っているか」を 1 コマンドで確認。MANIFEST.in / pyproject package-data / Cargo features / npm files / C Content / Android assets / SPM resources の更新漏れを…

    230 GitHub stars~964 tokensUpdated today
    Auto-check passed
  • Check PR Ready

    ayutaz/piper-plus

    PR 作成前の最終チェックリスト (lint/test/docs/CHANGELOG/未コミット確認)。/precheck の拡張版で、ドキュメント整合性も検証します。

    230 GitHub stars~687 tokensUpdated today
    Auto-check passed

Categories

Questions about Watch PR

What does Watch PR do?

PR push 直後 / PR 作成後の auto chain (/create-pr のフェーズ 6.2 から発動) / CI 監視 / レビュー対応 / merge 前確認 の文脈で発動。gh pr checks を一度 polling し green / red / pending を集計、 red なら失敗 job のログを fetch して「format drift / test…. Watch PR is an agent skill from ayutaz/piper-plus.

When should I use Watch PR?

Watch PR fits situations like: tasks that involve Pull requests.

How do I install Watch PR in Claude Code?

Run `npx skills add ayutaz/piper-plus --skill watch-pr -a claude-code`. Or copy the skill folder (.claude/skills/watch-pr in ayutaz/piper-plus) into .claude/skills/watch-pr in your project. Claude Code loads it when a task matches its description.

How do I install Watch PR in Codex?

Run `npx skills add ayutaz/piper-plus --skill watch-pr -a codex`. Or copy the skill folder (.claude/skills/watch-pr in ayutaz/piper-plus) into .agents/skills/watch-pr in your project. Codex loads it when a task matches its description.

Can I use Watch PR in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add ayutaz/piper-plus --skill watch-pr -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/watch-pr, .gemini/skills/watch-pr, .github/skills/watch-pr and .opencode/skills/watch-pr in your project.

What does Watch PR need to run?

Going by SKILL.md and its folder, Watch PR needs the command-line tools its instructions call (gh, git, cargo and dotnet). Its frontmatter pre-approves these tools: Bash(gh pr checks *), Bash(gh pr view *), Bash(gh run view *), Bash(gh api *), Bash(git rev-parse *), Bash(git branch *), Read, Grep, Skill.

Does Watch PR access the network?

SKILL.md contains no URLs. Its commands use gh and git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Watch PR safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Watch PR use?

Watch PR is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Watch PR use?

About 2k tokens (SKILL.md is roughly 8k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Watch PR?

Skills that share tags, products or a category with Watch PR: Finishing a Development Branch (obra/superpowers, 297k stars), PR Babysitter (openinterpreter/openinterpreter, 69k stars), Check PR (onyx-dot-app/onyx, 32k stars) and PR Design Doc (OpenHands/OpenHands, 90k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Watch PR?

ayutaz (a GitHub user) maintains it in ayutaz/piper-plus, which has 230 GitHub stars. The repository holds 20 skills in this directory. The repository was last updated on October 8, 2026.

Source: ayutaz/piper-plus on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.