Datasets:

Modalities:
Text
Formats:
parquet
ArXiv:
Libraries:
Datasets
pandas
License:
system HF staff commited on
Commit
cc9a080
0 Parent(s):

Update files from the datasets library (from 1.2.0)

Browse files

Release notes: https://github.com/huggingface/datasets/releases/tag/1.2.0

.gitattributes ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
README.md ADDED
@@ -0,0 +1,164 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ annotations_creators:
3
+ - found
4
+ language_creators:
5
+ - found
6
+ languages:
7
+ en-to-ku
8
+ - en
9
+ - ku
10
+ en-to-tr
11
+ - en
12
+ - tr
13
+ ku-to-tr
14
+ - ku
15
+ - tr
16
+ licenses:
17
+ - unknown
18
+ multilinguality:
19
+ - translation
20
+ size_categories:
21
+ - n>1M
22
+ source_datasets:
23
+ - original
24
+ task_categories:
25
+ - conditional-text-generation
26
+ task_ids:
27
+ - machine-translation
28
+ ---
29
+
30
+ # Dataset Card for [Dataset Name]
31
+
32
+ ## Table of Contents
33
+ - [Dataset Description](#dataset-description)
34
+ - [Dataset Summary](#dataset-summary)
35
+ - [Supported Tasks](#supported-tasks-and-leaderboards)
36
+ - [Languages](#languages)
37
+ - [Dataset Structure](#dataset-structure)
38
+ - [Data Instances](#data-instances)
39
+ - [Data Fields](#data-instances)
40
+ - [Data Splits](#data-instances)
41
+ - [Dataset Creation](#dataset-creation)
42
+ - [Curation Rationale](#curation-rationale)
43
+ - [Source Data](#source-data)
44
+ - [Annotations](#annotations)
45
+ - [Personal and Sensitive Information](#personal-and-sensitive-information)
46
+ - [Considerations for Using the Data](#considerations-for-using-the-data)
47
+ - [Social Impact of Dataset](#social-impact-of-dataset)
48
+ - [Discussion of Biases](#discussion-of-biases)
49
+ - [Other Known Limitations](#other-known-limitations)
50
+ - [Additional Information](#additional-information)
51
+ - [Dataset Curators](#dataset-curators)
52
+ - [Licensing Information](#licensing-information)
53
+ - [Citation Information](#citation-information)
54
+
55
+ ## Dataset Description
56
+
57
+ - **Homepage:** [Bianet](http://opus.nlpl.eu/Bianet.php)
58
+ - **Repository:**
59
+ - **Paper:** [Ataman, D. (2018) Bianet: A Parallel News Corpus in Turkish, Kurdish and English. In Proceedings of the LREC 2018 Workshop MLP-Moment. pp. 14-17. pdf](http://lrec-conf.org/workshops/lrec2018/W19/pdf/6_W19.pdf)
60
+ - **Leaderboard:**
61
+ - **Point of Contact:**
62
+
63
+ ### Dataset Summary
64
+
65
+ A parallel news corpus in Turkish, Kurdish and English;
66
+ Bianet collects 3,214 Turkish articles with their sentence-aligned Kurdish or English translations from the Bianet online newspaper.
67
+
68
+ 3 languages, 3 bitexts
69
+ total number of files: 6
70
+ total number of tokens: 2.25M
71
+ total number of sentence fragments: 0.14M
72
+
73
+ ### Supported Tasks and Leaderboards
74
+
75
+ [More Information Needed]
76
+
77
+ ### Languages
78
+
79
+ [More Information Needed]
80
+
81
+ ## Dataset Structure
82
+
83
+ ### Data Instances
84
+
85
+ [More Information Needed]
86
+
87
+ ### Data Fields
88
+
89
+ [More Information Needed]
90
+
91
+ ### Data Splits
92
+
93
+ [More Information Needed]
94
+
95
+ ## Dataset Creation
96
+
97
+ ### Curation Rationale
98
+
99
+ [More Information Needed]
100
+
101
+ ### Source Data
102
+
103
+ #### Initial Data Collection and Normalization
104
+
105
+ [More Information Needed]
106
+
107
+ #### Who are the source language producers?
108
+
109
+ [More Information Needed]
110
+
111
+ ### Annotations
112
+
113
+ #### Annotation process
114
+
115
+ [More Information Needed]
116
+
117
+ #### Who are the annotators?
118
+
119
+ [More Information Needed]
120
+
121
+ ### Personal and Sensitive Information
122
+
123
+ [More Information Needed]
124
+
125
+ ## Considerations for Using the Data
126
+
127
+ ### Social Impact of Dataset
128
+
129
+ [More Information Needed]
130
+
131
+ ### Discussion of Biases
132
+
133
+ [More Information Needed]
134
+
135
+ ### Other Known Limitations
136
+
137
+ [More Information Needed]
138
+
139
+ ## Additional Information
140
+
141
+ ### Dataset Curators
142
+
143
+ [More Information Needed]
144
+
145
+ ### Licensing Information
146
+
147
+ CC-BY-SA-4.0
148
+
149
+ ### Citation Information
150
+
151
+ @InProceedings{ATAMAN18.6,
152
+ author = {Duygu Ataman},
153
+ title = {Bianet: A Parallel News Corpus in Turkish, Kurdish and English},
154
+ booktitle = {Proceedings of the Eleventh International Conference on Language Resources and Evaluation (LREC 2018)},
155
+ year = {2018},
156
+ month = {may},
157
+ date = {7-12},
158
+ location = {Miyazaki, Japan},
159
+ editor = {Jinhua Du and Mihael Arcan and Qun Liu and Hitoshi Isahara},
160
+ publisher = {European Language Resources Association (ELRA)},
161
+ address = {Paris, France},
162
+ isbn = {979-10-95546-15-3},
163
+ language = {english}
164
+ }
bianet.py ADDED
@@ -0,0 +1,149 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # coding=utf-8
2
+ # Copyright 2020 The HuggingFace Datasets Authors and the current dataset script contributor.
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
+ """Bianet: A parallel news corpus in Turkish, Kurdish and English"""
16
+
17
+ from __future__ import absolute_import, division, print_function
18
+
19
+ import os
20
+
21
+ import datasets
22
+
23
+
24
+ _CITATION = """\
25
+ @InProceedings{ATAMAN18.6,
26
+ author = {Duygu Ataman},
27
+ title = {Bianet: A Parallel News Corpus in Turkish, Kurdish and English},
28
+ booktitle = {Proceedings of the Eleventh International Conference on Language Resources and Evaluation (LREC 2018)},
29
+ year = {2018},
30
+ month = {may},
31
+ date = {7-12},
32
+ location = {Miyazaki, Japan},
33
+ editor = {Jinhua Du and Mihael Arcan and Qun Liu and Hitoshi Isahara},
34
+ publisher = {European Language Resources Association (ELRA)},
35
+ address = {Paris, France},
36
+ isbn = {979-10-95546-15-3},
37
+ language = {english}
38
+ }"""
39
+
40
+ _HOMEPAGE = "http://opus.nlpl.eu/Bianet.php"
41
+
42
+
43
+ _LICENSE = "CC-BY-SA-4.0"
44
+
45
+ _VALID_LANGUAGE_PAIRS = {
46
+ ("en", "ku"): "http://opus.nlpl.eu/download.php?f=Bianet/v1/moses/en-ku.txt.zip",
47
+ ("en", "tr"): "http://opus.nlpl.eu/download.php?f=Bianet/v1/moses/en-tr.txt.zip",
48
+ ("ku", "tr"): "http://opus.nlpl.eu/download.php?f=Bianet/v1/moses/ku-tr.txt.zip",
49
+ }
50
+
51
+ _VERSION = "1.0.0"
52
+
53
+ _DESCRIPTION = """\
54
+ A parallel news corpus in Turkish, Kurdish and English.
55
+ Bianet collects 3,214 Turkish articles with their sentence-aligned Kurdish or English translations from the Bianet online newspaper.
56
+ 3 languages, 3 bitexts
57
+ total number of files: 6
58
+ total number of tokens: 2.25M
59
+ total number of sentence fragments: 0.14M
60
+ """
61
+
62
+ _BASE_NAME = "Bianet.{}-{}.{}"
63
+
64
+
65
+ class BianetConfig(datasets.BuilderConfig):
66
+ """BuilderConfig for Bianet: A parallel news corpus in Turkish, Kurdish and English"""
67
+
68
+ def __init__(self, language_pair=(None, None), **kwargs):
69
+ """BuilderConfig for Bianet: A parallel news corpus in Turkish, Kurdish and English.
70
+ The first language in `language_pair` should consist of two strings joined by
71
+ an underscore (e.g. "en-tr").
72
+ Args:
73
+ language_pair: pair of languages that will be used for translation.
74
+ **kwargs: keyword arguments forwarded to super.
75
+ """
76
+ name = "%s_to_%s" % (language_pair[0], language_pair[1])
77
+
78
+ description = ("Translation dataset from %s to %s or %s to %s.") % (
79
+ language_pair[0],
80
+ language_pair[1],
81
+ language_pair[1],
82
+ language_pair[0],
83
+ )
84
+ super(BianetConfig, self).__init__(
85
+ name=name, description=description, version=datasets.Version(_VERSION, ""), **kwargs
86
+ )
87
+
88
+ # Validate language pair.
89
+ assert language_pair in _VALID_LANGUAGE_PAIRS, (
90
+ "Config language pair (%s, " "%s) not supported"
91
+ ) % language_pair
92
+
93
+ self.language_pair = language_pair
94
+
95
+
96
+ class Bianet(datasets.GeneratorBasedBuilder):
97
+
98
+ BUILDER_CONFIGS = [
99
+ BianetConfig(
100
+ language_pair=pair,
101
+ )
102
+ for pair in _VALID_LANGUAGE_PAIRS.keys()
103
+ ]
104
+
105
+ BUILDER_CONFIG_CLASS = BianetConfig
106
+
107
+ def _info(self):
108
+ return datasets.DatasetInfo(
109
+ description=_DESCRIPTION,
110
+ features=datasets.Features(
111
+ {
112
+ "id": datasets.Value("string"),
113
+ "translation": datasets.Translation(languages=tuple(self.config.language_pair)),
114
+ },
115
+ ),
116
+ supervised_keys=None,
117
+ homepage=_HOMEPAGE,
118
+ citation=_CITATION,
119
+ )
120
+
121
+ def _split_generators(self, dl_manager):
122
+ download_url = _VALID_LANGUAGE_PAIRS.get(tuple(self.config.language_pair))
123
+ path = dl_manager.download_and_extract(download_url)
124
+ return [
125
+ datasets.SplitGenerator(
126
+ name=datasets.Split.TRAIN,
127
+ gen_kwargs={"datapath": path},
128
+ )
129
+ ]
130
+
131
+ def _generate_examples(self, datapath):
132
+ lang1, lang2 = self.config.language_pair
133
+ lang1_file = _BASE_NAME.format(lang1, lang2, lang1)
134
+ lang2_file = _BASE_NAME.format(lang1, lang2, lang2)
135
+ lang1_path = os.path.join(datapath, lang1_file)
136
+ lang2_path = os.path.join(datapath, lang2_file)
137
+
138
+ with open(lang1_path, encoding="utf-8") as f1, open(lang2_path, encoding="utf-8") as f2:
139
+ for sentence_counter, (x, y) in enumerate(zip(f1, f2)):
140
+ x = x.strip()
141
+ y = y.strip()
142
+ result = (
143
+ sentence_counter,
144
+ {
145
+ "id": str(sentence_counter),
146
+ "translation": {lang1: x, lang2: y},
147
+ },
148
+ )
149
+ yield result
dataset_infos.json ADDED
@@ -0,0 +1 @@
 
 
1
+ {"en_to_ku": {"description": "A parallel news corpus in Turkish, Kurdish and English.\nBianet collects 3,214 Turkish articles with their sentence-aligned Kurdish or English translations from the Bianet online newspaper.\n3 languages, 3 bitexts\ntotal number of files: 6\ntotal number of tokens: 2.25M\ntotal number of sentence fragments: 0.14M\n", "citation": "Ataman, D. (2018) Bianet: A Parallel News Corpus in Turkish, Kurdish and English. In Proceedings of the LREC 2018 Workshop MLP-Moment. pp. 14-17. pdf", "homepage": "http://opus.nlpl.eu/Bianet.php", "license": "", "features": {"id": {"dtype": "string", "id": null, "_type": "Value"}, "translation": {"languages": ["en", "ku"], "id": null, "_type": "Translation"}}, "post_processed": null, "supervised_keys": null, "builder_name": "bianet", "config_name": "en_to_ku", "version": {"version_str": "1.0.0", "description": "", "major": 1, "minor": 0, "patch": 0}, "splits": {"train": {"name": "train", "num_bytes": 1800806, "num_examples": 6402, "dataset_name": "bianet"}}, "download_checksums": {"http://opus.nlpl.eu/download.php?f=Bianet/v1/moses/en-ku.txt.zip": {"num_bytes": 622420, "checksum": "04238f916be585e426318eb486ecaa00c9800bdd219bd47216bbe1cb732bcde5"}}, "download_size": 622420, "post_processing_size": null, "dataset_size": 1800806, "size_in_bytes": 2423226}, "en_to_tr": {"description": "A parallel news corpus in Turkish, Kurdish and English.\nBianet collects 3,214 Turkish articles with their sentence-aligned Kurdish or English translations from the Bianet online newspaper.\n3 languages, 3 bitexts\ntotal number of files: 6\ntotal number of tokens: 2.25M\ntotal number of sentence fragments: 0.14M\n", "citation": "Ataman, D. (2018) Bianet: A Parallel News Corpus in Turkish, Kurdish and English. In Proceedings of the LREC 2018 Workshop MLP-Moment. pp. 14-17. pdf", "homepage": "http://opus.nlpl.eu/Bianet.php", "license": "", "features": {"id": {"dtype": "string", "id": null, "_type": "Value"}, "translation": {"languages": ["en", "tr"], "id": null, "_type": "Translation"}}, "post_processed": null, "supervised_keys": null, "builder_name": "bianet", "config_name": "en_to_tr", "version": {"version_str": "1.0.0", "description": "", "major": 1, "minor": 0, "patch": 0}, "splits": {"train": {"name": "train", "num_bytes": 10231043, "num_examples": 34770, "dataset_name": "bianet"}}, "download_checksums": {"http://opus.nlpl.eu/download.php?f=Bianet/v1/moses/en-tr.txt.zip": {"num_bytes": 3544116, "checksum": "08f0857457438be03e4e6f6359cac99522fe43d99daa92d49cec0d90fa0c68d4"}}, "download_size": 3544116, "post_processing_size": null, "dataset_size": 10231043, "size_in_bytes": 13775159}, "ku_to_tr": {"description": "A parallel news corpus in Turkish, Kurdish and English.\nBianet collects 3,214 Turkish articles with their sentence-aligned Kurdish or English translations from the Bianet online newspaper.\n3 languages, 3 bitexts\ntotal number of files: 6\ntotal number of tokens: 2.25M\ntotal number of sentence fragments: 0.14M\n", "citation": "Ataman, D. (2018) Bianet: A Parallel News Corpus in Turkish, Kurdish and English. In Proceedings of the LREC 2018 Workshop MLP-Moment. pp. 14-17. pdf", "homepage": "http://opus.nlpl.eu/Bianet.php", "license": "", "features": {"id": {"dtype": "string", "id": null, "_type": "Value"}, "translation": {"languages": ["ku", "tr"], "id": null, "_type": "Translation"}}, "post_processed": null, "supervised_keys": null, "builder_name": "bianet", "config_name": "ku_to_tr", "version": {"version_str": "1.0.0", "description": "", "major": 1, "minor": 0, "patch": 0}, "splits": {"train": {"name": "train", "num_bytes": 2086550, "num_examples": 7325, "dataset_name": "bianet"}}, "download_checksums": {"http://opus.nlpl.eu/download.php?f=Bianet/v1/moses/ku-tr.txt.zip": {"num_bytes": 725227, "checksum": "daf8ecaf9af71b1466d95703ffd335a8cc28578afb82e2d305eaaa56b1e2a12a"}}, "download_size": 725227, "post_processing_size": null, "dataset_size": 2086550, "size_in_bytes": 2811777}}
dummy/en_to_ku/1.0.0/dummy_data.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9adeb239eb6dee80f9c8742b988cc535bd4dff10a46781f928ce862642c4b4c2
3
+ size 4865
dummy/en_to_tr/1.0.0/dummy_data.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ca4f0855ca201a5b6628b77b8887e46d0b8a9d09b6163f9750a38264bbc08824
3
+ size 3430
dummy/ku_to_tr/1.0.0/dummy_data.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:69053baa503892efb4219b31f262b09b5495909e8ae495aec81120517c99a83e
3
+ size 4642