lxyuan_distilbert-base-multilingual-cased-sentiments-student
lxyuan · View on Hugging Face ↗
Model card
The complete upstream card, rendered from this payload's README.md — the same hash-verified bytes the torrent distributes. Images and off-site links are removed; the original card on Hugging Face carries them.
license: apache-2.0 tags:
- sentiment-analysis
- text-classification
- zero-shot-distillation
- distillation
- zero-shot-classification
- debarta-v3 model-index:
- name: distilbert-base-multilingual-cased-sentiments-student results: [] datasets:
- tyqiangz/multilingual-sentiments language:
- en
- ar
- de
- es
- fr
- ja
- zh
- id
- hi
- it
- ms
- pt
distilbert-base-multilingual-cased-sentiments-student
This model is distilled from the zero-shot classification pipeline on the Multilingual Sentiment dataset using this script.
In reality the multilingual-sentiment dataset is annotated of course, but we'll pretend and ignore the annotations for the sake of example.
Teacher model: MoritzLaurer/mDeBERTa-v3-base-mnli-xnli
Teacher hypothesis template: "The sentiment of this text is {}."
Student model: distilbert-base-multilingual-cased
Inference example
from transformers import pipeline
distilled_student_sentiment_classifier = pipeline(
model="lxyuan/distilbert-base-multilingual-cased-sentiments-student",
return_all_scores=True
)
# english
distilled_student_sentiment_classifier ("I love this movie and i would watch it again and again!")
>> [[{'label': 'positive', 'score': 0.9731044769287109},
{'label': 'neutral', 'score': 0.016910076141357422},
{'label': 'negative', 'score': 0.009985478594899178}]]
# malay
distilled_student_sentiment_classifier("Saya suka filem ini dan saya akan menontonnya lagi dan lagi!")
[[{'label': 'positive', 'score': 0.9760093688964844},
{'label': 'neutral', 'score': 0.01804516464471817},
{'label': 'negative', 'score': 0.005945465061813593}]]
# japanese
distilled_student_sentiment_classifier("私はこの映画が大好きで、何度も見ます!")
>> [[{'label': 'positive', 'score': 0.9342429041862488},
{'label': 'neutral', 'score': 0.040193185210227966},
{'label': 'negative', 'score': 0.025563929229974747}]]
Training procedure
Notebook link: here
Training hyperparameters
Result can be reproduce using the following commands:
python transformers/examples/research_projects/zero-shot-distillation/distill_classifier.py \
--data_file ./multilingual-sentiments/train_unlabeled.txt \
--class_names_file ./multilingual-sentiments/class_names.txt \
--hypothesis_template "The sentiment of this text is {}." \
--teacher_name_or_path MoritzLaurer/mDeBERTa-v3-base-mnli-xnli \
--teacher_batch_size 32 \
--student_name_or_path distilbert-base-multilingual-cased \
--output_dir ./distilbert-base-multilingual-cased-sentiments-student \
--per_device_train_batch_size 16 \
--fp16
If you are training this model on Colab, make the following code changes to avoid Out-of-memory error message:
###### modify L78 to disable fast tokenizer
default=False,
###### update dataset map part at L313
dataset = dataset.map(tokenizer, input_columns="text", fn_kwargs={"padding": "max_length", "truncation": True, "max_length": 512})
###### add following lines to L213
del model
print(f"Manually deleted Teacher model, free some memory for student model.")
###### add following lines to L337
trainer.push_to_hub()
tokenizer.push_to_hub("distilbert-base-multilingual-cased-sentiments-student")
Training log
Training completed. Do not forget to share your model on huggingface.co/models =)
{'train_runtime': 2009.8864, 'train_samples_per_second': 73.0, 'train_steps_per_second': 4.563, 'train_loss': 0.6473459283913797, 'epoch': 1.0}
100%|███████████████████████████████████████| 9171/9171 [33:29<00:00, 4.56it/s]
[INFO|trainer.py:762] 2023-05-06 10:56:18,555 >> The following columns in the evaluation set don't have a corresponding argument in `DistilBertForSequenceClassification.forward` and have been ignored: text. If text are not expected by `DistilBertForSequenceClassification.forward`, you can safely ignore this message.
[INFO|trainer.py:3129] 2023-05-06 10:56:18,557 >> ***** Running Evaluation *****
[INFO|trainer.py:3131] 2023-05-06 10:56:18,557 >> Num examples = 146721
[INFO|trainer.py:3134] 2023-05-06 10:56:18,557 >> Batch size = 128
100%|███████████████████████████████████████| 1147/1147 [08:59<00:00, 2.13it/s]
05/06/2023 11:05:18 - INFO - __main__ - Agreement of student and teacher predictions: 88.29%
[INFO|trainer.py:2868] 2023-05-06 11:05:18,251 >> Saving model checkpoint to ./distilbert-base-multilingual-cased-sentiments-student
[INFO|configuration_utils.py:457] 2023-05-06 11:05:18,251 >> Configuration saved in ./distilbert-base-multilingual-cased-sentiments-student/config.json
[INFO|modeling_utils.py:1847] 2023-05-06 11:05:18,905 >> Model weights saved in ./distilbert-base-multilingual-cased-sentiments-student/pytorch_model.bin
[INFO|tokenization_utils_base.py:2171] 2023-05-06 11:05:18,905 >> tokenizer config file saved in ./distilbert-base-multilingual-cased-sentiments-student/tokenizer_config.json
[INFO|tokenization_utils_base.py:2178] 2023-05-06 11:05:18,905 >> Special tokens file saved in ./distilbert-base-multilingual-cased-sentiments-student/special_tokens_map.json
Framework versions
- Transformers 4.28.1
- Pytorch 2.0.0+cu118
- Datasets 2.11.0
- Tokenizers 0.13.3
Magnet link
Opens the swarm directly in your torrent client — no file download needed. Copy-paste works too:
magnet:?xt=urn:btih:541027ef1293de615d1ff94ebd4a222ab8c37c93&dn=lxyuan_distilbert-base-multilingual-cased-sentiments-studentOpen magnet in torrent client · infohash 541027ef1293de615d1ff94ebd4a222ab8c37c93
Files & hashes
| Path | Size | sha1 | sha256 |
|---|---|---|---|
| README.md | 5.6 KB (5,771 B) | e764a3d86b80decf81b89f8eaf942fbab477e224 | 4ede535dd77d87e5c35077ea861b8964accef2699c29d7dbe47a44026b5f7af3 |
| config.json | 759 B (759 B) | f851b4de780378ae2cf3aa03224a31c0bf9825c3 | c4444692820027ddd8fcfc98238a994bf7296b41178bda11a2aa628686558204 |
| model.safetensors | 516.2 MB (541,320,452 B) | 41c98fd29fb8054a72372c96eea97ea7ca903963 | 0ab095b69033944004bb7a6ffcbfc2d77a240dd0f71c27820aa73efa71f664fe |
| onnx/config.json | 894 B (894 B) | 277243599f51c1981a3b524e3f7a30d0fd62917d | a46cba8b945d08b4a7ff5cdffe1d5b19e2a51dc1168394bafa8b826f9848b1d9 |
| pytorch_model.bin | 516.3 MB (541,343,405 B) | 615e030b910a87e0a2ed08a2388e487b9432e817 | ff7b7323d62a0097d99b13b151fce7bf799006e1e911d813e747d4955eed0df5 |
| special_tokens_map.json | 125 B (125 B) | a8b3208c2884c4efb86e49300fdd3dc877220cdf | b6d346be366a7d1d48332dbc9fdf3bf8960b5d879522b7799ddba59e76237ee3 |
| tokenizer.json | 2.8 MB (2,919,615 B) | 3197aecca8512baa6460d5e19c88b89d1b6465f6 | a4a4fa4b10a2a40361529954532f10257fda53cb22177554a862bcc661b7e4d8 |
| tokenizer_config.json | 373 B (373 B) | 9a03bf5b73b733600bed64997c1329f124c29907 | 2d61ce6c7646881e0e7ef08e3b5dd655a19553ab85c41b1a3c27090a63ff6f49 |
| training_args.bin | 3.6 KB (3,643 B) | 52dd5a8f8f6a13dbaf7ab3569fd2e0e86dbc8e73 | d0a703ae5fa8faeb9b4595394703a0f1fdd7a4f8d8436acf449c8032d939e519 |
| vocab.txt | 972.2 KB (995,526 B) | e837bab60a5d204e29622d127c2dafe508aa0731 | fe0fda7c425b48c516fc8f160d594c8022a0808447475c1a7c6d6479763f310c |
Cite this release
- Canonical URL
- https://aiseedbank.org/models/lxyuan_distilbert-base-multilingual-cased-sentiments-student/
- Slug
- lxyuan_distilbert-base-multilingual-cased-sentiments-student
- Infohash
- 541027ef1293de615d1ff94ebd4a222ab8c37c93
- License
- apache-2.0
- Signing key fingerprint
- 85a3b32c3712427b
Every file carries a locally computed sha256 — verify a download against the signed sums: lxyuan_distilbert-base-multilingual-cased-sentiments-student.SHA256SUMS (+ minisign signature).
Provenance
| Upstream repository | lxyuan/distilbert-base-multilingual-cased-sentiments-student |
|---|---|
| Revision (pinned) | cf991100d706c13c0a080c097134c05b7f436c45 |
| Fetched at | 2026-09-04T01:41:19Z |
| License at fetch | apache-2.0 |
| Snapshot tool | huggingface · seedbank 0.1.0 |
Trackers
- udp://announce.aitorrent.org:6969/announce
- http://announce.aitorrent.org:7070/announce
- udp://announce2.aitorrent.org:6970/announce
- http://announce2.aitorrent.org:7071/announce
- udp://tracker.opentrackr.org:1337/announce
- udp://open.demonii.com:1337/announce
- udp://open.stealth.si:80/announce
- udp://exodus.desync.com:6969/announce
- udp://tracker.torrent.eu.org:451/announce
✓ verified · rehash-vs-hf-metadata at 2026-09-04T01:41:31Z
apache-2.01.01 GB (1,086,590,563 bytes)transformerspytorchonnxsafetensorsdistilberttext-classificationsentiment-analysiszero-shot-distillationdistillationzero-shot-classificationdebarta-v3text-embeddings-inferenceendpoints_compatible12 languages (en, ar, de …)