buruzaemon commited on
Commit
c10ec2b
·
1 Parent(s): cef6af0

gzipping dataset files

Browse files
amazon_reviews_multi.py CHANGED
@@ -1,17 +1,4 @@
1
  # coding=utf-8
2
- # Copyright 2020 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
  """The Multilingual Amazon Reviews Corpus"""
17
 
@@ -22,27 +9,8 @@ import datasets
22
  from datasets.exceptions import DefunctDatasetError
23
 
24
 
25
- _CITATION = """\
26
- @inproceedings{marc_reviews,
27
- title={The Multilingual Amazon Reviews Corpus},
28
- author={Keung, Phillip and Lu, Yichao and Szarvas, György and Smith, Noah A.},
29
- booktitle={Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing},
30
- year={2020}
31
- }
32
- """
33
-
34
- _LICENSE = """\
35
- By accessing the Multilingual Amazon Reviews Corpus ("Reviews Corpus"), you agree that the Reviews Corpus is an Amazon Service subject to the Amazon.com Conditions of Use (https://www.amazon.com/gp/help/customer/display.html/ref=footer_cou?ie=UTF8&nodeId=508088) and you agree to be bound by them, with the following additional conditions:
36
-
37
- In addition to the license rights granted under the Conditions of Use, Amazon or its content providers grant you a limited, non-exclusive, non-transferable, non-sublicensable, revocable license to access and use the Reviews Corpus for purposes of academic research. You may not resell, republish, or make any commercial use of the Reviews Corpus or its contents, including use of the Reviews Corpus for commercial research, such as research related to a funding or consultancy contract, internship, or other relationship in which the results are provided for a fee or delivered to a for-profit organization. You may not (a) link or associate content in the Reviews Corpus with any personal information (including Amazon customer accounts), or (b) attempt to determine the identity of the author of any content in the Reviews Corpus. If you violate any of the foregoing conditions, your license to access and use the Reviews Corpus will automatically terminate without prejudice to any of the other rights or remedies Amazon may have.
38
- """
39
-
40
  _DESCRIPTION = """\
41
- We provide an Amazon product reviews dataset for multilingual text classification. The dataset contains reviews in English, Japanese, German, French, Chinese and Spanish, collected between November 1, 2015 and November 1, 2019. Each record in the dataset contains the review text, the review title, the star rating, an anonymized reviewer ID, an anonymized product ID and the coarse-grained product category (e.g. ‘books’, ‘appliances’, etc.) The corpus is balanced across stars, so each star rating constitutes 20% of the reviews in each language.
42
-
43
- For each language, there are 200,000, 5,000 and 5,000 reviews in the training, development and test sets respectively. The maximum number of reviews per reviewer is 20 and the maximum number of reviews per product is 20. All reviews are truncated after 2,000 characters, and all reviews are at least 20 characters long.
44
-
45
- Note that the language of a review does not necessarily match the language of its marketplace (e.g. reviews from amazon.de are primarily written in German, but could also be written in English, etc.). For this reason, we applied a language detection algorithm based on the work in Bojanowski et al. (2017) to determine the language of the review text and we removed reviews that were not written in the expected language.
46
  """
47
 
48
  _LANGUAGES = {
@@ -55,8 +23,8 @@ _LANGUAGES = {
55
  }
56
  _ALL_LANGUAGES = "all_languages"
57
  _VERSION = "1.0.0"
58
- _HOMEPAGE_URL = "https://registry.opendata.aws/amazon-reviews-ml/"
59
- _DOWNLOAD_URL = "https://huggingface.co/datasets/buruzaemon/amazon_reviews_multi/resolve/main/{lang}/{split}.jsonl"
60
 
61
 
62
  class AmazonReviewsMultiConfig(datasets.BuilderConfig):
@@ -106,9 +74,9 @@ class AmazonReviewsMulti(datasets.GeneratorBasedBuilder):
106
  }
107
  ),
108
  supervised_keys=None,
109
- license=_LICENSE,
110
  homepage=_HOMEPAGE_URL,
111
- citation=_CITATION,
112
  )
113
 
114
  def _split_generators(self, dl_manager):
 
1
  # coding=utf-8
 
 
 
 
 
 
 
 
 
 
 
 
 
2
 
3
  """The Multilingual Amazon Reviews Corpus"""
4
 
 
9
  from datasets.exceptions import DefunctDatasetError
10
 
11
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
12
  _DESCRIPTION = """\
13
+ Please refer to https://huggingface.co/datasets/defunct-datasets/amazon_reviews_multi.
 
 
 
 
14
  """
15
 
16
  _LANGUAGES = {
 
23
  }
24
  _ALL_LANGUAGES = "all_languages"
25
  _VERSION = "1.0.0"
26
+ _HOMEPAGE_URL = "https://huggingface.co/datasets/defunct-datasets/amazon_reviews_multi"
27
+ _DOWNLOAD_URL = "https://huggingface.co/datasets/buruzaemon/amazon_reviews_multi/resolve/main/{lang}/{split}.jsonl.gz"
28
 
29
 
30
  class AmazonReviewsMultiConfig(datasets.BuilderConfig):
 
74
  }
75
  ),
76
  supervised_keys=None,
77
+ license=None,
78
  homepage=_HOMEPAGE_URL,
79
+ citation=None,
80
  )
81
 
82
  def _split_generators(self, dl_manager):
de/test.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
en/train.jsonl → de/test.jsonl.gz RENAMED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:b52a8ce0b27b92cff65d90b45e909f85c278e8f6b2c8cc27625d4ea295340b27
3
- size 78598589
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1e9421e790b668b28a8debf17eb88803d00cfc5e6e34bd98ab38e71bccc99fdc
3
+ size 605132
de/{train.jsonl → train.jsonl.gz} RENAMED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:86a341509433f950e53a9924295920570dade6800549cd1c892cd40396e15fbb
3
- size 86905126
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:eee75e58da48a8a738898c1c01262bf76476efd84c69ec18c93c26a9867f592e
3
+ size 24193454
de/validation.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
es/train.jsonl → de/validation.jsonl.gz RENAMED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:4ec66fded5c2efc50b676d064a4e738c807c272adbee1b18c8fe0d070fa3c9db
3
- size 74078583
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:76f3f549f1edfcf831357102c126b921e8635b89eb27bdcceca308040769df97
3
+ size 603507
en/test.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
fr/train.jsonl → en/test.jsonl.gz RENAMED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:b5d494f55f298d69dd078f9bbacff7bf9f88d7e49d742a424de304b305462e5f
3
- size 78459816
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c77950731169a57fcc74153d5e46b5ad7cbddd13c37eed5d2416975e68f54d62
3
+ size 536112
en/train.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e76ccbd8ed2e18b395de3547765f00793994d4df78d1b21a234740288dbf4f3f
3
+ size 21483640
en/validation.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
en/validation.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5cd07daa26d37b834ef1afe645ffe8acdcbf3f8eaa3f634903b1184425026cc5
3
+ size 541894
es/test.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
es/test.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a0425ac99270b196d10585d45a3e3f6b3dc2ca757967c97034e83441d8a0f683
3
+ size 476261
es/train.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:7d9985b143cb33bf77eb2ffec962efd1ee527df95389e485482e2759f83cacba
3
+ size 18957013
es/validation.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
es/validation.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:797199f8c3e740be79b437005d30b3e82d236bbfa715937f7544125f15f373ac
3
+ size 472375
fr/test.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
fr/test.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:6f325712a60be82b06024e91c244a9394e80682dff5df8d652dfef55b831d0cb
3
+ size 499603
fr/train.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:bb5d763768b3dc184dc393b568013228a2afca008c60452b1991045921ba65b4
3
+ size 19939150
fr/validation.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
fr/validation.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4df173bcd2618e6a9b27b9b3fab137f8f01008315510a82613c762bd3ecb5204
3
+ size 490165
ja/test.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
ja/test.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:47691077c049a5587130e8b63a4787f56858a71f7c1a39c0eeca9004b6ea7476
3
+ size 831154
ja/train.jsonl DELETED
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:9d75556618516e0567a3a58507e0b9b451036d4b8a183b61bbe4ed7afb95ec26
3
- size 165981099
 
 
 
 
ja/train.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c16bb439ade21a9c8eaa9548d9ec95d683a4c56055e9927780a44a5959647d6f
3
+ size 33362363
ja/validation.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
ja/validation.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:cb4eb57fe54edac8a145504dfb1790d4a51e6bfaed4c03e80808b1f935971c7a
3
+ size 822464
zh/test.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
zh/test.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:7c3401a47c839c324c974d9a4ce17df76af266da2734015f47416a43098e2444
3
+ size 588705
zh/train.jsonl DELETED
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:0ed5a23e1811357db3c1a2776c679e28fce301067c197aee82f0b2655f321ca1
3
- size 105555515
 
 
 
 
zh/train.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:624700d06eccd421ee5a6f52f3575e3e75047990d44f3a6381b7e2ddb0aebd26
3
+ size 23300464
zh/validation.jsonl DELETED
The diff for this file is too large to render. See raw diff
 
zh/validation.jsonl.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9c0c0130d2524c24a14e063e7790f73d36f601a8b4bfae24be87635f40b6f535
3
+ size 577941