Commit From AutoNLP
Browse files- .gitattributes +2 -0
- README.md +52 -0
- config.json +64 -0
- merges.txt +0 -0
- pytorch_model.bin +3 -0
- sample_input.pkl +3 -0
- special_tokens_map.json +1 -0
- tokenizer.json +0 -0
- tokenizer_config.json +1 -0
- vocab.json +0 -0
.gitattributes
CHANGED
@@ -25,3 +25,5 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
25 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
26 |
*.zstandard filter=lfs diff=lfs merge=lfs -text
|
27 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
25 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
26 |
*.zstandard filter=lfs diff=lfs merge=lfs -text
|
27 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
28 |
+
*.tar.gz filter=lfs diff=lfs merge=lfs -text
|
29 |
+
*.pkl filter=lfs diff=lfs merge=lfs -text
|
README.md
ADDED
@@ -0,0 +1,52 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
tags: autonlp
|
3 |
+
language: en
|
4 |
+
widget:
|
5 |
+
- text: "I love AutoNLP 🤗"
|
6 |
+
datasets:
|
7 |
+
- alecmullen/autonlp-data-group-classification
|
8 |
+
co2_eq_emissions: 0.4362732160754736
|
9 |
+
---
|
10 |
+
|
11 |
+
# Model Trained Using AutoNLP
|
12 |
+
|
13 |
+
- Problem type: Multi-class Classification
|
14 |
+
- Model ID: 441411446
|
15 |
+
- CO2 Emissions (in grams): 0.4362732160754736
|
16 |
+
|
17 |
+
## Validation Metrics
|
18 |
+
|
19 |
+
- Loss: 0.7598486542701721
|
20 |
+
- Accuracy: 0.8222222222222222
|
21 |
+
- Macro F1: 0.2912091747693842
|
22 |
+
- Micro F1: 0.8222222222222222
|
23 |
+
- Weighted F1: 0.7707160863181806
|
24 |
+
- Macro Precision: 0.29631463146314635
|
25 |
+
- Micro Precision: 0.8222222222222222
|
26 |
+
- Weighted Precision: 0.7341339689524508
|
27 |
+
- Macro Recall: 0.30174603174603176
|
28 |
+
- Micro Recall: 0.8222222222222222
|
29 |
+
- Weighted Recall: 0.8222222222222222
|
30 |
+
|
31 |
+
|
32 |
+
## Usage
|
33 |
+
|
34 |
+
You can use cURL to access this model:
|
35 |
+
|
36 |
+
```
|
37 |
+
$ 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/alecmullen/autonlp-group-classification-441411446
|
38 |
+
```
|
39 |
+
|
40 |
+
Or Python API:
|
41 |
+
|
42 |
+
```
|
43 |
+
from transformers import AutoModelForSequenceClassification, AutoTokenizer
|
44 |
+
|
45 |
+
model = AutoModelForSequenceClassification.from_pretrained("alecmullen/autonlp-group-classification-441411446", use_auth_token=True)
|
46 |
+
|
47 |
+
tokenizer = AutoTokenizer.from_pretrained("alecmullen/autonlp-group-classification-441411446", use_auth_token=True)
|
48 |
+
|
49 |
+
inputs = tokenizer("I love AutoNLP", return_tensors="pt")
|
50 |
+
|
51 |
+
outputs = model(**inputs)
|
52 |
+
```
|
config.json
ADDED
@@ -0,0 +1,64 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "AutoNLP",
|
3 |
+
"_num_labels": 15,
|
4 |
+
"architectures": [
|
5 |
+
"RobertaForSequenceClassification"
|
6 |
+
],
|
7 |
+
"attention_probs_dropout_prob": 0.1,
|
8 |
+
"bos_token_id": 0,
|
9 |
+
"eos_token_id": 2,
|
10 |
+
"gradient_checkpointing": false,
|
11 |
+
"hidden_act": "gelu",
|
12 |
+
"hidden_dropout_prob": 0.1,
|
13 |
+
"hidden_size": 768,
|
14 |
+
"id2label": {
|
15 |
+
"0": "Beauty",
|
16 |
+
"1": "Business/Finance",
|
17 |
+
"2": "Faith",
|
18 |
+
"3": "Fitness",
|
19 |
+
"4": "Food",
|
20 |
+
"5": "Gaming",
|
21 |
+
"6": "Local",
|
22 |
+
"7": "Marketplace",
|
23 |
+
"8": "Memes",
|
24 |
+
"9": "Music",
|
25 |
+
"10": "None",
|
26 |
+
"11": "Social",
|
27 |
+
"12": "Sports",
|
28 |
+
"13": "TV/Movies",
|
29 |
+
"14": "Travel"
|
30 |
+
},
|
31 |
+
"initializer_range": 0.02,
|
32 |
+
"intermediate_size": 3072,
|
33 |
+
"label2id": {
|
34 |
+
"Beauty": 0,
|
35 |
+
"Business/Finance": 1,
|
36 |
+
"Faith": 2,
|
37 |
+
"Fitness": 3,
|
38 |
+
"Food": 4,
|
39 |
+
"Gaming": 5,
|
40 |
+
"Local": 6,
|
41 |
+
"Marketplace": 7,
|
42 |
+
"Memes": 8,
|
43 |
+
"Music": 9,
|
44 |
+
"None": 10,
|
45 |
+
"Social": 11,
|
46 |
+
"Sports": 12,
|
47 |
+
"TV/Movies": 13,
|
48 |
+
"Travel": 14
|
49 |
+
},
|
50 |
+
"layer_norm_eps": 1e-05,
|
51 |
+
"max_length": 96,
|
52 |
+
"max_position_embeddings": 514,
|
53 |
+
"model_type": "roberta",
|
54 |
+
"num_attention_heads": 12,
|
55 |
+
"num_hidden_layers": 6,
|
56 |
+
"pad_token_id": 1,
|
57 |
+
"padding": "max_length",
|
58 |
+
"position_embedding_type": "absolute",
|
59 |
+
"problem_type": "single_label_classification",
|
60 |
+
"transformers_version": "4.8.0",
|
61 |
+
"type_vocab_size": 1,
|
62 |
+
"use_cache": true,
|
63 |
+
"vocab_size": 50265
|
64 |
+
}
|
merges.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|
pytorch_model.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:acfbf9bb06bf0ff6622c8c78c5e80e63fc016c6de43df893c26e5307f9b5e388
|
3 |
+
size 328565869
|
sample_input.pkl
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:cb676842387dd13890b857b16cda2c30bc63e90598d5813dd9921f8298069bed
|
3 |
+
size 2546
|
special_tokens_map.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"bos_token": "<s>", "eos_token": "</s>", "unk_token": "<unk>", "sep_token": "</s>", "pad_token": "<pad>", "cls_token": "<s>", "mask_token": {"content": "<mask>", "single_word": false, "lstrip": true, "rstrip": false, "normalized": false}}
|
tokenizer.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"unk_token": "<unk>", "bos_token": "<s>", "eos_token": "</s>", "add_prefix_space": false, "errors": "replace", "sep_token": "</s>", "cls_token": "<s>", "pad_token": "<pad>", "mask_token": "<mask>", "model_max_length": 512, "special_tokens_map_file": null, "name_or_path": "AutoNLP", "tokenizer_class": "RobertaTokenizer"}
|
vocab.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|