lynlyn555 parquet-converter commited on
Commit
cd0ba0b
·
verified ·
0 Parent(s):

Duplicate from alexfabbri/multi_news

Browse files

Co-authored-by: Parquet-converter (BOT) <parquet-converter@users.noreply.huggingface.co>

.gitattributes ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.bin filter=lfs diff=lfs merge=lfs -text
4
+ *.bin.* filter=lfs diff=lfs merge=lfs -text
5
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
6
+ *.ftz filter=lfs diff=lfs merge=lfs -text
7
+ *.gz filter=lfs diff=lfs merge=lfs -text
8
+ *.h5 filter=lfs diff=lfs merge=lfs -text
9
+ *.joblib filter=lfs diff=lfs merge=lfs -text
10
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
11
+ *.model filter=lfs diff=lfs merge=lfs -text
12
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
13
+ *.onnx filter=lfs diff=lfs merge=lfs -text
14
+ *.ot filter=lfs diff=lfs merge=lfs -text
15
+ *.parquet filter=lfs diff=lfs merge=lfs -text
16
+ *.pb filter=lfs diff=lfs merge=lfs -text
17
+ *.pt filter=lfs diff=lfs merge=lfs -text
18
+ *.pth filter=lfs diff=lfs merge=lfs -text
19
+ *.rar filter=lfs diff=lfs merge=lfs -text
20
+ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
21
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
22
+ *.tflite filter=lfs diff=lfs merge=lfs -text
23
+ *.tgz filter=lfs diff=lfs merge=lfs -text
24
+ *.xz 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
+ data/* filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,233 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ annotations_creators:
3
+ - expert-generated
4
+ language_creators:
5
+ - expert-generated
6
+ language:
7
+ - en
8
+ license:
9
+ - other
10
+ multilinguality:
11
+ - monolingual
12
+ pretty_name: Multi-News
13
+ size_categories:
14
+ - 10K<n<100K
15
+ source_datasets:
16
+ - original
17
+ task_categories:
18
+ - summarization
19
+ task_ids:
20
+ - news-articles-summarization
21
+ paperswithcode_id: multi-news
22
+ train-eval-index:
23
+ - config: default
24
+ task: summarization
25
+ task_id: summarization
26
+ splits:
27
+ train_split: train
28
+ eval_split: test
29
+ col_mapping:
30
+ document: text
31
+ summary: target
32
+ metrics:
33
+ - type: rouge
34
+ name: Rouge
35
+ dataset_info:
36
+ features:
37
+ - name: document
38
+ dtype: string
39
+ - name: summary
40
+ dtype: string
41
+ splits:
42
+ - name: train
43
+ num_bytes: 558392265
44
+ num_examples: 44972
45
+ - name: validation
46
+ num_bytes: 68272432
47
+ num_examples: 5622
48
+ - name: test
49
+ num_bytes: 70032124
50
+ num_examples: 5622
51
+ download_size: 756785627
52
+ dataset_size: 696696821
53
+ ---
54
+
55
+ # Dataset Card for Multi-News
56
+
57
+ ## Table of Contents
58
+ - [Table of Contents](#table-of-contents)
59
+ - [Dataset Description](#dataset-description)
60
+ - [Dataset Summary](#dataset-summary)
61
+ - [Supported Tasks and Leaderboards](#supported-tasks-and-leaderboards)
62
+ - [Languages](#languages)
63
+ - [Dataset Structure](#dataset-structure)
64
+ - [Data Instances](#data-instances)
65
+ - [Data Fields](#data-fields)
66
+ - [Data Splits](#data-splits)
67
+ - [Dataset Creation](#dataset-creation)
68
+ - [Curation Rationale](#curation-rationale)
69
+ - [Source Data](#source-data)
70
+ - [Annotations](#annotations)
71
+ - [Personal and Sensitive Information](#personal-and-sensitive-information)
72
+ - [Considerations for Using the Data](#considerations-for-using-the-data)
73
+ - [Social Impact of Dataset](#social-impact-of-dataset)
74
+ - [Discussion of Biases](#discussion-of-biases)
75
+ - [Other Known Limitations](#other-known-limitations)
76
+ - [Additional Information](#additional-information)
77
+ - [Dataset Curators](#dataset-curators)
78
+ - [Licensing Information](#licensing-information)
79
+ - [Citation Information](#citation-information)
80
+ - [Contributions](#contributions)
81
+
82
+ ## Dataset Description
83
+
84
+ - **Homepage:** [https://github.com/Alex-Fabbri/Multi-News](https://github.com/Alex-Fabbri/Multi-News)
85
+ - **Repository:** [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
86
+ - **Paper:** [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
87
+ - **Point of Contact:** [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
88
+ - **Size of downloaded dataset files:** 256.96 MB
89
+ - **Size of the generated dataset:** 700.18 MB
90
+ - **Total amount of disk used:** 957.14 MB
91
+
92
+ ### Dataset Summary
93
+
94
+ Multi-News, consists of news articles and human-written summaries
95
+ of these articles from the site newser.com.
96
+ Each summary is professionally written by editors and
97
+ includes links to the original articles cited.
98
+
99
+ There are two features:
100
+ - document: text of news articles seperated by special token "|||||".
101
+ - summary: news summary.
102
+
103
+ ### Supported Tasks and Leaderboards
104
+
105
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
106
+
107
+ ### Languages
108
+
109
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
110
+
111
+ ## Dataset Structure
112
+
113
+ ### Data Instances
114
+
115
+ #### default
116
+
117
+ - **Size of downloaded dataset files:** 256.96 MB
118
+ - **Size of the generated dataset:** 700.18 MB
119
+ - **Total amount of disk used:** 957.14 MB
120
+
121
+ An example of 'validation' looks as follows.
122
+ ```
123
+ {
124
+ "document": "some line val \n another line",
125
+ "summary": "target val line"
126
+ }
127
+ ```
128
+
129
+ ### Data Fields
130
+
131
+ The data fields are the same among all splits.
132
+
133
+ #### default
134
+ - `document`: a `string` feature.
135
+ - `summary`: a `string` feature.
136
+
137
+ ### Data Splits
138
+
139
+ | name |train|validation|test|
140
+ |-------|----:|---------:|---:|
141
+ |default|44972| 5622|5622|
142
+
143
+ ## Dataset Creation
144
+
145
+ ### Curation Rationale
146
+
147
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
148
+
149
+ ### Source Data
150
+
151
+ #### Initial Data Collection and Normalization
152
+
153
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
154
+
155
+ #### Who are the source language producers?
156
+
157
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
158
+
159
+ ### Annotations
160
+
161
+ #### Annotation process
162
+
163
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
164
+
165
+ #### Who are the annotators?
166
+
167
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
168
+
169
+ ### Personal and Sensitive Information
170
+
171
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
172
+
173
+ ## Considerations for Using the Data
174
+
175
+ ### Social Impact of Dataset
176
+
177
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
178
+
179
+ ### Discussion of Biases
180
+
181
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
182
+
183
+ ### Other Known Limitations
184
+
185
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
186
+
187
+ ## Additional Information
188
+
189
+ ### Dataset Curators
190
+
191
+ [More Information Needed](https://github.com/huggingface/datasets/blob/master/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
192
+
193
+ ### Licensing Information
194
+
195
+ ```
196
+ This Dataset Usage Agreement ("Agreement") is a legal agreement with LILY LAB for the Dataset made available to the individual or entity ("Researcher") exercising rights under this Agreement. "Dataset" includes all text, data, information, source code, and any related materials, documentation, files, media, updates or revisions.
197
+
198
+ The Dataset is intended for non-commercial research and educational purposes only, and is made available free of charge without extending any license or other intellectual property rights. By downloading or using the Dataset, the Researcher acknowledges that they agree to the terms in this Agreement, and represent and warrant that they have authority to do so on behalf of any entity exercising rights under this Agreement. The Researcher accepts and agrees to be bound by the terms and conditions of this Agreement. If the Researcher does not agree to this Agreement, they may not download or use the Dataset.
199
+
200
+ By sharing content with m, such as by submitting content to this site or by corresponding with LILY LAB contributors, the Researcher grants LILY LAB the right to use, reproduce, display, perform, adapt, modify, distribute, have distributed, and promote the content in any form, anywhere and for any purpose, such as for evaluating and comparing summarization systems. Nothing in this Agreement shall obligate LILY LAB to provide any support for the Dataset. Any feedback, suggestions, ideas, comments, improvements given by the Researcher related to the Dataset is voluntarily given, and may be used by LILY LAB without obligation or restriction of any kind.
201
+
202
+ The Researcher accepts full responsibility for their use of the Dataset and shall defend indemnify, and hold harmless m, including their employees, trustees, officers, and agents, against any and all claims arising from the Researcher's use of the Dataset. The Researcher agrees to comply with all laws and regulations as they relate to access to and use of the Dataset and Service including U.S. export jurisdiction and other U.S. and international regulations.
203
+
204
+ THE DATASET IS PROVIDED "AS IS." LILY LAB DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT. WITHOUT LIMITATION OF THE ABOVE, LILY LAB DISCLAIMS ANY WARRANTY THAT DATASET IS BUG OR ERROR-FREE, AND GRANTS NO WARRANTY REGARDING ITS USE OR THE RESULTS THEREFROM INCLUDING, WITHOUT LIMITATION, ITS CORRECTNESS, ACCURACY, OR RELIABILITY. THE DATASET IS NOT WARRANTIED TO FULFILL ANY PARTICULAR PURPOSES OR NEEDS.
205
+
206
+ TO THE EXTENT NOT PROHIBITED BY LAW, IN NO EVENT SHALL LILY LAB BE LIABLE FOR ANY LOSS, DAMAGE OR INJURY, DIRECT AND INDIRECT, INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES, HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER FOR BREACH OF CONTRACT, TORT (INCLUDING NEGLIGENCE) OR OTHERWISE, ARISING OUT OF THIS AGREEMENT, INCLUDING BUT NOT LIMITED TO LOSS OF PROFITS, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. THESE LIMITATIONS SHALL APPLY NOTWITHSTANDING ANY FAILURE OF ESSENTIAL PURPOSE OF ANY LIMITED REMEDY.
207
+
208
+ This Agreement is effective until terminated. LILY LAB reserves the right to terminate the Researcher's access to the Dataset at any time. If the Researcher breaches this Agreement, the Researcher's rights to use the Dataset shall terminate automatically. The Researcher will immediately cease all use and distribution of the Dataset and destroy any copies or portions of the Dataset in their possession.
209
+
210
+ This Agreement is governed by the laws of the SOME_PLACE, without regard to conflict of law principles. All terms and provisions of this Agreement shall, if possible, be construed in a manner which makes them valid, but in the event any term or provision of this Agreement is found by a court of competent jurisdiction to be illegal or unenforceable, the validity or enforceability of the remainder of this Agreement shall not be affected.
211
+
212
+ This Agreement is the complete and exclusive agreement between the parties with respect to its subject matter and supersedes all prior or contemporaneous oral or written agreements or understandings relating to the subject matter.
213
+ ```
214
+
215
+ ### Citation Information
216
+
217
+ ```
218
+
219
+ @misc{alex2019multinews,
220
+ title={Multi-News: a Large-Scale Multi-Document Summarization Dataset and Abstractive Hierarchical Model},
221
+ author={Alexander R. Fabbri and Irene Li and Tianwei She and Suyi Li and Dragomir R. Radev},
222
+ year={2019},
223
+ eprint={1906.01749},
224
+ archivePrefix={arXiv},
225
+ primaryClass={cs.CL}
226
+ }
227
+
228
+ ```
229
+
230
+
231
+ ### Contributions
232
+
233
+ Thanks to [@patrickvonplaten](https://github.com/patrickvonplaten), [@lewtun](https://github.com/lewtun), [@thomwolf](https://github.com/thomwolf) for adding this dataset.
data/test.src.cleaned ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:138d3ac2dc899cbcd2e3745aaa94d1c1db55fb7058d9df4ba3ef2dac05a3a186
3
+ size 68999509
data/test.tgt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:fa97cf91a62ae82a0af6da88f2ddf8e06eb4e3b90f7971d8e0c516436518fae3
3
+ size 7309099
data/train.src.cleaned ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:627781c8ce55d528fcdacd495db45583a915e2d24b7983b0a5a6693ede933bb1
3
+ size 547512283
data/train.tgt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e9e82b8f413b0f1ed4eb7c883f93bb744f829c218c1608b6ba7615d687d07121
3
+ size 58793912
data/val.src.cleaned ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f0a43902da366eea2b882e39ddd4c0975ad44aba6b61095a2ea90362e9e2bb65
3
+ size 66875522
data/val.tgt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:bb08a078e0cb2b8ca9cc0fe3bfbe9d4098dee706bd00eb97449155e41b880157
3
+ size 7295302
multi_news.py ADDED
@@ -0,0 +1,111 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # coding=utf-8
2
+ # Copyright 2020 The TensorFlow Datasets Authors and the HuggingFace Datasets Authors.
3
+ #
4
+ # Licensed under the Apache License, Version 2.0 (the "License");
5
+ # you may not use this file except in compliance with the License.
6
+ # You may obtain a copy of the License at
7
+ #
8
+ # http://www.apache.org/licenses/LICENSE-2.0
9
+ #
10
+ # Unless required by applicable law or agreed to in writing, software
11
+ # distributed under the License is distributed on an "AS IS" BASIS,
12
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ # See the License for the specific language governing permissions and
14
+ # limitations under the License.
15
+
16
+ # Lint as: python3
17
+ """Multi-News dataset."""
18
+
19
+ import datasets
20
+
21
+
22
+ _HOMEPAGE = "https://github.com/Alex-Fabbri/Multi-News"
23
+
24
+ _LICENSE = "For non-commercial research and educational purposes only"
25
+
26
+ _CITATION = """
27
+ @misc{alex2019multinews,
28
+ title={Multi-News: a Large-Scale Multi-Document Summarization Dataset and Abstractive Hierarchical Model},
29
+ author={Alexander R. Fabbri and Irene Li and Tianwei She and Suyi Li and Dragomir R. Radev},
30
+ year={2019},
31
+ eprint={1906.01749},
32
+ archivePrefix={arXiv},
33
+ primaryClass={cs.CL}
34
+ }
35
+ """
36
+
37
+ _DESCRIPTION = """
38
+ Multi-News, consists of news articles and human-written summaries
39
+ of these articles from the site newser.com.
40
+ Each summary is professionally written by editors and
41
+ includes links to the original articles cited.
42
+
43
+ There are two features:
44
+ - document: text of news articles seperated by special token "|||||".
45
+ - summary: news summary.
46
+ """
47
+
48
+ _REPO = "https://huggingface.co/datasets/multi_news/resolve/main/data"
49
+ _URLs = {
50
+ "train": [
51
+ f"{_REPO}/train.src.cleaned",
52
+ f"{_REPO}/train.tgt",
53
+ ],
54
+ "val": [
55
+ f"{_REPO}/val.src.cleaned",
56
+ f"{_REPO}/val.tgt",
57
+ ],
58
+ "test": [
59
+ f"{_REPO}/test.src.cleaned",
60
+ f"{_REPO}/test.tgt",
61
+ ],
62
+ }
63
+
64
+ _DOCUMENT = "document"
65
+ _SUMMARY = "summary"
66
+
67
+
68
+ class MultiNews(datasets.GeneratorBasedBuilder):
69
+ """Multi-News dataset."""
70
+
71
+ VERSION = datasets.Version("1.0.0")
72
+
73
+ def _info(self):
74
+ return datasets.DatasetInfo(
75
+ description=_DESCRIPTION,
76
+ features=datasets.Features({_DOCUMENT: datasets.Value("string"), _SUMMARY: datasets.Value("string")}),
77
+ supervised_keys=(_DOCUMENT, _SUMMARY),
78
+ homepage=_HOMEPAGE,
79
+ license=_LICENSE,
80
+ citation=_CITATION,
81
+ )
82
+
83
+ def _split_generators(self, dl_manager):
84
+ """Returns SplitGenerators."""
85
+ files = dl_manager.download(_URLs)
86
+ return [
87
+ datasets.SplitGenerator(
88
+ name=datasets.Split.TRAIN,
89
+ gen_kwargs={"src_file": files["train"][0], "tgt_file": files["train"][1]},
90
+ ),
91
+ datasets.SplitGenerator(
92
+ name=datasets.Split.VALIDATION,
93
+ gen_kwargs={"src_file": files["val"][0], "tgt_file": files["val"][1]},
94
+ ),
95
+ datasets.SplitGenerator(
96
+ name=datasets.Split.TEST,
97
+ gen_kwargs={"src_file": files["test"][0], "tgt_file": files["test"][1]},
98
+ ),
99
+ ]
100
+
101
+ def _generate_examples(self, src_file, tgt_file):
102
+ """Yields examples."""
103
+ with open(src_file, encoding="utf-8") as src_f, open(tgt_file, encoding="utf-8") as tgt_f:
104
+ for i, (src_line, tgt_line) in enumerate(zip(src_f, tgt_f)):
105
+ yield i, {
106
+ # In original file, each line has one example and natural newline
107
+ # tokens "\n" are being replaced with "NEWLINE_CHAR". Here restore
108
+ # the natural newline token to avoid special vocab "NEWLINE_CHAR".
109
+ _DOCUMENT: src_line.strip().replace("NEWLINE_CHAR", "\n"),
110
+ _SUMMARY: tgt_line.strip(),
111
+ }