This article uses a model that combines the seq2seq model with the attention mechanism. This model is very good at solving problems such as repetition and incompatibility in the generation of words and sentences. And the quality of abstract generation has been improved [8]. 1) seq2seq model The seq2seq model can be applied to tasks such as part-of-speech tagging, text summarization, translation, etc. The main research of this article is a text Summarization, the correspondence between the input sequence and the output sequence is not obvious. So the model in this article is built by two RNN (recurrent neural networks). An RNN is an encoder, it is responsible for encoding the input sequence X, convert the input sequence
1 2 3 X , , , , n x x x x = < … > into a
fixed-length semantic vector C, this process is a non-linear change. [6] Another RNN is decoder, It is responsible for generating the y-i to be generated at time I, it according to the semantic vector C and the generated information y 1 , y 2 , y 3 , …, y i-1 . Finally generated sequence ( )
1 2 3 C F , , , , n x x x x = … (1) ( ) 1 2 3 1 C, , , , , i i y G y y y y − = … (2)
The end-to-end process of this model combines semantic understanding and text generation. But in the coding stage, regardless of the length of the input sequence, the length of the output semantic vector C is fixed. This leads to **data** loss when generating sequences. Therefore, we introduce an attention mechanism in the seq2seq model to solve the problem [9].