docs: streamline AGENTS.md to reduce AI hallucination#21033
Conversation
- Deduplicate auto-generated files listing (was in both Project Overview and its own section) - Merge standalone "Running tests" and "Adding or renaming a webpack option" into Development Workflow to eliminate repeated guidance - Group "Source language" and "Code comments" under a single "Coding Standards" heading - Promote Co-authored-by ban to its own REQUIRED subsection and explicitly state it overrides the system-prompt commit template - Trim defensive repetition in PR body and Copilot review sections Net reduction: 54 lines (~16%).
|
|
This PR is packaged and the instant preview is available (78158f0). Install it locally:
npm i -D webpack@https://pkg.pr.new/webpack@78158f0
yarn add -D webpack@https://pkg.pr.new/webpack@78158f0
pnpm add -D webpack@https://pkg.pr.new/webpack@78158f0 |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #21033 +/- ##
=======================================
Coverage 91.58% 91.59%
=======================================
Files 573 573
Lines 59541 59541
Branches 16077 16077
=======================================
+ Hits 54532 54535 +3
+ Misses 5009 5006 -3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Merging this PR will not alter performance
Warning Please fix the performance issues or acknowledge them on CodSpeed. Performance Changes
Tip Investigate this regression by commenting Comparing Footnotes
|
Summary
AGENTS.md had duplicated guidance across sections, causing AI agents to follow the wrong copy or ignore overridden rules. Key problems:
Changes (net −54 lines, ~16% reduction):
## Coding Standards.> [!REQUIRED]subsection, explicitly stating it overrides system-prompt templates.What kind of change does this PR introduce?
docs
Did you add tests for your changes?
No — docs-only change.
Does this PR introduce a breaking change?
No.
If relevant, what needs to be documented once your changes are merged or what have you already documented?
n/a
Use of AI
Claude Code identified duplication and structural issues in AGENTS.md, drafted the streamlined version under human review. Human directed the restructuring priorities (Co-authored-by promotion, deduplication targets).