Chinese Offensive Language Detection Algorithm based on Pre-trained Language model and Pointer Network Augmentation
作者
Boyuan Hou,Xin Xie,Dongcheng Zhang,Liyuan Zheng,Guojun Yan
出处
期刊:日期:2024-03-29卷期号:: 800-805被引量:2
标识
DOI:10.1109/ainit61980.2024.10581762
摘要
The traditional offensive language detection methods suffer from issues such as inadequate understanding of semantic information and sensitivity to noise in text. To address these problems, this paper proposes a Chinese offensive language detection algorithm based on a pre-trained language model and augmented with a pointer network. Firstly, the algorithm incorporates task prompt information into the text using the prompt layer. Then, it feeds the integrated text with task prompt information into the pre-trained language model RoBERTa to extract deep semantic information and obtain a semantic vector. Subsequently, the generated semantic vector is inputted into the focus layer of the pointer network to obtain a focus vector that strongly relates to offensive language. Finally, by concatenating the semantic vector and focus vector, they are passed through a classification layer for text classification and determining whether it contains offensive language. Experimental results on the Chinese offensive language dataset COLD demonstrate that our proposed method outperforms mainstream methods significantly in terms of detection effectiveness.