Netinfo Security ›› 2021, Vol. 21 ›› Issue (12): 102-108.doi: 10.3969/j.issn.1671-1122.2021.12.014

Previous Articles     Next Articles

Research on Chinese Question Answering Matching Based on Mutual Attention Mechanism and Bert

DAI Xiang, SUN Haichun(), NIU Shuo, ZHU Rongchen   

  1. School of Information and Network Security, People’s Public Security University of China, Beijing 100038, China
  • Received:2021-09-29 Online:2021-12-10 Published:2022-01-11
  • Contact: SUN Haichun E-mail:sunhaichun@ppsuc.edu.cn

Abstract:

Question and answer matching task is one of the key technologies of question and answer system. Focusing on the problems that the traditional question and answer matching model is not accurate enough in the representation of Chinese word vector and insufficient extraction of interactive features between texts, a bi-directional encoder representation algorithm based on attention is proposed. In Chinese vector representation, transfer learning is used to introduce the pretrained Chinese BERT model parameters, and further finetune the training set to obtain the optimal parameters. The Chinese character vector is represented by the BERT model, so as to solve the problem of insufficient representation ability of the traditional word vector model in Chinese vocabulary. At the text interaction layer, the interactive features of questions and answers are extracted by using the mutual attention mechanism, and the generated interactive features are combined with the input vector of the attention mechanism to form a feature combination. Then BiLSTM is used for reasoning combination, reducing the feature dimension and integrating the context semantic information. Finally, it is tested on the Chinese legal data set. The experimental results show that the model is better than many traditional models. Compared with ESIM, it improves the accuracy of Top-1 by 3.55%, MAP by 5.21% and MRR by 4.05%.

Key words: question and answer matching, bi-directional encoder representation from transformers, mutual attention mechanism

CLC Number: