Skip to content

Conversation

@kevalyq
Copy link
Contributor

@kevalyq kevalyq commented Nov 2, 2025

📋 Meta: Improve AI Instruction Compliance

Context: During PR #75, AI violated org-wide Copilot Review Protocol by attempting to use MCP comment tools instead of required GraphQL mutations.

🎯 What This Fixes

Root Cause:

  • AI read local api/.github/copilot-instructions.md
  • But missed org-wide SecPal/.github/.github/copilot-instructions.md
  • Org instructions have stricter protocols (e.g., GraphQL-only for Copilot reviews)

Solution:

  • Added prominent HTML comment block at top of local instructions
  • Explicitly reminds AI to read org-wide instructions FIRST
  • Lists critical topics that require org-level compliance

📝 Changes

File: .github/copilot-instructions.md

Added (lines 4-19):

<!--
🚨 AI MUST READ ORGANIZATION-WIDE INSTRUCTIONS FIRST:
   File: SecPal/.github/.github/copilot-instructions.md

   Contains CRITICAL rules about:
   - Copilot Review Protocol (GraphQL only, NO comment tools!)
   - Pre-Commit/Pre-Push/CI Quality Gates
   - Branch Protection & PR Rules
   - TDD Mandatory Policy
   - CHANGELOG Maintenance

   ALWAYS check org instructions before taking actions on:
   - Pull Request comments/reviews
   - Commits and pushes
   - Merges
   - Quality gate decisions
-->

🔒 Impact

Prevents:

  • ❌ Using mcp_github_github_add_issue_comment on Copilot reviews
  • ❌ Using mcp_github_github_add_comment_to_pending_review incorrectly
  • ❌ Bypassing quality gates defined in org instructions
  • ❌ Violating TDD or CHANGELOG policies

Enables:

  • ✅ Explicit checklist for AI before PR/commit/merge actions
  • ✅ Makes @EXTENDS inheritance actionable (not just documentation)
  • ✅ Reduces risk of protocol violations in future PRs

✅ Quality Checks

  • Prettier formatted
  • Markdownlint clean
  • REUSE compliant
  • All tests passing (127/127)

🔗 Related


Review Focus: Verify reminder is prominent and covers critical org-wide topics. Should prevent future instruction misses.

SPDX-FileCopyrightText: 2025 SecPal
SPDX-License-Identifier: AGPL-3.0-or-later

Adds prominent comment block reminding AI to check parent
organization instructions before PR/commit/merge operations.

Lists critical topics: Copilot Review Protocol, Quality Gates,
Branch Protection, TDD Policy, CHANGELOG maintenance.
Copilot AI review requested due to automatic review settings November 2, 2025 16:58
@github-actions
Copy link

github-actions bot commented Nov 2, 2025

💡 Tip: Consider Using Draft PRs

Benefits of opening PRs as drafts initially:

  • 💰 Saves CI runtime and Copilot review credits
  • 🎯 Automatically sets linked issues to "🚧 In Progress" status
  • 🚀 Mark "Ready for review" when done to trigger full CI pipeline

How to convert:

  1. Click "Still in progress? Convert to draft" in the sidebar, OR
  2. Use gh pr ready when ready for review

This is just a friendly reminder - feel free to continue as is! 😊

Copy link
Contributor

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

This PR adds a documentation comment block to the Copilot instructions file to remind AI tools about organization-wide instructions that must be read before taking certain actions. The comment references critical rules about review protocols, quality gates, branch protection, TDD policy, and changelog maintenance.

@github-actions
Copy link

github-actions bot commented Nov 2, 2025

💡 Tip: Consider Using Draft PRs

Benefits of opening PRs as drafts initially:

  • 💰 Saves CI runtime and Copilot review credits
  • 🎯 Automatically sets linked issues to "🚧 In Progress" status
  • 🚀 Mark "Ready for review" when done to trigger full CI pipeline

How to convert:

  1. Click "Still in progress? Convert to draft" in the sidebar, OR
  2. Use gh pr ready when ready for review

This is just a friendly reminder - feel free to continue as is! 😊

@kevalyq kevalyq merged commit a547e36 into main Nov 2, 2025
26 checks passed
@kevalyq kevalyq deleted the docs/add-org-instructions-reminder branch November 2, 2025 17:03
@github-actions
Copy link

github-actions bot commented Nov 2, 2025

💡 Tip: Consider Using Draft PRs

Benefits of opening PRs as drafts initially:

  • 💰 Saves CI runtime and Copilot review credits
  • 🎯 Automatically sets linked issues to "🚧 In Progress" status
  • 🚀 Mark "Ready for review" when done to trigger full CI pipeline

How to convert:

  1. Click "Still in progress? Convert to draft" in the sidebar, OR
  2. Use gh pr ready when ready for review

This is just a friendly reminder - feel free to continue as is! 😊

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