Skip to content

Autonomous agent pipeline — CI fixer, review responder, quality gate #53

@microsasa

Description

@microsasa

Problem

Agent-created PRs require manual babysitting: marking ready, fixing CI failures (ruff/pyright), requesting Copilot reviews, addressing review comments, and merging. This slows down the feedback loop and defeats the purpose of automated agents.

Spec

Build a fully autonomous pipeline for agent-created PRs (aw-labeled):

Implementer upgrade

  • Run ruff check --fix, ruff format, pyright, and pytest before pushing
  • Open regular PRs (not drafts) with auto-merge enabled
  • Add aw label to created PRs
  • Allow Python package network access for uv sync

CI Fixer agent (new)

  • Triggered by CI workflow when check job fails on aw-labeled PRs
  • Reads CI logs, identifies failures, pushes fix commit
  • Label guard (ci-fix-attempted) prevents infinite loops — max 1 retry

Review Responder agent (new)

  • Triggers on pull_request_review events for aw-labeled PRs
  • Reads unresolved review comment threads (up to 10)
  • Makes requested fixes, replies to threads, resolves them
  • Label guard (review-response-attempted) — max 1 attempt

Quality Gate agent (new)

  • Triggers on pull_request_review (Copilot approval) for aw-labeled PRs
  • Evaluates code quality and blast radius
  • LOW/MEDIUM impact → submits approval review → auto-merge fires
  • HIGH impact → adds comment flagging for human review, does NOT approve

Repo settings (post-merge)

  • Enable auto-merge on repo
  • Configure Copilot auto-review ruleset
  • Update branch protection to require 2 approving reviews (Copilot + Quality Gate)

End state

Audit/Health Agent → Issue → Implementer PR (lint-clean, auto-merge)
  → CI + Copilot review (parallel)
    → CI fails → CI Fixer (1 retry)
    → Copilot comments → Review Responder (1 attempt)
    → Copilot approves → Quality Gate evaluates
      → ≤ Medium impact → approves → auto-merge
      → High impact → flags for human

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions