hugosousa commited on
Commit
7d5545c
•
1 Parent(s): dbc8b37

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +216 -0
README.md CHANGED
@@ -98,3 +98,219 @@ configs:
98
  - split: train
99
  path: web/train-*
100
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
98
  - split: train
99
  path: web/train-*
100
  ---
101
+
102
+
103
+ # PtBrVId
104
+
105
+ The developed corpus is a composition of pre-existing datasets initially created for other NLP tasks that provide permissive licenses. The first release of the corpus is available on [Huggingface](https://huggingface.co/datasets/Random-Mary-Smith/port_data_random).
106
+
107
+ #### Data Sources
108
+
109
+ The corpus consists of the following datasets:
110
+
111
+ <p align="center">
112
+ <table>
113
+ <tr>
114
+ <th>Domain</th>
115
+ <th>Variety</th>
116
+ <th>Dataset</th>
117
+ <th>Original Task</th>
118
+ <th># Docs</th>
119
+ <th>License</th>
120
+ <th>Silver Labeled</th>
121
+ </tr>
122
+ <tr>
123
+ <td rowspan="5">Literature</td>
124
+ <td rowspan="3">PT-PT</td>
125
+ <td><a href="http://arquivopessoa.net/">Arquivo Pessoa</a></td>
126
+ <td>-</td>
127
+ <td>~4k</td>
128
+ <td>CC</td>
129
+ <td>✔</td>
130
+ </tr>
131
+ <tr>
132
+ <td><a href="https://www.gutenberg.org/ebooks/bookshelf/99">Gutenberg Project</a></td>
133
+ <td>-</td>
134
+ <td>6</td>
135
+ <td>CC</td>
136
+ <td>✔</td>
137
+ </tr>
138
+ <tr>
139
+ <td><a href="https://www.clul.ulisboa.pt/recurso/corpus-de-textos-literarios">LT-Corpus</a></td>
140
+ <td>-</td>
141
+ <td>56</td>
142
+ <td>ELRA END USER</td>
143
+ <td>✘</td>
144
+ </tr>
145
+ <tr>
146
+ <td rowspan="2">PT-BR</td>
147
+ <td><a href="https://www.kaggle.com/datasets/rtatman/brazilian-portuguese-literature-corpus">Brazilian Literature</a></td>
148
+ <td>Author Identification</td>
149
+ <td>81</td>
150
+ <td>CC</td>
151
+ <td>✘</td>
152
+ </tr>
153
+ <tr>
154
+ <td>LT-Corpus</td>
155
+ <td>-</td>
156
+ <td>8</td>
157
+ <td>ELRA END USER</td>
158
+ <td>✘</td>
159
+ </tr>
160
+ <tr>
161
+ <td rowspan="2">Politics</td>
162
+ <td>PT-PT</td>
163
+ <td><a href="http://www.statmt.org/europarl/">Koehn (2005) Europarl</a></td>
164
+ <td>Machine Translation</td>
165
+ <td>~10k</td>
166
+ <td>CC</td>
167
+ <td>✘</td>
168
+ </tr>
169
+ <tr>
170
+ <td>PT-BR</td>
171
+ <td>Brazilian Senate Speeches</td>
172
+ <td>-</td>
173
+ <td>~5k</td>
174
+ <td>CC</td>
175
+ <td>✔</td>
176
+ </tr>
177
+ <tr>
178
+ <td rowspan="2">Journalistic</td>
179
+ <td>PT-PT</td>
180
+ <td><a href="https://www.linguateca.pt/CETEMPublico/">CETEM Público</a></td>
181
+ <td>-</td>
182
+ <td>1M</td>
183
+ <td>CC</td>
184
+ <td>✘</td>
185
+ </tr>
186
+ <tr>
187
+ <td>PT-BR</td>
188
+ <td><a href="https://www.linguateca.pt/CETEMFolha/">CETEM Folha</a></td>
189
+ <td>-</td>
190
+ <td>272k</td>
191
+ <td>CC</td>
192
+ <td>✘</td>
193
+ </tr>
194
+ <tr>
195
+ <td rowspan="3">Social Media</td>
196
+ <td>PT-PT</td>
197
+ <td><a href="https://www.aclweb.org/anthology/2021.ranlp-1.37/">Ramalho (2021)</a></td>
198
+ <td>Fake News Detection</td>
199
+ <td>2M</td>
200
+ <td>MIT</td>
201
+ <td>✔</td>
202
+ </tr>
203
+ <tr>
204
+ <td rowspan="2">PT-BR</td>
205
+ <td><a href="https://www.aclweb.org/anthology/2022.lrec-1.322/">Vargas (2022)</a></td>
206
+ <td>Hate Speech Detection</td>
207
+ <td>5k</td>
208
+ <td>CC-BY-NC-4.0</td>
209
+ <td>✘</td>
210
+ </tr>
211
+ <tr>
212
+ <td><a href="https://www.aclweb.org/anthology/2021.wlp-1.72/">Cunha (2021)</a></td>
213
+ <td>Fake News Detection</td>
214
+ <td>2k</td>
215
+ <td>GPL-3.0 license</td>
216
+ <td>✔</td>
217
+ </tr>
218
+ <tr>
219
+ <td>Web</td>
220
+ <td>BOTH</td>
221
+ <td><a href="https://www.aclweb.org/anthology/2020.lrec-1.451/">Ortiz-Suarez (2020)</a></td>
222
+ <td>-</td>
223
+ <td>10k</td>
224
+ <td>CC</td>
225
+ <td>✔</td>
226
+ </tr>
227
+ </table>
228
+ </p>
229
+
230
+ <p align="center">
231
+ <em>Table 1: Data Sources</em>
232
+ </p>
233
+
234
+ #####
235
+
236
+ Note: The dataset "Brazilian Senate Speeches" was created by the authors of this paper, using web crawling of the Brazilian Senate website and is available in the Huggingface repository.
237
+
238
+ #### Annotation Schema & Data Preprocessing Pipeline
239
+
240
+ We leveraged our knowledge of the Portuguese language to identify data sources that guaranteed mono-variety documents. However, this first release lacks any kind of supervision, so we cannot guarantee that all documents are mono-variety. In the future, we plan to release a second version of the corpus with a more robust annotation schema, combining automatic and manual annotation.
241
+
242
+ To improve the quality of the corpus, we applied a preprocessing pipeline to all documents. The pipeline consists of the following steps:
243
+
244
+ 1. Remove all NaN values.
245
+ 2. Remove all empty documents.
246
+ 3. Remove all duplicated documents.
247
+ 4. Apply the [clean_text](https://github.com/jfilter/clean-text) library to remove non-relevant information for language identification from the documents.
248
+ 5. Remove all documents with a length significantly more than two standard deviations from the mean length of the documents in the corpus.
249
+
250
+ The pipeline is illustrated in Figure 1.
251
+
252
+ <p align="center">
253
+ <img src="assets/pipeline_lid.jpg" alt="Image Description">
254
+ </p>
255
+ <p align="center">
256
+ <em>Figure 1: Data Pre-Processing Pipeline</em>
257
+ </p>
258
+
259
+ #### Class Distribution
260
+
261
+ The class distribution of the corpus is presented in Table 2. The corpus is highly imbalanced, with the majority of the documents being from the journalistic domain. In the future, we plan to release a second version of the corpus with a more balanced distribution across the six domains. Depending on the imbalance of the textual domain, we used different strategies to perform train-validation-test splits. For the heavily imbalanced domains, we ensured a minimum of 100 documents for validation and 400 for testing. In the other domains, we applied a stratified split.
262
+
263
+ <p align="center">
264
+ <table>
265
+ <tr>
266
+ <th>Domain</th>
267
+ <th># PT-PT</th>
268
+ <th># PT-BR</th>
269
+ <th>Stratified</th>
270
+ </tr>
271
+ <tr>
272
+ <td>Politics</td>
273
+ <td>6500</td>
274
+ <td>4894</td>
275
+ <td>&#10003;</td>
276
+ </tr>
277
+ <tr>
278
+ <td>Web</td>
279
+ <td>7960</td>
280
+ <td>21592</td>
281
+ <td>&#10003;</td>
282
+ </tr>
283
+ <tr>
284
+ <td>Literature</td>
285
+ <td>18282</td>
286
+ <td>2772</td>
287
+ <td>&#10003;</td>
288
+ </tr>
289
+ <tr>
290
+ <td>Law</td>
291
+ <td>392839</td>
292
+ <td>5766</td>
293
+ <td>&#10005;</td>
294
+ </tr>
295
+ <tr>
296
+ <td>Journalistic</td>
297
+ <td>1494494</td>
298
+ <td>354180</td>
299
+ <td>&#10003;</td>
300
+ </tr>
301
+ <tr>
302
+ <td>Social Media</td>
303
+ <td>2013951</td>
304
+ <td>6222</td>
305
+ <td>&#10005;</td>
306
+ </tr>
307
+ </table>
308
+ </p>
309
+
310
+ <p align="center">
311
+ <em>Table 2: Class Balance across the six textual domains in both varieties of Portuguese.</em>
312
+ </p>
313
+
314
+ #### Future Releases & How to Contribute
315
+
316
+ We plan to release a second version of this corpus considering more textual domains and extending the scope to other Portuguese varieties. If you want to contribute to this corpus, please [contact us]().