We present M2D2, a fine-grained, massively multi-domain corpus for studying domain adaptation in language models (LMs). M2D2 consists of 8.5B tokens and spans 145 domains extracted from Wikipedia and Semantic Scholar. Using ontologies derived from Wikipedia and ArXiv categories, we organize the domains in each data source into 22 groups. This two-level hierarchy enables the study of relationships between domains and their effects on in- and out-of-domain performance after adaptation. We also present a number of insights into the nature of effective domain adaptation in LMs, as examples of the new types of studies M2D2 enables. To improve in-domain performance, we show the benefits of adapting the LM along a domain hierarchy; adapting to smaller amounts of fine-grained domain-specific data can lead to larger in-domain performance gains than larger amounts of weakly relevant data. We further demonstrate a trade-off between in-domain specialization and out-of-domain generalization within and across ontologies, as well as a strong correlation between out-of-domain performance and lexical overlap between domains.
翻译:我们提出了M2D2, 这是一种用于研究语言模型领域适应的精细的、大规模多域体。 M2D2 由来自维基百科和语义学学者的8.5B符号和145个域组成。我们利用来自维基百科和ArXiv 类的本体学,将每个数据源的域分为22个组。这一两级的层次使得能够研究各域之间的关系及其对适应后内外性能的影响。我们还提出了一些关于LM 中有效领域适应的性质的深刻见解,作为新的M2D2研究类型的例子。为了改善内部性能,我们展示了将LM按域等级调整的好处;适应小量的精细度特定域数据,可以导致更大的内部性能收益,超过与较弱的相关数据数量。我们进一步展示了内部专门化和外部内和跨领域性一般化之间的利弊,以及外性性性绩效和地域间重叠之间的紧密关联。