Agent skill · Code Review & Quality

transformers-js

Run Hugging Face models in JavaScript or TypeScript with Transformers.js in Node.js or the browser.

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill transformers-js --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 22 KB
Bundled scripts: none
Version: 3.8.1
Declared author: huggingface
Requires: Requires Node.js 18+ or modern browser with ES modules support. WebGPU support requires compatible browser/environment.…
Path: skills/ai-ml/transformers-js/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

Review
written from the skill's own SKILL.md · Aug 5, 2026

What it does

Runs Hugging Face models in JavaScript or TypeScript with Transformers.js in Node.js or the browser.

How it works

  • Provides a Pipeline API to simplify preprocessing, inference, and postprocessing for tasks like text classification, translation, summarization, and more.
  • Allows specifying a model by ID when creating a pipeline, e.g., pipeline('text-classification', 'model-id').
  • Supports device selection (CPU by default; optional WebGPU for GPU acceleration).
  • Supports quantization options (e.g., dtype: 'q4', 'q8', etc.) to trade accuracy for speed/size.
  • Includes a Browser/Node usage path via npm install and CDN import.
  • Emphasizes memory management by disposing pipelines when finished (pipe.dispose()).
  • Encourages model discovery on Hugging Face Hub and provides example model IDs.
  • Offers advanced environment configuration (env) for loading remote/local models, caching, and paths.
  • Documents a variety of tasks across NLP, Computer Vision, Audio, and Multimodal pipelines, with code examples for setup and use.

When to use it

  • You need to run ML models client-side or in Node.js without a backend.
  • You want to perform text analysis, generation, translation, image tasks, audio processing, or multimodal tasks in JavaScript/TypeScript.
  • You require optional GPU acceleration via WebGPU or quantized models for performance/cost trade-offs.
  • You need a straightforward way to fetch or load models from Hugging Face Hub or use local models with caching.

What it can touch

  • Code paths for npm installation: npm install @huggingface/transformers.
  • Browser CDN usage: import { pipeline } from 'https://cdn.jsdelivr.net/npm/@huggingface/transformers';.
  • Model loading via pipeline(...) with model-id and optional config such as dtype and device.
  • Environment configuration via env from @huggingface/transformers to control remote/local models, caching, and paths.
  • Tokenizers and models loaded with AutoTokenizer and AutoModel as shown in examples.

Caveats

  • Compatibility requires Node.js 18+ or a modern browser with ES modules support; WebGPU support is conditional on browser/environment.
  • Internet access may be needed to download models from Hugging Face Hub (local models can be used if available).
  • Memory management is manual; pipelines must be disposed to prevent leaks.
  • The skill notes risk status as unknown.
From the SKILL.md

# Transformers.js - Machine Learning for JavaScript Transformers.js enables running state-of-the-art machine learning models directly in JavaScript, both in browsers and Node.js environments, with no server required. ## When to Use This Skill Use this skill when you need to: - Run ML models for text analysis, generation, or translation in JavaScript - Perform image classification, object detection, or segmentation - Implement speech recognition or audio processing - Build multimodal AI applications (text-to-image, image-to-text, etc.) - Run models client-side in the browser without a backend ## Installation ### NPM Installation ```bash npm install @huggingface/transformers ``` ### Browser Usage (CDN) ```javascript <script type="module"> import { pipeline } from 'https://cdn.jsdelivr.net/npm/@huggingface/transformers'; </script> ``` ## Core Concepts ### 1. Pipeline API The pipeline API is the easiest way to use models. It groups together preprocessing, model inference, and postprocessing: ```javascript import { pipeline } from '@huggingface/transformers'; // Create a pipeline for a specific task const pipe = await pipeline('sentiment-analysis'); // Use the pipeline const result = aw

What's inside
Steps it walks through
  1. When to Use This Skill
  2. Installation
  3. NPM Installation
  4. Browser Usage (CDN)
  5. Core Concepts
  6. 1. Pipeline API
  7. 2. Model Selection
  8. 3. Device Selection
  9. 4. Quantization Options
  10. Supported Tasks
  11. Natural Language Processing
  12. Computer Vision
  13. Audio Processing
  14. Multimodal
Ships with 1 file
  • metadata.json
Commands it runs
npm install @huggingface/transformers
More from claude-skill-registry
All skills →
About this skill
What does the transformers-js skill do?

Run Hugging Face models in JavaScript or TypeScript with Transformers.js in Node.js or the browser.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill transformers-js --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going