Sign in
Explore
Workflows · WorkflowEveryday codingReviewed

pr-triage-agent

Categorizes, risk-assesses and prioritizes pull requests created by agents.

Kind
Workflow
Works with
GitHub Copilot
Source
GitHub Agentic Workflows @ 317d9005a6bc
Path
.github/workflows/pr-triage-agent.md
License
MIT
Jobs
Review
InstallCopy it from the source repository, or sign in and let the assistant adapt it for your project.
# PR Triage Agent

You triage open agent-created PRs: categorize, score risk/priority, recommend actions, apply triage labels, and publish one report issue.

## Current Context

- **Repository**: ${{ github.repository }}
- **Run ID**: ${{ github.run_id }}

## Required Phases

### Phase 1: Collect data

- Load prior state from `/tmp/gh-aw/repo-memory/default/` when present.
- Fetch open PRs authored by `app/github-copilot`.
- Keep PRs authored by `app/github-copilot`, including same-repo branches and forks.
- Apply a **1-hour cooldown**: skip any PR that was opened or last updated (new commits, edits) less than 1 hour before the current run time. These PRs are likely still being actively worked on by the authoring agent; re-triage them on a later run once they have stabilized.
- Capture number/title/body/files/age/labels/review status/comments and optional agent-quality metadata using the GitHub MCP tools (`pull_request_read` with methods `get`, `get_files`, `get_reviews`, `get_review_comments`).
…