Commit From AutoNLP
Browse files- .gitattributes +2 -0
- README.md +45 -0
- config.json +63 -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.txt +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,45 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
tags: autonlp
|
3 |
+
language: en
|
4 |
+
widget:
|
5 |
+
- text: "I love AutoNLP 🤗"
|
6 |
+
datasets:
|
7 |
+
- kSaluja/autonlp-data-tele_red_data_model
|
8 |
+
co2_eq_emissions: 2.379476355147211
|
9 |
+
---
|
10 |
+
|
11 |
+
# Model Trained Using AutoNLP
|
12 |
+
|
13 |
+
- Problem type: Entity Extraction
|
14 |
+
- Model ID: 585716433
|
15 |
+
- CO2 Emissions (in grams): 2.379476355147211
|
16 |
+
|
17 |
+
## Validation Metrics
|
18 |
+
|
19 |
+
- Loss: 0.15210922062397003
|
20 |
+
- Accuracy: 0.9724770642201835
|
21 |
+
- Precision: 0.950836820083682
|
22 |
+
- Recall: 0.9625838333921638
|
23 |
+
- F1: 0.9566742676723382
|
24 |
+
|
25 |
+
## Usage
|
26 |
+
|
27 |
+
You can use cURL to access this model:
|
28 |
+
|
29 |
+
```
|
30 |
+
$ 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/kSaluja/autonlp-tele_red_data_model-585716433
|
31 |
+
```
|
32 |
+
|
33 |
+
Or Python API:
|
34 |
+
|
35 |
+
```
|
36 |
+
from transformers import AutoModelForTokenClassification, AutoTokenizer
|
37 |
+
|
38 |
+
model = AutoModelForTokenClassification.from_pretrained("kSaluja/autonlp-tele_red_data_model-585716433", use_auth_token=True)
|
39 |
+
|
40 |
+
tokenizer = AutoTokenizer.from_pretrained("kSaluja/autonlp-tele_red_data_model-585716433", use_auth_token=True)
|
41 |
+
|
42 |
+
inputs = tokenizer("I love AutoNLP", return_tensors="pt")
|
43 |
+
|
44 |
+
outputs = model(**inputs)
|
45 |
+
```
|
config.json
ADDED
@@ -0,0 +1,63 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "AutoNLP",
|
3 |
+
"_num_labels": 15,
|
4 |
+
"architectures": [
|
5 |
+
"BertForTokenClassification"
|
6 |
+
],
|
7 |
+
"attention_probs_dropout_prob": 0.1,
|
8 |
+
"classifier_dropout": null,
|
9 |
+
"gradient_checkpointing": false,
|
10 |
+
"hidden_act": "gelu",
|
11 |
+
"hidden_dropout_prob": 0.1,
|
12 |
+
"hidden_size": 1024,
|
13 |
+
"id2label": {
|
14 |
+
"0": "B-BUYPRICE",
|
15 |
+
"1": "B-CALLTYPE",
|
16 |
+
"2": "B-HOLDINGPERIOD",
|
17 |
+
"3": "B-INSTRUMENT",
|
18 |
+
"4": "B-STOPLOSS",
|
19 |
+
"5": "B-SUGGESTIONTYPE",
|
20 |
+
"6": "B-TARGET",
|
21 |
+
"7": "I-BUYPRICE",
|
22 |
+
"8": "I-CALLTYPE",
|
23 |
+
"9": "I-HOLDINGPERIOD",
|
24 |
+
"10": "I-INSTRUMENT",
|
25 |
+
"11": "I-STOPLOSS",
|
26 |
+
"12": "I-SUGGESTIONTYPE",
|
27 |
+
"13": "I-TARGET",
|
28 |
+
"14": "O"
|
29 |
+
},
|
30 |
+
"initializer_range": 0.02,
|
31 |
+
"intermediate_size": 4096,
|
32 |
+
"label2id": {
|
33 |
+
"B-BUYPRICE": 0,
|
34 |
+
"B-CALLTYPE": 1,
|
35 |
+
"B-HOLDINGPERIOD": 2,
|
36 |
+
"B-INSTRUMENT": 3,
|
37 |
+
"B-STOPLOSS": 4,
|
38 |
+
"B-SUGGESTIONTYPE": 5,
|
39 |
+
"B-TARGET": 6,
|
40 |
+
"I-BUYPRICE": 7,
|
41 |
+
"I-CALLTYPE": 8,
|
42 |
+
"I-HOLDINGPERIOD": 9,
|
43 |
+
"I-INSTRUMENT": 10,
|
44 |
+
"I-STOPLOSS": 11,
|
45 |
+
"I-SUGGESTIONTYPE": 12,
|
46 |
+
"I-TARGET": 13,
|
47 |
+
"O": 14
|
48 |
+
},
|
49 |
+
"layer_norm_eps": 1e-12,
|
50 |
+
"max_length": 96,
|
51 |
+
"max_position_embeddings": 512,
|
52 |
+
"model_type": "bert",
|
53 |
+
"num_attention_heads": 16,
|
54 |
+
"num_hidden_layers": 24,
|
55 |
+
"pad_token_id": 0,
|
56 |
+
"padding": "max_length",
|
57 |
+
"position_embedding_type": "absolute",
|
58 |
+
"torch_dtype": "float32",
|
59 |
+
"transformers_version": "4.15.0",
|
60 |
+
"type_vocab_size": 2,
|
61 |
+
"use_cache": true,
|
62 |
+
"vocab_size": 30522
|
63 |
+
}
|
pytorch_model.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:c3e0a8b96a30e46f280c5eb8d2518747582c3c75cdc14266c269973f2565f0c0
|
3 |
+
size 1336591537
|
sample_input.pkl
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:33ab5e70eaac1bc6625532f6e3b4eeff0e66bcffb52ad31f63d974c9cc92d83f
|
3 |
+
size 3882
|
special_tokens_map.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"unk_token": "[UNK]", "sep_token": "[SEP]", "pad_token": "[PAD]", "cls_token": "[CLS]", "mask_token": "[MASK]"}
|
tokenizer.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"do_lower_case": true, "unk_token": "[UNK]", "sep_token": "[SEP]", "pad_token": "[PAD]", "cls_token": "[CLS]", "mask_token": "[MASK]", "tokenize_chinese_chars": true, "strip_accents": null, "model_max_length": 512, "special_tokens_map_file": null, "name_or_path": "AutoNLP", "tokenizer_class": "BertTokenizer"}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|