Skip to content

Centralize AI agent templates in .ai#5268

Open
qgallouedec wants to merge 5 commits intomainfrom
ai-templates
Open

Centralize AI agent templates in .ai#5268
qgallouedec wants to merge 5 commits intomainfrom
ai-templates

Conversation

@qgallouedec
Copy link
Member

@qgallouedec qgallouedec commented Mar 10, 2026

See huggingface/transformers#44489. Please discuss directly in huggingface/transformers#44489. Ideally, comments here should only be about TRL specific points


Note

Low Risk
Low risk: repo meta/config changes only (docs, symlinks, gitignore, Makefile) with no runtime/library behavior impact beyond developer tooling.

Overview
Centralizes AI-agent configuration by moving the canonical guidance to .ai/AGENTS.md and exposing it via lightweight symlink files (AGENTS.md, CLAUDE.md, .cursorrules).

Adds Makefile targets (codex, claude, cursor, clean-ai) to create/remove the expected symlinked skills directories, updates CONTRIBUTING.md with the new workflow, and extends .gitignore to exclude agent-generated skill artifacts (and wandb/).

Written by Cursor Bugbot for commit 8ec6644. This will update automatically on new commits. Configure here.

@chatgpt-codex-connector
Copy link

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

ln -snf .ai/AGENTS.md AGENTS.md
mkdir -p .agents
rm -rf .agents/skills
ln -snf ../.ai/skills .agents/skills
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Symlinks target non-existent .ai/skills directory

Low Severity

The codex and claude Makefile targets create symlinks pointing to .ai/skills, and CONTRIBUTING.md tells developers to edit .ai/skills/..., but the .ai/skills directory does not exist in the repository (.ai/ only contains AGENTS.md). Running make codex or make claude will produce dangling symlinks for the skills path, which would cause failures if an AI agent tries to follow them.

Additional Locations (2)
Fix in Cursor Fix in Web

@HuggingFaceDocBuilderDev

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

/AGENTS.md
/CLAUDE.md
/.agents/skills
/.claude/skills No newline at end of file
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

.cursorrules missing from .gitignore

Medium Severity

The make cursor target creates a .cursorrules symlink, and clean-ai removes it, but .cursorrules is not added to .gitignore. The other generated artifacts (/AGENTS.md, /CLAUDE.md, /.agents/skills, /.claude/skills) are all properly gitignored, but /.cursorrules was missed. Running make cursor would produce an untracked file that could be accidentally committed.

Additional Locations (1)
Fix in Cursor Fix in Web

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