How to Find a Model for a Task on the Hugging Face Hub
The Hugging Face Hub holds a huge number of free, pretrained models, so the hard part is often choosing one. The Models page can narrow them down by task, by name and by license, and each model's page tells you how big it is, how well it did and what it learned from. This guide finds a model that tells which emotion a sentence expresses.
The Example
The task: label short English texts with an emotion, such as joy, anger or fear. Choosing one label out of a fixed list is called text classification. The model should also allow commercial use, so the search keeps only models under the Apache 2.0 license. You don't need an account for any of this.
Step 1: Choose the Task
Open huggingface.co/models. On the left are filters in tabs: Main, Tasks, Libraries, Languages, Licenses and Other. Click Tasks, and under Natural Language Processing, click Text Classification:

Models on the Hub are tagged with the task they were trained for, and this filter keeps only the ones tagged for text classification. The other names in the list are tasks too, such as Token Classification, which finds names and places in a sentence.
Step 2: Filter by Name
Above the list is a box called Filter by name. Type emotion:

The box matches the word in the model's name, which is how most authors describe what a model does. 5,510 text-classification models matched. The list is sorted by Trending, which puts models that are getting attention right now on top: here, new models with a few dozen downloads.
Step 3: Sort by Downloads
Click Sort: Trending to see the other orders:

Choose Most downloads. A model that many people download has been tried by many people, so problems with it are more likely to have been noticed:

Each card shows the task, the size where the Hub knows it (82.1M is 82.1 million parameters, the numbers a model learns), when it was last updated, its downloads and its likes. The top result has 353 thousand downloads. Before you take it, check its license.
Step 4: Keep Only the Licenses You Can Use
Click the Licenses tab in the filters and choose apache-2.0:

The list now holds 3,208 models:

The most downloaded model from Step 3 is gone. Its card has no license in its metadata, so the license filter can't include it, and without a license you can't tell what you're allowed to do with it. The license guide shows how to read and check a license.
All the filters are in the page's address, so you can save or share the search:
https://huggingface.co/models?pipeline_tag=text-classification&license=license:apache-2.0&sort=downloads&search=emotion
Step 5: Check the Model's Page
Click a model that fits. Here it's bhadresh-savani/distilbert-base-uncased-emotion, the most liked of these four. Its page starts with the model's name and its tags:

The tags answer the first questions: the task (Text Classification), the libraries it works with (Transformers and PyTorch among them), its language (English) and its license (apache-2.0). Safetensors means its weights are stored in the safe file format that loads without running any code.
On the right of the page are its downloads and its size:

67 million parameters stored as 32-bit numbers (F32) is about 268 MB to download, small enough for any laptop.
Below the tags is the model card, the author's description. Look for results, a table or numbers that say how well the model did on test data. This one has a table:

It got 93.8% of the test messages right, close to the other three models in the table, and it handled about twice as many messages per second as each of them. Treat the author's numbers as a starting point: what counts is how it does on your own texts.
Last, the right side also names the data the model learned from:

Open the dataset too. It tells you what kind of text the model knows, here English tweets, and the dataset has its own terms: the dair-ai/emotion card says "The dataset should be used for educational and research purposes only." If you're building a product, weigh that along with the model's own license.
Step 6: Use the Model
The model's name, bhadresh-savani/distilbert-base-uncased-emotion, is all a pipeline needs. Pin it to a commit so it can't change under you, as the revision guide shows, and run it on your own texts: the every-label guide runs this model and prints its score for each of the six emotions.
What to Check Before You Choose
| Check | Where | Why |
|---|---|---|
| Task | The first tag | A model only does the task it was trained for |
| License | The License: tag | It says whether you may use the model in a product |
| Language | The language tag | A model trained on English text does poorly on other languages |
| Size | Model size on the right | Bigger models are slower and need more memory |
| Results | The model card | They show how well it did on test data |
| Training data | Dataset used to train | It shows what texts the model knows, and the data has its own terms |
| Downloads and likes | The list and the page | Widely used models are more likely to work as described |
Common Mistakes
| Mistake | What happens | Do this instead |
|---|---|---|
| Taking the first result | The default Trending order favours new models, often with few downloads | Sort by Most downloads or Most likes |
| Choosing by name alone | A name such as emotion-english doesn't say which emotions, what data or what license | Open the model's page and check the tags and the card |
| Skipping the license | Some models have no license or forbid commercial use | Filter by license, then read the license itself |
| Trusting the card's numbers for your data | They were measured on the author's test data | Try the model on examples of your own texts |
FAQ
Do I need an account to search the Hub?
No. Searching and reading model pages is open to everyone. You need an account for gated and private models, and to upload your own.
Why are there thousands of emotion models?
Anyone can upload a model, and many people fine-tune a base model on an emotion dataset for practice or for their own project. The filters exist to cut that list down.
Can I search from Python or the terminal instead?
Yes. hf models ls takes a search text (--search), a task (--pipeline-tag) and an order (--sort downloads), and the huggingface_hub library can search from Python, which is handy in scripts. The page is easier for comparing models by eye.
Conclusion
The Text Classification task, the name emotion, the Most downloads order and the apache-2.0 license turned 5,510 matches into a short list of well-used models you may build on. The model page of bhadresh-savani/distilbert-base-uncased-emotion then showed its size (67M parameters), its results (93.8% accuracy) and its training data, including that data's own terms.
Additional Resources
- The Model Hub — what's on the Hub and how models are shared.
- Model cards — what a model's page and card contain.
- Search the Hub — the same search from Python.
