Downloads · 30 days
10
7% of all-time downloads
SrothJr/banglamentalBERT-banglaBERT-dapt
banglamentalBERT-banglaBERT-dapt is a text classification model from SrothJr. Use it when you need a label for a piece of text. The card lists the license as mit.
This is a Domain-Adaptive Pre-Trained (DAPT) model for detecting depression severity in Bangla social media text. The high-accuracy model based on ELECTRA architecture. Achieved best performance (~84% F1) in experiments.
Downloads · 30 days
10
7% of all-time downloads
All-time downloads
148
Public
Parameters
111M
443 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors443 MB · 100%
From the Hugging Face model README
This is a Domain-Adaptive Pre-Trained (DAPT) model for detecting depression severity in Bangla social media text. The high-accuracy model based on ELECTRA architecture. Achieved best performance (~84% F1) in experiments.
The model outputs one of the following classes:
from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch
# Load the model
model_name = "SrothJr/banglamentalBERT-banglaBERT-dapt"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForSequenceClassification.from_pretrained(model_name)
# Inference
text = "আপনার বাংলা টেক্সট এখানে (Your Bengali text here)"
inputs = tokenizer(text, return_tensors="pt")
with torch.no_grad():
outputs = model(**inputs)
predictions = torch.argmax(outputs.logits, dim=-1)
labels = ["Minimum", "Mild", "Moderate", "Severe"]
print(f"Prediction: {labels[predictions.item()]}")
If you use this mode, please cite our research.