KLUE-BERT ํ๊ตญ์ด ๊ฐ์ ๋ถ๋ฅ (6-class)
klue/bert-base๋ฅผ AI Hubใ๊ณต๊ฐํ ๋ํใ๋ฐ์ดํฐ๋ก ๋ฏธ์ธ์กฐ์ ํ ํ๊ตญ์ด ๊ฐ์ ๋ถ๋ฅ ๋ชจ๋ธ์
๋๋ค.
๋ผ๋ฒจ
| id | ๊ฐ์ |
|---|---|
| 0 | ๊ธฐ์จ |
| 1 | ์ฌํ |
| 2 | ๋ถ๋ ธ |
| 3 | ๋ถ์ |
| 4 | ๋นํฉ |
| 5 | ์์ฒ |
์ฑ๋ฅ (๊ฒ์ฆ ์ธํธ)
- Accuracy: 0.7375
- F1 (macro): 0.7291
ํ์ต ์ ๋ณด
- Base:
klue/bert-base - ๋ฐ์ดํฐ: AI Hub ๊ณต๊ฐํ ๋ํ (ํ์ ๋ฐํ 24,250๋ฌธ์ฅ, 8:2 ๋ถํ )
- 3 epochs, batch 8 (grad accum 2), lr 2e-5, max_length 128, fp16, RTX 3060
์ฌ์ฉ๋ฒ
import torch
from transformers import AutoTokenizer, AutoModelForSequenceClassification
REPO = "YMmim/klue-bert-emotion-6"
labels = ["๊ธฐ์จ", "์ฌํ", "๋ถ๋
ธ", "๋ถ์", "๋นํฉ", "์์ฒ"]
tok = AutoTokenizer.from_pretrained(REPO)
model = AutoModelForSequenceClassification.from_pretrained(REPO)
model.eval()
x = tok("์ํ ๊ฒฐ๊ณผ๊ฐ ๊ฑฑ์ ๋ผ์ ์ ์ด ์ ์.", return_tensors="pt", truncation=True, max_length=128)
with torch.no_grad():
print(labels[int(model(**x).logits.argmax())])
ํ๊ณ
๊ฐ์ ๋ผ๋ฒจ์ด ๋ฐํ ๋จ์๊ฐ ์๋๋ผ ๋ํ ๋จ์๋ก ๋ถ์ฌ๋ ๋ฐ์ดํฐ ํน์ฑ์, ํ ๋ํ ๋ด ๋ชจ๋ ํ์ ๋ฐํ์ ๋์ผ ๊ฐ์ ์ด ์ ์ฉ๋์ด ์ฑ๋ฅ ์ํ์ ์ ์ฝ์ด ์์ต๋๋ค.
์ถ์ฒ
AI Hub ใ๊ณต๊ฐํ ๋ํใ ๋ฐ์ดํฐ์ ๊ธฐ๋ฐ. ๋น์์ ์ ์ฉ๋๋ก ์ฌ์ฉํ์ธ์.
- Downloads last month
- 16
Model tree for YMmim/klue-bert-emotion-6
Base model
klue/bert-base