Skip to content

Docs: contribution guidelines for people and AI agents - #212

Merged
ivall merged 1 commit into
xcl-dev:mainfrom
1bugproof:docs/contribution-guidelines
Nov 23, 2026
Merged

ivall merged 1 commit into
xcl-dev:mainfrom
1bugproof:docs/contribution-guidelines

Conversation

@1bugproof

@1bugproof 1bugproof commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

The repository has no contribution guidelines, and many PRs are written with AI tools. This adds rules that keep PRs easy to review without turning AI away. Most of them write down what the history already does: Area: commit subjects, PR descriptions that name the hardware tested and what was not tested, skip_test for GPU tests, and the GPL-2.0-only rules from HANDOFF.md.

What is in it

  • CONTRIBUTING.md:
    • check for an open PR or issue before starting
    • one logical change per PR, about 400 changed lines at most, stacked PRs when one depends on another
    • no repo-wide cargo fmt, since the tree is not rustfmt-clean
    • a PR description outline (Tested / Not tested / AI use)
    • commits: Area: outcome, each one builds, fixups squashed
    • where tests go, and GPU and game-data tests that skip when there is nothing to run them on
    • licence and provenance
    • HANDOFF.md / docs/specs/ are left to the maintainer
    • an AI policy: name the tool and model, the author answers for every line, tests are actually run, AI test reports are welcome
  • AGENTS.md: the same rules written as instructions for coding agents, plus build and test commands, known pitfalls (Windows only, PowerShell UTF-8) and a list of things an agent never does.
  • CLAUDE.md: loads AGENTS.md and CONTRIBUTING.md for Claude Code.

Tested

  • Docs only, no code changes. The test commands, paths and the gpu::recomp::runner::skip_test helper they name were checked against the tree at eaa36b6.

Not tested

  • The size limits (~400 / ~800 lines) and the "maintainer's notes" rule for HANDOFF.md are proposals. Adjust them as you see fit.

AI use

  • Written with Claude Code (Claude Opus 5.5) from a look at the repo's commits and PRs; reviewed and directed by me.

🤖 Generated with Claude Code

CONTRIBUTING.md: small single-purpose PRs (~400 changed lines, stacked
when dependent), Area: commit subjects as in the history, tests with
every logic change, licence and provenance rules, and an AI policy
(disclose tool and model, the author answers for every line, tests
actually run, AI test reports welcome).

AGENTS.md: the same rules as instructions for coding agents, plus build
and test commands and what an agent must never do. CLAUDE.md loads both.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@1bugproof
1bugproof force-pushed the docs/contribution-guidelines branch from f9ede10 to 5a537b3 Compare November 23, 2026 21:09
@ivall
ivall merged commit 163b55e into xcl-dev:main Nov 23, 2026
ivall added a commit that referenced this pull request Nov 23, 2026
… title, checked by PR checks

CONTRIBUTING.md gets the merge requirements: both required checks green (CI, PR checks), the
whole suite run on a GPU with its counts, and for a runtime change (crates/xcl/src outside
tests) two xcl-smoke blocks from scripts/smoke.ps1 - built from main and from the PR's head
commit with no uncommitted changes - with no device removal or crash. The maintainer runs the
suite and a retail title again on every merged batch.

- scripts/smoke.ps1: runs a title for a fixed time (network off, XCL_ACTIVITY) and prints the
  xcl-smoke block: commit, GPU, exit, frames shown, presents, device removals, crashes, peak
  commit.
- .github/pull_request_template.md: Tested / Regression run / Not tested / AI use.
- .github/workflows/pr-check.yml: refuses a description without those sections, and a runtime
  change without a smoke block made on the PR's head commit.
- AGENTS.md / CLAUDE.md (from #212): the same rules for agents; AI use is disclosed in the PR's
  AI use section, a commit trailer is not required.
@ivall

ivall commented Nov 23, 2026

Copy link
Copy Markdown
Collaborator

Merged (163b55e), thanks - this is the base of the contribution rules now. On top of it (63b9930): a What a PR needs to be merged section in CONTRIBUTING.md (both required checks green, the whole suite run on a GPU with its counts, and for a runtime change two xcl-smoke blocks from the new scripts/smoke.ps1, built from main and from the PR's head commit, with no device removal or crash), a PR template with a Regression run section, and a PR checks workflow that refuses a description without them. One change to your text: AI use is disclosed in the PR's AI use section; the Co-Authored-By trailer is welcome but no longer required (CLAUDE.md, AGENTS.md).

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