rea-analysis-optimization
MOmorluto/rea485k9,215 new stars in the last 7 days
Implements triaged review actions, commits focused fixes, and posts Done plus resolves threads. Use when the user wants only the implementation phase of the review-framework workflow.
Run only the implementation phase of the review-framework loop:
take triaged will_address actions, make code changes, commit in logical steps, post GitHub status updates, and update action status.
Run commands from this skill directory. All script paths below are relative to it.
review-actions.json in output dirIf output directory is omitted, derive:
wip/reviews/<owner>_<repo>_pr-<number>/
<output-dir>/review-actions.json must exist and be valid v2.
System dependencies required on PATH:
node (Node.js)gh (GitHub CLI)If either is missing, halt immediately and ask the user to install it. The implement-phase scripts require only node and gh.
GitHub admin capability must be available before starting implementation:
node ./scripts/check-github-admin-ready.mjs --pr <PR_URL>
If missing, instruct user to run:
/review-fetch-phase <PR_URL> [output-dir]/review-triage-phase <PR_URL> [output-dir]decision: will_addressstatus: pending | in_progresscheck-github-admin-ready.mjs and fail fast if unavailablegh pr review --comment ...addPullRequestReview, addPullRequestReviewComment, addPullRequestReviewThread (this workflow never uses pending reviews)addPullRequestReviewThreadReply (or wrapper script)addComment (or wrapper script)gh api graphql -f query='query($owner:String!,$repo:String!,$pr:Int!,$before:String){viewer{login} repository(owner:$owner,name:$repo){pullRequest(number:$pr){reviews(last:100,states:PENDING,before:$before){pageInfo{hasPreviousPage startCursor} nodes{id author{login}}}}}}' -F owner=<owner> -F repo=<repo> -F pr=<number> --jq '.data as $d | $d.repository.pullRequest.reviews | {mine: [.nodes[] | select(.author.login == $d.viewer.login)], pageInfo}'author.login filter matters: another user's pending review is not yours to submit or dismiss, and must not block this workflow. --jq is gh's built-in filter and needs no jq binary.pageInfo beside the matches, because an empty mine alone cannot tell "no pending review" from "the match is on an earlier page". Read both: while mine is empty and pageInfo.hasPreviousPage is true, re-run the query with -f before=<pageInfo.startCursor>. Conclude there is no pending review only when mine is empty and hasPreviousPage is false.mine holds at most one node across all pages.pageInfo until mine is non-empty or hasPreviousPage is false.review_thread targets, always reply using thread replies (never inline PR review comments).
addPullRequestReviewThreadReply.pull_request_review targets (review-body findings, PRR_… node ids), inline replies are not possible. post-review-thread-reply.mjs auto-detects this and posts a top-level PR issue comment instead (response kind: "issue_comment"); there is no thread to resolve, so the implementer skips resolve-review-thread.mjs for these and records the issue-comment id in the action's done record../agents/review-implementer.mdtarget.kind === "review_thread" and a threadNodeId is available. pull_request_review targets have no inline thread, so the implementer skips the resolve step for them and records the issue-comment id in the action's done record (per behavior step 3).node ./scripts/post-review-thread-reply.mjs --repo <owner>/<repo> --pr <number> --comment-node-id <primaryCommentNodeId> --body "<text>" (works for both review_thread and pull_request_review — auto-detects node kind)node ./scripts/resolve-review-thread.mjs --thread-node-id <threadNodeId> (only for review_thread targets)python -c, node -e, ruby -e, ad-hoc awk/sed JSON parsing)status: done after Done (and, for review_thread targets, resolve) succeedsreview-actions.json (status, done.doneAt, done.summary, done.commits) in the same completion stepnode ../review-triage-phase/scripts/render-review-actions.mjs --in <output-dir>/review-actions.json --out <output-dir>/review-actions.md
Return:
review-actions.json, review-actions.md)Suggest next steps:
/review-fetch-phase <PR_URL> [output-dir]/review-triage-phase <PR_URL> [output-dir]MOmorluto/rea485k9,215 new stars in the last 7 days
MAmattpocock/skills336k5,004 new stars in the last 7 days
Diagnose hard bugs and performance regressions by building a feedback loop with tests or scripts.
MAmattpocock/skills336k5,004 new stars in the last 7 days
MAmattpocock/skills336k5,004 new stars in the last 7 days
MAmattpocock/skills336k5,004 new stars in the last 7 days
MAmattpocock/skills336k5,004 new stars in the last 7 days