Downloads · 30 days
10
2% of all-time downloads
Muhannedbsh/arabert-sentiment-model-MuhannedSh
arabert-sentiment-model-MuhannedSh is a text classification model from Muhannedbsh. Use it when you need a label for a piece of text. It is set up for transformers.
This is a fine-tuned BERT-based Arabic sentiment analysis model, specifically adapted from the aubmindlab/bert-base-arabertv02 model. It has been fine-tuned for binary sentiment classification tasks (positive vs. nega…
Downloads · 30 days
10
2% of all-time downloads
All-time downloads
508
Public
Parameters
135M
541 MB on disk
Likes
1
Public
Click a slice to open those files.
.safetensors541 MB · 100%
From the Hugging Face model README
This is a fine-tuned BERT-based Arabic sentiment analysis model, specifically adapted from the aubmindlab/bert-base-arabertv02 model. It has been fine-tuned for binary sentiment classification tasks (positive vs. negative sentiment) and achieves excellent performance on the validation set.
aubmindlab/bert-base-arabertv02This model is intended to be used for binary sentiment analysis tasks in Arabic. It can classify Arabic text into positive or negative sentiment.
The model can be fine-tuned further for other tasks in Arabic text classification or sentiment analysis.
The model is not recommended for tasks involving non-Arabic text or for sentiment analysis with more than two classes.
Users should be aware that the model's performance is tied to the data used during fine-tuning. Biases in the dataset could affect predictions.
from transformers import AutoTokenizer, AutoModelForSequenceClassification
model_name = "muhannedshaheen/Arabic_Sentiment_Muhannedsh"
# Load the model and tokenizer
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForSequenceClassification.from_pretrained(model_name)
# Example
text = "هذا المنتج رائع جدا"
inputs = tokenizer(text, return_tensors="pt")
outputs = model(**inputs)
print(outputs.logits)