AgentFlows
Multi-agentLabelNot executed· 3 caveats

Label-driven dev loop: triage → plan → implement → red-team → human merge

issues/pull_request: labeled

Mirrors Greg's Trailside Dev Loop labels. Different vendors for author vs red-team reduce shared blind spots. Human gates: adding `ready` approves the plan; merge is manual.

Estimated cost per run

~$0.40–$2.50 per issue end to end (ASSUMPTION)

Estimated, not measured.

Basis. Sum of stages: triage ~2 min, plan ~5 min, implement ~15 min, red-team ~6 min of runner at $0.006/min GitHub-hosted Linux 2-core (docs.github.com/en/billing/reference/actions-runner-pricing), plus ASSUMED ~350k input / 35k output Claude tokens at Claude Sonnet 5 API $2/MTok in, $10/MTok out (platform.claude.com/docs/en/about-claude/pricing) and an unquantified Codex review. Not measured.

Verification

Last checked Oct 16, 2026.

inputs checked against source docs; workflow not executed.

Open caveats

  • IMPORTANT: labels added with the default GITHUB_TOKEN do NOT trigger new workflow runs (GitHub anti-recursion rule), so triage→planning and implement→review-red-team hand-offs need a GitHub App token or PAT (`github_token` input / GH_TOKEN). Not wired here.
  • Combining `label_trigger` with a custom `prompt` in one step is untested.
  • Whole flow not run end to end. Disclose relation to Trailside on the page.

Labels

  • triage
  • planning
  • ready
  • review-red-team
  • in-review

Workflow YAML

Copy the file as-is. Highlighting is only for reading.

workflow.yml

name: Dev Loopon:  issues:    types: [opened, labeled]  pull_request:    types: [labeled]permissions:  contents: write  issues: write  pull-requests: write  id-token: writejobs:  triage:  # new issue -> label triage/planning    if: github.event_name == 'issues' && github.event.action == 'opened'    runs-on: ubuntu-latest    steps:      - uses: actions/checkout@v6      - uses: anthropics/claude-code-action@v1        with:          anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}          prompt: |            REPO: ${{ github.repository }}  ISSUE: ${{ github.event.issue.number }}            Triage this issue. If it is actionable, run:            gh issue edit ${{ github.event.issue.number }} --add-label planning            Otherwise comment asking for missing info and add label triage.          claude_args: |            --allowedTools "Bash(gh issue view:*),Bash(gh issue edit:*),Bash(gh issue comment:*)"  plan:  # label planning -> post plan, then label ready (human can veto)    if: github.event_name == 'issues' && github.event.label.name == 'planning'    runs-on: ubuntu-latest    steps:      - uses: actions/checkout@v6      - uses: anthropics/claude-code-action@v1        with:          anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}          prompt: |            REPO: ${{ github.repository }}  ISSUE: ${{ github.event.issue.number }}            Read the code and post an implementation plan as an issue comment (files, steps, tests).            Do NOT add the ready label; a human adds it to approve the plan.          claude_args: |            --allowedTools "Read,Grep,Glob,Bash(gh issue view:*),Bash(gh issue comment:*)"  implement:  # human adds ready -> Claude implements and opens PR    if: github.event_name == 'issues' && github.event.label.name == 'ready'    runs-on: ubuntu-latest    steps:      - uses: actions/checkout@v6      - uses: anthropics/claude-code-action@v1        with:          anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}          label_trigger: "ready"          branch_prefix: "claude/"          prompt: |            Implement the approved plan in the issue comments. Run tests.            Open a PR that says "Closes #${{ github.event.issue.number }}" and add label review-red-team to the PR.  red_team:  # PR labeled review-red-team -> a DIFFERENT agent attacks it    if: github.event_name == 'pull_request' && github.event.label.name == 'review-red-team'    runs-on: ubuntu-latest    permissions:      contents: read    outputs:      verdict: ${{ steps.codex.outputs.final-message }}    steps:      - uses: actions/checkout@v5        with:          ref: refs/pull/${{ github.event.pull_request.number }}/merge          persist-credentials: false      - id: codex        uses: openai/codex-action@v1        with:          openai-api-key: ${{ secrets.OPENAI_API_KEY }}          permission-profile: ":read-only"          prompt: |            You are a red-team reviewer. Try to break PR #${{ github.event.pull_request.number }}:            edge cases, security, missing tests, plan drift. End with a line VERDICT: PASS or VERDICT: FAIL.  hand_off:  # post verdict, move to in-review; a human merges    needs: red_team    runs-on: ubuntu-latest    permissions:      pull-requests: write    steps:      - env:          GH_TOKEN: ${{ github.token }}          VERDICT: ${{ needs.red_team.outputs.verdict }}          PR: ${{ github.event.pull_request.number }}        run: |          gh pr comment "$PR" -R "${{ github.repository }}" --body "$VERDICT"          if echo "$VERDICT" | grep -q "VERDICT: PASS"; then            gh pr edit "$PR" -R "${{ github.repository }}" --remove-label review-red-team --add-label in-review          fi          # No auto-merge: a human reviews in-review PRs and merges.

More workflows

  • Claude01

    Claude auto PR review

    Copied from the official Solutions Guide basic example (prompt shortened).

    pull_request: opened, synchronize

    Estimated cost~$0.18

    Not executed

    Checked Oct 16, 2026

  • Claude02

    Claude PR review with progress tracking

    `track_progress: true` posts a checkbox tracking comment (per Solutions Guide).

    pull_request: opened, synchronize, ready_for_review, reopened

    Estimated cost~$0.22

    Not executed

    Checked Oct 16, 2026

  • Claude03

    @claude mention assistant on issues and PRs

    No `prompt` → the action runs in tag/interactive mode and responds to the comment. `trigger_phrase` default is `@claude` (usage.md).

    issue_comment / pull_request_review_comment containing @claude

    Estimated cost~$0.27

    Not executed· 1 caveat

    Checked Oct 16, 2026