Instructions to use premsa/political-bias-prediction-allsides-DeBERTa with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use premsa/political-bias-prediction-allsides-DeBERTa with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="premsa/political-bias-prediction-allsides-DeBERTa")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("premsa/political-bias-prediction-allsides-DeBERTa") model = AutoModelForSequenceClassification.from_pretrained("premsa/political-bias-prediction-allsides-DeBERTa") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -31,7 +31,7 @@ usage:
|
|
| 31 |
|
| 32 |
```
|
| 33 |
model = AutoModelForSequenceClassification.from_pretrained("premsa/political-bias-prediction-allsides-DeBERTa")
|
| 34 |
-
tokenizer = AutoTokenizer.from_pretrained(
|
| 35 |
nlp = pipeline("text-classification", model=model, tokenizer=tokenizer)
|
| 36 |
print(nlp("the masses are controlled by media."))
|
| 37 |
```
|
|
|
|
| 31 |
|
| 32 |
```
|
| 33 |
model = AutoModelForSequenceClassification.from_pretrained("premsa/political-bias-prediction-allsides-DeBERTa")
|
| 34 |
+
tokenizer = AutoTokenizer.from_pretrained("premsa/political-bias-prediction-allsides-DeBERTa")
|
| 35 |
nlp = pipeline("text-classification", model=model, tokenizer=tokenizer)
|
| 36 |
print(nlp("the masses are controlled by media."))
|
| 37 |
```
|