arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2006.16174cs.CLcs.LG
收藏

带注意力的多通道CNN文本分类

Multichannel CNN with Attention for Text Classification

China University of Political Science and Law(中国政法大学);University of Science and Technique of China(中国科学技术大学)

Zhenyu Liu, Haiwei Huang, Chaohong Lu, Shengfei Lyu

摘要:

近年来,基于神经网络的句子建模方法显示出了巨大的潜力。神经网络主要有两种结构:递归神经网络(RNN)和卷积神经网络(CNN)。RNN可以捕获长期依赖关系,并将先前信息的语义存储在固定大小的向量中。然而,RNN是一个有偏模型,其提取全局语义的能力受到固定大小向量的限制。或者,CNN能够通过利用卷积滤波器来捕获文本的n-gram特征。但是卷积滤波器的宽度限制了它的性能。为了结合这两种网络的优点,弥补它们的不足,本文提出了基于注意力的多通道卷积神经网络(AMCNN)用于文本分类。AMCNN利用双向的长短期记忆将词的历史和未来信息编码成高维表示,使句子前后的信息都能得到充分表达。然后,标量注意力和矢量注意力被应用到获得多通道表示。标量注意力可以计算词级的重要性,矢量注意力可以计算特征级的重要性。在分类任务中,AM CNN使用CNN结构来捕获由标量和矢量注意力机制生成的表示上的词关系,而不是计算加权和。它可以有效地提取文本的n-gram特征。在基准数据集上的实验结果表明,AMCNN实现了比最先进的方法更好的性能。此外,可视化结果验证了多通道表示的语义丰富性。

英文摘要:

Recent years, the approaches based on neural networks have shown remarkable potential for sentence modeling. There are two main neural network structures: recurrent neural network (RNN) and convolution neural network (CNN). RNN can capture long term dependencies and store the semantics of the previous information in a fixed-sized vector. However, RNN is a biased model and its ability to extract global semantics is restricted by the fixed-sized vector. Alternatively, CNN is able to capture n-gram features of texts by utilizing convolutional filters. But the width of convolutional filters restricts its performance. In order to combine the strengths of the two kinds of networks and alleviate their shortcomings, this paper proposes Attention-based Multichannel Convolutional Neural Network (AMCNN) for text classification. AMCNN utilizes a bi-directional long short-term memory to encode the history and future information of words into high dimensional representations, so that the information of both the front and back of the sentence can be fully expressed. Then the scalar attention and vectorial attention are applied to obtain multichannel representations. The scalar attention can calculate the word-level importance and the vectorial attention can calculate the feature-level importance. In the classification task, AMCNN uses a CNN structure to cpture word relations on the representations generated by the scalar and vectorial attention mechanism instead of calculating the weighted sums. It can effectively extract the n-gram features of the text. The experimental results on the benchmark datasets demonstrate that AMCNN achieves better performance than state-of-the-art methods. In addition, the visualization results verify the semantic richness of multichannel representations.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑