Shobhank-iiitdwd
commited on
Commit
•
4275b55
1
Parent(s):
974cc1c
Upload 8 files
Browse files- README.md +52 -0
- config.json +145 -0
- index.gitattributes +8 -0
- index.lock +0 -0
- pytorch_model.bin +3 -0
- special_tokens_map.json +1 -0
- tokenizer_config.json +1 -0
- vocab.txt +0 -0
README.md
ADDED
@@ -0,0 +1,52 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
language: en
|
3 |
+
license: apache-2.0
|
4 |
+
datasets:
|
5 |
+
- cnn_dailymail
|
6 |
+
tags:
|
7 |
+
- summarization
|
8 |
+
model-index:
|
9 |
+
- name: patrickvonplaten/bert2bert_cnn_daily_mail
|
10 |
+
results:
|
11 |
+
- task:
|
12 |
+
type: summarization
|
13 |
+
name: Summarization
|
14 |
+
dataset:
|
15 |
+
name: cnn_dailymail
|
16 |
+
type: cnn_dailymail
|
17 |
+
config: 3.0.0
|
18 |
+
split: test
|
19 |
+
metrics:
|
20 |
+
- name: ROUGE-1
|
21 |
+
type: rouge
|
22 |
+
value: 41.2808
|
23 |
+
verified: true
|
24 |
+
- name: ROUGE-2
|
25 |
+
type: rouge
|
26 |
+
value: 18.6853
|
27 |
+
verified: true
|
28 |
+
- name: ROUGE-L
|
29 |
+
type: rouge
|
30 |
+
value: 28.191
|
31 |
+
verified: true
|
32 |
+
- name: ROUGE-LSUM
|
33 |
+
type: rouge
|
34 |
+
value: 38.0871
|
35 |
+
verified: true
|
36 |
+
- name: loss
|
37 |
+
type: loss
|
38 |
+
value: 2.3451855182647705
|
39 |
+
verified: true
|
40 |
+
- name: gen_len
|
41 |
+
type: gen_len
|
42 |
+
value: 73.8332
|
43 |
+
verified: true
|
44 |
+
---
|
45 |
+
|
46 |
+
Bert2Bert Summarization with 🤗EncoderDecoder Framework
|
47 |
+
This model is a warm-started *BERT2BERT* model fine-tuned on the *CNN/Dailymail* summarization dataset.
|
48 |
+
|
49 |
+
The model achieves a **18.22** ROUGE-2 score on *CNN/Dailymail*'s test dataset.
|
50 |
+
|
51 |
+
For more details on how the model was fine-tuned, please refer to
|
52 |
+
[this](https://colab.research.google.com/drive/1Ekd5pUeCX7VOrMx94_czTkwNtLN32Uyu?usp=sharing) notebook.
|
config.json
ADDED
@@ -0,0 +1,145 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"architectures": [
|
3 |
+
"EncoderDecoderModel"
|
4 |
+
],
|
5 |
+
"decoder": {
|
6 |
+
"_name_or_path": "bert-base-uncased",
|
7 |
+
"add_cross_attention": true,
|
8 |
+
"architectures": [
|
9 |
+
"BertForMaskedLM"
|
10 |
+
],
|
11 |
+
"attention_probs_dropout_prob": 0.1,
|
12 |
+
"bad_words_ids": null,
|
13 |
+
"bos_token_id": null,
|
14 |
+
"chunk_size_feed_forward": 0,
|
15 |
+
"decoder_start_token_id": null,
|
16 |
+
"do_sample": false,
|
17 |
+
"early_stopping": false,
|
18 |
+
"eos_token_id": null,
|
19 |
+
"finetuning_task": null,
|
20 |
+
"gradient_checkpointing": false,
|
21 |
+
"hidden_act": "gelu",
|
22 |
+
"hidden_dropout_prob": 0.1,
|
23 |
+
"hidden_size": 768,
|
24 |
+
"id2label": {
|
25 |
+
"0": "LABEL_0",
|
26 |
+
"1": "LABEL_1"
|
27 |
+
},
|
28 |
+
"initializer_range": 0.02,
|
29 |
+
"intermediate_size": 3072,
|
30 |
+
"is_decoder": true,
|
31 |
+
"is_encoder_decoder": false,
|
32 |
+
"label2id": {
|
33 |
+
"LABEL_0": 0,
|
34 |
+
"LABEL_1": 1
|
35 |
+
},
|
36 |
+
"layer_norm_eps": 1e-12,
|
37 |
+
"length_penalty": 1.0,
|
38 |
+
"max_length": 20,
|
39 |
+
"max_position_embeddings": 512,
|
40 |
+
"min_length": 0,
|
41 |
+
"model_type": "bert",
|
42 |
+
"no_repeat_ngram_size": 0,
|
43 |
+
"num_attention_heads": 12,
|
44 |
+
"num_beams": 1,
|
45 |
+
"num_hidden_layers": 12,
|
46 |
+
"num_return_sequences": 1,
|
47 |
+
"output_attentions": false,
|
48 |
+
"output_hidden_states": false,
|
49 |
+
"pad_token_id": 0,
|
50 |
+
"prefix": null,
|
51 |
+
"pruned_heads": {},
|
52 |
+
"repetition_penalty": 1.0,
|
53 |
+
"return_dict": false,
|
54 |
+
"sep_token_id": null,
|
55 |
+
"task_specific_params": null,
|
56 |
+
"temperature": 1.0,
|
57 |
+
"tie_encoder_decoder": false,
|
58 |
+
"tie_word_embeddings": true,
|
59 |
+
"tokenizer_class": null,
|
60 |
+
"top_k": 50,
|
61 |
+
"top_p": 1.0,
|
62 |
+
"torchscript": false,
|
63 |
+
"type_vocab_size": 2,
|
64 |
+
"use_bfloat16": false,
|
65 |
+
"use_cache": true,
|
66 |
+
"vocab_size": 30522,
|
67 |
+
"xla_device": null
|
68 |
+
},
|
69 |
+
"decoder_start_token_id": 101,
|
70 |
+
"early_stopping": true,
|
71 |
+
"encoder": {
|
72 |
+
"_name_or_path": "bert-base-uncased",
|
73 |
+
"add_cross_attention": false,
|
74 |
+
"architectures": [
|
75 |
+
"BertForMaskedLM"
|
76 |
+
],
|
77 |
+
"attention_probs_dropout_prob": 0.1,
|
78 |
+
"bad_words_ids": null,
|
79 |
+
"bos_token_id": null,
|
80 |
+
"chunk_size_feed_forward": 0,
|
81 |
+
"decoder_start_token_id": null,
|
82 |
+
"do_sample": false,
|
83 |
+
"early_stopping": false,
|
84 |
+
"eos_token_id": null,
|
85 |
+
"finetuning_task": null,
|
86 |
+
"gradient_checkpointing": false,
|
87 |
+
"hidden_act": "gelu",
|
88 |
+
"hidden_dropout_prob": 0.1,
|
89 |
+
"hidden_size": 768,
|
90 |
+
"id2label": {
|
91 |
+
"0": "LABEL_0",
|
92 |
+
"1": "LABEL_1"
|
93 |
+
},
|
94 |
+
"initializer_range": 0.02,
|
95 |
+
"intermediate_size": 3072,
|
96 |
+
"is_decoder": false,
|
97 |
+
"is_encoder_decoder": false,
|
98 |
+
"label2id": {
|
99 |
+
"LABEL_0": 0,
|
100 |
+
"LABEL_1": 1
|
101 |
+
},
|
102 |
+
"layer_norm_eps": 1e-12,
|
103 |
+
"length_penalty": 1.0,
|
104 |
+
"max_length": 20,
|
105 |
+
"max_position_embeddings": 512,
|
106 |
+
"min_length": 0,
|
107 |
+
"model_type": "bert",
|
108 |
+
"no_repeat_ngram_size": 0,
|
109 |
+
"num_attention_heads": 12,
|
110 |
+
"num_beams": 1,
|
111 |
+
"num_hidden_layers": 12,
|
112 |
+
"num_return_sequences": 1,
|
113 |
+
"output_attentions": false,
|
114 |
+
"output_hidden_states": false,
|
115 |
+
"pad_token_id": 0,
|
116 |
+
"prefix": null,
|
117 |
+
"pruned_heads": {},
|
118 |
+
"repetition_penalty": 1.0,
|
119 |
+
"return_dict": false,
|
120 |
+
"sep_token_id": null,
|
121 |
+
"task_specific_params": null,
|
122 |
+
"temperature": 1.0,
|
123 |
+
"tie_encoder_decoder": false,
|
124 |
+
"tie_word_embeddings": true,
|
125 |
+
"tokenizer_class": null,
|
126 |
+
"top_k": 50,
|
127 |
+
"top_p": 1.0,
|
128 |
+
"torchscript": false,
|
129 |
+
"type_vocab_size": 2,
|
130 |
+
"use_bfloat16": false,
|
131 |
+
"use_cache": true,
|
132 |
+
"vocab_size": 30522,
|
133 |
+
"xla_device": null
|
134 |
+
},
|
135 |
+
"eos_token_id": 102,
|
136 |
+
"is_encoder_decoder": true,
|
137 |
+
"length_penalty": 2.0,
|
138 |
+
"max_length": 142,
|
139 |
+
"min_length": 56,
|
140 |
+
"model_type": "encoder-decoder",
|
141 |
+
"no_repeat_ngram_size": 3,
|
142 |
+
"num_beams": 4,
|
143 |
+
"pad_token_id": 0,
|
144 |
+
"vocab_size": 30522
|
145 |
+
}
|
index.gitattributes
ADDED
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
*.bin.* filter=lfs diff=lfs merge=lfs -text
|
2 |
+
*.lfs.* filter=lfs diff=lfs merge=lfs -text
|
3 |
+
*.bin filter=lfs diff=lfs merge=lfs -text
|
4 |
+
*.h5 filter=lfs diff=lfs merge=lfs -text
|
5 |
+
*.tflite filter=lfs diff=lfs merge=lfs -text
|
6 |
+
*.tar.gz filter=lfs diff=lfs merge=lfs -text
|
7 |
+
*.ot filter=lfs diff=lfs merge=lfs -text
|
8 |
+
*.onnx filter=lfs diff=lfs merge=lfs -text
|
index.lock
ADDED
File without changes
|
pytorch_model.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:c42e5122d8eaf2192d3da7cd4fa360d1cfad98ca07ffe6a9a3aeb8ea1e525dd9
|
3 |
+
size 989691346
|
special_tokens_map.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"bos_token": "[CLS]", "eos_token": "[SEP]", "unk_token": "[UNK]", "sep_token": "[SEP]", "pad_token": "[PAD]", "cls_token": "[CLS]", "mask_token": "[MASK]"}
|
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, "name_or_path": "bert-base-uncased"}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|