Text Classification
Transformers
Safetensors
distilbert
Generated from Trainer
text-embeddings-inference
Instructions to use ContextNews/news-classifier with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ContextNews/news-classifier with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="ContextNews/news-classifier")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("ContextNews/news-classifier") model = AutoModelForSequenceClassification.from_pretrained("ContextNews/news-classifier", device_map="auto") - Notebooks
- Google Colab
- Kaggle
File size: 317 Bytes
240e62e | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | {
"politics": 0.38,
"geopolitics": 0.5,
"conflict": 0.32,
"crime": 0.38,
"law": 0.53,
"business": 0.29,
"economy": 0.27,
"markets": 0.53,
"technology": 0.34,
"science": 0.14,
"health": 0.3,
"environment": 0.39,
"society": 0.31,
"education": 0.1,
"sports": 0.2,
"entertainment": 0.28
}
|