Downloads · 30 days
5
8% of all-time downloads
hunterdie333/Dazk-Nhan-Dien-Tot-Xau
Dazk-Nhan-Dien-Tot-Xau is a text classification model from hunterdie333. Use it when you need a label for a piece of text. It is set up for transformers. The card lists the license as mit.
Downloads · 30 days
5
8% of all-time downloads
All-time downloads
61
Public
Repo size
1.1 GB
Likes
0
Public
Click a slice to open those files.
.bin540 MB · 100%
From the Hugging Face model README
Labels:
Dataset: Từ từ sẽ được update
import torch
from transformers import RobertaForSequenceClassification, AutoTokenizer
model = RobertaForSequenceClassification.from_pretrained("hunterdie333/Dazk-Nhan-Dien-Tot-Xau")
tokenizer = AutoTokenizer.from_pretrained("hunterdie333/Dazk-Nhan-Dien-Tot-Xau", use_fast=False)
# Just like PhoBERT: INPUT TEXT MUST BE ALREADY WORD-SEGMENTED!
sentence = 'Mô hình được clone lại bởi DazkDev'
input_ids = torch.tensor([tokenizer.encode(sentence)])
with torch.no_grad():
out = model(input_ids)
print(out.logits.softmax(dim=-1).tolist())
# Output:
# [[0.293, 0.040, 0.667]]
# ^ ^ ^
# NEG POS NEU