Skip to content
huggingface/transformers (opens in a new tab)

Exceptional first impression and abundance of resources undercut by a sprawling codebase, steep learning curve, and explicit discouragement of certain contributions.

Python★ 161,6032,435 open issuesApache License 2.0
Overall score: 72 out of 100
Holding

last scored 2026-06-15

Readiness lenses

The same repo, two ways: how ready it is for an AI coding agent, and for a human newcomer. Switch lenses to see each one's score and checks.

How ready the repo is for an AI coding agent to read, build, and operate it.

21 of 33 checks passed across 6 categories.

  • Machine Orientation

    6 checks passed2 problems found

    • lowllms.txt present

      An llms.txt is the emerging machine-orientation standard — a curated map for LLMs.

      Fix: Add an llms.txt pointing at the key docs and entry points.

    • lowArchitecture doc

      An ARCHITECTURE doc hands an agent the module map instead of making it infer one.

      Fix: Add an ARCHITECTURE.md describing the major components and how they fit.

    • README present — An agent reconstructs what the repo is and how to work in it from the README first.
    • Agent instructions file — AGENTS.md / CLAUDE.md is the direct, machine-read channel for entry points and conventions.
    • Agent instructions stay lean — A bloated instructions file burns context and measurably hurts more than it helps.
    • Repository description set — The one-line description is the fastest orientation signal an agent reads.
    • Topics set — GitHub topics situate the repo's domain and stack for an agent at a glance.
    • Contribution conventions are written down — A contributor guide is where an agent learns the branch, commit, and review conventions it must follow.
  • Reproducible Setup

    1 check passed4 problems found

    • highLockfile committed

      Without a lockfile two clones can resolve different dependency trees — the build isn't reproducible.

      Fix: Commit your lockfile (package-lock.json / pnpm-lock.yaml / Cargo.lock / …).

    • mediumRuntime / toolchain pinned

      An unpinned runtime makes an agent guess the version a clean environment needs.

      Fix: Pin the runtime with .nvmrc / .tool-versions / an engines field / packageManager.

    • lowEnv template present

      A .env.example tells an agent which configuration keys it must supply to run.

      Fix: Ship a .env.example listing every required key with placeholder values.

    • lowDev container

      A .devcontainer gives an agent a one-command, fully-declared environment.

      Fix: Add a .devcontainer so the toolchain is declared, not assumed.

    • Container or dev-container — A Dockerfile / compose / devcontainer removes 'works on my machine' from setup.
  • Code Navigability

    1 check passed0 problems found

    • Conventional source layout — A recognised src/ · lib/ · app/ layout lets an agent localise code without spelunking.
  • Verification Surface

    3 checks passed4 problems found

    • mediumTest command defined

      A `test` script is the documented, discoverable way to run the suite.

      Fix: Add a `test` script (package.json / Makefile / Taskfile) that runs the suite.

    • lowLint command defined

      A linter an agent can run catches a class of mistakes before they ship.

      Fix: Add a `lint` script and a linter config.

    • lowTypecheck command

      A typecheck script lets an agent catch type errors before they ship.

      Fix: Add a `typecheck` script (e.g. `tsc --noEmit`).

    • lowBuild command

      A documented build command is the discoverable way for an agent to produce artifacts.

      Fix: Add a `build` script that produces the distributable.

    • Tests present — Runnable tests are the ground truth an agent checks its own edits against.
    • CI configured — Readable CI is the feedback loop an agent reads to know what 'green' means here.
    • Task runner present — A Makefile / Taskfile / justfile gives an agent a single index of the project's commands.
  • Agent Safety

    7 checks passed1 problem found

    • lowCODEOWNERS present

      CODEOWNERS marks the 'don't touch without review' zones an agent should respect.

      Fix: Add a CODEOWNERS file marking the sensitive paths.

    • No committed .env — A tracked real .env hands secrets to anything — including an agent — that reads the repo.
    • No exposed secrets — Secret-shaped literals in tracked files are a live credential leak.
    • .gitignore covers env files — An ignore rule for .env is what keeps the next careless commit from leaking secrets.
    • Automated dependency updates — Dependabot / Renovate keeps dependencies patched without a human in the loop.
    • .gitignore present — A .gitignore is the first guard against an agent committing secrets or build junk.
    • Security policy — A SECURITY.md is where an autonomous security agent reads this repo's rules before acting on it.
    • License makes the code reusable — Without a license an agent cannot safely copy, redistribute, or vendor any of this code.
  • Context Economy

    3 checks passed1 problem found

    • lowGenerated / vendored files marked

      A .gitattributes linguist marker tells tools (and agents) what to skip.

      Fix: Mark generated/vendored paths in .gitattributes (linguist-generated / linguist-vendored).

    • Dependencies not vendored in — A committed node_modules / vendor tree drowns the real signal an agent needs.
    • Build output not committed — Generated dist/ · build/ output is noise an agent has to read past.
    • No oversized source file — A single file in the hundreds of KB blows past an agent's effective context window.

Where the grip slips

  1. highFinding Your Way+15 pts if fixed

    No explicit architecture overview or codebase map

    The snapshot contains 5800+ files and no top-level architecture document (e.g., `ARCHITECTURE.md`) explaining how transformers, tokenizers, pipelines, and training utilities fit together. A newcomer must dive into code or extensive docs to build a mental model. The Makefile references 'modeling_structure' checks but doesn't explain what that validates. Getting lost navigating the codebase is highly likely.

    Fix: Create an `ARCHITECTURE.md` in the root that sketches the main modules (models/, tokenizers/, pipelines/, training/), their relationships, and entry points (e.g., 'start here to load a model' vs. 'start here to fine-tune'). Include a dependency graph or visual flowchart. Reference it from the README.

  2. highPath To Contribute+12 pts if fixed

    Discouraging tone in CONTRIBUTING.md creates friction for human newcomers

    The opening WARNING blocks AI-agent PRs and advises 'new users do not submit pure code agent PRs,' closes 'agent-written' PRs without review, discourages 'small or busywork PRs' like typos, and warns 'we don't have time for small style changes.' A human newcomer—especially one uncertain about repo norms—may read this as 'don't bother' and bounce off without trying. The list of valued contributions (root-cause diagnosis, minimal diffs) is intimidating for a first-time contributor.

    Fix: Reframe CONTRIBUTING.md to welcome newcomers while managing agent-PR load. Move the AI-agent warning to a distinct subsection (e.g., '### Note on Autonomous Agents'). Follow the warning with a clear, positive statement: 'We warmly welcome contributions from humans. If you're unsure whether your idea is welcome, open a [Discussion](link) first or ask in an issue.' Add a 'Good First Issues' section that links to actual beginner-friendly issues (curated with GitHub label like `good-first-issue`). Soften language around 'busywork'—e.g., 'We're currently prioritizing bug fixes and feature PRs; docs and typo improvements are welcome too but may have longer review times.'

  3. mediumGetting Running+10 pts if fixed

    Development setup and dependency info scattered across docs

    Full dependency list is not shown in the pyproject.toml snippet; instead, devs must cross-reference Makefile, CONTRIBUTING.md, and docs to find all steps (install extras, run tests, build docs). A newcomer clone-and-installing `pip install '.[torch]'` may not get the test runner, type checker, or linting tools they need to contribute.

    Fix: Expand the pyproject.toml snippet to show all dependencies (core, dev, optional extras clearly separated). Add a concise 'Developer Setup' section to README that references pyproject.toml, lists the Makefile targets for dev tasks (`make test`, `make check-code-quality`), and explains what each does. Example: 'Run `make test` to execute the test suite; run `make check-repo` to validate code quality before submitting a PR.'

  4. mediumPath To Contribute+8 pts if fixed

    No beginner-labeled issues visible; contribution ramp is unclear

    The snapshot shows issue templates (bug-report.yml, feature-request.yml, new-model-addition.yml) but does not surface any issues labeled `good-first-issue` or `beginner-friendly`. A newcomer cannot easily find an entry point to contribute code. The 2435 open issues are likely a mix of bug, feature, and discussion; without labels or curation, a newcomer will struggle to find something appropriate for their skill level.

    Fix: Curate and label at least 10–20 open issues with `good-first-issue` or `beginner-friendly` and ensure they have clear reproduction steps (for bugs) or acceptance criteria (for features). Mention this curation in CONTRIBUTING.md: 'See [Issues labeled `good-first-issue`](URL) for a curated list of tasks suitable for your first contribution.' Alternatively, add a 'First Contribution' discussion or guide in `.github/` or the docs.

  5. mediumGetting Running+8 pts if fixed

    Dependency versions not pinned in setup files; 'works on my machine' risk

    The pyproject.toml snippet shows tool configuration (ruff, pytest) but does not show the full dependencies list or whether they are pinned (e.g., `transformers>=4.30.0` vs. `transformers==4.30.0`). A newcomer installing dev dependencies may get incompatible versions of PyTorch, tokenizers, or other libs, leading to test failures that are not their fault. The README specifies Python 3.10+ and PyTorch 2.4+ floors, but optional extras and dev-tool versions are not explicitly locked.

    Fix: Include a `requirements-dev.txt` or expand `pyproject.toml` to show pinned dev-dependency versions (e.g., via a [dev] extras group or lock file like `poetry.lock`). Document this in the README or CONTRIBUTING.md: 'For development, install with `pip install -e '.[dev]'` to get pinned versions of linting and testing tools.' Ensure CI/CD is reproducible by committing a lock file or using a `--require-hashes` approach.

  6. lowFinding Your Way+5 pts if fixed

    Makefile checker targets are cryptic; no guide to what they do

    The Makefile defines targets like `check-code-quality`, `check-repository-consistency`, `typing`, and lists checkers (ruff_check, types, modeling_structure, dummies, etc.) but never explains what each checker does or why a contributor should care. A newcomer running `make check-repo` will see errors they don't understand. The comment 'The two CI jobs own the canonical sets below' implies a CI/CD setup but doesn't help a local dev.

    Fix: Add a section to CONTRIBUTING.md called 'Code Quality & Consistency Checks' that lists each Makefile target, what it does, and when to run it. Example: '`make check-code-quality` runs ruff linting, type checking, and import sorting; run this before pushing.' Include a table or list mapping checker names to their purpose (e.g., 'modeling_structure: validates that all models follow consistent architectural patterns'). Optionally, enhance the Makefile itself with comment headers for each checker list.

Show your score

Latch badge
[![Latch score](https://latch.fyi/api/badge/806c54dc-45a6-440e-84be-bf6052c19851)](https://latch.fyi/huggingface/transformers)

Share this analysis

https://latch.fyi/huggingface/transformers

Fixed some issues? Re-analyze to measure your progress →

Copy the whole report

Grab the entire verdict in one go — a Markdown block for a README or an issue, plain text, or a prompt you can paste straight into an LLM.

Was this verdict fair?

One tap helps — or tell us more.