From 1a60a0cee47696d975e79d49f9e35a2bb6d3434d Mon Sep 17 00:00:00 2001 From: luckyPipewrench Date: Mon, 16 Nov 2026 17:31:54 -0500 Subject: [PATCH] ci: adopt review progress and suggestions --- .github/workflows/agent-review.yaml | 74 +++++++++++++++++++++++++++-- 1 file changed, 69 insertions(+), 5 deletions(-) diff --git a/.github/workflows/agent-review.yaml b/.github/workflows/agent-review.yaml index a0b8136..91fd8f2 100644 --- a/.github/workflows/agent-review.yaml +++ b/.github/workflows/agent-review.yaml @@ -1,16 +1,43 @@ -name: PR-Agent review +name: Agentic review on: - # Default-branch code only; the identity gate and fork admission are tested. + # Commands run on the default branch; inline replies have independent admission. issue_comment: # zizmor: ignore[dangerous-triggers] types: [created] + pull_request_review_comment: # zizmor: ignore[dangerous-triggers] + types: [created] permissions: {} jobs: + acknowledge: + if: >- + (github.event_name == 'issue_comment' && + github.event.action == 'created' && + github.actor == 'luckyPipewrench' && + github.actor_id == '142104046' && + github.run_attempt == '1' && + github.triggering_actor == 'luckyPipewrench' && + github.event.comment.user.login == 'luckyPipewrench' && + github.event.comment.user.id == 142104046 && + github.event.comment.user.type == 'User' && + github.event.comment.author_association == 'MEMBER' && + github.event.issue.pull_request && + contains(fromJSON('["/review","/review deep","/review codex","/review codex deep"]'), github.event.comment.body)) + permissions: + actions: read + contents: read + issues: write + pull-requests: write + uses: pipelab-org/agent-review/.github/workflows/agent-review-reusable.yaml@1aa9741927ec5546036506a0ec764e1b41b1a241 # main + with: + progress_only: true review: + needs: acknowledge if: >- - github.event_name == 'issue_comment' && + !cancelled() && + ( + (github.event_name == 'issue_comment' && github.event.action == 'created' && github.actor == 'luckyPipewrench' && github.actor_id == '142104046' && @@ -21,13 +48,50 @@ jobs: github.event.comment.user.type == 'User' && github.event.comment.author_association == 'MEMBER' && github.event.issue.pull_request && - contains(fromJSON('["/review","/review deep"]'), github.event.comment.body) + contains(fromJSON('["/review","/review deep","/review codex","/review codex deep"]'), github.event.comment.body)) || + (github.event_name == 'pull_request_review_comment' && + github.event.action == 'created' && + github.run_attempt == '1' && + github.actor == github.event.comment.user.login && + github.triggering_actor == github.actor && + github.event.comment.user.type == 'User' && + github.event.comment.in_reply_to_id) + ) permissions: + actions: read contents: read issues: write pull-requests: write - uses: pipelab-org/agent-review/.github/workflows/agent-review-reusable.yaml@856e474c1697f3897ccaa156f083e0b9504196e0 # main + uses: pipelab-org/agent-review/.github/workflows/agent-review-reusable.yaml@1aa9741927ec5546036506a0ec764e1b41b1a241 # main secrets: ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} ANTHROPIC_API_KEY_2: ${{ secrets.ANTHROPIC_API_KEY_2 }} OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} + ORG_MEMBERS_TOKEN: ${{ secrets.ORG_MEMBERS_TOKEN }} + AGENT_REVIEW_LEARNINGS_APP_ID: ${{ secrets.AGENT_REVIEW_LEARNINGS_APP_ID }} + AGENT_REVIEW_LEARNINGS_APP_KEY: ${{ secrets.AGENT_REVIEW_LEARNINGS_APP_KEY }} + cancelled: + needs: [acknowledge, review] + if: >- + cancelled() && + (github.event_name == 'issue_comment' && + github.event.action == 'created' && + github.actor == 'luckyPipewrench' && + github.actor_id == '142104046' && + github.run_attempt == '1' && + github.triggering_actor == 'luckyPipewrench' && + github.event.comment.user.login == 'luckyPipewrench' && + github.event.comment.user.id == 142104046 && + github.event.comment.user.type == 'User' && + github.event.comment.author_association == 'MEMBER' && + github.event.issue.pull_request && + contains(fromJSON('["/review","/review deep","/review codex","/review codex deep"]'), github.event.comment.body)) + permissions: + actions: read + contents: read + issues: write + pull-requests: write + uses: pipelab-org/agent-review/.github/workflows/agent-review-reusable.yaml@1aa9741927ec5546036506a0ec764e1b41b1a241 # main + with: + progress_only: true + progress_cancelled: true