Commit
·
14d9342
1
Parent(s):
25a54be
Upload README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Model Trained Using AutoNLP
|
| 2 |
+
|
| 3 |
+
- Problem type: Multi-class Classification
|
| 4 |
+
- Model ID: 492513457
|
| 5 |
+
- CO2 Emissions (in grams): 5.527544460835904
|
| 6 |
+
|
| 7 |
+
## Validation Metrics
|
| 8 |
+
|
| 9 |
+
- Loss: 0.07609463483095169
|
| 10 |
+
- Accuracy: 0.9735624586913417
|
| 11 |
+
- Macro F1: 0.9736173135739408
|
| 12 |
+
- Micro F1: 0.9735624586913417
|
| 13 |
+
- Weighted F1: 0.9736173135739408
|
| 14 |
+
- Macro Precision: 0.9737771415197378
|
| 15 |
+
- Micro Precision: 0.9735624586913417
|
| 16 |
+
- Weighted Precision: 0.9737771415197378
|
| 17 |
+
- Macro Recall: 0.9735624586913417
|
| 18 |
+
- Micro Recall: 0.9735624586913417
|
| 19 |
+
- Weighted Recall: 0.9735624586913417
|
| 20 |
+
|
| 21 |
+
|
| 22 |
+
## Usage
|
| 23 |
+
|
| 24 |
+
You can use cURL to access this model:
|
| 25 |
+
|
| 26 |
+
```
|
| 27 |
+
$ curl -X POST -H "Authorization: Bearer YOUR_API_KEY" -H "Content-Type: application/json" -d '{"inputs": "I love AutoNLP"}' https://api-inference.huggingface.co/models/madhurjindal/autonlp-Gibberish-Detector-492513457
|
| 28 |
+
```
|
| 29 |
+
|
| 30 |
+
Or Python API:
|
| 31 |
+
|
| 32 |
+
```
|
| 33 |
+
from transformers import AutoModelForSequenceClassification, AutoTokenizer
|
| 34 |
+
|
| 35 |
+
model = AutoModelForSequenceClassification.from_pretrained("madhurjindal/autonlp-Gibberish-Detector-492513457", use_auth_token=True)
|
| 36 |
+
|
| 37 |
+
tokenizer = AutoTokenizer.from_pretrained("madhurjindal/autonlp-Gibberish-Detector-492513457", use_auth_token=True)
|
| 38 |
+
|
| 39 |
+
inputs = tokenizer("I love AutoNLP", return_tensors="pt")
|
| 40 |
+
|
| 41 |
+
outputs = model(**inputs)
|
| 42 |
+
```
|