albertvillanova HF staff commited on
Commit
98c3b60
1 Parent(s): 70b50eb

Convert dataset to Parquet (#3)

Browse files

- Convert dataset to Parquet (7460f81f4375cfb9b5087b5ea2c4233773262e85)
- Delete loading script (c8399e588cc0b891a4ddaf60ae5bc6327461e065)

CSRestaurants/test-00000-of-00001.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4a4b571b009305d9284b4320834ce51a76eb8695afc84435750c80caa2a09dc8
3
+ size 50096
CSRestaurants/train-00000-of-00001.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9238f3610ea85353232436aac6f45692e22fdb0ff2195f386f355df8961224c4
3
+ size 185914
CSRestaurants/validation-00000-of-00001.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c2a6a44b0b86ea8725190f1643340e21459d5f0808fbb6f4b71410cdaa7735ee
3
+ size 46784
README.md CHANGED
@@ -27,28 +27,38 @@ pretty_name: Czech Restaurant
27
  tags:
28
  - intent-to-text
29
  dataset_info:
 
30
  features:
31
- - name: dialogue_act
32
  dtype: string
33
- - name: delexicalized_dialogue_act
34
  dtype: string
35
  - name: text
36
  dtype: string
37
- - name: delexicalized_text
38
  dtype: string
39
- config_name: CSRestaurants
40
  splits:
41
  - name: train
42
- num_bytes: 654071
43
  num_examples: 3569
44
  - name: validation
45
- num_bytes: 181528
46
  num_examples: 781
47
  - name: test
48
- num_bytes: 191334
49
  num_examples: 842
50
- download_size: 1463019
51
- dataset_size: 1026933
 
 
 
 
 
 
 
 
 
 
52
  ---
53
 
54
  # Dataset Card for Czech Restaurant
 
27
  tags:
28
  - intent-to-text
29
  dataset_info:
30
+ config_name: CSRestaurants
31
  features:
32
+ - name: da
33
  dtype: string
34
+ - name: delex_da
35
  dtype: string
36
  - name: text
37
  dtype: string
38
+ - name: delex_text
39
  dtype: string
 
40
  splits:
41
  - name: train
42
+ num_bytes: 654055
43
  num_examples: 3569
44
  - name: validation
45
+ num_bytes: 181512
46
  num_examples: 781
47
  - name: test
48
+ num_bytes: 191318
49
  num_examples: 842
50
+ download_size: 282794
51
+ dataset_size: 1026885
52
+ configs:
53
+ - config_name: CSRestaurants
54
+ data_files:
55
+ - split: train
56
+ path: CSRestaurants/train-*
57
+ - split: validation
58
+ path: CSRestaurants/validation-*
59
+ - split: test
60
+ path: CSRestaurants/test-*
61
+ default: true
62
  ---
63
 
64
  # Dataset Card for Czech Restaurant
cs_restaurants.py DELETED
@@ -1,102 +0,0 @@
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
- """Czech restaurant information dataset for NLG"""
16
-
17
-
18
- import json
19
-
20
- import datasets
21
-
22
-
23
- # Find for instance the citation on arxiv or on the dataset repo/website
24
- _CITATION = """\
25
- @article{DBLP:journals/corr/abs-1910-05298,
26
- author = {Ondrej Dusek and
27
- Filip Jurcicek},
28
- title = {Neural Generation for Czech: Data and Baselines},
29
- journal = {CoRR},
30
- volume = {abs/1910.05298},
31
- year = {2019},
32
- url = {http://arxiv.org/abs/1910.05298},
33
- archivePrefix = {arXiv},
34
- eprint = {1910.05298},
35
- timestamp = {Wed, 16 Oct 2019 16:25:53 +0200},
36
- biburl = {https://dblp.org/rec/journals/corr/abs-1910-05298.bib},
37
- bibsource = {dblp computer science bibliography, https://dblp.org}
38
- }
39
- """
40
-
41
- _DESCRIPTION = """\
42
- This is a dataset for NLG in task-oriented spoken dialogue systems with Czech as the target language. It originated as
43
- a translation of the English San Francisco Restaurants dataset by Wen et al. (2015).
44
- """
45
-
46
- _LICENSE = "Creative Commons 4.0 BY-SA"
47
-
48
- _URLs = {
49
- "CSRestaurants": "https://raw.githubusercontent.com/UFAL-DSG/cs_restaurant_dataset/master/",
50
- }
51
-
52
-
53
- class CSRestaurants(datasets.GeneratorBasedBuilder):
54
- """Czech restaurant information dataset for NLG"""
55
-
56
- VERSION = datasets.Version("1.0.0")
57
- BUILDER_CONFIGS = [datasets.BuilderConfig(name="CSRestaurants", description="NLG data for Czech")]
58
- DEFAULT_CONFIG_NAME = "CSRestaurants"
59
-
60
- def _info(self):
61
- features = datasets.Features(
62
- {
63
- "da": datasets.Value("string"),
64
- "delex_da": datasets.Value("string"),
65
- "text": datasets.Value("string"),
66
- "delex_text": datasets.Value("string"),
67
- }
68
- )
69
- return datasets.DatasetInfo(
70
- description=_DESCRIPTION,
71
- features=features,
72
- supervised_keys=None,
73
- homepage="https://github.com/UFAL-DSG/cs_restaurant_dataset",
74
- license=_LICENSE,
75
- citation=_CITATION,
76
- )
77
-
78
- def _split_generators(self, dl_manager):
79
- """Returns SplitGenerators."""
80
- master_url = _URLs[self.config.name]
81
- train_path = dl_manager.download_and_extract(master_url + "train.json")
82
- valid_path = dl_manager.download_and_extract(master_url + "devel.json")
83
- test_path = dl_manager.download_and_extract(master_url + "test.json")
84
-
85
- return [
86
- datasets.SplitGenerator(name=datasets.Split.TRAIN, gen_kwargs={"filepath": train_path}),
87
- datasets.SplitGenerator(name=datasets.Split.VALIDATION, gen_kwargs={"filepath": valid_path}),
88
- datasets.SplitGenerator(name=datasets.Split.TEST, gen_kwargs={"filepath": test_path}),
89
- ]
90
-
91
- def _generate_examples(self, filepath):
92
- """Yields examples."""
93
-
94
- with open(filepath, encoding="utf8") as f:
95
- data = json.load(f)
96
- for id_, instance in enumerate(data):
97
- yield id_, {
98
- "da": instance["da"],
99
- "delex_da": instance["delex_da"],
100
- "text": instance["text"],
101
- "delex_text": instance["delex_text"],
102
- }