mqa / README.md
maximedb's picture
Update README.md
4b1f1e6
|
raw
history blame
No virus
6.71 kB
metadata
annotations_creators:
  - no-annotation
language_creators:
  - other
languages:
  - ca
  - en
  - de
  - es
  - fr
  - ru
  - ja
  - it
  - zh
  - pt
  - nl
  - tr
  - pl
  - vi
  - ar
  - id
  - uk
  - ro
  - 'no'
  - th
  - sv
  - el
  - fi
  - he
  - da
  - cs
  - ko
  - fa
  - hi
  - hu
  - sk
  - lt
  - et
  - hr
  - is
  - lv
  - ms
  - bg
  - sr
  - ca
licenses:
  - cc0-1.0
multilinguality:
  - multilingual
pretty_name: MQA - a Multilingual FAQ and CQA Dataset
size_categories:
  - unknown
source_datasets:
  - original
task_categories:
  - question-answering
task_ids:
  - multiple-choice-qa

MQA

MQA is a Multilingual corpus of Questions and Answers (MQA) parsed from the Common Crawl. Questions are divided in two types: Frequently Asked Questions (FAQ) and Community Question Answering (CQA).

from datasets import load_dataset
all_data = load_dataset("clips/mqa", language="en")
{
  "name": "the title of the question (if any)",
  "text": "the body of the question (if any)",
  "answers": [{
    "text": "the text of the answer",
    "is_accepted": "true|false"
  }]
}
faq_data = load_dataset("clips/mqa", scope="faq", language="en")
cqa_data = load_dataset("clips/mqa", scope="cqa", language="en")

Languages

We collected around 234M pairs of questions and answers in 39 languages. To download a language specific subset you need to specify the language key as configuration. See below for an example.

load_dataset("clips/mqa", language="en") # replace "en" by any language listed below
Language FAQ Questions CQA Questions
en 130,344,204 7,804,182
de 12,393,508 607,436
es 10,469,289 606,335
fr 9,308,231 1,035,504
ru 8,917,939 1,150,006
it 4,748,047 307,368
ja 4,718,682 1,219,364
zh 4,596,792 410,451
pt 3,912,171 308,025
nl 3,443,730 281,342
pl 2,880,754 43,526
tr 2,845,351 200,334
vi 2,030,513 73,755
ar 1,664,424 606,190
id 1,564,936 145,973
uk 1,412,468 20,534
ro 1,344,766 76,781
no 1,270,541 9,247
th 1,185,354 23,261
sv 1,128,790 11,376
el 1,123,855 2,348
fi 993,789 20,065
da 956,871 8,805
he 935,144 53,764
ko 789,772 37,290
cs 758,390 102,013
fa 631,084 87,088
hu 496,215 12,350
sk 471,196 3,795
hi 462,052 145,906
lt 397,695 155
et 286,187 411
hr 221,410 12,846
is 219,771 12
lv 213,524 57
ms 165,703 7,259
bg 114,842 3,323
sr 87,684 8,344
ca 66,249 812

FAQ vs. CQA

You can download the Frequently Asked Questions (FAQ) or the Community Question Answering (CQA) part of the dataset.

faq = load_dataset("clips/mqa", scope="faq")
cqa = load_dataset("clips/mqa", scope="cqa")
all = load_dataset("clips/mqa", scope="all")

Although FAQ and CQA questions share the same structure, CQA questions can have multiple answers for a given questions, while FAQ questions have a single answer. FAQ questions typically only have a title (name key), while CQA have a title and a body (name and text).

Nesting and Data Fields

You can specify three different nesting level: question, page and domain.

Question

load_dataset("clips/mqa", level="question") # default

The default level is the question object:

  • name: the title of the question(if any) in markdown format
  • text: the body of the question (if any) in markdown format
  • answers: a list of answers
    • text: the title of the answer (if any) in markdown format
    • name: the body of the answer in markdown format
    • is_accepted: true if the answer is selected.

Page

This level returns a list of questions present on the same page. This is mostly useful for FAQs since CQAs already have one question per page.

load_dataset("clips/mqa", level="page")

Domain

This level returns a list of pages present on the web domain. This is a good way to cope with FAQs duplication by sampling one page per domain at each epoch.

load_dataset("clips/mqa", level="domain")

Source Data

This section was adapted from the source data description of OSCAR

Common Crawl is a non-profit foundation which produces and maintains an open repository of web crawled data that is both accessible and analysable. Common Crawl's complete web archive consists of petabytes of data collected over 8 years of web crawling. The repository contains raw web page HTML data (WARC files), metdata extracts (WAT files) and plain text extracts (WET files). The organisation's crawlers has always respected nofollow and robots.txt policies.

To construct MQA, we used the WARC files of Common Crawl.

People

This model was developed by Maxime De Bruyn, Ehsan Lotfi, Jeska Buhmann and Walter Daelemans.

Licensing Information

These data are released under this licensing scheme.
We do not own any of the text from which these data has been extracted.
We license the actual packaging of these data under the Creative Commons CC0 license ("no rights reserved") http://creativecommons.org/publicdomain/zero/1.0/

Should you consider that our data contains material that is owned by you and should therefore not be reproduced here, please:
* Clearly identify yourself, with detailed contact data such as an address, telephone number or email address at which you can be contacted.
* Clearly identify the copyrighted work claimed to be infringed.
* Clearly identify the material that is claimed to be infringing and information reasonably sufficient to allow us to locate the material.

We will comply to legitimate requests by removing the affected sources from the next release of the corpus.

Citation information

@misc{debruyn2021mfaq,
      title={MFAQ: a Multilingual FAQ Dataset}, 
      author={Maxime {De Bruyn} and Ehsan Lotfi and Jeska Buhmann and Walter Daelemans},
      year={2021},
      booktitle={MRQA@EMNLP2021},
}