Skip to content

chore: adopt AGENTS.md as the agent-instruction source of truth (+ CLAUDE.md shim) - #148

Merged
comfyui-wiki merged 1 commit into
mainfrom
matt/be-3560-cursorrules-to-agents-md
Sep 16, 2026
Merged

comfyui-wiki merged 1 commit into
mainfrom
matt/be-3560-cursorrules-to-agents-md

Conversation

@mattmillerai

Copy link
Copy Markdown
Contributor

ELI-5

This repo told AI coding tools how to write the docs using a file named
.cursorrules — a name only Cursor recognizes. Newer tools (and the wider
cross-tool standard) look for AGENTS.md instead, and Claude Code looks only
for CLAUDE.md. So this PR renames the rules file to AGENTS.md (the words
inside are unchanged) and adds a tiny CLAUDE.md that just says "read
AGENTS.md." Now every agent reads the same instructions from a standard place,
and nobody has to keep two copies in sync.

What changed

  • git mv .cursorrules AGENTS.md — content unchanged (it was already plain
    markdown; only a trailing newline was added). 146 lines, well under the
    200-line cap.
  • New root CLAUDE.md containing exactly the canonical shim (an explanatory
    comment plus @AGENTS.md, which Claude Code resolves relative to the shim's
    directory).
  • Updated one stale in-code comment that still named the old policy file, so it
    points at AGENTS.md (the rename would otherwise leave a dangling reference).

Self-review

  • Acceptance: .cursorrules gone (rename detected at 99%, only the trailing
    newline differs); AGENTS.md content otherwise unchanged and < 200 lines;
    CLAUDE.md present with byte-exact canonical shim content; no nested
    AGENTS.md exists, so no nested shim is required.
  • Riskiest line: the CLAUDE.md comment text — it must match the canonical
    shim exactly (including the em-dash). Verified byte-for-byte. The @AGENTS.md
    import resolves relative to the shim's own directory (repo root), which is
    where AGENTS.md now lives.
  • CI: the repo's markdown format/link checks are path-scoped to
    comfyui_embedded_docs/docs/** (verified: the format checker's DOCS_DIR is
    that folder), so they do not run against these root/tooling files — not a
    silent skip, just out of their declared scope. The edited Python file compiles
    (py_compile clean); the edit is a comment only.

Judgment calls

  • The two .gitignore entries (root and docs-generation/) that ignore
    .cursorrules were kept on purpose: with the legacy file removed, the
    ignore rules now serve to keep anyone from re-adding it, which matches the
    "no legacy rules file" intent. Removing them was out of scope and would only
    invite regressions.

Residual

  • No unfixed scope: the rename, the shim, and the one dangling in-code reference
    are all handled, and a repo-wide sweep found no other references to the old
    file name.
  • Unexercised artifact: the parent tracking epic for this standardization effort
    is referenced by name only and is not reachable from this environment, so its
    body was not read; this change follows the org standard as restated in the
    work item itself.

Provenance

  • Authored by: agent-work loop
  • Verified: git mv rename confirmed at 99% similarity; CLAUDE.md content
    diffed byte-for-byte against the canonical shim; python3 -m py_compile clean
    on the edited script; repo-wide grep confirms no remaining stale references
    outside the intentionally-kept .gitignore lines.
  • Deviations: added a trailing newline to AGENTS.md and updated one stale
    in-code comment reference — both minor follow-through on the rename, disclosed
    above.

Rename .cursorrules to AGENTS.md (content unchanged; already valid
markdown) and add a root CLAUDE.md shim that imports it, so Claude Code
(which reads only CLAUDE.md) and other agent tools share one source.

Update a stale in-code reference to the renamed policy file.
@coderabbitai

coderabbitai Bot commented Sep 16, 2026

Copy link
Copy Markdown

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Team

Run ID: 380fe550-8653-4a89-ae66-de74c45bcd7d

📥 Commits

Reviewing files that changed from the base of the PR and between 1c61185 and dcf52d5.

📒 Files selected for processing (3)
  • AGENTS.md
  • CLAUDE.md
  • docs-generation/scripts/update_param_translations.py

Included review availability: 0 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 1 review per hour.


📝 Walkthrough

Walkthrough

The changes centralize instruction references on AGENTS.md. CLAUDE.md now acts as a shim, the translation script updates its policy reference, and the Persian headings remain unchanged.

Changes

Instruction Source Alignment

Layer / File(s) Summary
Shared instruction references
CLAUDE.md, docs-generation/scripts/update_param_translations.py, AGENTS.md
CLAUDE.md imports AGENTS.md. The translation script references AGENTS.md instead of .cursorrules. Persian input and output headings remain unchanged.

Suggested reviewers: lin-bot23

Priority: ⬇️ Low

Merge Risk: ⚪ Minimal · up to dcf52

The rename and instruction shim do not introduce an actionable current-head risk.

🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch matt/be-3560-cursorrules-to-agents-md
✨ Simplify code
  • Create PR with simplified code
  • Commit simplified code in branch matt/be-3560-cursorrules-to-agents-md

Comment @coderabbitai help to get the list of available commands.

@mattmillerai mattmillerai added agent-coded Authored by the agent-work loop cursor-review Requested cursor bot review labels Sep 16, 2026
@comfyui-wiki
comfyui-wiki merged commit 731965c into main Sep 16, 2026
4 checks passed
@github-actions
github-actions Bot deleted the matt/be-3560-cursorrules-to-agents-md branch September 16, 2026 05:11
@github-actions github-actions Bot locked and limited conversation to collaborators Sep 16, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

agent-coded Authored by the agent-work loop cursor-review Requested cursor bot review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants