Skip to content

docs: add AGENTS.md with PR quality rules - #199

Draft
lym953 wants to merge 1 commit into
mainfrom
yiming.luo/agents-md-pr-quality
Draft

lym953 wants to merge 1 commit into
mainfrom
yiming.luo/agents-md-pr-quality

Conversation

@lym953

@lym953 lym953 commented Oct 28, 2026

Copy link
Copy Markdown
Contributor

Problem

Coding agents and review bots in this repository have no guidance on PR quality. The only instruction file is .github/copilot-instructions.md, and it covers only security.

On #169, several rounds of bot review did not report problems that a human review found later:

  • The PR had about 310 lines of core code and about 1,490 lines of tests.
  • Many tests checked cases that one table test already covered.
  • A test checked a setting that no code reads.
  • A new setting differed from the setting that the Lambda Extension uses for the same shared sampler.

This PR

  • Adds AGENTS.md with rules for code style, settings, tests, PR size and reviews. Four rules come from the AGENTS.md file of the Lambda Extension:

    • the 300-line limit for core code
    • no defensive checks without a reason
    • short comments
    • a PR description that agrees with the code

    The other rules come from the review of [Traces] Add error sampling with opt-in tracer-drop rescue #169.

  • Removes /AGENTS.md from .gitignore, so that the file can be committed. /CLAUDE.md stays in .gitignore, so that personal files stay local.

Testing

This PR changes only documentation. I did not run a bot review with the new file.

Open questions

  • Does Copilot code review read AGENTS.md? If it does not, we can copy the review rules into .github/copilot-instructions.md.
  • A user of Claude Code who has a local CLAUDE.md can add the line @AGENTS.md to it, to load these rules. The Lambda Extension commits a CLAUDE.md with that line. Do we want the same here? That change removes /CLAUDE.md from .gitignore, and a pull fails for each person who has an untracked CLAUDE.md.
  • Some people possibly have a local, untracked AGENTS.md. After this PR merges, a pull fails for them until they move that file.

🤖 Generated with Claude Code

Add guidance for coding agents and review bots on PR size, duplicate
tests, defensive checks, and settings shared with the Lambda Extension
and the Go Agent. Stop ignoring /AGENTS.md so the file can be committed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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.

1 participant