Repository navigation
fix: suppress false-positive threat detection on size/triage AWs - #277
Merged
Merged
Conversation
The detection LLM scans the agent's full prompt context (19 KB) and
flags the gh-aw framework's own <system> and <safe-outputs> scaffolding
as prompt injection — specifically the mandatory safe-output tool-call
instructions ("CRITICAL: You MUST call one of the safe-output tools").
Add a threat-detection.prompt exclusion to gh-aw-issue-size,
gh-aw-issue-triage, and gh-aw-issue-auto-triage telling the detection
model to treat those framework-owned blocks as non-threatening and to
only flag content that originates from the issue body or comments.
Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
reakaleek
approved these changes
Aug 11, 2026
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The threat detection LLM fires a false positive on every size/triage run. The fix adds a
threat-detection.promptexclusion to the three affected AWs.Root cause
The detection job receives the agent's full prompt context (≈19 KB). That context includes the gh-aw framework's own
<system>security policy block and the<safe-outputs>block, which contains text like:The detection LLM (gpt-5.4-mini) sees these mandatory-tool-call instructions and concludes they are prompt injection — "a hidden requirement to call a specific tool before finishing, indicating untrusted content trying to steer the agent's actions."
This is 100% a false positive. The flagged content is the gh-aw framework's own scaffolding, not anything from the issue being analyzed. The actual agent output being scanned is only 271 bytes (a single tool call).
Fix
Added
safe-outputs.threat-detection.promptexclusion to:gh-aw-issue-size.mdgh-aw-issue-triage.mdgh-aw-issue-auto-triage.mdThe exclusion tells the detector to ignore
<system>and<safe-outputs>framework blocks and only flag content originating from the issue body or comments. This uses the documentedthreat-detection.promptfield from the gh-aw threat detection reference.The same false positive was reported upstream at github/gh-aw#51782.
Test plan
/sizerun on any issue and confirm the CAUTION banner is goneadd_labels)🤖 Generated with Claude Code
Related to #404