nlp365第112天,nlp论文总结了基于方面的挑战数据集和有效模型

内置AI NLP365(INSIDE AI NLP365)

Project #NLP365 (+1) is where I document my NLP learning journey every single day in 2020. Feel free to check out what I have been learning over the last 257 days here. At the end of this article, you can find previous papers summary grouped by NLP areas :)

在#NLP365(+1)项目中,我记录了2020年每一天的NLP学习历程。请随时在这里查看我过去257天的学习内容。 在本文的结尾,您可以找到按NLP领域分组的以前的论文摘要:)

Today’s NLP paper is A Challenge Dataset and Effective Models for Aspect-Based Sentiment Analysis. Below are the key takeaways of the research paper.

今天的NLP论文是基于方面的情感分析的挑战数据集和有效模型。 以下是研究论文的主要内容。

目标与贡献 (Objective and Contribution)

Introduced a new aspect-based sentiment analysis (ABSA) dataset known as Multi-Aspect Multi-Sentiment (MAMS), where each sentence contains at least two different aspects and two difference sentiment. The proposed MAMS dataset could solve the common issue of existing ABSA dataset, where most sentences contain the same sentiment for different aspects, degenerating ABSA to sentence-level sentiment analysis. The paper also proposed a simple baseline model, CapsNet-BERT, for the dataset.

引入了一个新的基于方面的情感分析(ABSA)数据集,称为多方面多情感(MAMS),其中每个句子至少包含两个不同的方面和两个不同的情感。 提出的MAMS数据集可以解决现有ABSA数据集的普遍问题,即大多数句子在不同方面包含相同的情感,从而将ABSA退化为句子级情感分析。 本文还为数据集提出了一个简单的基线模型CapsNet-BERT。

数据集构建 (Dataset Construction)

The dataset construction of MAMS is broken down to three steps:

MAMS的数据集构建分为三个步骤:

  1. Data Collection

    数据采集
  2. Data Annotation

    资料注解
  3. Dataset Analysis

    数据集分析

数据采集(Data Collection)

Annotate Citysearch New York dataset similar to SemEval-2014 dataset. Remove any sentences with more than 70 words.

注释类似于SemEval-2014数据集的Citysearch New York数据集。 删除所有超过70个单词的句子。

资料注解 (Data Annotation)

Two versions of MAMS dataset are created to tackle two areas of aspect-based sentiment analysis: aspect-term sentiment analysis (ATSA) and aspect-category sentiment analysis (ACSA). For ATSA, we extracted aspect terms in sentences and map them with the appropriate sentiment and remove any sentences with one aspect or multiple aspects with the same sentiment. The dataset also includes the start and end positions for each aspect term. For ACSA, we pre-defined eight aspect categories: food, service, staff, price, ambience, menu, place, and miscellaneous. Each sentence is map to an aspect category along with the appropriate sentiment towards the aspect category. The dataset only includes sentences with at least two unique aspect categories with different sentiment.

创建了两个版本的MAMS数据集,以解决基于方面的情感分析的两个领域:方面术语情感分析(ATSA)和方面类别情感分析(ACSA)。 对于ATSA,我们提取了句子中的方面术语,并以适当的情感对其进行映射,并删除具有一个方面或具有相同情感的多个方面的任何句子。 数据集还包括每个方面术语的开始和结束位置。 对于ACSA,我们预定义了八个方面类别:食物,服务,人员,价格,环境,菜单,地点和其他。 每个句子都映射到一个方面类别,并带有针对该方面类别的适当情感。 数据集仅包含具有至少两个具有不同情感的独特方面类别的句子。

数据集分析 (Dataset Analysis)

ATSA contains 13,854 sentences with an average of 2.62 aspect terms. ACSA has 8,879 sentences with an average of 2.25 aspect categories. Note that all sentences in MAMS contains multiple aspects with different sentiment. Existing ABSA datasets (SemEval-2014 and Twitter) contains no more than 30% of sentences that are multi-aspect multi-sentiment, some even less than 1%.

ATSA包含13,854个句子,平均长宽比为2.62。 ACSA有8,879个句子,平均分为2.25个方面类别。 请注意,MAMS中的所有句子都包含具有不同情感的多个方面。 现有的ABSA数据集(SemEval-2014和Twitter)包含的多角度多情感句子不超过30%,有些甚至不到1%。

Image for post
Descriptive Statistics of MAMS dataset [1]
MAMS数据集的描述性统计[1]

CapsNet-BERT (CapsNet-BERT)

Given a sentence and an aspect term or an aspect category, we want the model to predict the sentiment of the sentence with respect to the aspects. The proposed model is CapsNet-BERT, which consists of 4 layers:

给定一个句子和一个方面术语或一个方面类别,我们希望模型预测有关方面的句子情感。 提出的模型是CapsNet-BERT,它由4层组成:

  1. Embedding layer

    嵌入层
  2. Encoding layer

    编码层
  3. Primary capsule layer

    初级胶囊层
  4. Category capsule layer

    分类胶囊层
Image for post
CapsNet-BERT [1]
CapsNet-BERT [1]

嵌入层 (Embedding layer)

In this layer, we convert the input sentence and aspect into word embeddings. For aspect term embedding, we computed it as the average of the aspect word embeddings. For aspect category embedding, we initialised the embedding randomly and learn during training. The output of the embedding layer is the aspect-aware sentence embedding where we concatenate aspect embedding with each word embedding in the sentence.

在这一层中,我们将输入的句子和方面转换为单词嵌入。 对于方面词嵌入,我们将其计算为方面词嵌入的平均值。 对于方面类别嵌入,我们随机初始化嵌入并在训练期间学习。 嵌入层的输出是可感知方面的句子嵌入,其中我们将方面嵌入与句子中嵌入的每个单词连接起来。

编码层 (Encoding layer)

We take the aspect-aware sentence embedding and feed it into Bi-directional GRU with residual connection to get the contextualised representation.

我们将具有方面意识的句子嵌入,并通过残差连接将其馈送到双向GRU中,以获取上下文表示。

初级胶囊层 (Primary capsule layer)

Using linear transformation and squashing activation, we get the primary capsules P using the contextualised representation and aspect capsule using the aspect embedding from the embedding layer. There are two further mechanisms in this layer:

使用线性变换和挤压激活,我们使用上下文表示法来获得主胶囊P,并使用嵌入层中的长宽比嵌入长宽比胶囊。 该层还有两种其他机制:

  1. Aspect Aware Normalisation. This is to counter the fact that variation of sentence length cause training to be unstable and so we use aspect capsule to normalise primary capsule weights, to select important primary capsules.

    方面感知规范化。 这是为了克服这样的事实,即句子长度的变化会导致训练不稳定,因此我们使用方面胶囊来标准化初级胶囊的重量,以选择重要的初级胶囊。

  2. Capsule Guided Routing. This leverages prior knowledge of sentiment categories to improve the routing process. During training, a sentiment matrix is initialised and this is feed into a squash activation to obtain sentiment capsules. The routing weights are then computed by measuring the similarity between the primary capsules and sentiment capsules.

    胶囊制导路由。 这利用了情感类别的先验知识来改进路由过程。 在训练期间,将情绪矩阵初始化,并将其输入到壁球激活中以获取情绪胶囊。 然后,通过测量初级胶囊和情感胶囊之间的相似度来计算路由权重。

分类胶囊层 (Category capsule layer)

Using the primary capsules, aspect-aware normalised weights and capsule-guided routing weights, we can compute the final category capsules. Note that for CapsNet-BERT, the embedding and encoding layer are replaced with pre-trained BERT.

使用主要胶囊,方面感知归一化权重和胶囊指导的路由权重,我们可以计算最终类别的胶囊。 请注意,对于CapsNet-BERT,嵌入和编码层已替换为预训练的BERT。

实验与结果 (Experiments and Results)

There are three evaluation datasets: ATSA, ACSA, and SemEval-2014 restaurant review.

共有三个评估数据集:ATSA,ACSA和SemEval-2014餐厅评论。

型号比较 (Models Comparison)

Models are divided into 4 categories:

模型分为4类:

  1. LSTM-based

    基于LSTM
  2. CNN-based

    基于CNN
  3. Attention-based

    基于注意
  4. Ablation study to compared the effectiveness of combining CapsNet and BERT and the effect of proposed mechanism

    通过消融研究比较CapsNet和BERT组合的有效性以及所提出机制的效果

结果(Results)

Image for post
Experimental Results for both ATSA and ACSA subtasks [1]
ATSA和ACSA子任务的实验结果[1]
  • As mentioned, sentence-level sentiment classifier (TextCNN and LSTM) performed competitively in SemEval-2014 but poorly in MAMS datasets

    如前所述,句子级情感分类器(TextCNN和LSTM)在SemEval-2014中表现出色,但在MAMS数据集中表现不佳
  • The SOTA ABSA method on SemEval-2014 perform poorly or average on the MAMS datasets, indicating the high difficulty level of the MAMS dataset

    SemEval-2014上的SOTA ABSA方法在MAMS数据集上的表现不佳或平均,表明MAMS数据集的难度很高
  • Attention-based models without properly modelling word sequences performed badly in MAMS as they lose sequential information of sentences and so fail to connect the context with the aspect

    没有正确建模单词序列的基于注意力的模型在MAMS中表现不佳,因为它们丢失了句子的顺序信息,因此无法将上下文与方面联系起来
  • CapsNet outperformed BERT on 4 out of 6 datasets, showing the strength of CapsNet. The combination of CapsNet-BERT outperformed all models in all datasets

    在6个数据集中的4个数据集上,CapsNet的表现优于BERT,显示了CapsNet的优势。 CapsNet-BERT的组合优于所有数据集中的所有模型
  • CapsNet-DR and CapsNet-BERT-DR are included to measure the effectiveness of the capsule guided routing. We use the standardised dynamic routing (DR) which reduces the performance of the model and underperformed our CapsNet-BERT

    CapsNet-DR和CapsNet-BERT-DR包括在内,用于测量胶囊引导式布线的有效性。 我们使用标准化的动态路由(DR),这会降低模型的性能,并且性能不如CapsNet-BERT

资源: (Source:)

[1] Jiang, Q., Chen, L., Xu, R., Ao, X. and Yang, M., 2019, November. A challenge dataset and effective models for aspect-based sentiment analysis. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP) (pp. 6281–6286).

[1] Jiang,Q.,Chen,L.,Xu,R.,Ao,X. and Yang,M.,2019年11月。 用于基于方面的情感分析的挑战数据集和有效模型。 在《 2019年自然语言处理经验方法会议》和第9届国际自然语言处理联合会议(EMNLP- IJCNLP)的会议记录中(第6281–6286页)。

Originally published at https://ryanong.co.uk on April 21, 2020.

最初于2020年4月21日发布在https://ryanong.co.uk

方面提取/基于方面的情感分析 (Aspect Extraction / Aspect-based Sentiment Analysis)

总结 (Summarisation)

其他 (Others)

翻译自: https://towardsdatascience.com/day-112-of-nlp365-nlp-papers-summary-a-challenge-dataset-and-effective-models-for-aspect-based-35b7a5e245b5

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值