Divyasreepat
commited on
Commit
•
a3925d1
1
Parent(s):
ab3bc62
Upload folder using huggingface_hub
Browse files- README.md +19 -0
- assets/tokenizer/vocabulary.txt +0 -0
- config.json +17 -0
- metadata.json +6 -0
- model.weights.h5 +3 -0
- preprocessor.json +29 -0
- task.json +57 -0
- task.weights.h5 +3 -0
- tokenizer.json +17 -0
README.md
ADDED
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
library_name: keras-hub
|
3 |
+
---
|
4 |
+
This is a [`Bert` model](https://keras.io/api/keras_hub/models/bert) uploaded using the KerasHub library and can be used with JAX, TensorFlow, and PyTorch backends.
|
5 |
+
This model is related to a `Classifier` task.
|
6 |
+
|
7 |
+
Model config:
|
8 |
+
* **name:** bert_backbone
|
9 |
+
* **trainable:** True
|
10 |
+
* **vocabulary_size:** 30522
|
11 |
+
* **num_layers:** 2
|
12 |
+
* **num_heads:** 2
|
13 |
+
* **hidden_dim:** 128
|
14 |
+
* **intermediate_dim:** 512
|
15 |
+
* **dropout:** 0.1
|
16 |
+
* **max_sequence_length:** 512
|
17 |
+
* **num_segments:** 2
|
18 |
+
|
19 |
+
This model card has been generated automatically and should be completed by the model author. See [Model Cards documentation](https://huggingface.co/docs/hub/model-cards) for more information.
|
assets/tokenizer/vocabulary.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|
config.json
ADDED
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"module": "keras_nlp.src.models.bert.bert_backbone",
|
3 |
+
"class_name": "BertBackbone",
|
4 |
+
"config": {
|
5 |
+
"name": "bert_backbone",
|
6 |
+
"trainable": true,
|
7 |
+
"vocabulary_size": 30522,
|
8 |
+
"num_layers": 2,
|
9 |
+
"num_heads": 2,
|
10 |
+
"hidden_dim": 128,
|
11 |
+
"intermediate_dim": 512,
|
12 |
+
"dropout": 0.1,
|
13 |
+
"max_sequence_length": 512,
|
14 |
+
"num_segments": 2
|
15 |
+
},
|
16 |
+
"registered_name": "keras_nlp>BertBackbone"
|
17 |
+
}
|
metadata.json
ADDED
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"keras_version": "3.3.2",
|
3 |
+
"keras_nlp_version": "0.10.0.dev0",
|
4 |
+
"parameter_count": 4385920,
|
5 |
+
"date_saved": "2024-04-26@21:06:10"
|
6 |
+
}
|
model.weights.h5
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:ed53ae7618b3a4e7f214e41c59bf74f82c7917d3147be8a57d448c3736ece334
|
3 |
+
size 17632104
|
preprocessor.json
ADDED
@@ -0,0 +1,29 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"module": "keras_nlp.src.models.bert.bert_preprocessor",
|
3 |
+
"class_name": "BertPreprocessor",
|
4 |
+
"config": {
|
5 |
+
"name": "bert_preprocessor_2",
|
6 |
+
"trainable": true,
|
7 |
+
"dtype": "float32",
|
8 |
+
"tokenizer": {
|
9 |
+
"module": "keras_nlp.src.models.bert.bert_tokenizer",
|
10 |
+
"class_name": "BertTokenizer",
|
11 |
+
"config": {
|
12 |
+
"name": "bert_tokenizer",
|
13 |
+
"trainable": true,
|
14 |
+
"dtype": "int32",
|
15 |
+
"vocabulary": null,
|
16 |
+
"sequence_length": null,
|
17 |
+
"lowercase": true,
|
18 |
+
"strip_accents": false,
|
19 |
+
"split": true,
|
20 |
+
"suffix_indicator": "##",
|
21 |
+
"oov_token": "[UNK]"
|
22 |
+
},
|
23 |
+
"registered_name": "keras_nlp>BertTokenizer"
|
24 |
+
},
|
25 |
+
"sequence_length": 512,
|
26 |
+
"truncate": "round_robin"
|
27 |
+
},
|
28 |
+
"registered_name": "keras_nlp>BertPreprocessor"
|
29 |
+
}
|
task.json
ADDED
@@ -0,0 +1,57 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"module": "keras_nlp.src.models.bert.bert_classifier",
|
3 |
+
"class_name": "BertClassifier",
|
4 |
+
"config": {
|
5 |
+
"backbone": {
|
6 |
+
"module": "keras_nlp.src.models.bert.bert_backbone",
|
7 |
+
"class_name": "BertBackbone",
|
8 |
+
"config": {
|
9 |
+
"name": "bert_backbone",
|
10 |
+
"trainable": true,
|
11 |
+
"vocabulary_size": 30522,
|
12 |
+
"num_layers": 2,
|
13 |
+
"num_heads": 2,
|
14 |
+
"hidden_dim": 128,
|
15 |
+
"intermediate_dim": 512,
|
16 |
+
"dropout": 0.1,
|
17 |
+
"max_sequence_length": 512,
|
18 |
+
"num_segments": 2
|
19 |
+
},
|
20 |
+
"registered_name": "keras_nlp>BertBackbone"
|
21 |
+
},
|
22 |
+
"preprocessor": {
|
23 |
+
"module": "keras_nlp.src.models.bert.bert_preprocessor",
|
24 |
+
"class_name": "BertPreprocessor",
|
25 |
+
"config": {
|
26 |
+
"name": "bert_preprocessor_2",
|
27 |
+
"trainable": true,
|
28 |
+
"dtype": "float32",
|
29 |
+
"tokenizer": {
|
30 |
+
"module": "keras_nlp.src.models.bert.bert_tokenizer",
|
31 |
+
"class_name": "BertTokenizer",
|
32 |
+
"config": {
|
33 |
+
"name": "bert_tokenizer",
|
34 |
+
"trainable": true,
|
35 |
+
"dtype": "int32",
|
36 |
+
"vocabulary": null,
|
37 |
+
"sequence_length": null,
|
38 |
+
"lowercase": true,
|
39 |
+
"strip_accents": false,
|
40 |
+
"split": true,
|
41 |
+
"suffix_indicator": "##",
|
42 |
+
"oov_token": "[UNK]"
|
43 |
+
},
|
44 |
+
"registered_name": "keras_nlp>BertTokenizer"
|
45 |
+
},
|
46 |
+
"sequence_length": 512,
|
47 |
+
"truncate": "round_robin"
|
48 |
+
},
|
49 |
+
"registered_name": "keras_nlp>BertPreprocessor"
|
50 |
+
},
|
51 |
+
"name": "bert_classifier_2",
|
52 |
+
"num_classes": 2,
|
53 |
+
"activation": "linear",
|
54 |
+
"dropout": 0.1
|
55 |
+
},
|
56 |
+
"registered_name": "keras_nlp>BertClassifier"
|
57 |
+
}
|
task.weights.h5
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:590b2faac564a34b509dea8f16a50d4f3186e84b2f6144a71deaf6ffc70621b5
|
3 |
+
size 52766840
|
tokenizer.json
ADDED
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"module": "keras_nlp.src.models.bert.bert_tokenizer",
|
3 |
+
"class_name": "BertTokenizer",
|
4 |
+
"config": {
|
5 |
+
"name": "bert_tokenizer",
|
6 |
+
"trainable": true,
|
7 |
+
"dtype": "int32",
|
8 |
+
"vocabulary": null,
|
9 |
+
"sequence_length": null,
|
10 |
+
"lowercase": true,
|
11 |
+
"strip_accents": false,
|
12 |
+
"split": true,
|
13 |
+
"suffix_indicator": "##",
|
14 |
+
"oov_token": "[UNK]"
|
15 |
+
},
|
16 |
+
"registered_name": "keras_nlp>BertTokenizer"
|
17 |
+
}
|