Downloads · 30 days
3
19% of all-time downloads
heeggo/bert-based-uncased-agnews4-v01
bert-based-uncased-agnews4-v01 is a machine learning model from heeggo. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
Downloads · 30 days
3
19% of all-time downloads
All-time downloads
16
Public
Parameters
109M
438 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors438 MB · 100%
From the Hugging Face model README
Model Card
모델 개요
이 모델은 bert-base-uncased를 기반으로 파인튜닝한 텍스트 분류 모델입니다. AG News 데이터셋으로 학습되었으며 네 개 카테고리(세계뉴스, 스포츠, 비즈니스, 과학/기술)를 분류합니다.
사용 방법
from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch
model_name = "blockenters/bert-based-uncased-agnews4-v01"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForSequenceClassification.from_pretrained(model_name)
text = "NASA launches a new satellite into space"
inputs = tokenizer(text, return_tensors="pt")
with torch.no_grad():
outputs = model(**inputs)
predictions = torch.argmax(outputs.logits, dim=-1)
print("Predicted label:", predictions.item())
성능
활용 사례
제한 사항
라이선스