HanTrans: An Empirical Study on Cross-Era Transferability of Chinese Pre-trained Language Model

1015

Authors

nan

Abstract

AbstractThe pre-trained language model has recently dominated most downstream tasks in the NLP area. Particularly, bidirectional Encoder Representations from Transformers (BERT) is the most iconic pre-trained language model among the NLP tasks. Their proposed masked-language modeling (MLM) is an indispensable part of the existing pre-trained language models. Those outperformed models for downstream tasks benefited directly from the large training corpus in the pre-training stage. However, their training corpus for modern traditional Chinese was light. Most of all, the ancient Chinese corpus is still disappearance in the pre-training stage. Therefore, we aim to address this problem by transforming the annotation data of ancient Chinese into BERT style training corpus. Then we propose a pre-trained Oldhan Chinese BERT model for the NLP community. Our proposed model outperforms the original BERT model by significantly reducing perplexity scores in masked-language modeling (MLM). Also, our fine-tuning models improve F1 scores on word segmentation and part-of-speech tasks. Then we comprehensively study zero-shot cross-eras ability in the BERT model. Finally, we visualize and investigate personal pronouns in the embedding space of ancient Chinese records from four eras. We have released our code at https://github.com/ckiplab/han-transformers.

Keywords

nan

Full Content

HanTrans: An Empirical Study on Cross-Era Transferability of Chinese Pre-trained Language Model (預訓練語言模型在漢語上的跨時代學習能力) Chin-Tung Lin Academia Sinica cindylin@iis.sinica.edu.tw Wei-Yun Ma Academia Sinica ma@iis.sinica.edu.tw 摘要 近年來預訓練的語言模型在自然語言處理 中蔚為風潮,以 BERT (Bidirectional En- coder Representations form Transformers) 模型為代表,其掩碼語言建模 (masked- language modeling, MLM) 被廣泛應用於 大型語言模型的預訓練,使得後續微調 (fine tuning) 後的模型即可在下游任務有 很好的表現。然而,在預訓練的語料中, 相比於簡體中文,繁體中文只佔了很少 的比例,尤其缺乏古漢語(上古、中古、 近代等)的語料。這使得古漢語的自然語 言處理一直沒有適切的大型預訓練模型 可用。基於此,我們訓練與發佈了一個專 為古漢語打造的 BERT 系列模型。我們 的預訓練語言模型與原本的中文 BERT 系列模型相比,能夠成功降低了古漢語 的 perplexity 分數。同時,我們也進一 步開發了不同時代的分詞與詞類標記的 模型,並探究其對於跨時代語料的遷移 學習能力。最後,我們將不同時代模型 的人稱代名詞詞向量 (word embedding) 進行降維,觀察其不同時代的變異情形。 我們的程式碼發布在https://github.com/ ckiplab/han-transformers。 Abstract The pre-trained language model has re- cently dominated most downstream tasks in the NLP area. Particularly, bidi- rectional Encoder Representations from Transformers (BERT) is the most iconic pre-trained language model among the NLP tasks. Their proposed masked- language modeling (MLM) is an indispens- able part of the existing pre-trained lan- guage models. Those outperformed mod- els for downstream tasks benefited directly from the large training corpus in the pre- training stage. However, their training cor- pus for modern traditional Chinese was light. Most of all, the ancient Chinese corpus is still disappearance in the pre- training stage. Therefore, we aim to ad- dress this problem by transforming the Figure 1: 漢語分詞和詞類標記範例,我們使用四 個時代的漢語語料預訓練語言模型,同時應用在 分詞和詞類標記的下游任務上。 annotation data of ancient Chinese into BERT style training corpus. Then we pro- pose a pre-trained Oldhan Chinese BERT model for the NLP community. Our proposed model outperforms the original BERT model by significantly reducing per- plexity scores in masked-language model- ing (MLM). Also, our fine-tuning models improve F1 scores on word segmentation and part-of-speech tasks. Then we compre- hensively study zero-shot cross-eras ability in the BERT model. Finally, we visual- ize and investigate personal pronouns in the embedding space of ancient Chinese records from four eras. We have released our code at https://github.com/ckiplab/ han-transformers. The 34th Conference on Computational Linguistics and Speech Processing (ROCLING 2022) Taipei, Taiwan, November 21-22, 2022. The Association for Computational Linguistics and Chinese Language Processing 164 關鍵字:漢語、預訓練語言模型、零樣本跨 時代學習 Keywords: Chinese Language Model, Zero-shot Cross-Era Transfer Learning 1 緒論 近年自然語言處理 (Natural Language Pro- cessing, NLP) 領域中,大型預訓練的語言 模型 (Kenton and Toutanova, 2019; Radford et al., 2019; Raffel et al., 2020) 在許多下游任 務中均取得優異的表現。多語言的預訓練模 型 (Kenton and Toutanova, 2019; Xue et al., 2021) 也日益出現,能夠支援中文的自然語 言處理。常見的中文下游任務包含問答系統 (Shao et al., 2018; Cui et al., 2019)、機器翻譯 (Sennrich et al., 2016)、文本情感分析 (Pon- tiki et al., 2016; Tan and Zhang, 2008)、文本 摘要 (Hu et al., 2015)、詞性標記 (Xue et al., 2005) 和中文分词 (Emerson, 2005; Jin and Chen, 2008) 等等。 得益於多語言的預訓練資料,(Pires et al., 2019) 發現以 104 種語言預訓練的 Multilin- gual BERT (mBERT) 有 zero-shot 的跨語言 學習能力。以中文問答系統為例,(Hsu et al., 2019) 實驗得出英文問答資料上做微調的 BERT 模型,測試於中文的問答資料上就能 得到不錯的 F1 值。而同時使用中文和英文的 問答資料做微調,比單獨使用中文的資料表 現有更高的 F1 值。然而多語言的預訓練模型 同時也受限於預訓練階段不同語言文本的資 料量多寡,與多資源的語言相比之下,下游任 務在少資源語言上表現較為不佳,舉例來說, mBERT (Pires et al., 2019) 的預訓練資料中 最多的是英文 (21%),因此在 XNLI (Conneau et al., 2018) 的任務上英文有最好的表現,相 比之下簡體中文差了大約五個百分點。在現存 大部分預訓練語言模型以英文語料為主的情況 下,增加中文的預訓練語料來提升中文下游任 務的成績,有著迫切的需求。 簡 體 中 文 的 領 域 有 已 經 發 布 的 MacBERT (Cui et al., 2021) 使 用 大 量 簡 體中文語料做為預訓練文本,在各個中文 下游任務比原始 BERT 模型 (Kenton and Toutanova, 2019) 有更好的成績,然而在繁體 中文的領域中,這部分較為缺乏。特別在古漢 語的部分,據我們所知,還未有專門為其打造 的預訓練語言模型。因此,在這份工作中,我 們使用古漢語的語料對 BERT 系列模型做預 訓練,並開發了不同時代的分詞與詞類標記的 模型。同時,基於上述多語言預訓練給我們的 啟示,我們擬探究中文不同時代的語料訓練出 斷詞和詞性標註 (擷取自堯典) 乃 (DL) 命 (VF) 羲 (NB1) 和 (NB1) , 欽若 (VH1N) 昊天 (NA1) ; 歷 (DA) 象 (VP) 日月 (NB2) 星辰 (NA2) , …

Content truncated to 500 words

Labeled Text

AbstractThe pre-trained language model has recently dominated most downstream tasks in the NLP area. Particularly, bidirectional Encoder Representations from Transformers (BERT) is the most iconic pre-trained language model among the NLP tasks. Their proposed masked-language modeling (MLM) is an indispensable part of the existing pre-trained language models. Those outperformed models for downstream tasks benefited directly from the large training corpus in the pre-training stage. However, their training corpus for modern traditional Chinese was light. Most of all, the ancient Chinese corpus is still disappearance in the pre-training stage. Therefore, we aim to address this problem by transforming the annotation data of ancient Chinese into BERT style training corpus. Then we propose a pre-trained Oldhan Chinese BERT model for the NLP community. Our proposed model outperforms the original BERT model by significantly reducing perplexity scores in masked-language modeling (MLM). Also, our fine-tuning models improve F1 scores on word segmentation and part-of-speech tasks. Then we comprehensively study zero-shot cross-eras ability in the BERT model. Finally, we visualize and investigate personal pronouns in the embedding space of ancient Chinese records from four eras. We have released our code at

Publication Details

Paper ID:
1015
Year:
2022
Publication:
TIPSTER
Publication Type:
conf
DOI:
nan