Text Classification
Transformers
Safetensors
English
bert
sentiment analysis
text classification
news
reviews
text-embeddings-inference
Instructions to use mervp/SentimentBERT with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use mervp/SentimentBERT with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="mervp/SentimentBERT")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("mervp/SentimentBERT") model = AutoModelForSequenceClassification.from_pretrained("mervp/SentimentBERT") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -39,9 +39,14 @@ This model is well-suited for:
|
|
| 39 |
- **Customer support or service feedback systems**
|
| 40 |
- **General-purpose opinion mining**
|
| 41 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 42 |
---
|
| 43 |
|
| 44 |
-
##
|
| 45 |
|
| 46 |
```python
|
| 47 |
from transformers import AutoTokenizer, AutoModelForSequenceClassification
|
|
@@ -68,10 +73,3 @@ print(predict_sentiment("Everything went wrong.")) # negative
|
|
| 68 |
print(predict_sentiment("He opened the door and walked in.")) # neutral
|
| 69 |
print(predict_sentiment("They are meeting at 5 PM.")) # neutral
|
| 70 |
print(predict_sentiment("She has a cat.")) # neutral
|
| 71 |
-
|
| 72 |
-
|
| 73 |
-
|
| 74 |
-
|
| 75 |
-
|
| 76 |
-
Thanks for visiting and downloading this model!
|
| 77 |
-
If this model helped you, please consider leaving a 👍 like. Your support helps this model reach more developers and encourages further improvements if any.
|
|
|
|
| 39 |
- **Customer support or service feedback systems**
|
| 40 |
- **General-purpose opinion mining**
|
| 41 |
|
| 42 |
+
|
| 43 |
+
|
| 44 |
+
Thanks for visiting and downloading this model!
|
| 45 |
+
If this model helped you, please consider leaving a 👍 like. Your support helps this model reach more developers and encourages further improvements if any.
|
| 46 |
+
|
| 47 |
---
|
| 48 |
|
| 49 |
+
## How to use the model
|
| 50 |
|
| 51 |
```python
|
| 52 |
from transformers import AutoTokenizer, AutoModelForSequenceClassification
|
|
|
|
| 73 |
print(predict_sentiment("He opened the door and walked in.")) # neutral
|
| 74 |
print(predict_sentiment("They are meeting at 5 PM.")) # neutral
|
| 75 |
print(predict_sentiment("She has a cat.")) # neutral
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|