Commit From AutoTrain
Browse files- .gitattributes +3 -0
- README.md +49 -0
- config.json +83 -0
- pytorch_model.bin +3 -0
- special_tokens_map.json +7 -0
- tokenizer.json +3 -0
- tokenizer_config.json +13 -0
- vocab.txt +0 -0
.gitattributes
CHANGED
@@ -32,3 +32,6 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
32 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
33 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
34 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
32 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
33 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
34 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
35 |
+
*.bin.* filter=lfs diff=lfs merge=lfs -text
|
36 |
+
*.tar.gz filter=lfs diff=lfs merge=lfs -text
|
37 |
+
tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
README.md
ADDED
@@ -0,0 +1,49 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
tags:
|
3 |
+
- autotrain
|
4 |
+
- token-classification
|
5 |
+
language:
|
6 |
+
- unk
|
7 |
+
widget:
|
8 |
+
- text: "I love AutoTrain 🤗"
|
9 |
+
datasets:
|
10 |
+
- tinyYhorm/autotrain-data-2-roberta-r
|
11 |
+
co2_eq_emissions:
|
12 |
+
emissions: 0.7754785356509495
|
13 |
+
---
|
14 |
+
|
15 |
+
# Model Trained Using AutoTrain
|
16 |
+
|
17 |
+
- Problem type: Entity Extraction
|
18 |
+
- Model ID: 53890126861
|
19 |
+
- CO2 Emissions (in grams): 0.7755
|
20 |
+
|
21 |
+
## Validation Metrics
|
22 |
+
|
23 |
+
- Loss: 0.178
|
24 |
+
- Accuracy: 0.958
|
25 |
+
- Precision: 0.868
|
26 |
+
- Recall: 0.877
|
27 |
+
- F1: 0.873
|
28 |
+
|
29 |
+
## Usage
|
30 |
+
|
31 |
+
You can use cURL to access this model:
|
32 |
+
|
33 |
+
```
|
34 |
+
$ curl -X POST -H "Authorization: Bearer YOUR_API_KEY" -H "Content-Type: application/json" -d '{"inputs": "I love AutoTrain"}' https://api-inference.huggingface.co/models/tinyYhorm/autotrain-2-roberta-r-53890126861
|
35 |
+
```
|
36 |
+
|
37 |
+
Or Python API:
|
38 |
+
|
39 |
+
```
|
40 |
+
from transformers import AutoModelForTokenClassification, AutoTokenizer
|
41 |
+
|
42 |
+
model = AutoModelForTokenClassification.from_pretrained("tinyYhorm/autotrain-2-roberta-r-53890126861", use_auth_token=True)
|
43 |
+
|
44 |
+
tokenizer = AutoTokenizer.from_pretrained("tinyYhorm/autotrain-2-roberta-r-53890126861", use_auth_token=True)
|
45 |
+
|
46 |
+
inputs = tokenizer("I love AutoTrain", return_tensors="pt")
|
47 |
+
|
48 |
+
outputs = model(**inputs)
|
49 |
+
```
|
config.json
ADDED
@@ -0,0 +1,83 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "AutoTrain",
|
3 |
+
"_num_labels": 21,
|
4 |
+
"architectures": [
|
5 |
+
"BertForTokenClassification"
|
6 |
+
],
|
7 |
+
"attention_probs_dropout_prob": 0.1,
|
8 |
+
"bos_token_id": 0,
|
9 |
+
"classifier_dropout": null,
|
10 |
+
"directionality": "bidi",
|
11 |
+
"eos_token_id": 2,
|
12 |
+
"hidden_act": "gelu",
|
13 |
+
"hidden_dropout_prob": 0.1,
|
14 |
+
"hidden_size": 768,
|
15 |
+
"id2label": {
|
16 |
+
"0": "B-Case",
|
17 |
+
"1": "B-Commute",
|
18 |
+
"2": "B-Date",
|
19 |
+
"3": "B-H_Address",
|
20 |
+
"4": "B-L_Address",
|
21 |
+
"5": "B-Quarantine",
|
22 |
+
"6": "B-Relationship",
|
23 |
+
"7": "B-Time",
|
24 |
+
"8": "B-Transportation",
|
25 |
+
"9": "B-W_Address",
|
26 |
+
"10": "I-Case",
|
27 |
+
"11": "I-Commute",
|
28 |
+
"12": "I-Date",
|
29 |
+
"13": "I-H_Address",
|
30 |
+
"14": "I-L_Address",
|
31 |
+
"15": "I-Quarantine",
|
32 |
+
"16": "I-Relationship",
|
33 |
+
"17": "I-Time",
|
34 |
+
"18": "I-Transportation",
|
35 |
+
"19": "I-W_Address",
|
36 |
+
"20": "O"
|
37 |
+
},
|
38 |
+
"initializer_range": 0.02,
|
39 |
+
"intermediate_size": 3072,
|
40 |
+
"label2id": {
|
41 |
+
"B-Case": 0,
|
42 |
+
"B-Commute": 1,
|
43 |
+
"B-Date": 2,
|
44 |
+
"B-H_Address": 3,
|
45 |
+
"B-L_Address": 4,
|
46 |
+
"B-Quarantine": 5,
|
47 |
+
"B-Relationship": 6,
|
48 |
+
"B-Time": 7,
|
49 |
+
"B-Transportation": 8,
|
50 |
+
"B-W_Address": 9,
|
51 |
+
"I-Case": 10,
|
52 |
+
"I-Commute": 11,
|
53 |
+
"I-Date": 12,
|
54 |
+
"I-H_Address": 13,
|
55 |
+
"I-L_Address": 14,
|
56 |
+
"I-Quarantine": 15,
|
57 |
+
"I-Relationship": 16,
|
58 |
+
"I-Time": 17,
|
59 |
+
"I-Transportation": 18,
|
60 |
+
"I-W_Address": 19,
|
61 |
+
"O": 20
|
62 |
+
},
|
63 |
+
"layer_norm_eps": 1e-12,
|
64 |
+
"max_length": 192,
|
65 |
+
"max_position_embeddings": 512,
|
66 |
+
"model_type": "bert",
|
67 |
+
"num_attention_heads": 12,
|
68 |
+
"num_hidden_layers": 12,
|
69 |
+
"output_past": true,
|
70 |
+
"pad_token_id": 0,
|
71 |
+
"padding": "max_length",
|
72 |
+
"pooler_fc_size": 768,
|
73 |
+
"pooler_num_attention_heads": 12,
|
74 |
+
"pooler_num_fc_layers": 3,
|
75 |
+
"pooler_size_per_head": 128,
|
76 |
+
"pooler_type": "first_token_transform",
|
77 |
+
"position_embedding_type": "absolute",
|
78 |
+
"torch_dtype": "float32",
|
79 |
+
"transformers_version": "4.28.1",
|
80 |
+
"type_vocab_size": 2,
|
81 |
+
"use_cache": true,
|
82 |
+
"vocab_size": 21128
|
83 |
+
}
|
pytorch_model.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:0e63f3c8ecb0218c84a3906bfdeb1433ae3be34fe90e8073ead44f7e8e921380
|
3 |
+
size 406844973
|
special_tokens_map.json
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"cls_token": "[CLS]",
|
3 |
+
"mask_token": "[MASK]",
|
4 |
+
"pad_token": "[PAD]",
|
5 |
+
"sep_token": "[SEP]",
|
6 |
+
"unk_token": "[UNK]"
|
7 |
+
}
|
tokenizer.json
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:519f3bcfdcf0a69ab248d5b68bb25d83d3a237f4c19d41668725fbd3eeb3ab34
|
3 |
+
size 439389
|
tokenizer_config.json
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"clean_up_tokenization_spaces": true,
|
3 |
+
"cls_token": "[CLS]",
|
4 |
+
"do_lower_case": true,
|
5 |
+
"mask_token": "[MASK]",
|
6 |
+
"model_max_length": 1000000000000000019884624838656,
|
7 |
+
"pad_token": "[PAD]",
|
8 |
+
"sep_token": "[SEP]",
|
9 |
+
"strip_accents": null,
|
10 |
+
"tokenize_chinese_chars": true,
|
11 |
+
"tokenizer_class": "BertTokenizer",
|
12 |
+
"unk_token": "[UNK]"
|
13 |
+
}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|