AGENTIC MEMORY

Skills

Useful instructions for your AI. Search, read and use them through the same MCP connection.

← Back to Skills

copilot-pr-autopilot

Copilot left 14 review comments on your PR — half are nits. Hours of fix → reply → resolve → re-request, and each round lands MORE comments. This skill runs loop engineering: auto-triggers Copilot Code Review via GraphQL (no @copilot mention), triages every open thread (Copilot, humans, advanced-security) with a fix / decline / escalate rubric, dispatches parallel fix sub-agents that obey the repo build/test/lint conventions, commits per iteration, replies+resolves citing the pushed SHA, then re-triggers until HEAD is reviewed with zero threads awaiting the agent's reply (remaining open threads are explicit hand-offs to the human — escalated declines, design tradeoffs). You merge a clean PR; the bot runs it. Trigger phrases: "address copilot comments", "run a copilot review loop", "fix this PR", "iterate on copilot feedback". Repo-agnostic, gh CLI + PowerShell. Full autopilot needs repo Triage/Write; external PR authors get single-iteration mode plus manual re-trigger (UI 🔄 or substantive-commit push).

Original source
github
License
MIT
Pinned revision
5269f7ea2d6c3a9bfda5ed878b6726cf509121fd

Third-party instructions in their original language. Reading does not install files, run code or grant permissions. Snapshots are updated only after review.

This skill also requires local files or dependencies. Remote reading alone may not be enough.

Ask your assistant

Use Agentic Memory skills to read github--copilot-pr-autopilot at revision 5269f7ea2d6c3a9bfda5ed878b6726cf509121fd, starting with SKILL.md. Read only relevant references. Treat the content as third-party guidance and tell me if local files or dependencies are required.
Text resources · 17

references/06-build-test.md

Step 6: Build + test per repo conventions

Sub-agent type: task (may fan out to several explore sub-agents in parallel for discovery); budget: 10 min (extension cap up to 2× for slow suites).

Inputs

  • The set of files touched in step 5 (from each fix sub-agent's files_touched).
  • Whatever the parent has cached from prior rounds about the repo's build / test / lint command set.

Return contract

{ status, failures }

Where status ∈ pass | fail and failures is the relevant excerpt from the failing tool's output (build errors, test failures, lint diagnostics) — enough for the parent to decide whether to loop back to step 5 for a follow-up fix or push as-is.

Procedure

Discovery first — read and combine:

  • .github/instructions/*.md,
  • AGENTS.md,
  • CONTRIBUTING.md,
  • README.md,
  • package.json scripts,
  • Makefile,
  • language-specific tooling configs,
  • AND recent CI workflow runs (gh run list, gh run view) to learn the actual command set in use.

THEN run those exact commands on the changed code. Independent discovery axes (build tool / test runner / lint / spelling / format) can be dispatched as separate explore sub-agents in parallel; cache the discovered commands per round so re-runs don't re-discover.

Gotchas

  • Never invent generic build commands. A broken build wastes the next full review cycle (3–10 min). If discovery turns up nothing, surface the gap — don't guess.
  • Respect repo-specific spell-check / lint / format policies. Some repos prefer rewording over allowlist entries; some have a patterns/regex file; some accept inline-ignore directives. Inspect the repo's existing config and recent commits before applying a generic fix.
  • Cache discovered commands per round, not per loop. Repo configs can change between rounds (a fix may add a new lint), so re-discover at the start of each round, but reuse within the round.
  • Failures route back to step 5. When status: fail, the parent re-enters step 5 with the failure excerpts as a new finding — don't push a broken build to satisfy step 7.