Instructions to use Kate-lf/emotion-classification with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Kate-lf/emotion-classification with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="Kate-lf/emotion-classification")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("Kate-lf/emotion-classification") model = AutoModelForSequenceClassification.from_pretrained("Kate-lf/emotion-classification", device_map="auto") - Notebooks
- Google Colab
- Kaggle
|
Download README.md from Kate-lf/emotion-classification: direct link, hf CLI and curl.
- Browser
- Download file 1.89 kB
-
https://huggingface.co/Kate-lf/emotion-classification/resolve/main/README.md
- Command line
-
hf download hf://Kate-lf/emotion-classification/README.md
-
curl -L -o README.md https://huggingface.co/Kate-lf/emotion-classification/resolve/main/README.md
1.89 kB
metadata
library_name: transformers
license: apache-2.0
base_model: bert-base-chinese
metrics:
- accuracy
- f1
model-index:
- name: emotion-classification
results: []
language:
- zh
pipeline_tag: text-classification
emotion-classification
This model is a fine-tuned version of bert-base-chinese on an unknown dataset. It achieves the following results on the evaluation set:
- Loss: 0.4979
- Model Preparation Time: 0.0019
- Accuracy: 0.8718
- F1: 0.8701
Model description
More information needed
Intended uses & limitations
More information needed
Training and evaluation data
More information needed
Training procedure
Training hyperparameters
The following hyperparameters were used during training:
- learning_rate: 2e-05
- train_batch_size: 8
- eval_batch_size: 8
- seed: 42
- optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
- lr_scheduler_type: linear
- num_epochs: 3
Training results
| Training Loss | Epoch | Step | Validation Loss | Model Preparation Time | Accuracy | F1 |
|---|---|---|---|---|---|---|
| No log | 1.0 | 364 | 0.4835 | 0.0019 | 0.8510 | 0.8457 |
| 0.734 | 2.0 | 728 | 0.4865 | 0.0019 | 0.8638 | 0.8604 |
| 0.2323 | 3.0 | 1092 | 0.4782 | 0.0019 | 0.8830 | 0.8814 |
Framework versions
- Transformers 4.57.3
- Pytorch 2.11.0+cu128
- Datasets 5.0.0
- Tokenizers 0.22.2