Skip to content

chore(tools): Add pr-triage workflow for reviewing PR feedback#601

Merged
JeanMertz merged 1 commit intomainfrom
prr169
May 6, 2026
Merged

chore(tools): Add pr-triage workflow for reviewing PR feedback#601
JeanMertz merged 1 commit intomainfrom
prr169

Conversation

@JeanMertz
Copy link
Copy Markdown
Collaborator

The just pr-triage NNN command opens a structured triage session for a pull request's review comments. It attaches the PR's diff and reviews, routes to a new pr-triager persona, and resumes an existing pr-triage:NNN conversation when one is found — keeping context across review cycles without rediscovering the codebase.

Replying to review threads from the triager requires three supporting pieces. jp_github's PullsHandler gains two new GraphQL methods: fetch_thread_id_for_comment maps a REST comment ID to the thread's GraphQL node ID (needed by the reply mutation), and add_review_thread_reply calls addPullRequestReviewThreadReply to queue the reply in the caller's pending review. On top of those, a new github_pr_review_add_reply tool exposes the capability with a parameter formatter that re-fetches the parent comment so the user sees a fresh preview before approving the post.

The gh:pull/N/reviews attachment now surfaces each comment's REST ID as id=<n> in the rendered output, so the triager can pass it directly as comment_id. Pending reviews also show the author's real login instead of the generic "you" — the old label was misleading when a different model triages the same PR under the same credentials.

The rfd-feedback persona is renamed to rfd-triager for consistency with the new naming convention; its instructions are otherwise unchanged.

The `just pr-triage NNN` command opens a structured triage session for a
pull request's review comments. It attaches the PR's diff and reviews,
routes to a new `pr-triager` persona, and resumes an existing
`pr-triage:NNN` conversation when one is found — keeping context across
review cycles without rediscovering the codebase.

Replying to review threads from the triager requires three supporting
pieces. `jp_github`'s `PullsHandler` gains two new GraphQL methods:
`fetch_thread_id_for_comment` maps a REST comment ID to the thread's
GraphQL node ID (needed by the reply mutation), and
`add_review_thread_reply` calls `addPullRequestReviewThreadReply` to
queue the reply in the caller's pending review. On top of those, a new
`github_pr_review_add_reply` tool exposes the capability with a
parameter formatter that re-fetches the parent comment so the user sees
a fresh preview before approving the post.

The `gh:pull/N/reviews` attachment now surfaces each comment's REST ID
as `id=<n>` in the rendered output, so the triager can pass it directly
as `comment_id`. Pending reviews also show the author's real login
instead of the generic "you" — the old label was misleading when a
different model triages the same PR under the same credentials.

The `rfd-feedback` persona is renamed to `rfd-triager` for consistency
with the new naming convention; its instructions are otherwise
unchanged.

Signed-off-by: Jean Mertz <git@jeanmertz.com>
@JeanMertz JeanMertz merged commit 9b83cab into main May 6, 2026
13 checks passed
@JeanMertz JeanMertz deleted the prr169 branch May 6, 2026 08:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant