AIAny
AI Model2022
Icon for item

DistilBERT (distilbert-base-uncased)

A compact pretrained bidirectional Transformer distilled from BERT base for masked language modeling and downstream NLP fine-tuning. Trained via knowledge distillation on BookCorpus and English Wikipedia, it reduces size/latency (≈67M params) while preserving BERT-like representations.

Introduction

Distillation makes strong language representations cheaper: this model trades parameter count and inference latency for a close approximation of BERT's internal features, so you can run typical sentence-level NLP tasks (classification, token labeling, QA embeddings) with much lower compute.

Key Capabilities
  • Knowledge-distilled BERT representations: trained to match BERT base logits and hidden states via a triple-objective (distillation loss, masked language modeling, cosine loss), so fine-tuned variants often approach BERT-level accuracy with smaller footprint.
  • Small, uncased Transformer backbone (≈67M parameters): lower memory and faster inference than BERT base, so it’s useful for CPU or latency-sensitive deployment and large-scale feature extraction.
  • Off-the-shelf masked-language and feature-extraction support: compatible with Hugging Face Transformers pipelines (fill-mask, text-classification, embeddings) and available in PyTorch/TF runtimes.
  • Standard pretraining data and behavior: pretrained on BookCorpus + English Wikipedia with WordPiece 30k vocabulary and the usual 15% masking scheme, so it integrates smoothly into existing BERT-style workflows.
Who It's For and Trade-offs

Great fit if you need a BERT-like encoder but want lower inference cost, e.g., production classifiers, token-labeling systems, embedding generation for retrieval, or quick prototyping on limited hardware. Look elsewhere if you require the absolute top GLUE/SQuAD performance (BERT-large or current larger encoder models) or if you need causal/text-generation capabilities (use GPT-family models for that). Note also that it inherits biases from its teacher and pretraining corpora; expect similar demographic and occupational biases and evaluate accordingly.

Where It Fits

Practical alternative to BERT base when throughput or deployment constraints matter; not a replacement for autoregressive generators. Often chosen as a baseline or backbone when teams want faster iteration and reduced cloud cost while preserving a bidirectional encoder architecture.

Information

  • Websitehuggingface.co
  • OrganizationsHugging Face
  • AuthorsVictor Sanh, Lysandre Debut, Julien Chaumond, Thomas Wolf
  • Published date2022/03/02

Categories

More Items

Hugging Face
AI Model2026

Generates text conditioned on multimodal inputs (text, image, audio, video) with a 1M-token context window; an open-weights mixture-of-experts model aimed at long-horizon coding and agentic workflows, with NVFP4 checkpoints to reduce memory footprint.

Hugging Face
AI Model2026

Quantized multimodal vision-language model for reasoning, coding, tool use, document and video understanding; 120B total (12B active) with NVFP4 quantization, native Multi-Token Prediction for speculative decoding, and up to 1M-token context — designed for deployment on NVIDIA GPU stacks.

Hugging Face
AI Model2026

Text-only sparse Mixture-of-Experts language model for long-context reasoning, coding, and agentic tool use; 501B total / ~23B active parameters, 1M-token context, and BF16/FP8/NVFP4 checkpoints released under Apache 2.0.