agentleFS
Hugging FaceKnown publisherhuggingface/transformers.js/.ai/AGENTS.md

transformers.js

AGENTS.md16k starsChanged 3 months agoApache-2.0View on GitHub

This file governs AI-assisted contributions to the huggingface/transformers.js repository. Agentic users must read and follow it before proposing changes. - transformers-js — how to use the library itself. Load this skill when working on code that calls @huggingface/transformers. Before opening a pull request: - Check for existing work. Search open PRs and issues (gh pr list, gh issue list) for the area you're touching. Don't duplicate someone else's in-progress work. - Coordinate on the issue first. If an issue exists,…

  • Installs packages

Trending

More talk lately.about the whole repository

Dec 2025: 2 mentionsJan 2026: 0 mentionsFeb 2026: 0 mentionsMar 2026: 3 mentionsApr 2026: 3 mentionsMay 2026: 0 mentionsJun 2026: 2 mentionsJul 2026: 0 mentionsAug 2026: 1 mentionSep 2026: 2 mentionsOct 2026: 9 mentionsNov 2026: 25 mentions
Dec 2025Jun 2026Nov 2026
Mentions a month of the huggingface/transformers.js repository that our weekly crawl found. There is no adoption data for this file yet.

Who's talking about huggingface/transformers.js

The biggest 5 of 61 mentions linking to the repository that our crawl found. Each line is their own headline.

See all 61

Talked about on GitHub, Bluesky and Hacker News (61 times).

On GitHub · 50

45 more on GitHub

On Bluesky · 8

3 more on Bluesky

On Hacker News · 3

  • 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 repository3 other files it gives its agents.

The file

We split this AGENTS.md into the rules it gives an agent

6 rules. About 0 are common, 4 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  • could be automatic: a setting could enforce it
  1. Distinctive:

    Before opening a pull request:

    line 13
  2. Very specific:

    Check for existing work: Search open PRs and issues (gh pr list, gh issue list) for the area you're touching.

    line 15
  3. Distinctive:

    Coordinate on the issue first: If an issue exists, comment on it before drafting a PR.

    line 17
  4. Distinctive:

    Run the full documentation generator after any JSDoc, docs snippet, task metadata, or generated skill content change:

    line 37
  5. Distinctive:

    Do not edit generated API pages, the generated skill reference files, or the root README by hand.

    line 54
  6. Very specific:

    Run pnpm --filter @huggingface/transformers docs-generate from the repo root.

    line 65

≈ “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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
AGENTS.md

Agent guidelines for transformers.js

This file governs AI-assisted contributions to the huggingface/transformers.js repository. Agentic users must read and follow it before proposing changes.

Available skills

  • transformers-js — how to use the library itself. Load this skill when working on code that calls @huggingface/transformers.

Contributing

Before opening a pull request:

  • Check for existing work. Search open PRs and issues (gh pr list, gh issue list) for the area you're touching. Don't duplicate someone else's in-progress work.
  • Coordinate on the issue first. If an issue exists, comment on it before drafting a PR. If approval from the issue author or a maintainer is unclear, stop and ask.
  • No low-value busywork. Reformatting, renaming, and cosmetic-only PRs that don't fix a reported problem or implement a requested feature are discouraged.
  • Run the full test suite locally. pnpm test at the package root must pass before you submit. Don't skip hooks with --no-verify.
  • Accountability. AI-assisted patches are the responsibility of the human submitter. Review the diff yourself before pushing.

Local setup

pnpm install
pnpm --filter @huggingface/transformers test
pnpm --filter @huggingface/transformers typegen
pnpm --filter @huggingface/transformers docs-generate

Documentation generation

Run the full documentation generator after any JSDoc, docs snippet, task metadata, or generated skill content change:

pnpm --filter @huggingface/transformers docs-generate

docs-generate runs docs/scripts/generate-all.js, which generates:

  • packages/transformers/docs/source/api/**/*.md from JSDoc comments in packages/transformers/src/**/*.js.
  • The marker-delimited generated sections in .ai/skills/transformers-js/SKILL.md and references/{CONFIGURATION,PIPELINE_OPTIONS}.md.
  • .ai/skills/transformers-js/references/TASKS.md (fully generated).
  • The repo-root README.md from packages/transformers/docs/snippets/*.snippet.

Do not edit generated API pages, the generated skill reference files, or the root README by hand. Update the source JSDoc, docs snippets, or generator modules instead.

The generator also validates generated API pages against docs/source/_toctree.yml and checks local Markdown links and anchors under docs/source/. To run only the validator (without regenerating), use pnpm --filter @huggingface/transformers docs-validate.

Workflow after touching JSDoc

  1. Edit the JSDoc in packages/transformers/src/**/*.js.
  2. Run pnpm --filter @huggingface/transformers docs-generate from the repo root.
  3. Inspect the diff under packages/transformers/docs/source/api/ — that's the page a human or agent will read. If the JSDoc didn't render the way you expected, tweak the source, not the generated markdown.
  4. Watch for "doc-quality warnings" at the end of the generator's output — these flag undocumented public exports and malformed @param tags.
  5. Stage the source files; the generated api/**/*.md files are gitignored.

What is generated vs. hand-written

PathGenerated?Tracked in git?
packages/transformers/docs/source/api/**/*.mdyesno — gitignored
packages/transformers/docs/source/{guides,tutorials,integrations}/*.mdhand-writtenyes
packages/transformers/docs/source/_toctree.ymlhand-written (must list every generated API page)yes
.ai/skills/transformers-js/SKILL.mdmixed — prose hand-written, blocks between <!-- @generated:start ... --> markers regeneratedyes
.ai/skills/transformers-js/references/TASKS.mdfully generated, do not edityes
.ai/skills/transformers-js/references/{CONFIGURATION,PIPELINE_OPTIONS}.mdmixed (same marker convention as SKILL.md)yes
README.mdgenerated from packages/transformers/docs/snippets/*.snippetyes

Generated files that are tracked in git (the .ai/ references and README.md) must be regenerated and committed together with the source change that affects them — CI fails the build if they drift from the source JSDoc.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.