The purpose of this paper was to study how to effectively remove the toxicity of Chinese texts.For this task,this paper re-constructed a Chinese texts toxicity corpus set,which was used as the data basis for task research.Based on this data set,this paper explored the toxic manifestations of texts,and analyzed the causes of specific types of toxic texts.Based on the analysis results above,this paper used two types of text style transfer models based on editing and generating to remove text toxicity,and further ex-plored the performance of removing text toxicity based on different Prompts in large language models.According to the experimen-tal results,the edited model can effectively remove the toxicity of explicit toxic text,and has a higher degree of content preservation,while the generated text has a higher degree of fluency.Prompt-based large language model can remove sentence toxicity to a certain extent,but compared with specific style transfer models,the detoxification ability of small parameter large language model needs to be improved.
text style transfertext detoxificationlarge language model