Repository navigation
Stop agents documenting helper exports and implementation details - #1603
Merged
Merged
Conversation
Scope the docs rule in AGENTS.md to user-facing API changes, say that docs describe how to use a feature rather than how it is implemented, and say that adding a feature is not a reason to add a line to AGENTS.md or a skill. Update the review-pr checklist to match.
Put the rule where docs get written and where the diff is checked before committing, so it is not only caught at review.
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
Agent-written PRs keep adding two things to
docs/that don't belong there: sections for helpers that are exported only so modules can import them, and explanations of how a feature is implemented. They also add lines about their own feature to AGENTS.md and the skills.Three things in the rules cause it:
index.tsexports. Modules can only import core through that entry point, so every helper a module needs counts as public API and, by that rule, needs docs.review-prchecked the same thing.Examples: #1594 added a "Polling" docs section for the
pollhelper and a line about it to theadd-moduleskill. #1584 adds a line about its startup signal to the same skill.Changes:
write-code: a "Before touching docs" section states the rule at the point the docs get written, and the line about exporting a helper from core says it gets no docs. That line called the export "public API", which is what led to the docs.open-pr: the pre-commit checks include checking anydocs/, AGENTS.md or skill changes in the diff against the rule.review-pr: the Docs check matches the new rule and flags the two kinds of docs above. The Scope check flags AGENTS.md or skill lines that only describe the PR's own feature.Verification
npm run format,npm run lintandnpm run knippass. The change is Markdown outsidedocs/, so there are no tests to run and the docs build is unaffected.Not breaking
Only AGENTS.md and three skills change. No package code, docs or workflows are touched.