Buckets:
| <meta charset="utf-8" /><meta name="hf:doc:metadata" content="{"title":"Recommended Transformers.js Models for First-Time Trials","local":"recommended-transformersjs-models-for-first-time-trials","sections":[{"title":"About the Model Recommendations","local":"about-the-model-recommendations","sections":[],"depth":2},{"title":"Audio-Classification","local":"audio-classification","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"onnx-community/Musical-genres-Classification-Hubert-V1-ONNX","local":"onnx-communitymusical-genres-classification-hubert-v1-onnx","sections":[],"depth":4},{"title":"Xenova/ast-finetuned-audioset-10-10-0.4593","local":"xenovaast-finetuned-audioset-10-10-04593","sections":[],"depth":4},{"title":"Xenova/ast-finetuned-speech-commands-v2","local":"xenovaast-finetuned-speech-commands-v2","sections":[],"depth":4},{"title":"onnx-community/Speech-Emotion-Classification-ONNX","local":"onnx-communityspeech-emotion-classification-onnx","sections":[],"depth":4},{"title":"Xenova/wav2vec2-base-superb-ks","local":"xenovawav2vec2-base-superb-ks","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Automatic-Speech-Recognition","local":"automatic-speech-recognition","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/whisper-tiny.en","local":"xenovawhisper-tinyen","sections":[],"depth":4},{"title":"Xenova/whisper-tiny","local":"xenovawhisper-tiny","sections":[],"depth":4},{"title":"onnx-community/moonshine-base-ONNX","local":"onnx-communitymoonshine-base-onnx","sections":[],"depth":4},{"title":"onnx-community/whisper-base","local":"onnx-communitywhisper-base","sections":[],"depth":4},{"title":"Xenova/whisper-base.en","local":"xenovawhisper-baseen","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Depth-Estimation","local":"depth-estimation","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/depth-anything-small-hf","local":"xenovadepth-anything-small-hf","sections":[],"depth":4},{"title":"onnx-community/depth-anything-v2-small","local":"onnx-communitydepth-anything-v2-small","sections":[],"depth":4},{"title":"onnx-community/metric3d-vit-small","local":"onnx-communitymetric3d-vit-small","sections":[],"depth":4},{"title":"Xenova/glpn-nyu","local":"xenovaglpn-nyu","sections":[],"depth":4},{"title":"Xenova/glpn-kitti","local":"xenovaglpn-kitti","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Feature-Extraction","local":"feature-extraction","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/all-MiniLM-L6-v2","local":"xenovaall-minilm-l6-v2","sections":[],"depth":4},{"title":"Xenova/bge-base-en-v1.5","local":"xenovabge-base-en-v15","sections":[],"depth":4},{"title":"Xenova/gte-small","local":"xenovagte-small","sections":[],"depth":4},{"title":"onnx-community/bert_uncased_L-2_H-128_A-2-ONNX","local":"onnx-communitybertuncasedl-2h-128a-2-onnx","sections":[],"depth":4},{"title":"Xenova/paraphrase-albert-base-v2","local":"xenovaparaphrase-albert-base-v2","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Fill-Mask","local":"fill-mask","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/distilbert-base-uncased","local":"xenovadistilbert-base-uncased","sections":[],"depth":4},{"title":"Xenova/bert-base-uncased","local":"xenovabert-base-uncased","sections":[],"depth":4},{"title":"Xenova/albert-base-v2","local":"xenovaalbert-base-v2","sections":[],"depth":4},{"title":"Xenova/distilbert-base-cased","local":"xenovadistilbert-base-cased","sections":[],"depth":4},{"title":"Xenova/albert-large-v2","local":"xenovaalbert-large-v2","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Image-Classification","local":"image-classification","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/vit-base-patch16-224","local":"xenovavit-base-patch16-224","sections":[],"depth":4},{"title":"Xenova/facial_emotions_image_detection","local":"xenovafacialemotionsimagedetection","sections":[],"depth":4},{"title":"Xenova/resnet-18","local":"xenovaresnet-18","sections":[],"depth":4},{"title":"Xenova/resnet-50","local":"xenovaresnet-50","sections":[],"depth":4},{"title":"onnx-community/mobilenet_v2_1.0_224","local":"onnx-communitymobilenetv210224","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Image-Feature-Extraction","local":"image-feature-extraction","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX","local":"onnx-communitydinov3-vits16-pretrain-lvd1689m-onnx","sections":[],"depth":4},{"title":"Xenova/dino-vits16","local":"xenovadino-vits16","sections":[],"depth":4},{"title":"onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX-MHA-scores","local":"onnx-communitydinov3-vits16-pretrain-lvd1689m-onnx-mha-scores","sections":[],"depth":4},{"title":"onnx-community/dinov2-small-ONNX","local":"onnx-communitydinov2-small-onnx","sections":[],"depth":4},{"title":"onnx-community/dinov2-with-registers-small","local":"onnx-communitydinov2-with-registers-small","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Image-Segmentation","local":"image-segmentation","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/segformer-b0-finetuned-ade-512-512","local":"xenovasegformer-b0-finetuned-ade-512-512","sections":[],"depth":4},{"title":"Xenova/modnet","local":"xenovamodnet","sections":[],"depth":4},{"title":"onnx-community/modnet-webnn","local":"onnx-communitymodnet-webnn","sections":[],"depth":4},{"title":"Xenova/segformer_b0_clothes","local":"xenovasegformerb0clothes","sections":[],"depth":4},{"title":"Xenova/segformer-b0-finetuned-cityscapes-1024-1024","local":"xenovasegformer-b0-finetuned-cityscapes-1024-1024","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Image-To-Image","local":"image-to-image","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/2x_APISR_RRDB_GAN_generator-onnx","local":"xenova2xapisrrrdbgangenerator-onnx","sections":[],"depth":4},{"title":"Xenova/4x_APISR_GRL_GAN_generator-onnx","local":"xenova4xapisrgrlgangenerator-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Object-Detection","local":"object-detection","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/detr-resnet-50","local":"xenovadetr-resnet-50","sections":[],"depth":4},{"title":"Xenova/yolos-tiny","local":"xenovayolos-tiny","sections":[],"depth":4},{"title":"onnx-community/rfdetr_base-ONNX","local":"onnx-communityrfdetrbase-onnx","sections":[],"depth":4},{"title":"Xenova/yolos-small-300","local":"xenovayolos-small-300","sections":[],"depth":4},{"title":"onnx-community/rfdetr_medium-ONNX","local":"onnx-communityrfdetrmedium-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Question-Answering","local":"question-answering","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/distilbert-base-cased-distilled-squad","local":"xenovadistilbert-base-cased-distilled-squad","sections":[],"depth":4},{"title":"onnx-community/rubert_tiny_qa_kontur-ONNX","local":"onnx-communityruberttinyqakontur-onnx","sections":[],"depth":4},{"title":"Xenova/distilbert-base-uncased-distilled-squad","local":"xenovadistilbert-base-uncased-distilled-squad","sections":[],"depth":4},{"title":"onnx-community/xlm-roberta-base-squad2-distilled-ONNX","local":"onnx-communityxlm-roberta-base-squad2-distilled-onnx","sections":[],"depth":4},{"title":"onnx-community/mobilebert-uncased-squad-v2-ONNX","local":"onnx-communitymobilebert-uncased-squad-v2-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Summarization","local":"summarization","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/distilbart-cnn-6-6","local":"xenovadistilbart-cnn-6-6","sections":[],"depth":4},{"title":"Xenova/distilbart-xsum-12-1","local":"xenovadistilbart-xsum-12-1","sections":[],"depth":4},{"title":"Xenova/distilbart-xsum-6-6","local":"xenovadistilbart-xsum-6-6","sections":[],"depth":4},{"title":"Xenova/distilbart-xsum-9-6","local":"xenovadistilbart-xsum-9-6","sections":[],"depth":4},{"title":"Xenova/distilbart-cnn-12-3","local":"xenovadistilbart-cnn-12-3","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Text-Classification","local":"text-classification","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/distilbert-base-uncased-finetuned-sst-2-english","local":"xenovadistilbert-base-uncased-finetuned-sst-2-english","sections":[],"depth":4},{"title":"Xenova/ms-marco-MiniLM-L-6-v2","local":"xenovams-marco-minilm-l-6-v2","sections":[],"depth":4},{"title":"Xenova/ms-marco-TinyBERT-L-2-v2","local":"xenovams-marco-tinybert-l-2-v2","sections":[],"depth":4},{"title":"Xenova/toxic-bert","local":"xenovatoxic-bert","sections":[],"depth":4},{"title":"onnx-community/language_detection-ONNX","local":"onnx-communitylanguagedetection-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Text-Generation","local":"text-generation","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/distilgpt2","local":"xenovadistilgpt2","sections":[],"depth":4},{"title":"Xenova/llama2.c-stories15M","local":"xenovallama2c-stories15m","sections":[],"depth":4},{"title":"onnx-community/ettin-decoder-17m-ONNX","local":"onnx-communityettin-decoder-17m-onnx","sections":[],"depth":4},{"title":"onnx-community/Lamina-extend-ONNX","local":"onnx-communitylamina-extend-onnx","sections":[],"depth":4},{"title":"onnx-community/chess-llama-ONNX","local":"onnx-communitychess-llama-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Token-Classification","local":"token-classification","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"onnx-community/NeuroBERT-NER-ONNX","local":"onnx-communityneurobert-ner-onnx","sections":[],"depth":4},{"title":"onnx-community/TinyBERT-finetuned-NER-ONNX","local":"onnx-communitytinybert-finetuned-ner-onnx","sections":[],"depth":4},{"title":"Xenova/esm2_t6_8M_UR50D_rna_binding_site_predictor","local":"xenovaesm2t68mur50drnabindingsitepredictor","sections":[],"depth":4},{"title":"onnx-community/distilbert-NER-ONNX","local":"onnx-communitydistilbert-ner-onnx","sections":[],"depth":4},{"title":"onnx-community/small-e-czech-finetuned-ner-wikiann-ONNX","local":"onnx-communitysmall-e-czech-finetuned-ner-wikiann-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Translation","local":"translation","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/opus-mt-en-es","local":"xenovaopus-mt-en-es","sections":[],"depth":4},{"title":"Xenova/opus-mt-zh-en","local":"xenovaopus-mt-zh-en","sections":[],"depth":4},{"title":"Xenova/opus-mt-en-zh","local":"xenovaopus-mt-en-zh","sections":[],"depth":4},{"title":"Xenova/opus-mt-en-fr","local":"xenovaopus-mt-en-fr","sections":[],"depth":4},{"title":"Xenova/opus-mt-ar-en","local":"xenovaopus-mt-ar-en","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"About These Recommendations","local":"about-these-recommendations","sections":[{"title":"Selection Criteria","local":"selection-criteria","sections":[],"depth":3},{"title":"Understanding Benchmark Metrics","local":"understanding-benchmark-metrics","sections":[],"depth":3},{"title":"For Production Use","local":"for-production-use","sections":[],"depth":3}],"depth":2}],"depth":1}"> | |
| <link href="/docs/transformers.js/pr_1452/en/_app/immutable/assets/0.e3b0c442.css" rel="modulepreload"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/entry/start.59e52715.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/chunks/scheduler.6efaaf90.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/chunks/singletons.a484fb59.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/chunks/paths.6f9ae3f4.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/entry/app.17425e4e.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/chunks/preload-helper.1c30ebd1.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/chunks/index.eb3e1f0f.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/nodes/0.b0328ddf.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/chunks/each.e59479a4.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/nodes/24.437c9e3e.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/chunks/MermaidChart.svelte_svelte_type_style_lang.95efcab6.js"> | |
| <link rel="modulepreload" href="/docs/transformers.js/pr_1452/en/_app/immutable/chunks/CodeBlock.df907707.js"><!-- HEAD_svelte-u9bgzb_START --><meta name="hf:doc:metadata" content="{"title":"Recommended Transformers.js Models for First-Time Trials","local":"recommended-transformersjs-models-for-first-time-trials","sections":[{"title":"About the Model Recommendations","local":"about-the-model-recommendations","sections":[],"depth":2},{"title":"Audio-Classification","local":"audio-classification","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"onnx-community/Musical-genres-Classification-Hubert-V1-ONNX","local":"onnx-communitymusical-genres-classification-hubert-v1-onnx","sections":[],"depth":4},{"title":"Xenova/ast-finetuned-audioset-10-10-0.4593","local":"xenovaast-finetuned-audioset-10-10-04593","sections":[],"depth":4},{"title":"Xenova/ast-finetuned-speech-commands-v2","local":"xenovaast-finetuned-speech-commands-v2","sections":[],"depth":4},{"title":"onnx-community/Speech-Emotion-Classification-ONNX","local":"onnx-communityspeech-emotion-classification-onnx","sections":[],"depth":4},{"title":"Xenova/wav2vec2-base-superb-ks","local":"xenovawav2vec2-base-superb-ks","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Automatic-Speech-Recognition","local":"automatic-speech-recognition","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/whisper-tiny.en","local":"xenovawhisper-tinyen","sections":[],"depth":4},{"title":"Xenova/whisper-tiny","local":"xenovawhisper-tiny","sections":[],"depth":4},{"title":"onnx-community/moonshine-base-ONNX","local":"onnx-communitymoonshine-base-onnx","sections":[],"depth":4},{"title":"onnx-community/whisper-base","local":"onnx-communitywhisper-base","sections":[],"depth":4},{"title":"Xenova/whisper-base.en","local":"xenovawhisper-baseen","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Depth-Estimation","local":"depth-estimation","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/depth-anything-small-hf","local":"xenovadepth-anything-small-hf","sections":[],"depth":4},{"title":"onnx-community/depth-anything-v2-small","local":"onnx-communitydepth-anything-v2-small","sections":[],"depth":4},{"title":"onnx-community/metric3d-vit-small","local":"onnx-communitymetric3d-vit-small","sections":[],"depth":4},{"title":"Xenova/glpn-nyu","local":"xenovaglpn-nyu","sections":[],"depth":4},{"title":"Xenova/glpn-kitti","local":"xenovaglpn-kitti","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Feature-Extraction","local":"feature-extraction","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/all-MiniLM-L6-v2","local":"xenovaall-minilm-l6-v2","sections":[],"depth":4},{"title":"Xenova/bge-base-en-v1.5","local":"xenovabge-base-en-v15","sections":[],"depth":4},{"title":"Xenova/gte-small","local":"xenovagte-small","sections":[],"depth":4},{"title":"onnx-community/bert_uncased_L-2_H-128_A-2-ONNX","local":"onnx-communitybertuncasedl-2h-128a-2-onnx","sections":[],"depth":4},{"title":"Xenova/paraphrase-albert-base-v2","local":"xenovaparaphrase-albert-base-v2","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Fill-Mask","local":"fill-mask","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/distilbert-base-uncased","local":"xenovadistilbert-base-uncased","sections":[],"depth":4},{"title":"Xenova/bert-base-uncased","local":"xenovabert-base-uncased","sections":[],"depth":4},{"title":"Xenova/albert-base-v2","local":"xenovaalbert-base-v2","sections":[],"depth":4},{"title":"Xenova/distilbert-base-cased","local":"xenovadistilbert-base-cased","sections":[],"depth":4},{"title":"Xenova/albert-large-v2","local":"xenovaalbert-large-v2","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Image-Classification","local":"image-classification","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/vit-base-patch16-224","local":"xenovavit-base-patch16-224","sections":[],"depth":4},{"title":"Xenova/facial_emotions_image_detection","local":"xenovafacialemotionsimagedetection","sections":[],"depth":4},{"title":"Xenova/resnet-18","local":"xenovaresnet-18","sections":[],"depth":4},{"title":"Xenova/resnet-50","local":"xenovaresnet-50","sections":[],"depth":4},{"title":"onnx-community/mobilenet_v2_1.0_224","local":"onnx-communitymobilenetv210224","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Image-Feature-Extraction","local":"image-feature-extraction","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX","local":"onnx-communitydinov3-vits16-pretrain-lvd1689m-onnx","sections":[],"depth":4},{"title":"Xenova/dino-vits16","local":"xenovadino-vits16","sections":[],"depth":4},{"title":"onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX-MHA-scores","local":"onnx-communitydinov3-vits16-pretrain-lvd1689m-onnx-mha-scores","sections":[],"depth":4},{"title":"onnx-community/dinov2-small-ONNX","local":"onnx-communitydinov2-small-onnx","sections":[],"depth":4},{"title":"onnx-community/dinov2-with-registers-small","local":"onnx-communitydinov2-with-registers-small","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Image-Segmentation","local":"image-segmentation","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/segformer-b0-finetuned-ade-512-512","local":"xenovasegformer-b0-finetuned-ade-512-512","sections":[],"depth":4},{"title":"Xenova/modnet","local":"xenovamodnet","sections":[],"depth":4},{"title":"onnx-community/modnet-webnn","local":"onnx-communitymodnet-webnn","sections":[],"depth":4},{"title":"Xenova/segformer_b0_clothes","local":"xenovasegformerb0clothes","sections":[],"depth":4},{"title":"Xenova/segformer-b0-finetuned-cityscapes-1024-1024","local":"xenovasegformer-b0-finetuned-cityscapes-1024-1024","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Image-To-Image","local":"image-to-image","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/2x_APISR_RRDB_GAN_generator-onnx","local":"xenova2xapisrrrdbgangenerator-onnx","sections":[],"depth":4},{"title":"Xenova/4x_APISR_GRL_GAN_generator-onnx","local":"xenova4xapisrgrlgangenerator-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Object-Detection","local":"object-detection","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/detr-resnet-50","local":"xenovadetr-resnet-50","sections":[],"depth":4},{"title":"Xenova/yolos-tiny","local":"xenovayolos-tiny","sections":[],"depth":4},{"title":"onnx-community/rfdetr_base-ONNX","local":"onnx-communityrfdetrbase-onnx","sections":[],"depth":4},{"title":"Xenova/yolos-small-300","local":"xenovayolos-small-300","sections":[],"depth":4},{"title":"onnx-community/rfdetr_medium-ONNX","local":"onnx-communityrfdetrmedium-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Question-Answering","local":"question-answering","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/distilbert-base-cased-distilled-squad","local":"xenovadistilbert-base-cased-distilled-squad","sections":[],"depth":4},{"title":"onnx-community/rubert_tiny_qa_kontur-ONNX","local":"onnx-communityruberttinyqakontur-onnx","sections":[],"depth":4},{"title":"Xenova/distilbert-base-uncased-distilled-squad","local":"xenovadistilbert-base-uncased-distilled-squad","sections":[],"depth":4},{"title":"onnx-community/xlm-roberta-base-squad2-distilled-ONNX","local":"onnx-communityxlm-roberta-base-squad2-distilled-onnx","sections":[],"depth":4},{"title":"onnx-community/mobilebert-uncased-squad-v2-ONNX","local":"onnx-communitymobilebert-uncased-squad-v2-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Summarization","local":"summarization","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/distilbart-cnn-6-6","local":"xenovadistilbart-cnn-6-6","sections":[],"depth":4},{"title":"Xenova/distilbart-xsum-12-1","local":"xenovadistilbart-xsum-12-1","sections":[],"depth":4},{"title":"Xenova/distilbart-xsum-6-6","local":"xenovadistilbart-xsum-6-6","sections":[],"depth":4},{"title":"Xenova/distilbart-xsum-9-6","local":"xenovadistilbart-xsum-9-6","sections":[],"depth":4},{"title":"Xenova/distilbart-cnn-12-3","local":"xenovadistilbart-cnn-12-3","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Text-Classification","local":"text-classification","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/distilbert-base-uncased-finetuned-sst-2-english","local":"xenovadistilbert-base-uncased-finetuned-sst-2-english","sections":[],"depth":4},{"title":"Xenova/ms-marco-MiniLM-L-6-v2","local":"xenovams-marco-minilm-l-6-v2","sections":[],"depth":4},{"title":"Xenova/ms-marco-TinyBERT-L-2-v2","local":"xenovams-marco-tinybert-l-2-v2","sections":[],"depth":4},{"title":"Xenova/toxic-bert","local":"xenovatoxic-bert","sections":[],"depth":4},{"title":"onnx-community/language_detection-ONNX","local":"onnx-communitylanguagedetection-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Text-Generation","local":"text-generation","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/distilgpt2","local":"xenovadistilgpt2","sections":[],"depth":4},{"title":"Xenova/llama2.c-stories15M","local":"xenovallama2c-stories15m","sections":[],"depth":4},{"title":"onnx-community/ettin-decoder-17m-ONNX","local":"onnx-communityettin-decoder-17m-onnx","sections":[],"depth":4},{"title":"onnx-community/Lamina-extend-ONNX","local":"onnx-communitylamina-extend-onnx","sections":[],"depth":4},{"title":"onnx-community/chess-llama-ONNX","local":"onnx-communitychess-llama-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Token-Classification","local":"token-classification","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"onnx-community/NeuroBERT-NER-ONNX","local":"onnx-communityneurobert-ner-onnx","sections":[],"depth":4},{"title":"onnx-community/TinyBERT-finetuned-NER-ONNX","local":"onnx-communitytinybert-finetuned-ner-onnx","sections":[],"depth":4},{"title":"Xenova/esm2_t6_8M_UR50D_rna_binding_site_predictor","local":"xenovaesm2t68mur50drnabindingsitepredictor","sections":[],"depth":4},{"title":"onnx-community/distilbert-NER-ONNX","local":"onnx-communitydistilbert-ner-onnx","sections":[],"depth":4},{"title":"onnx-community/small-e-czech-finetuned-ner-wikiann-ONNX","local":"onnx-communitysmall-e-czech-finetuned-ner-wikiann-onnx","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"Translation","local":"translation","sections":[{"title":"Recommended Models for First-Time Trials","local":"recommended-models-for-first-time-trials","sections":[{"title":"Xenova/opus-mt-en-es","local":"xenovaopus-mt-en-es","sections":[],"depth":4},{"title":"Xenova/opus-mt-zh-en","local":"xenovaopus-mt-zh-en","sections":[],"depth":4},{"title":"Xenova/opus-mt-en-zh","local":"xenovaopus-mt-en-zh","sections":[],"depth":4},{"title":"Xenova/opus-mt-en-fr","local":"xenovaopus-mt-en-fr","sections":[],"depth":4},{"title":"Xenova/opus-mt-ar-en","local":"xenovaopus-mt-ar-en","sections":[],"depth":4}],"depth":3}],"depth":2},{"title":"About These Recommendations","local":"about-these-recommendations","sections":[{"title":"Selection Criteria","local":"selection-criteria","sections":[],"depth":3},{"title":"Understanding Benchmark Metrics","local":"understanding-benchmark-metrics","sections":[],"depth":3},{"title":"For Production Use","local":"for-production-use","sections":[],"depth":3}],"depth":2}],"depth":1}"><!-- HEAD_svelte-u9bgzb_END --> <p></p> <div class="items-center shrink-0 min-w-[100px] max-sm:min-w-[50px] justify-end ml-auto flex" style="float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"><div class="inline-flex rounded-md max-sm:rounded-sm"><button class="inline-flex items-center gap-1 max-sm:gap-0.5 h-6 max-sm:h-5 px-2 max-sm:px-1.5 text-[11px] max-sm:text-[9px] font-medium text-gray-800 border border-r-0 rounded-l-md max-sm:rounded-l-sm border-gray-200 bg-white hover:shadow-inner dark:border-gray-850 dark:bg-gray-950 dark:text-gray-200 dark:hover:bg-gray-800" aria-live="polite"><span class="inline-flex items-center justify-center rounded-md p-0.5 max-sm:p-0"><svg class="w-3 h-3 max-sm:w-2.5 max-sm:h-2.5" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg></span> <span>Copy page</span></button> <button class="inline-flex items-center justify-center w-6 max-sm:w-5 h-6 max-sm:h-5 disabled:pointer-events-none text-sm text-gray-500 hover:text-gray-700 dark:hover:text-white rounded-r-md max-sm:rounded-r-sm border border-l transition border-gray-200 bg-white hover:shadow-inner dark:border-gray-850 dark:bg-gray-950 dark:text-gray-200 dark:hover:bg-gray-800" aria-haspopup="menu" aria-expanded="false" aria-label="Open copy menu"><svg class="transition-transform text-gray-400 overflow-visible w-3 h-3 max-sm:w-2.5 max-sm:h-2.5 rotate-0" width="1em" height="1em" viewBox="0 0 12 7" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M1 1L6 6L11 1" stroke="currentColor"></path></svg></button></div> </div> <h1 class="relative group"><a id="recommended-transformersjs-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-transformersjs-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Transformers.js Models for First-Time Trials</span></h1> <p data-svelte-h="svelte-1ougmmw">This guide provides curated model recommendations for each task type, selected for their:</p> <ul data-svelte-h="svelte-1dbanq0"><li><strong>Popularity</strong>: Widely used with strong community support</li> <li><strong>Performance</strong>: Fast loading and inference times</li> <li><strong>WebGPU Compatibility</strong>: GPU-accelerated in modern browsers</li></ul> <p data-svelte-h="svelte-4pu6lu"><strong>Important:</strong> These recommendations are designed for initial experimentation and learning. Many other models are available for each task. <strong>You should evaluate and choose the best model for your specific use case, performance requirements, and constraints.</strong></p> <h2 class="relative group"><a id="about-the-model-recommendations" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#about-the-model-recommendations"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>About the Model Recommendations</span></h2> <p data-svelte-h="svelte-pjn9by">The models below are selected for their popularity and ease of use, making them ideal for initial experimentation. <strong>This list does not cover all available models</strong> - you should evaluate and select the best model for your specific use case and requirements.</p> <h2 class="relative group"><a id="audio-classification" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#audio-classification"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Audio-Classification</span></h2> <p data-svelte-h="svelte-h5u9p"><strong>Usage Example:</strong> Perform audio classification</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> classifier = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'audio-classification'</span>, <span class="hljs-string">'onnx-community/Musical-genres-Classification-Hubert-V1-ONNX'</span>); | |
| <span class="hljs-keyword">const</span> url = <span class="hljs-string">'https://huggingface.co/datasets/Xenova/transformers.js-docs/resolve/main/jfk.wav'</span>; | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">classifier</span>(url);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="onnx-communitymusical-genres-classification-hubert-v1-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitymusical-genres-classification-hubert-v1-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/Musical-genres-Classification-Hubert-V1-ONNX</span></h4> <ul data-svelte-h="svelte-176vo66"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/Musical-genres-Classification-Hubert-V1-ONNX" rel="nofollow">https://huggingface.co/onnx-community/Musical-genres-Classification-Hubert-V1-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 264.4ms | Inference: 136.5ms</li></ul> <h4 class="relative group"><a id="xenovaast-finetuned-audioset-10-10-04593" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaast-finetuned-audioset-10-10-04593"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/ast-finetuned-audioset-10-10-0.4593</span></h4> <ul data-svelte-h="svelte-cde445"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/ast-finetuned-audioset-10-10-0.4593" rel="nofollow">https://huggingface.co/Xenova/ast-finetuned-audioset-10-10-0.4593</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 2827.1ms | Inference: 544.1ms</li></ul> <h4 class="relative group"><a id="xenovaast-finetuned-speech-commands-v2" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaast-finetuned-speech-commands-v2"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/ast-finetuned-speech-commands-v2</span></h4> <ul data-svelte-h="svelte-11wa7gp"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/ast-finetuned-speech-commands-v2" rel="nofollow">https://huggingface.co/Xenova/ast-finetuned-speech-commands-v2</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 3254.1ms | Inference: 759.0ms</li></ul> <h4 class="relative group"><a id="onnx-communityspeech-emotion-classification-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communityspeech-emotion-classification-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/Speech-Emotion-Classification-ONNX</span></h4> <ul data-svelte-h="svelte-1w70u8q"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/Speech-Emotion-Classification-ONNX" rel="nofollow">https://huggingface.co/onnx-community/Speech-Emotion-Classification-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 3070.4ms | Inference: 574.9ms</li></ul> <h4 class="relative group"><a id="xenovawav2vec2-base-superb-ks" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovawav2vec2-base-superb-ks"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/wav2vec2-base-superb-ks</span></h4> <ul data-svelte-h="svelte-dengdk"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/wav2vec2-base-superb-ks" rel="nofollow">https://huggingface.co/Xenova/wav2vec2-base-superb-ks</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 3211.4ms | Inference: 584.7ms</li></ul> <hr> <h2 class="relative group"><a id="automatic-speech-recognition" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#automatic-speech-recognition"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Automatic-Speech-Recognition</span></h2> <p data-svelte-h="svelte-1nto3h3"><strong>Usage Example:</strong> Transcribe audio from a URL</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> transcriber = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'automatic-speech-recognition'</span>, <span class="hljs-string">'Xenova/whisper-tiny.en'</span>); | |
| <span class="hljs-keyword">const</span> url = <span class="hljs-string">'https://huggingface.co/datasets/Xenova/transformers.js-docs/resolve/main/jfk.wav'</span>; | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">transcriber</span>(url);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovawhisper-tinyen" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovawhisper-tinyen"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/whisper-tiny.en</span></h4> <ul data-svelte-h="svelte-1wiglgx"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/whisper-tiny.en" rel="nofollow">https://huggingface.co/Xenova/whisper-tiny.en</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1045.6ms | Inference: 1314.3ms</li></ul> <h4 class="relative group"><a id="xenovawhisper-tiny" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovawhisper-tiny"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/whisper-tiny</span></h4> <ul data-svelte-h="svelte-1o44kxa"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/whisper-tiny" rel="nofollow">https://huggingface.co/Xenova/whisper-tiny</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1037.2ms | Inference: 1258.4ms</li></ul> <h4 class="relative group"><a id="onnx-communitymoonshine-base-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitymoonshine-base-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/moonshine-base-ONNX</span></h4> <ul data-svelte-h="svelte-1ocbs82"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/moonshine-base-ONNX" rel="nofollow">https://huggingface.co/onnx-community/moonshine-base-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1906.3ms | Inference: 889.1ms</li></ul> <h4 class="relative group"><a id="onnx-communitywhisper-base" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitywhisper-base"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/whisper-base</span></h4> <ul data-svelte-h="svelte-5l1lc1"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/whisper-base" rel="nofollow">https://huggingface.co/onnx-community/whisper-base</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1885.8ms | Inference: 878.9ms</li></ul> <h4 class="relative group"><a id="xenovawhisper-baseen" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovawhisper-baseen"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/whisper-base.en</span></h4> <ul data-svelte-h="svelte-2owhwk"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/whisper-base.en" rel="nofollow">https://huggingface.co/Xenova/whisper-base.en</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1591.3ms | Inference: 1941.5ms</li></ul> <hr> <h2 class="relative group"><a id="depth-estimation" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#depth-estimation"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Depth-Estimation</span></h2> <p data-svelte-h="svelte-1v6eeq6"><strong>Usage Example:</strong> Depth estimation</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> depth_estimator = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'depth-estimation'</span>, <span class="hljs-string">'Xenova/depth-anything-small-hf'</span>); | |
| <span class="hljs-keyword">const</span> url = <span class="hljs-string">'https://huggingface.co/datasets/Xenova/transformers.js-docs/resolve/main/cats.jpg'</span>; | |
| <span class="hljs-keyword">const</span> out = <span class="hljs-keyword">await</span> <span class="hljs-title function_">depth_estimator</span>(url);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovadepth-anything-small-hf" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadepth-anything-small-hf"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/depth-anything-small-hf</span></h4> <ul data-svelte-h="svelte-i1r2j2"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/depth-anything-small-hf" rel="nofollow">https://huggingface.co/Xenova/depth-anything-small-hf</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 414.3ms | Inference: 419.3ms</li></ul> <h4 class="relative group"><a id="onnx-communitydepth-anything-v2-small" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitydepth-anything-v2-small"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/depth-anything-v2-small</span></h4> <ul data-svelte-h="svelte-jdp1so"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/depth-anything-v2-small" rel="nofollow">https://huggingface.co/onnx-community/depth-anything-v2-small</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 450.0ms | Inference: 357.1ms</li></ul> <h4 class="relative group"><a id="onnx-communitymetric3d-vit-small" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitymetric3d-vit-small"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/metric3d-vit-small</span></h4> <ul data-svelte-h="svelte-qxld9s"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/metric3d-vit-small" rel="nofollow">https://huggingface.co/onnx-community/metric3d-vit-small</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 786.2ms | Inference: 515.7ms</li></ul> <h4 class="relative group"><a id="xenovaglpn-nyu" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaglpn-nyu"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/glpn-nyu</span></h4> <ul data-svelte-h="svelte-1uakfhx"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/glpn-nyu" rel="nofollow">https://huggingface.co/Xenova/glpn-nyu</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1454.5ms | Inference: 1076.9ms</li></ul> <h4 class="relative group"><a id="xenovaglpn-kitti" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaglpn-kitti"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/glpn-kitti</span></h4> <ul data-svelte-h="svelte-1picxlf"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/glpn-kitti" rel="nofollow">https://huggingface.co/Xenova/glpn-kitti</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1451.4ms | Inference: 1083.3ms</li></ul> <hr> <h2 class="relative group"><a id="feature-extraction" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#feature-extraction"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Feature-Extraction</span></h2> <p data-svelte-h="svelte-mxaqda"><strong>Usage Example:</strong> Run feature extraction</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> extractor = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'feature-extraction'</span>, <span class="hljs-string">'Xenova/all-MiniLM-L6-v2'</span>); | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">extractor</span>(<span class="hljs-string">'This is a simple test.'</span>);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovaall-minilm-l6-v2" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaall-minilm-l6-v2"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/all-MiniLM-L6-v2</span></h4> <ul data-svelte-h="svelte-1h4mec6"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/all-MiniLM-L6-v2" rel="nofollow">https://huggingface.co/Xenova/all-MiniLM-L6-v2</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 373.5ms | Inference: 143.9ms</li></ul> <h4 class="relative group"><a id="xenovabge-base-en-v15" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovabge-base-en-v15"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/bge-base-en-v1.5</span></h4> <ul data-svelte-h="svelte-1o4hzhd"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/bge-base-en-v1.5" rel="nofollow">https://huggingface.co/Xenova/bge-base-en-v1.5</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 3620.8ms | Inference: 816.4ms</li></ul> <h4 class="relative group"><a id="xenovagte-small" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovagte-small"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/gte-small</span></h4> <ul data-svelte-h="svelte-t86wd9"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/gte-small" rel="nofollow">https://huggingface.co/Xenova/gte-small</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 588.7ms | Inference: 228.4ms</li></ul> <h4 class="relative group"><a id="onnx-communitybertuncasedl-2h-128a-2-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitybertuncasedl-2h-128a-2-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/bert_uncased_L-2_H-128_A-2-ONNX</span></h4> <ul data-svelte-h="svelte-m2ov9i"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/bert_uncased_L-2_H-128_A-2-ONNX" rel="nofollow">https://huggingface.co/onnx-community/bert_uncased_L-2_H-128_A-2-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 110.8ms | Inference: 49.2ms</li></ul> <h4 class="relative group"><a id="xenovaparaphrase-albert-base-v2" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaparaphrase-albert-base-v2"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/paraphrase-albert-base-v2</span></h4> <ul data-svelte-h="svelte-h25nbf"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/paraphrase-albert-base-v2" rel="nofollow">https://huggingface.co/Xenova/paraphrase-albert-base-v2</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 328.8ms | Inference: 39.1ms</li></ul> <hr> <h2 class="relative group"><a id="fill-mask" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#fill-mask"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Fill-Mask</span></h2> <p data-svelte-h="svelte-1yjundw"><strong>Usage Example:</strong> Perform masked language modelling (a.k.a. “fill-mask”)</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> unmasker = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'fill-mask'</span>, <span class="hljs-string">'Xenova/distilbert-base-uncased'</span>); | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">unmasker</span>(<span class="hljs-string">'The goal of life is [MASK].'</span>);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovadistilbert-base-uncased" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilbert-base-uncased"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilbert-base-uncased</span></h4> <ul data-svelte-h="svelte-4se27k"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilbert-base-uncased" rel="nofollow">https://huggingface.co/Xenova/distilbert-base-uncased</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 769.8ms | Inference: 302.4ms</li></ul> <h4 class="relative group"><a id="xenovabert-base-uncased" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovabert-base-uncased"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/bert-base-uncased</span></h4> <ul data-svelte-h="svelte-kykmmy"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/bert-base-uncased" rel="nofollow">https://huggingface.co/Xenova/bert-base-uncased</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 4432.7ms | Inference: 919.4ms</li></ul> <h4 class="relative group"><a id="xenovaalbert-base-v2" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaalbert-base-v2"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/albert-base-v2</span></h4> <ul data-svelte-h="svelte-txa9yq"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/albert-base-v2" rel="nofollow">https://huggingface.co/Xenova/albert-base-v2</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 324.9ms | Inference: 68.1ms</li></ul> <h4 class="relative group"><a id="xenovadistilbert-base-cased" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilbert-base-cased"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilbert-base-cased</span></h4> <ul data-svelte-h="svelte-1ljrttm"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilbert-base-cased" rel="nofollow">https://huggingface.co/Xenova/distilbert-base-cased</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 742.7ms | Inference: 301.1ms</li></ul> <h4 class="relative group"><a id="xenovaalbert-large-v2" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaalbert-large-v2"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/albert-large-v2</span></h4> <ul data-svelte-h="svelte-1xvhnka"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/albert-large-v2" rel="nofollow">https://huggingface.co/Xenova/albert-large-v2</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 499.6ms | Inference: 78.8ms</li></ul> <hr> <h2 class="relative group"><a id="image-classification" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#image-classification"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Image-Classification</span></h2> <p data-svelte-h="svelte-wov8hq"><strong>Usage Example:</strong> Classify an image</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> classifier = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'image-classification'</span>, <span class="hljs-string">'Xenova/vit-base-patch16-224'</span>); | |
| <span class="hljs-keyword">const</span> url = <span class="hljs-string">'https://huggingface.co/datasets/Xenova/transformers.js-docs/resolve/main/tiger.jpg'</span>; | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">classifier</span>(url);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovavit-base-patch16-224" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovavit-base-patch16-224"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/vit-base-patch16-224</span></h4> <ul data-svelte-h="svelte-13r7zzr"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/vit-base-patch16-224" rel="nofollow">https://huggingface.co/Xenova/vit-base-patch16-224</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 2894.1ms | Inference: 476.3ms</li></ul> <h4 class="relative group"><a id="xenovafacialemotionsimagedetection" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovafacialemotionsimagedetection"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/facial_emotions_image_detection</span></h4> <ul data-svelte-h="svelte-ofyhs2"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/facial_emotions_image_detection" rel="nofollow">https://huggingface.co/Xenova/facial_emotions_image_detection</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 2922.3ms | Inference: 479.3ms</li></ul> <h4 class="relative group"><a id="xenovaresnet-18" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaresnet-18"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/resnet-18</span></h4> <ul data-svelte-h="svelte-11utoc9"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/resnet-18" rel="nofollow">https://huggingface.co/Xenova/resnet-18</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 152.1ms | Inference: 90.8ms</li></ul> <h4 class="relative group"><a id="xenovaresnet-50" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaresnet-50"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/resnet-50</span></h4> <ul data-svelte-h="svelte-1hy8frd"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/resnet-50" rel="nofollow">https://huggingface.co/Xenova/resnet-50</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 304.9ms | Inference: 160.5ms</li></ul> <h4 class="relative group"><a id="onnx-communitymobilenetv210224" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitymobilenetv210224"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/mobilenet_v2_1.0_224</span></h4> <ul data-svelte-h="svelte-yo4cre"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/mobilenet_v2_1.0_224" rel="nofollow">https://huggingface.co/onnx-community/mobilenet_v2_1.0_224</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 90.7ms | Inference: 99.7ms</li></ul> <hr> <h2 class="relative group"><a id="image-feature-extraction" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#image-feature-extraction"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Image-Feature-Extraction</span></h2> <p data-svelte-h="svelte-hgkohj"><strong>Usage Example:</strong> Perform image feature extraction</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> image_feature_extractor = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'image-feature-extraction'</span>, <span class="hljs-string">'onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX'</span>); | |
| <span class="hljs-keyword">const</span> url = <span class="hljs-string">'https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/cats.png'</span>; | |
| <span class="hljs-keyword">const</span> features = <span class="hljs-keyword">await</span> <span class="hljs-title function_">image_feature_extractor</span>(url);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="onnx-communitydinov3-vits16-pretrain-lvd1689m-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitydinov3-vits16-pretrain-lvd1689m-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX</span></h4> <ul data-svelte-h="svelte-fk6tac"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX" rel="nofollow">https://huggingface.co/onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 311.4ms | Inference: 352.4ms</li></ul> <h4 class="relative group"><a id="xenovadino-vits16" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadino-vits16"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/dino-vits16</span></h4> <ul data-svelte-h="svelte-17i4cva"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/dino-vits16" rel="nofollow">https://huggingface.co/Xenova/dino-vits16</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 321.7ms | Inference: 247.3ms</li></ul> <h4 class="relative group"><a id="onnx-communitydinov3-vits16-pretrain-lvd1689m-onnx-mha-scores" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitydinov3-vits16-pretrain-lvd1689m-onnx-mha-scores"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX-MHA-scores</span></h4> <ul data-svelte-h="svelte-125sc2w"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX-MHA-scores" rel="nofollow">https://huggingface.co/onnx-community/dinov3-vits16-pretrain-lvd1689m-ONNX-MHA-scores</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 342.8ms | Inference: 259.6ms</li></ul> <h4 class="relative group"><a id="onnx-communitydinov2-small-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitydinov2-small-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/dinov2-small-ONNX</span></h4> <ul data-svelte-h="svelte-1gq5tb5"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/dinov2-small-ONNX" rel="nofollow">https://huggingface.co/onnx-community/dinov2-small-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 311.5ms | Inference: 264.2ms</li></ul> <h4 class="relative group"><a id="onnx-communitydinov2-with-registers-small" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitydinov2-with-registers-small"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/dinov2-with-registers-small</span></h4> <ul data-svelte-h="svelte-137h9tq"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/dinov2-with-registers-small" rel="nofollow">https://huggingface.co/onnx-community/dinov2-with-registers-small</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 312.4ms | Inference: 270.6ms</li></ul> <hr> <h2 class="relative group"><a id="image-segmentation" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#image-segmentation"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Image-Segmentation</span></h2> <p data-svelte-h="svelte-1o1pzoo"><strong>Usage Example:</strong> Perform image segmentation</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> segmenter = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'image-segmentation'</span>, <span class="hljs-string">'Xenova/segformer-b0-finetuned-ade-512-512'</span>); | |
| <span class="hljs-keyword">const</span> url = <span class="hljs-string">'https://huggingface.co/datasets/Xenova/transformers.js-docs/resolve/main/cats.jpg'</span>; | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">segmenter</span>(url);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovasegformer-b0-finetuned-ade-512-512" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovasegformer-b0-finetuned-ade-512-512"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/segformer-b0-finetuned-ade-512-512</span></h4> <ul data-svelte-h="svelte-gk0yqf"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/segformer-b0-finetuned-ade-512-512" rel="nofollow">https://huggingface.co/Xenova/segformer-b0-finetuned-ade-512-512</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 205.6ms | Inference: 1612.3ms</li></ul> <h4 class="relative group"><a id="xenovamodnet" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovamodnet"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/modnet</span></h4> <ul data-svelte-h="svelte-s5qqgv"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/modnet" rel="nofollow">https://huggingface.co/Xenova/modnet</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 144.6ms | Inference: 286.9ms</li></ul> <h4 class="relative group"><a id="onnx-communitymodnet-webnn" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitymodnet-webnn"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/modnet-webnn</span></h4> <ul data-svelte-h="svelte-ausdyv"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/modnet-webnn" rel="nofollow">https://huggingface.co/onnx-community/modnet-webnn</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 147.5ms | Inference: 223.2ms</li></ul> <h4 class="relative group"><a id="xenovasegformerb0clothes" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovasegformerb0clothes"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/segformer_b0_clothes</span></h4> <ul data-svelte-h="svelte-1fsldbs"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/segformer_b0_clothes" rel="nofollow">https://huggingface.co/Xenova/segformer_b0_clothes</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 203.9ms | Inference: 632.4ms</li></ul> <h4 class="relative group"><a id="xenovasegformer-b0-finetuned-cityscapes-1024-1024" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovasegformer-b0-finetuned-cityscapes-1024-1024"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/segformer-b0-finetuned-cityscapes-1024-1024</span></h4> <ul data-svelte-h="svelte-1r6jl44"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/segformer-b0-finetuned-cityscapes-1024-1024" rel="nofollow">https://huggingface.co/Xenova/segformer-b0-finetuned-cityscapes-1024-1024</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 200.2ms | Inference: 519.0ms</li></ul> <hr> <h2 class="relative group"><a id="image-to-image" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#image-to-image"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Image-To-Image</span></h2> <p data-svelte-h="svelte-1a7lu1i"><strong>Usage Example:</strong></p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> processor = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'image-to-image'</span>, <span class="hljs-string">'Xenova/2x_APISR_RRDB_GAN_generator-onnx'</span>); | |
| <span class="hljs-keyword">const</span> url = <span class="hljs-string">'https://huggingface.co/datasets/Xenova/transformers.js-docs/resolve/main/tiger.jpg'</span>; | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">processor</span>(url);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenova2xapisrrrdbgangenerator-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenova2xapisrrrdbgangenerator-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/2x_APISR_RRDB_GAN_generator-onnx</span></h4> <ul data-svelte-h="svelte-2ltgbq"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/2x_APISR_RRDB_GAN_generator-onnx" rel="nofollow">https://huggingface.co/Xenova/2x_APISR_RRDB_GAN_generator-onnx</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 117.5ms | Inference: 596.3ms</li></ul> <h4 class="relative group"><a id="xenova4xapisrgrlgangenerator-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenova4xapisrgrlgangenerator-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/4x_APISR_GRL_GAN_generator-onnx</span></h4> <ul data-svelte-h="svelte-2dd3aw"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/4x_APISR_GRL_GAN_generator-onnx" rel="nofollow">https://huggingface.co/Xenova/4x_APISR_GRL_GAN_generator-onnx</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 2712.5ms | Inference: 3362.6ms</li></ul> <hr> <h2 class="relative group"><a id="object-detection" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#object-detection"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Object-Detection</span></h2> <p data-svelte-h="svelte-ptxzko"><strong>Usage Example:</strong> Run object-detection</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> detector = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'object-detection'</span>, <span class="hljs-string">'Xenova/detr-resnet-50'</span>); | |
| <span class="hljs-keyword">const</span> img = <span class="hljs-string">'https://huggingface.co/datasets/Xenova/transformers.js-docs/resolve/main/cats.jpg'</span>; | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">detector</span>(img, { <span class="hljs-attr">threshold</span>: <span class="hljs-number">0.9</span> });<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovadetr-resnet-50" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadetr-resnet-50"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/detr-resnet-50</span></h4> <ul data-svelte-h="svelte-16cfxcu"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/detr-resnet-50" rel="nofollow">https://huggingface.co/Xenova/detr-resnet-50</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 718.2ms | Inference: 625.4ms</li></ul> <h4 class="relative group"><a id="xenovayolos-tiny" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovayolos-tiny"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/yolos-tiny</span></h4> <ul data-svelte-h="svelte-1z1o6q"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/yolos-tiny" rel="nofollow">https://huggingface.co/Xenova/yolos-tiny</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 190.1ms | Inference: 904.3ms</li></ul> <h4 class="relative group"><a id="onnx-communityrfdetrbase-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communityrfdetrbase-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/rfdetr_base-ONNX</span></h4> <ul data-svelte-h="svelte-1db4g7r"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/rfdetr_base-ONNX" rel="nofollow">https://huggingface.co/onnx-community/rfdetr_base-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 470.4ms | Inference: 420.9ms</li></ul> <h4 class="relative group"><a id="xenovayolos-small-300" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovayolos-small-300"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/yolos-small-300</span></h4> <ul data-svelte-h="svelte-1mnri63"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/yolos-small-300" rel="nofollow">https://huggingface.co/Xenova/yolos-small-300</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 400.0ms | Inference: 1776.1ms</li></ul> <h4 class="relative group"><a id="onnx-communityrfdetrmedium-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communityrfdetrmedium-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/rfdetr_medium-ONNX</span></h4> <ul data-svelte-h="svelte-11esm3f"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/rfdetr_medium-ONNX" rel="nofollow">https://huggingface.co/onnx-community/rfdetr_medium-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 578.1ms | Inference: 486.1ms</li></ul> <hr> <h2 class="relative group"><a id="question-answering" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#question-answering"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Question-Answering</span></h2> <p data-svelte-h="svelte-990x6x"><strong>Usage Example:</strong> Run question answering</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> answerer = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'question-answering'</span>, <span class="hljs-string">'Xenova/distilbert-base-cased-distilled-squad'</span>); | |
| <span class="hljs-keyword">const</span> question = <span class="hljs-string">'Who was Jim Henson?'</span>; | |
| <span class="hljs-keyword">const</span> context = <span class="hljs-string">'Jim Henson was a nice puppet.'</span>; | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">answerer</span>(question, context);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovadistilbert-base-cased-distilled-squad" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilbert-base-cased-distilled-squad"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilbert-base-cased-distilled-squad</span></h4> <ul data-svelte-h="svelte-12avsz8"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilbert-base-cased-distilled-squad" rel="nofollow">https://huggingface.co/Xenova/distilbert-base-cased-distilled-squad</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 746.8ms | Inference: 164.3ms</li></ul> <h4 class="relative group"><a id="onnx-communityruberttinyqakontur-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communityruberttinyqakontur-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/rubert_tiny_qa_kontur-ONNX</span></h4> <ul data-svelte-h="svelte-1gstazf"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/rubert_tiny_qa_kontur-ONNX" rel="nofollow">https://huggingface.co/onnx-community/rubert_tiny_qa_kontur-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 411.4ms | Inference: 111.1ms</li></ul> <h4 class="relative group"><a id="xenovadistilbert-base-uncased-distilled-squad" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilbert-base-uncased-distilled-squad"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilbert-base-uncased-distilled-squad</span></h4> <ul data-svelte-h="svelte-ddo2z4"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilbert-base-uncased-distilled-squad" rel="nofollow">https://huggingface.co/Xenova/distilbert-base-uncased-distilled-squad</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 726.1ms | Inference: 204.5ms</li></ul> <h4 class="relative group"><a id="onnx-communityxlm-roberta-base-squad2-distilled-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communityxlm-roberta-base-squad2-distilled-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/xlm-roberta-base-squad2-distilled-ONNX</span></h4> <ul data-svelte-h="svelte-1u403wn"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/xlm-roberta-base-squad2-distilled-ONNX" rel="nofollow">https://huggingface.co/onnx-community/xlm-roberta-base-squad2-distilled-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 9046.6ms | Inference: 1201.1ms</li></ul> <h4 class="relative group"><a id="onnx-communitymobilebert-uncased-squad-v2-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitymobilebert-uncased-squad-v2-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/mobilebert-uncased-squad-v2-ONNX</span></h4> <ul data-svelte-h="svelte-1pa35gl"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/mobilebert-uncased-squad-v2-ONNX" rel="nofollow">https://huggingface.co/onnx-community/mobilebert-uncased-squad-v2-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 465.3ms | Inference: 911.1ms</li></ul> <hr> <h2 class="relative group"><a id="summarization" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#summarization"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Summarization</span></h2> <p data-svelte-h="svelte-17ij995"><strong>Usage Example:</strong> Summarization</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> generator = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'summarization'</span>, <span class="hljs-string">'Xenova/distilbart-cnn-6-6'</span>); | |
| <span class="hljs-keyword">const</span> text = <span class="hljs-string">'The tower is 324 metres (1,063 ft) tall, about the same height as an 81-storey building, '</span> + | |
| <span class="hljs-string">'and the tallest structure in Paris. Its base is square, measuring 125 metres (410 ft) on each side. '</span> + | |
| <span class="hljs-string">'During its construction, the Eiffel Tower surpassed the Washington Monument to become the tallest '</span> + | |
| <span class="hljs-string">'man-made structure in the world, a title it held for 41 years until the Chrysler Building in New '</span> + | |
| <span class="hljs-string">'York City was finished in 1930. It was the first structure to reach a height of 300 metres. Due to '</span> + | |
| <span class="hljs-string">'the addition of a broadcasting aerial at the top of the tower in 1957, it is now taller than the '</span> + | |
| <span class="hljs-string">'Chrysler Building by 5.2 metres (17 ft). Excluding transmitters, the Eiffel Tower is the second '</span> + | |
| <span class="hljs-string">'tallest free-standing structure in France after the Millau Viaduct.'</span>; | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">generator</span>(text, { | |
| <span class="hljs-attr">max_new_tokens</span>: <span class="hljs-number">100</span>, | |
| });<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovadistilbart-cnn-6-6" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilbart-cnn-6-6"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilbart-cnn-6-6</span></h4> <ul data-svelte-h="svelte-rel922"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilbart-cnn-6-6" rel="nofollow">https://huggingface.co/Xenova/distilbart-cnn-6-6</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 9311.4ms | Inference: 2527.9ms</li></ul> <h4 class="relative group"><a id="xenovadistilbart-xsum-12-1" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilbart-xsum-12-1"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilbart-xsum-12-1</span></h4> <ul data-svelte-h="svelte-qund1j"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilbart-xsum-12-1" rel="nofollow">https://huggingface.co/Xenova/distilbart-xsum-12-1</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 8184.2ms | Inference: 1283.7ms</li></ul> <h4 class="relative group"><a id="xenovadistilbart-xsum-6-6" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilbart-xsum-6-6"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilbart-xsum-6-6</span></h4> <ul data-svelte-h="svelte-18f4mh3"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilbart-xsum-6-6" rel="nofollow">https://huggingface.co/Xenova/distilbart-xsum-6-6</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 8895.0ms | Inference: 1519.4ms</li></ul> <h4 class="relative group"><a id="xenovadistilbart-xsum-9-6" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilbart-xsum-9-6"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilbart-xsum-9-6</span></h4> <ul data-svelte-h="svelte-1vhwi72"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilbart-xsum-9-6" rel="nofollow">https://huggingface.co/Xenova/distilbart-xsum-9-6</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 10079.9ms | Inference: 1730.8ms</li></ul> <h4 class="relative group"><a id="xenovadistilbart-cnn-12-3" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilbart-cnn-12-3"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilbart-cnn-12-3</span></h4> <ul data-svelte-h="svelte-anvap4"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilbart-cnn-12-3" rel="nofollow">https://huggingface.co/Xenova/distilbart-cnn-12-3</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 8878.6ms | Inference: 2479.6ms</li></ul> <hr> <h2 class="relative group"><a id="text-classification" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#text-classification"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Text-Classification</span></h2> <p data-svelte-h="svelte-1a7lu1i"><strong>Usage Example:</strong></p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> classifier = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'text-classification'</span>, <span class="hljs-string">'Xenova/distilbert-base-uncased-finetuned-sst-2-english'</span>); | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">classifier</span>(<span class="hljs-string">'I love transformers!'</span>);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovadistilbert-base-uncased-finetuned-sst-2-english" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilbert-base-uncased-finetuned-sst-2-english"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilbert-base-uncased-finetuned-sst-2-english</span></h4> <ul data-svelte-h="svelte-1k718vp"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilbert-base-uncased-finetuned-sst-2-english" rel="nofollow">https://huggingface.co/Xenova/distilbert-base-uncased-finetuned-sst-2-english</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 662.4ms | Inference: 245.3ms</li></ul> <h4 class="relative group"><a id="xenovams-marco-minilm-l-6-v2" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovams-marco-minilm-l-6-v2"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/ms-marco-MiniLM-L-6-v2</span></h4> <ul data-svelte-h="svelte-1hots9t"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/ms-marco-MiniLM-L-6-v2" rel="nofollow">https://huggingface.co/Xenova/ms-marco-MiniLM-L-6-v2</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 365.1ms | Inference: 146.6ms</li></ul> <h4 class="relative group"><a id="xenovams-marco-tinybert-l-2-v2" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovams-marco-tinybert-l-2-v2"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/ms-marco-TinyBERT-L-2-v2</span></h4> <ul data-svelte-h="svelte-1buntbk"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/ms-marco-TinyBERT-L-2-v2" rel="nofollow">https://huggingface.co/Xenova/ms-marco-TinyBERT-L-2-v2</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 115.1ms | Inference: 56.2ms</li></ul> <h4 class="relative group"><a id="xenovatoxic-bert" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovatoxic-bert"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/toxic-bert</span></h4> <ul data-svelte-h="svelte-1uw4gdm"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/toxic-bert" rel="nofollow">https://huggingface.co/Xenova/toxic-bert</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 3789.0ms | Inference: 808.8ms</li></ul> <h4 class="relative group"><a id="onnx-communitylanguagedetection-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitylanguagedetection-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/language_detection-ONNX</span></h4> <ul data-svelte-h="svelte-1boqmpw"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/language_detection-ONNX" rel="nofollow">https://huggingface.co/onnx-community/language_detection-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 338.1ms | Inference: 116.0ms</li></ul> <hr> <h2 class="relative group"><a id="text-generation" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#text-generation"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Text-Generation</span></h2> <p data-svelte-h="svelte-12n0d3h"><strong>Usage Example:</strong> Text generation</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> generator = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'text-generation'</span>, <span class="hljs-string">'Xenova/distilgpt2'</span>); | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">generator</span>(<span class="hljs-string">'Once upon a time, there was'</span>, { <span class="hljs-attr">max_new_tokens</span>: <span class="hljs-number">10</span> });<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovadistilgpt2" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovadistilgpt2"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/distilgpt2</span></h4> <ul data-svelte-h="svelte-zat8rg"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/distilgpt2" rel="nofollow">https://huggingface.co/Xenova/distilgpt2</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 3207.5ms | Inference: 469.7ms</li></ul> <h4 class="relative group"><a id="xenovallama2c-stories15m" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovallama2c-stories15m"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/llama2.c-stories15M</span></h4> <ul data-svelte-h="svelte-1c9mqgj"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/llama2.c-stories15M" rel="nofollow">https://huggingface.co/Xenova/llama2.c-stories15M</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 396.8ms | Inference: 251.4ms</li></ul> <h4 class="relative group"><a id="onnx-communityettin-decoder-17m-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communityettin-decoder-17m-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/ettin-decoder-17m-ONNX</span></h4> <ul data-svelte-h="svelte-1la2evs"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/ettin-decoder-17m-ONNX" rel="nofollow">https://huggingface.co/onnx-community/ettin-decoder-17m-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 328.2ms | Inference: 221.9ms</li></ul> <h4 class="relative group"><a id="onnx-communitylamina-extend-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitylamina-extend-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/Lamina-extend-ONNX</span></h4> <ul data-svelte-h="svelte-1b5uwl4"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/Lamina-extend-ONNX" rel="nofollow">https://huggingface.co/onnx-community/Lamina-extend-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 141.9ms | Inference: 190.0ms</li></ul> <h4 class="relative group"><a id="onnx-communitychess-llama-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitychess-llama-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/chess-llama-ONNX</span></h4> <ul data-svelte-h="svelte-1a9xcle"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/chess-llama-ONNX" rel="nofollow">https://huggingface.co/onnx-community/chess-llama-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 249.3ms | Inference: 197.2ms</li></ul> <hr> <h2 class="relative group"><a id="token-classification" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#token-classification"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Token-Classification</span></h2> <p data-svelte-h="svelte-4glj32"><strong>Usage Example:</strong> Perform named entity recognition</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> classifier = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'token-classification'</span>, <span class="hljs-string">'onnx-community/NeuroBERT-NER-ONNX'</span>); | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">classifier</span>(<span class="hljs-string">'My name is Sarah and I live in London'</span>);<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="onnx-communityneurobert-ner-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communityneurobert-ner-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/NeuroBERT-NER-ONNX</span></h4> <ul data-svelte-h="svelte-1yo31p8"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/NeuroBERT-NER-ONNX" rel="nofollow">https://huggingface.co/onnx-community/NeuroBERT-NER-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 170.4ms | Inference: 61.6ms</li></ul> <h4 class="relative group"><a id="onnx-communitytinybert-finetuned-ner-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitytinybert-finetuned-ner-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/TinyBERT-finetuned-NER-ONNX</span></h4> <ul data-svelte-h="svelte-70q46u"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/TinyBERT-finetuned-NER-ONNX" rel="nofollow">https://huggingface.co/onnx-community/TinyBERT-finetuned-NER-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 261.7ms | Inference: 79.9ms</li></ul> <h4 class="relative group"><a id="xenovaesm2t68mur50drnabindingsitepredictor" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaesm2t68mur50drnabindingsitepredictor"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/esm2_t6_8M_UR50D_rna_binding_site_predictor</span></h4> <ul data-svelte-h="svelte-79zcte"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/esm2_t6_8M_UR50D_rna_binding_site_predictor" rel="nofollow">https://huggingface.co/Xenova/esm2_t6_8M_UR50D_rna_binding_site_predictor</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 279.3ms | Inference: 118.6ms</li></ul> <h4 class="relative group"><a id="onnx-communitydistilbert-ner-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitydistilbert-ner-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/distilbert-NER-ONNX</span></h4> <ul data-svelte-h="svelte-1h2foea"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/distilbert-NER-ONNX" rel="nofollow">https://huggingface.co/onnx-community/distilbert-NER-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 682.0ms | Inference: 258.2ms</li></ul> <h4 class="relative group"><a id="onnx-communitysmall-e-czech-finetuned-ner-wikiann-onnx" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#onnx-communitysmall-e-czech-finetuned-ner-wikiann-onnx"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>onnx-community/small-e-czech-finetuned-ner-wikiann-ONNX</span></h4> <ul data-svelte-h="svelte-9agry5"><li><strong>Model page:</strong> <a href="https://huggingface.co/onnx-community/small-e-czech-finetuned-ner-wikiann-ONNX" rel="nofollow">https://huggingface.co/onnx-community/small-e-czech-finetuned-ner-wikiann-ONNX</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 271.3ms | Inference: 193.4ms</li></ul> <hr> <h2 class="relative group"><a id="translation" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#translation"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Translation</span></h2> <p data-svelte-h="svelte-11ygxtw"><strong>Usage Example:</strong> Multilingual translation</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg class="" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg> <div class="absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0"><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent; "></div> Copied</div></button></div> <pre class=""><!-- HTML_TAG_START --><span class="hljs-keyword">const</span> translator = <span class="hljs-keyword">await</span> <span class="hljs-title function_">pipeline</span>(<span class="hljs-string">'translation'</span>, <span class="hljs-string">'Xenova/opus-mt-en-es'</span>); | |
| <span class="hljs-keyword">const</span> output = <span class="hljs-keyword">await</span> <span class="hljs-title function_">translator</span>(<span class="hljs-string">'Life is like a box of chocolate.'</span>, { | |
| <span class="hljs-attr">src_lang</span>: <span class="hljs-string">'...'</span>, | |
| <span class="hljs-attr">tgt_lang</span>: <span class="hljs-string">'...'</span>, | |
| });<!-- HTML_TAG_END --></pre></div> <h3 class="relative group"><a id="recommended-models-for-first-time-trials" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#recommended-models-for-first-time-trials"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Recommended Models for First-Time Trials</span></h3> <h4 class="relative group"><a id="xenovaopus-mt-en-es" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaopus-mt-en-es"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/opus-mt-en-es</span></h4> <ul data-svelte-h="svelte-ddt1zo"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/opus-mt-en-es" rel="nofollow">https://huggingface.co/Xenova/opus-mt-en-es</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1956.5ms | Inference: 617.7ms</li></ul> <h4 class="relative group"><a id="xenovaopus-mt-zh-en" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaopus-mt-zh-en"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/opus-mt-zh-en</span></h4> <ul data-svelte-h="svelte-19nq0nz"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/opus-mt-zh-en" rel="nofollow">https://huggingface.co/Xenova/opus-mt-zh-en</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1964.7ms | Inference: 799.0ms</li></ul> <h4 class="relative group"><a id="xenovaopus-mt-en-zh" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaopus-mt-en-zh"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/opus-mt-en-zh</span></h4> <ul data-svelte-h="svelte-1v7wnf9"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/opus-mt-en-zh" rel="nofollow">https://huggingface.co/Xenova/opus-mt-en-zh</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1830.0ms | Inference: 481.5ms</li></ul> <h4 class="relative group"><a id="xenovaopus-mt-en-fr" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaopus-mt-en-fr"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/opus-mt-en-fr</span></h4> <ul data-svelte-h="svelte-1xb5syz"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/opus-mt-en-fr" rel="nofollow">https://huggingface.co/Xenova/opus-mt-en-fr</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1786.1ms | Inference: 446.7ms</li></ul> <h4 class="relative group"><a id="xenovaopus-mt-ar-en" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#xenovaopus-mt-ar-en"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Xenova/opus-mt-ar-en</span></h4> <ul data-svelte-h="svelte-qux06d"><li><strong>Model page:</strong> <a href="https://huggingface.co/Xenova/opus-mt-ar-en" rel="nofollow">https://huggingface.co/Xenova/opus-mt-ar-en</a></li> <li><strong>WebGPU Compatible:</strong> ✅ Yes</li> <li><strong>Metrics:</strong> Load: 1756.6ms | Inference: 733.8ms</li></ul> <hr> <h2 class="relative group"><a id="about-these-recommendations" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#about-these-recommendations"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>About These Recommendations</span></h2> <h3 class="relative group"><a id="selection-criteria" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#selection-criteria"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Selection Criteria</span></h3> <p data-svelte-h="svelte-1isp378">Models in this guide are selected based on:</p> <ul data-svelte-h="svelte-ulifmj"><li><strong>Popularity</strong>: High download counts and community engagement on HuggingFace Hub</li> <li><strong>Performance</strong>: Fast loading and inference times based on benchmark results</li> <li><strong>Compatibility</strong>: Verified WebGPU support for GPU-accelerated browser execution</li></ul> <h3 class="relative group"><a id="understanding-benchmark-metrics" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#understanding-benchmark-metrics"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>Understanding Benchmark Metrics</span></h3> <p data-svelte-h="svelte-1b921z8"><strong>Important:</strong> All performance metrics (load time, inference time, etc.) are measured in a controlled benchmark environment. These metrics are useful for <strong>comparing models against each other</strong>, but they may not reflect the actual performance you’ll experience in your specific environment. Factors that affect real-world performance include:</p> <ul data-svelte-h="svelte-1r8ydu5"><li>Hardware specifications (CPU, GPU, memory)</li> <li>Browser type and version</li> <li>Operating system</li> <li>Network conditions (for model loading)</li> <li>Concurrent processes and system load</li></ul> <p data-svelte-h="svelte-15wsq7"><strong>We recommend</strong> benchmarking models in your own environment with your actual use case to get accurate performance measurements.</p> <h3 class="relative group"><a id="for-production-use" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#for-production-use"><span><svg class="" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg></span></a> <span>For Production Use</span></h3> <p data-svelte-h="svelte-1ojrb63">These recommendations are optimized for first-time trials and learning. For production applications, consider:</p> <ul data-svelte-h="svelte-qmmpm3"><li>Evaluating multiple models for your specific use case</li> <li>Testing with your actual data and performance requirements</li> <li>Reviewing the full benchmark results for comprehensive comparisons</li> <li>Exploring specialized models that may better fit your needs</li></ul> <p data-svelte-h="svelte-1ti3234">Visit the full leaderboard to explore all available models and their benchmark results.</p> <a class="!text-gray-400 !no-underline text-sm flex items-center not-prose mt-4" href="https://github.com/huggingface/transformers.js/blob/main/docs/source/good-first-models.md" target="_blank"><svg class="mr-1" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M31,16l-7,7l-1.41-1.41L28.17,16l-5.58-5.59L24,9l7,7z"></path><path d="M1,16l7-7l1.41,1.41L3.83,16l5.58,5.59L8,23l-7-7z"></path><path d="M12.419,25.484L17.639,6.552l1.932,0.518L14.351,26.002z"></path></svg> <span data-svelte-h="svelte-zjs2n5"><span class="underline">Update</span> on GitHub</span></a> <p></p> | |
| <script> | |
| { | |
| __sveltekit_bt7g0s = { | |
| assets: "/docs/transformers.js/pr_1452/en", | |
| base: "/docs/transformers.js/pr_1452/en", | |
| env: {} | |
| }; | |
| const element = document.currentScript.parentElement; | |
| const data = [null,null]; | |
| Promise.all([ | |
| import("/docs/transformers.js/pr_1452/en/_app/immutable/entry/start.59e52715.js"), | |
| import("/docs/transformers.js/pr_1452/en/_app/immutable/entry/app.17425e4e.js") | |
| ]).then(([kit, app]) => { | |
| kit.start(app, element, { | |
| node_ids: [0, 24], | |
| data, | |
| form: null, | |
| error: null | |
| }); | |
| }); | |
| } | |
| </script> | |
Xet Storage Details
- Size:
- 231 kB
- Xet hash:
- e150032e88afdf508f324de09ac813a2bb6c0e44a51b39c078b45f73e3a87082
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.