gpu-perf-tune
AGENTS.md3 starsChanged 4 months agoMITView on GitHub
Canonical guidance for coding agents working in gpu-perf-tune. Client-specific files may point here, but shared policy belongs in this file. The repository layout, client setup, and methodology live in README.md and docs/METHODOLOGY.md. - gpu-perf-tune is the project and repository. - profile-and-optimize is the Agent Skills package. Claude Code consumes it as a plugin. Codex installs the same skills from a clone. - profile_and_optimize is the MCP server key. - Claude Code has first-class Skills, MCP, and opt-in provenance enforcement. -…
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.
Of the AGENTS.md files we read, the 11,773 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository2 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- .cursor/rules/coding-guidelines.mdcCursor rule
The file
Show its rules and text
We split this AGENTS.md into the rules it gives an agent
22 rules. About 0 are common, 16 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈16
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 30
Keep a Claude-specific instruction in a Claude adapter when the instruction is truly client-specific.
- Distinctive: line 40
Do not hide assumptions or uncertainty.
- Distinctive: line 47
Stop and ask when missing context would change the outcome.
- Distinctive: line 51
Write the minimum code that solves the requested problem.
- Distinctive: line 53
Do not add speculative features.
- Distinctive: line 54
Do not build an abstraction for one use.
- Distinctive: line 55
Do not add configurability that no caller needs.
- Distinctive: line 58
Ask whether a senior engineer would call the change overcomplicated.
- Distinctive: line 65
Do not reformat or refactor unrelated code.
- Distinctive: line 68
Remove only the imports, variables, and functions made obsolete by your change.
- Distinctive: line 72
Every changed line should trace to the request.
- Distinctive: line 88
Every benchmark, report, skill change, and README claim must be adversarially-confirmed to add value before promotion.
- Distinctive: line 99
Write a rough work times unit-cost ledger and state overlap assumptions.
- Distinctive: line 101
Prefer less work, bulk operations, compact representations, fewer copies, reuse, and less synchronization before instruction-level tuning.
- Very specific: line 116
Use the run ID as the experiment ID and the join key across evidence, cluster objects, and published results.
- Very specific: line 123
Run make all before committing.
- Very specific: line 125
Use make -j4 all to run independent targets in parallel.
- Distinctive: line 128
Never hardcode a replacement count without updating and running the count lints.
- Very specific: line 130
Start a new skill from plugins/profile-and-optimize/templates/skill/SKILL.md.
- Very specific: line 137
Keep adapter and package versions plus the changelog aligned.
- Very specific: line 140
Use make release only to recover a missing release from the current, already-green main version bump.
- Distinctive: line 142
Write human-facing text in plain language.
≈ “Common” is an estimate: at least 1 in 5 of the 16,595 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
AGENTS.md
Canonical guidance for coding agents working in gpu-perf-tune.
Client-specific files may point here, but shared policy belongs in this file.
Run it
make demo # print the tool and skill surface, no GPU needed
make help # list operator targets
make quality # run Ruff, Pyright, and ShellCheck
make all # run quality checks, docs, skill lint, MCP smoke, and pytestThe repository layout, client setup, and methodology live in
README.md and docs/METHODOLOGY.md.
Project names and client boundaries
gpu-perf-tuneis the project and repository.profile-and-optimizeis the Agent Skills package. Claude Code consumes it as a plugin. Codex installs the same skills from a clone.profile_and_optimizeis the MCP server key.- Claude Code has first-class Skills, MCP, and opt-in provenance enforcement.
- Codex has first-class Skills and MCP setup. It uses this
AGENTS.mdfor project guidance and has no packaged client hook. - Cursor, Gemini CLI, and Google Antigravity helpers are best effort. Do not treat those clients as release gates or claim full adapter support.
Keep a Claude-specific instruction in a Claude adapter when the instruction is truly client-specific. Put project policy here.
Behavioral guidelines
These rules reduce common agent mistakes. They favor caution over speed. Use judgment for trivial work.
1. Think before coding
Do not hide assumptions or uncertainty.
Before implementing:
- State assumptions that affect the result.
- Present materially different interpretations before choosing one.
- Name a simpler approach when it exists.
- Stop and ask when missing context would change the outcome.
2. Keep the solution small
Write the minimum code that solves the requested problem.
- Do not add speculative features.
- Do not build an abstraction for one use.
- Do not add configurability that no caller needs.
- Rewrite a large change when a much smaller one would be clearer.
Ask whether a senior engineer would call the change overcomplicated. If so, simplify it.
3. Make surgical changes
Touch only what the task needs.
- Do not reformat or refactor unrelated code.
- Match the local style.
- Preserve user changes and unrelated worktree state.
- Remove only the imports, variables, and functions made obsolete by your change.
- Report unrelated dead code instead of deleting it.
Every changed line should trace to the request.
4. Work toward a verifiable result
Translate the task into checks that can pass or fail.
- "Add validation" means test invalid input, then make the test pass.
- "Fix the bug" means reproduce it, then prove the fix.
- "Refactor" means keep the same behavior before and after the change.
For a multi-step task, state a short plan with a verification step.
5. Apply the value bar
Measured is not automatically valuable.
Every benchmark, report, skill change, and README claim must be adversarially-confirmed to add value before promotion. Name the workload, baseline, skeptical check, receipt, and user-facing value. If that chain is missing, label the result DRAFT or candidate.
6. Estimate, then measure
For performance work, apply the
performance hints adaptation:
- Classify the path as setup, per request, per token, or shared library work.
- Write a rough work times unit-cost ledger and state overlap assumptions.
- Rank changes by measured contributor share and maximum possible impact.
- Prefer less work, bulk operations, compact representations, fewer copies, reuse, and less synchronization before instruction-level tuning.
- Re-run the production-shaped baseline after each change. Estimates stay DRAFT.
Reproducibility-Grade Evidence
Significant performance work produces an evidence bundle, not loose output. Record the source revision, operator, environment, exact commands, stdout, stderr, exit codes, raw measurements, and summary in the bundle. A future reviewer must be able to identify what ran and decide whether the claim follows from the captured data.
Experiment Isolation and Traceability
Use the run ID as the experiment ID and the join key across evidence, cluster
objects, and published results. Give experiment resources unique names and the
matching experiment=<run-id> label. Do not reuse evidence across workloads,
source revisions, or delivery methods.
Working in this repository
- Run
make allbefore committing. It includes Python lint and formatting, production type checks, shell lint, repository gates, MCP smoke, and pytest. Usemake -j4 allto run independent targets in parallel. - Skill, tool, and library counts are canonical in
plugins/profile-and-optimize/server/mcp_surface.py. Never hardcode a replacement count without updating and running the count lints. - Start a new skill from
plugins/profile-and-optimize/templates/skill/SKILL.md. - Measurement rules live in
docs/METHODOLOGY.md. - MCP request, response, and acknowledgement rules live in
plugins/profile-and-optimize/server/docs/mcp-tool-io-contract.md. - The root
VERSIONfile is the release version source of truth. Keep adapter and package versions plus the changelog aligned. Every release uses an annotatedvX.Y.Ztag. A successful main push CI run triggers the release workflow. The version bump must be in the final squash-merged commit. Usemake releaseonly to recover a missing release from the current, already-green main version bump. - Write human-facing text in plain language. Do not use em dashes, en dashes, prose semicolons, inflated claims, or filler.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

