Skip to content

Commit be90d8e

Browse files
docs: Add agent contribution guidance (#534)
* Add agent contribution guidance * Simplify AI disclosure checkbox --------- Co-authored-by: bubaizhanshen <bubaizhanshen@users.noreply.github.com>
1 parent 5983317 commit be90d8e

2 files changed

Lines changed: 61 additions & 0 deletions

File tree

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,7 @@ Fixes #
77
- [ ] Documentation updated
88
- [ ] Changelog entry added
99
- [ ] `./check.sh` passed
10+
11+
### AI assistance disclosure
12+
13+
- [ ] No AI assistance was used to generate this contribution.

AGENTS.md

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# Agent Guidance
2+
3+
These instructions apply to the entire repository.
4+
5+
## Project Layout
6+
7+
- Runtime code lives in `src/mss`.
8+
- Tests live in `src/tests`.
9+
- Documentation lives in `docs/source`.
10+
- `check.sh` and `check.ps1` are the maintainer-provided quality check entry points.
11+
12+
## Working Guidelines
13+
14+
- Keep changes focused on the issue or PR scope.
15+
- Be careful with public API changes. Update docs and tests when behavior changes.
16+
- Prefer the existing ctypes-based, dependency-free style for runtime code.
17+
- Do not add runtime dependencies unless the issue explicitly calls for one.
18+
- If AI assistance was used, disclose it in the pull request template and state which parts were AI-assisted.
19+
20+
## Validation
21+
22+
Install development dependencies:
23+
24+
```shell
25+
python -m pip install -e ".[dev,tests]"
26+
```
27+
28+
Run quality checks before submitting a PR:
29+
30+
```shell
31+
./check.sh
32+
```
33+
34+
On Windows:
35+
36+
```powershell
37+
.\check.ps1
38+
```
39+
40+
Run tests:
41+
42+
```shell
43+
python -m pytest
44+
```
45+
46+
On headless GNU/Linux environments, run tests with a virtual display:
47+
48+
```shell
49+
xvfb-run python -m pytest
50+
```
51+
52+
When documentation changes, install docs dependencies and build docs with warnings as errors:
53+
54+
```shell
55+
python -m pip install -e ".[docs]"
56+
sphinx-build -d docs docs/source docs_out --color -W -bhtml
57+
```

0 commit comments

Comments
 (0)