parquet-converter commited on
Commit
6c902bb
1 Parent(s): 6994192

Update parquet files

Browse files
.gitattributes DELETED
@@ -1,27 +0,0 @@
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 DELETED
@@ -1,237 +0,0 @@
1
- ---
2
- annotations_creators:
3
- - expert-generated
4
- - crowdsourced
5
- language_creators:
6
- - found
7
- language:
8
- - en
9
- license:
10
- - unknown
11
- multilinguality:
12
- - monolingual
13
- size_categories:
14
- - 10K<n<100K
15
- source_datasets:
16
- - original
17
- task_categories:
18
- - text-classification
19
- task_ids: []
20
- paperswithcode_id: hate-speech-and-offensive-language
21
- pretty_name: Hate Speech and Offensive Language
22
- train-eval-index:
23
- - config: default
24
- task: text-classification
25
- task_id: multi_class_classification
26
- splits:
27
- train_split: train
28
- col_mapping:
29
- tweet: text
30
- label: target
31
- metrics:
32
- - type: accuracy
33
- name: Accuracy
34
- - type: f1
35
- name: F1 macro
36
- args:
37
- average: macro
38
- - type: f1
39
- name: F1 micro
40
- args:
41
- average: micro
42
- - type: f1
43
- name: F1 weighted
44
- args:
45
- average: weighted
46
- - type: precision
47
- name: Precision macro
48
- args:
49
- average: macro
50
- - type: precision
51
- name: Precision micro
52
- args:
53
- average: micro
54
- - type: precision
55
- name: Precision weighted
56
- args:
57
- average: weighted
58
- - type: recall
59
- name: Recall macro
60
- args:
61
- average: macro
62
- - type: recall
63
- name: Recall micro
64
- args:
65
- average: micro
66
- - type: recall
67
- name: Recall weighted
68
- args:
69
- average: weighted
70
- tags:
71
- - hate-speech-detection
72
- dataset_info:
73
- features:
74
- - name: count
75
- dtype: int64
76
- - name: hate_speech_count
77
- dtype: int64
78
- - name: offensive_language_count
79
- dtype: int64
80
- - name: neither_count
81
- dtype: int64
82
- - name: class
83
- dtype:
84
- class_label:
85
- names:
86
- 0: hate speech
87
- 1: offensive language
88
- 2: neither
89
- - name: tweet
90
- dtype: string
91
- splits:
92
- - name: train
93
- num_bytes: 3207826
94
- num_examples: 24783
95
- download_size: 2546446
96
- dataset_size: 3207826
97
- ---
98
-
99
- # Dataset Card for [Dataset Name]
100
-
101
- ## Table of Contents
102
- - [Dataset Description](#dataset-description)
103
- - [Dataset Summary](#dataset-summary)
104
- - [Supported Tasks and Leaderboards](#supported-tasks-and-leaderboards)
105
- - [Languages](#languages)
106
- - [Dataset Structure](#dataset-structure)
107
- - [Data Instances](#data-instances)
108
- - [Data Fields](#data-fields)
109
- - [Data Splits](#data-splits)
110
- - [Dataset Creation](#dataset-creation)
111
- - [Curation Rationale](#curation-rationale)
112
- - [Source Data](#source-data)
113
- - [Annotations](#annotations)
114
- - [Personal and Sensitive Information](#personal-and-sensitive-information)
115
- - [Considerations for Using the Data](#considerations-for-using-the-data)
116
- - [Social Impact of Dataset](#social-impact-of-dataset)
117
- - [Discussion of Biases](#discussion-of-biases)
118
- - [Other Known Limitations](#other-known-limitations)
119
- - [Additional Information](#additional-information)
120
- - [Dataset Curators](#dataset-curators)
121
- - [Licensing Information](#licensing-information)
122
- - [Citation Information](#citation-information)
123
- - [Contributions](#contributions)
124
-
125
- ## Dataset Description
126
-
127
- - **Homepage:** https://github.com/t-davidson/hate-speech-and-offensive-language
128
- - **Repository:** https://github.com/t-davidson/hate-speech-and-offensive-language
129
- - **Paper:** https://arxiv.org/abs/1703.04009
130
- - **Leaderboard:**
131
- - **Point of Contact:** https://docs.google.com/forms/d/e/1FAIpQLSdrPNlfVBlqxun2tivzAtsZaOoPC5YYMocn-xscCgeRakLXHg/viewform?usp=pp_url&entry.1506871634&entry.147453066&entry.1390333885&entry.516829772
132
-
133
- ### Dataset Summary
134
-
135
- An annotated dataset for hate speech and offensive language detection on tweets.
136
-
137
- ### Supported Tasks and Leaderboards
138
-
139
- [More Information Needed]
140
-
141
- ### Languages
142
- English (`en`)
143
-
144
- ## Dataset Structure
145
-
146
- ### Data Instances
147
- ```
148
- {
149
- "count": 3,
150
- "hate_speech_annotation": 0,
151
- "offensive_language_annotation": 0,
152
- "neither_annotation": 3,
153
- "label": 2, # "neither"
154
- "tweet": "!!! RT @mayasolovely: As a woman you shouldn't complain about cleaning up your house. &amp; as a man you should always take the trash out...")
155
- }
156
- ```
157
-
158
- ### Data Fields
159
- ```
160
- count: (Integer) number of users who coded each tweet (min is 3, sometimes more users coded a tweet when judgments were determined to be unreliable,
161
- hate_speech_annotation: (Integer) number of users who judged the tweet to be hate speech,
162
- offensive_language_annotation: (Integer) number of users who judged the tweet to be offensive,
163
- neither_annotation: (Integer) number of users who judged the tweet to be neither offensive nor non-offensive,
164
- label: (Class Label) class label for majority of CF users (0: 'hate-speech', 1: 'offensive-language' or 2: 'neither'),
165
- tweet: (string)
166
- ```
167
-
168
- ### Data Splits
169
- This dataset is not splitted, only the train split is available.
170
-
171
- ## Dataset Creation
172
-
173
- ### Curation Rationale
174
-
175
- [More Information Needed]
176
-
177
- ### Source Data
178
-
179
- #### Initial Data Collection and Normalization
180
-
181
- [More Information Needed]
182
-
183
- #### Who are the source language producers?
184
-
185
- [More Information Needed]
186
-
187
- ### Annotations
188
-
189
- #### Annotation process
190
-
191
- [More Information Needed]
192
-
193
- #### Who are the annotators?
194
-
195
- [More Information Needed]
196
-
197
- ### Personal and Sensitive Information
198
- Usernames are not anonymized in the dataset.
199
-
200
-
201
- ## Considerations for Using the Data
202
-
203
- ### Social Impact of Dataset
204
-
205
- [More Information Needed]
206
-
207
- ### Discussion of Biases
208
-
209
- [More Information Needed]
210
-
211
- ### Other Known Limitations
212
-
213
- [More Information Needed]
214
-
215
- ## Additional Information
216
-
217
- ### Dataset Curators
218
-
219
- [More Information Needed]
220
-
221
- ### Licensing Information
222
- MIT License
223
-
224
- ### Citation Information
225
- @inproceedings{hateoffensive,
226
- title = {Automated Hate Speech Detection and the Problem of Offensive Language},
227
- author = {Davidson, Thomas and Warmsley, Dana and Macy, Michael and Weber, Ingmar},
228
- booktitle = {Proceedings of the 11th International AAAI Conference on Web and Social Media},
229
- series = {ICWSM '17},
230
- year = {2017},
231
- location = {Montreal, Canada},
232
- pages = {512-515}
233
- }
234
-
235
- ### Contributions
236
-
237
- Thanks to [@hugoabonizio](https://github.com/hugoabonizio) for adding this dataset.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
dataset_infos.json DELETED
@@ -1 +0,0 @@
1
- {"default": {"description": "An annotated dataset for hate speech and offensive language detection on tweets.\n", "citation": "@inproceedings{hateoffensive,\ntitle = {Automated Hate Speech Detection and the Problem of Offensive Language},\nauthor = {Davidson, Thomas and Warmsley, Dana and Macy, Michael and Weber, Ingmar},\nbooktitle = {Proceedings of the 11th International AAAI Conference on Web and Social Media},\nseries = {ICWSM '17},\nyear = {2017},\nlocation = {Montreal, Canada},\npages = {512-515}\n}\n", "homepage": "https://github.com/t-davidson/hate-speech-and-offensive-language", "license": "MIT", "features": {"count": {"dtype": "int64", "id": null, "_type": "Value"}, "hate_speech_count": {"dtype": "int64", "id": null, "_type": "Value"}, "offensive_language_count": {"dtype": "int64", "id": null, "_type": "Value"}, "neither_count": {"dtype": "int64", "id": null, "_type": "Value"}, "class": {"num_classes": 3, "names": ["hate speech", "offensive language", "neither"], "names_file": null, "id": null, "_type": "ClassLabel"}, "tweet": {"dtype": "string", "id": null, "_type": "Value"}}, "post_processed": null, "supervised_keys": {"input": "tweet", "output": "class"}, "builder_name": "hate_speech_offensive", "config_name": "default", "version": {"version_str": "1.0.0", "description": null, "major": 1, "minor": 0, "patch": 0}, "splits": {"train": {"name": "train", "num_bytes": 3207826, "num_examples": 24783, "dataset_name": "hate_speech_offensive"}}, "download_checksums": {"https://raw.githubusercontent.com/t-davidson/hate-speech-and-offensive-language/master/data/labeled_data.csv": {"num_bytes": 2546446, "checksum": "fcb8bc7c68120ae4af04a5b9acd58585513ede11e1548ebf36a5c2040b6f6281"}}, "download_size": 2546446, "post_processing_size": null, "dataset_size": 3207826, "size_in_bytes": 5754272}}
 
 
default/hate_speech_offensive-train.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:10aa71180e9afd3e4a3b8102a60b3912383d2d7d6920e3e6a0bce988b10ce045
3
+ size 1627671
hate_speech_offensive.py DELETED
@@ -1,105 +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
- """An annotated dataset for hate speech and offensive language detection on tweets."""
16
-
17
-
18
- import csv
19
-
20
- import datasets
21
-
22
-
23
- _CITATION = """\
24
- @inproceedings{hateoffensive,
25
- title = {Automated Hate Speech Detection and the Problem of Offensive Language},
26
- author = {Davidson, Thomas and Warmsley, Dana and Macy, Michael and Weber, Ingmar},
27
- booktitle = {Proceedings of the 11th International AAAI Conference on Web and Social Media},
28
- series = {ICWSM '17},
29
- year = {2017},
30
- location = {Montreal, Canada},
31
- pages = {512-515}
32
- }
33
- """
34
-
35
- _DESCRIPTION = """\
36
- An annotated dataset for hate speech and offensive language detection on tweets.
37
- """
38
-
39
- _HOMEPAGE = "https://github.com/t-davidson/hate-speech-and-offensive-language"
40
-
41
- _LICENSE = "MIT"
42
-
43
- _URL = "https://raw.githubusercontent.com/t-davidson/hate-speech-and-offensive-language/master/data/labeled_data.csv"
44
-
45
- _CLASS_MAP = {
46
- "0": "hate speech",
47
- "1": "offensive language",
48
- "2": "neither",
49
- }
50
-
51
-
52
- class HateSpeechOffensive(datasets.GeneratorBasedBuilder):
53
- """An annotated dataset for hate speech and offensive language detection on tweets."""
54
-
55
- VERSION = datasets.Version("1.0.0")
56
-
57
- def _info(self):
58
- return datasets.DatasetInfo(
59
- description=_DESCRIPTION,
60
- features=datasets.Features(
61
- {
62
- "count": datasets.Value("int64"),
63
- "hate_speech_count": datasets.Value("int64"),
64
- "offensive_language_count": datasets.Value("int64"),
65
- "neither_count": datasets.Value("int64"),
66
- "class": datasets.ClassLabel(names=["hate speech", "offensive language", "neither"]),
67
- "tweet": datasets.Value("string"),
68
- }
69
- ),
70
- supervised_keys=("tweet", "class"),
71
- homepage=_HOMEPAGE,
72
- license=_LICENSE,
73
- citation=_CITATION,
74
- )
75
-
76
- def _split_generators(self, dl_manager):
77
- """Returns SplitGenerators."""
78
-
79
- data_file = dl_manager.download_and_extract(_URL)
80
- return [
81
- datasets.SplitGenerator(
82
- name=datasets.Split.TRAIN,
83
- gen_kwargs={
84
- "filepath": data_file,
85
- },
86
- ),
87
- ]
88
-
89
- def _generate_examples(self, filepath):
90
- """Yields examples."""
91
-
92
- with open(filepath, encoding="utf-8") as f:
93
- reader = csv.reader(f)
94
- for id_, row in enumerate(reader):
95
- if id_ == 0:
96
- continue
97
-
98
- yield id_, {
99
- "count": row[1],
100
- "hate_speech_count": row[2],
101
- "offensive_language_count": row[3],
102
- "neither_count": row[4],
103
- "class": _CLASS_MAP[row[5]],
104
- "tweet": row[6],
105
- }