system HF staff commited on
Commit
cb72bef
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,137 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ annotations_creators:
3
+ - expert-generated
4
+ language_creators:
5
+ - found
6
+ languages:
7
+ - pt
8
+ licenses:
9
+ - unknown
10
+ multilinguality:
11
+ - monolingual
12
+ size_categories:
13
+ - n<1K
14
+ source_datasets:
15
+ - original
16
+ task_categories:
17
+ - text-classification
18
+ task_ids:
19
+ - text-classification-other-hate-speech-detection
20
+ ---
21
+
22
+ # Dataset Card for [Dataset Name]
23
+
24
+ ## Table of Contents
25
+ - [Dataset Description](#dataset-description)
26
+ - [Dataset Summary](#dataset-summary)
27
+ - [Supported Tasks](#supported-tasks-and-leaderboards)
28
+ - [Languages](#languages)
29
+ - [Dataset Structure](#dataset-structure)
30
+ - [Data Instances](#data-instances)
31
+ - [Data Fields](#data-instances)
32
+ - [Data Splits](#data-instances)
33
+ - [Dataset Creation](#dataset-creation)
34
+ - [Curation Rationale](#curation-rationale)
35
+ - [Source Data](#source-data)
36
+ - [Annotations](#annotations)
37
+ - [Personal and Sensitive Information](#personal-and-sensitive-information)
38
+ - [Considerations for Using the Data](#considerations-for-using-the-data)
39
+ - [Social Impact of Dataset](#social-impact-of-dataset)
40
+ - [Discussion of Biases](#discussion-of-biases)
41
+ - [Other Known Limitations](#other-known-limitations)
42
+ - [Additional Information](#additional-information)
43
+ - [Dataset Curators](#dataset-curators)
44
+ - [Licensing Information](#licensing-information)
45
+ - [Citation Information](#citation-information)
46
+
47
+ ## Dataset Description
48
+
49
+ - **Homepage:** http://www.inf.ufrgs.br/~rppelle/hatedetector/
50
+ - **Repository:** https://github.com/rogersdepelle/OffComBR
51
+ - **Paper:** https://sol.sbc.org.br/index.php/brasnam/article/view/3260/3222
52
+ - **Leaderboard:**
53
+ - **Point of Contact:**
54
+
55
+ ### Dataset Summary
56
+
57
+ OffComBR: an annotated dataset containing for hate speech detection in Portuguese composed of news comments on the Brazilian Web.
58
+
59
+ ### Supported Tasks and Leaderboards
60
+
61
+ [More Information Needed]
62
+
63
+ ### Languages
64
+
65
+ [More Information Needed]
66
+
67
+ ## Dataset Structure
68
+
69
+ ### Data Instances
70
+
71
+ [More Information Needed]
72
+
73
+ ### Data Fields
74
+
75
+ [More Information Needed]
76
+
77
+ ### Data Splits
78
+
79
+ [More Information Needed]
80
+
81
+ ## Dataset Creation
82
+
83
+ ### Curation Rationale
84
+
85
+ [More Information Needed]
86
+
87
+ ### Source Data
88
+
89
+ #### Initial Data Collection and Normalization
90
+
91
+ [More Information Needed]
92
+
93
+ #### Who are the source language producers?
94
+
95
+ [More Information Needed]
96
+
97
+ ### Annotations
98
+
99
+ #### Annotation process
100
+
101
+ [More Information Needed]
102
+
103
+ #### Who are the annotators?
104
+
105
+ [More Information Needed]
106
+
107
+ ### Personal and Sensitive Information
108
+
109
+ [More Information Needed]
110
+
111
+ ## Considerations for Using the Data
112
+
113
+ ### Social Impact of Dataset
114
+
115
+ [More Information Needed]
116
+
117
+ ### Discussion of Biases
118
+
119
+ [More Information Needed]
120
+
121
+ ### Other Known Limitations
122
+
123
+ [More Information Needed]
124
+
125
+ ## Additional Information
126
+
127
+ ### Dataset Curators
128
+
129
+ [More Information Needed]
130
+
131
+ ### Licensing Information
132
+
133
+ [More Information Needed]
134
+
135
+ ### Citation Information
136
+
137
+ [More Information Needed]
dataset_infos.json ADDED
@@ -0,0 +1 @@
 
1
+ {"offcombr-2": {"description": "OffComBR: an annotated dataset containing for hate speech detection in Portuguese composed of news comments on the Brazilian Web.\n", "citation": "@article{Pelle2017,\ntitle={Offensive Comments in the Brazilian Web: a dataset and baseline results},\nauthor={Rogers P. de Pelle and Viviane P. Moreira},\nbooktitle={6th Brazilian Workshop on Social Network Analysis and Mining (BraSNAM)},\nyear={2017},\n}\n", "homepage": "http://www.inf.ufrgs.br/~rppelle/hatedetector/", "license": "Unknown", "features": {"label": {"num_classes": 2, "names": ["no", "yes"], "names_file": null, "id": null, "_type": "ClassLabel"}, "text": {"dtype": "string", "id": null, "_type": "Value"}}, "post_processed": null, "supervised_keys": {"input": "label", "output": "text"}, "builder_name": "offcombr", "config_name": "offcombr-2", "version": {"version_str": "1.0.0", "description": null, "major": 1, "minor": 0, "patch": 0}, "splits": {"train": {"name": "train", "num_bytes": 105703, "num_examples": 1250, "dataset_name": "offcombr"}}, "download_checksums": {"https://github.com/rogersdepelle/OffComBR/raw/master/OffComBR2.arff": {"num_bytes": 99956, "checksum": "2e699a42c91a117f62906bc6f01d661874098a1460eb95e4d069b2b73e155cb8"}}, "download_size": 99956, "post_processing_size": null, "dataset_size": 105703, "size_in_bytes": 205659}, "offcombr-3": {"description": "OffComBR: an annotated dataset containing for hate speech detection in Portuguese composed of news comments on the Brazilian Web.\n", "citation": "@article{Pelle2017,\ntitle={Offensive Comments in the Brazilian Web: a dataset and baseline results},\nauthor={Rogers P. de Pelle and Viviane P. Moreira},\nbooktitle={6th Brazilian Workshop on Social Network Analysis and Mining (BraSNAM)},\nyear={2017},\n}\n", "homepage": "http://www.inf.ufrgs.br/~rppelle/hatedetector/", "license": "Unknown", "features": {"label": {"num_classes": 2, "names": ["no", "yes"], "names_file": null, "id": null, "_type": "ClassLabel"}, "text": {"dtype": "string", "id": null, "_type": "Value"}}, "post_processed": null, "supervised_keys": {"input": "label", "output": "text"}, "builder_name": "offcombr", "config_name": "offcombr-3", "version": {"version_str": "1.0.0", "description": null, "major": 1, "minor": 0, "patch": 0}, "splits": {"train": {"name": "train", "num_bytes": 90094, "num_examples": 1033, "dataset_name": "offcombr"}}, "download_checksums": {"https://github.com/rogersdepelle/OffComBR/raw/master/OffComBR3.arff": {"num_bytes": 85215, "checksum": "a69597eca1ebbf1c438e4a8534361fa63e4e5bf9c5caca5b0ee9b7b7e8521a1d"}}, "download_size": 85215, "post_processing_size": null, "dataset_size": 90094, "size_in_bytes": 175309}}
dummy/offcombr-2/1.0.0/dummy_data.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5860a976714f6daee31447b9abb489f32d57663799a0e84f29e68c9ca263ce27
3
+ size 498
dummy/offcombr-3/1.0.0/dummy_data.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:22eaedf90ee13656f1678b233338e73c5301c0e7cad268175bcc1f6310d2fe90
3
+ size 498
offcombr.py ADDED
@@ -0,0 +1,105 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
+ """OffComBR: an annotated dataset containing for hate speech detection in Portuguese composed of news comments on the Brazilian Web."""
16
+
17
+ from __future__ import absolute_import, division, print_function
18
+
19
+ import datasets
20
+
21
+
22
+ _CITATION = """\
23
+ @article{Pelle2017,
24
+ title={Offensive Comments in the Brazilian Web: a dataset and baseline results},
25
+ author={Rogers P. de Pelle and Viviane P. Moreira},
26
+ booktitle={6th Brazilian Workshop on Social Network Analysis and Mining (BraSNAM)},
27
+ year={2017},
28
+ }
29
+ """
30
+
31
+ _DESCRIPTION = """\
32
+ OffComBR: an annotated dataset containing for hate speech detection in Portuguese composed of news comments on the Brazilian Web.
33
+ """
34
+
35
+ _HOMEPAGE = "http://www.inf.ufrgs.br/~rppelle/hatedetector/"
36
+
37
+ _LICENSE = "Unknown"
38
+
39
+ _URLs = {
40
+ "offcombr-2": "https://github.com/rogersdepelle/OffComBR/raw/master/OffComBR2.arff",
41
+ "offcombr-3": "https://github.com/rogersdepelle/OffComBR/raw/master/OffComBR3.arff",
42
+ }
43
+
44
+
45
+ class Offcombr(datasets.GeneratorBasedBuilder):
46
+ """OffComBR: an annotated dataset containing for hate speech detection in Portuguese composed of news comments on the Brazilian Web."""
47
+
48
+ VERSION = datasets.Version("1.0.0")
49
+
50
+ BUILDER_CONFIGS = [
51
+ datasets.BuilderConfig(
52
+ name="offcombr-2",
53
+ version=VERSION,
54
+ description="OffComBR-2 contains samples with Fleiss Kappa measure between annotators of 0.71",
55
+ ),
56
+ datasets.BuilderConfig(
57
+ name="offcombr-3",
58
+ version=VERSION,
59
+ description="OffComBR-3 only contains instances for which the class has been agreed by all three judges",
60
+ ),
61
+ ]
62
+
63
+ def _info(self):
64
+ return datasets.DatasetInfo(
65
+ description=_DESCRIPTION,
66
+ features=datasets.Features(
67
+ {
68
+ "label": datasets.ClassLabel(names=["no", "yes"]),
69
+ "text": datasets.Value("string"),
70
+ }
71
+ ),
72
+ supervised_keys=("label", "text"),
73
+ homepage=_HOMEPAGE,
74
+ license=_LICENSE,
75
+ citation=_CITATION,
76
+ )
77
+
78
+ def _split_generators(self, dl_manager):
79
+ """Returns SplitGenerators."""
80
+
81
+ urls = _URLs[self.config.name]
82
+ data_file = dl_manager.download_and_extract(urls)
83
+ return [
84
+ datasets.SplitGenerator(
85
+ name=datasets.Split.TRAIN,
86
+ gen_kwargs={
87
+ "filepath": data_file,
88
+ },
89
+ ),
90
+ ]
91
+
92
+ def _generate_examples(self, filepath):
93
+ """ Yields examples. """
94
+
95
+ with open(filepath, encoding="utf-8") as f:
96
+ for id_, row in enumerate(f):
97
+ if id_ < 8:
98
+ continue
99
+
100
+ label, *text = row.split(",")
101
+ text = "".join(text)
102
+ yield id_, {
103
+ "label": label,
104
+ "text": text.strip().strip("'"),
105
+ }