The invention discloses a text emotion reason identification method based on a CPC-ANN, and belongs to the technical field of natural language processing text emotion analysis. A text emotion reason identification method based on a CPC-ANN is characterized in that a CPC-ANN model is mainly divided into five layers: an embedded layer, a Bi-LSTM layer, a Transform layer, an attention layer and a CNN output layer. A collaborative attention neural network model based on context and position interaction is provided on the basis of a CANN method, relative position information of clauses is encoded into each word vector of the clauses, and the relative position information of the clauses is encoded into each word vector of the clauses; the semantic information of the clauses is captured through a two-way long and short term memory Transformer network so as to help to generate better clause representation; then, an attention mechanism is used to capture a semantic relationship between candidate reason clauses and emotion clauses fused with context clause information; and finally, the candidate reason clauses are classified by using a convolutional neural network. According to the method, the problem that the semantic and position information is insufficiently utilized by the current text emotion reason identification method is solved.
Text emotion reason identification method based on CPC-ANN