Skip to content

feat(ai-reviewer): pushback patterns for AI reviewer comments#74

Merged
CybotTM merged 3 commits into
mainfrom
feat/ai-reviewer-pushback
May 10, 2026
Merged

feat(ai-reviewer): pushback patterns for AI reviewer comments#74
CybotTM merged 3 commits into
mainfrom
feat/ai-reviewer-pushback

Conversation

@CybotTM
Copy link
Copy Markdown
Member

@CybotTM CybotTM commented May 10, 2026

Summary

Adds a new reference for handling AI reviewer comments (Copilot, gemini-code-assist, CodeRabbit, Sourcery, Codium / PR-Agent) without either rubber-stamping wrong advice or ignoring valid feedback.

File: skills/github-project/references/ai-reviewer-pushback.md (+ link from SKILL.md table, description updated)

What it covers

Four common failure modes documented with real examples:

  1. Field-name / API-name hallucination — bot confidently invents config fields/types. Real example: gemini-code-assist suggesting ignoredBuilds: for pnpm 11. That field doesn't exist; the legacy name was ignoredBuiltDependencies (removed in pnpm 11), and the modern equivalent is allowBuilds: { pkg: false }.
  2. Stale knowledge of release status — claiming a current release is unreleased, recommending outdated minimums, asserting a feature doesn't exist when it has shipped. Examples: "PHP 8.5 not released yet," "use Node 20 max," "TYPO3 v14 has not shipped."
  3. Pattern advice frozen at a past major — jQuery for DOM in vanilla code, Vue 2 Options API in Vue 3, deprecated GitHub Actions inputs (fail_on_error instead of fail_level), CKE4 plugin shapes in CKE5.
  4. Inverting a security control — "set strict-peer-dependencies=false," "set engine-strict=false," "disable harden-runner." The fix removes the check that produced the symptom.

Plus:

  • Six-step pushback workflow: verify against primary sources → check empirical evidence (green CI is strong) → read bot rationale → decide → reply on thread → resolve.
  • gh GraphQL snippets for finding thread IDs, replying directly to a thread (not top-level), and resolving.
  • Reply templates for full pushback (4-part structure: state disagreement, cite primary source, cite empirical evidence, state action) and partial agreement.
  • Anti-patterns — silently changing code to clear reviews, top-level "addressed in commit X" comments, leaving unresolved threads, resolving without rationale.
  • Per-bot quirks table for gemini-code-assist, copilot-pull-request-reviewer, coderabbitai, sourcery-ai (with caveats — bot behavior changes).

Why now

This came up on netresearch/timetracker-ui#717, where gemini-code-assist marked a config change as a high-priority bug and recommended replacing a working allowBuilds map with a non-existent ignoredBuilds array. The right response was to push back with docs links and green CI evidence rather than apply the wrong change. The pattern is going to keep coming up across all our repos as more bot reviewers come online.

Relationship to existing references

  • Complements auto-merge-guide.md (which covers the Copilot-as-reviewer race condition — a different failure mode where the bot blocks a merge by not reviewing).
  • Both files are about "AI reviewer didn't help merge," but the failure shapes are distinct.

Test plan

  • bash scripts/verify-harness.sh → Level 3 COMPLETE | 0 errors, 0 warnings
  • SKILL.md word count ≤ 500 (currently 484)
  • All references resolve

New references/ai-reviewer-pushback.md documenting how to evaluate,
respond to, and resolve AI reviewer comments (Copilot, gemini-code-assist,
CodeRabbit, Sourcery, etc.) without rubber-stamping wrong advice or
ignoring valid feedback.

Covers four common failure modes:

- Field-name / API hallucination (real example: gemini-code-assist
  suggesting non-existent pnpm `ignoredBuilds:` field).
- Stale knowledge of release status (claiming current versions are
  unreleased; recommending outdated minimum versions).
- Pattern advice frozen at a past major (jQuery in vanilla DOM code,
  Vue 2 Options API in Vue 3, deprecated GitHub Actions inputs).
- Inverting a security control to make a build pass.

Includes a six-step pushback workflow (verify against primary sources,
check empirical evidence on the PR, read the bot rationale, decide,
reply on the thread, resolve), reply templates for both pushback and
partial-agreement, gh-graphql snippets for thread reply and resolve,
anti-patterns, and bot-specific quirks.

Source: production review handling on
netresearch/timetracker-ui#717 (gemini-code-assist incorrectly
suggesting `ignoredBuilds` for pnpm 11 — pushed back with docs +
green CI evidence rather than applying the wrong change).

Signed-off-by: Sebastian Mendel <info@sebastianmendel.de>
Copilot AI review requested due to automatic review settings May 10, 2026 11:55
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 10, 2026

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new guide, ai-reviewer-pushback.md, which provides strategies for evaluating and responding to automated AI code reviews, covering failure modes like hallucinations and stale knowledge. The main SKILL.md file was also updated to include this new reference and improve existing descriptions. Feedback from the review correctly identified an accidental deletion of existing documentation references in the main skill file and suggested technical refinements to the provided shell and GraphQL snippets to ensure better error handling and consistency.

Comment thread skills/github-project/SKILL.md Outdated
Comment thread skills/github-project/references/ai-reviewer-pushback.md Outdated
Comment thread skills/github-project/references/ai-reviewer-pushback.md Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new reference document to help maintainers handle incorrect or stale AI reviewer feedback in PR threads, and updates the skill’s summary/entry points to include this use case.

Changes:

  • Added a new reference guide: ai-reviewer-pushback.md (workflows, templates, GraphQL snippets, failure-mode catalog).
  • Updated SKILL.md front-matter description and “When to Use” list to include AI reviewer scenarios.
  • Updated the SKILL.md References table to link the new guide (currently at the cost of dropping two existing reference links).

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.

File Description
skills/github-project/SKILL.md Expands the skill description + “When to Use” bullets; updates the References table to include the new AI reviewer pushback doc.
skills/github-project/references/ai-reviewer-pushback.md New reference describing common AI review failure modes, an evidence-based pushback workflow, and thread-reply/resolve GraphQL commands.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread skills/github-project/SKILL.md Outdated
Comment thread skills/github-project/references/ai-reviewer-pushback.md Outdated
Comment thread skills/github-project/references/ai-reviewer-pushback.md Outdated
Comment thread skills/github-project/references/ai-reviewer-pushback.md Outdated
CybotTM added 2 commits May 10, 2026 14:22
- Restore upstream SKILL.md (When-to-Use compression and the
  org-security-settings / tag-validation reference rows that were
  accidentally overwritten when initial copy came from a stale main
  worktree, per Copilot + gemini-code-assist comments).
- Bump skill metadata version 2.13.1 -> 2.14.0 for the new reference.
- Reference doc fixes (Copilot review):
  * Rephrase 'Stale knowledge of release status' examples as
    pattern-shapes with a 'these will go stale' caveat instead of
    naming specific current versions that will rot.
  * Rewrite 'CKEditor 4 plugin shapes in a CKE5 file' with the full
    framework name on both sides for clarity.
  * Add a parenthetical introducing Context7 as a docs-lookup MCP
    server so the mention has context.
- Reference doc fixes (gemini-code-assist review):
  * Add jq '?' suffix and '// \"\"' fallback in the thread-listing
    snippet so empty 'comments' nodes don't error.
  * Rewrite the resolveReviewThread snippet to use a GraphQL variable
    for thread ID, matching the style of the reply snippet.

Signed-off-by: Sebastian Mendel <info@sebastianmendel.de>
Signed-off-by: Sebastian Mendel <info@sebastianmendel.de>
@sonarqubecloud
Copy link
Copy Markdown

@CybotTM CybotTM merged commit 95c66ea into main May 10, 2026
16 checks passed
@CybotTM CybotTM deleted the feat/ai-reviewer-pushback branch May 10, 2026 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants