Downloads · 30 days
614
24% of all-time downloads
knok/japanese-distilgpt2
japanese-distilgpt2 is a text generation model from knok. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as mit.
このモデルはrinna/japanese-gpt2-meduimを教師として蒸留したものです。 蒸留には、HuggigFace Transformersのコードをベースとし、りんなの訓練コードと組み合わせてデータ扱うよう改造したものを使っています。
Downloads · 30 days
614
24% of all-time downloads
All-time downloads
2.5K
Public
Parameters
116M
888 MB on disk
Likes
3
Public
Click a slice to open those files.
.bin444 MB · 50%
How the weights are stored.
F32109M · 95%
From the Hugging Face model README
このモデルはrinna/japanese-gpt2-meduimを教師として蒸留したものです。 蒸留には、HuggigFace Transformersのコードをベースとし、りんなの訓練コードと組み合わせてデータ扱うよう改造したものを使っています。
訓練用コード: https://github.com/knok/japanese-pretrained-models
学習に当たり、Google Startup Programにて提供されたクレジットを用いました。 a2-highgpu-4インスタンス(A100 x 4)を使って4か月程度、何度かのresumeを挟んで訓練させました。
Wikipediaをコーパスとし、perplexity 40 程度となります。 rinna/japanese-gpt2-meduim を直接使った場合、27 程度なので、そこまで及びません。 何度か複数のパラメータで訓練の再開を試みたものの、かえって損失が上昇してしまう状態となってしまったので、現状のものを公開しています。
トークナイザは rinna/japanese-gpt2-meduim を使ってください。
This model is a dillated model from rinna/japanese-gpt2-medium. To train, I combined HuggingFace Transformers code and rinna gpt2 train code.
The code is available at: https://github.com/knok/japanese-pretrained-models
To train, I used GCP credit offered by Google Startup Progam. Using a2-highgpu-4 instance (A100 x4), it takes about 4 months with some stopping and resume training.
The model gets about 40 perplexity with Wikipedia corpus. The teacher model rinna/japanese-gpt2-meduim gets about 27 perplexity, so the student model is worse.
The repository don't have tokenizer, so you shoud use rinna/japanese-gpt2-medium.
MIT (same as rinna/japanese-gpt2-medium)