I'm working on unsupervised aspect based sentiment analysis. I tried using Vader for it, which gave me good result but the problem is if the topic is negative like 'food waste' then the sentiment is always coming as negative even though content is saying 'and i really hate food waste'. Can someone help me in tackling this issue, or even suggest me a method better than Vader. I've also tried using 'Flair' but its' results are not as promising as Vader.
-
Can you please post the alle the scores that vader outputs for this sentence? Are you using the python module or some other implementation? Sometimes the compound score gives insight in the more complicated phrases. – m.rp Jan 14 '20 at 09:08
-
@m.rp result was {'neg': 0.702, 'neu': 0.298, 'pos': 0.0, 'compound': -0.7939} – Kazama Jan 14 '20 at 09:34
1 Answers
Probably the rule-based model VADER uses is not a good approach in this case, in that phrase you have 3 words that will surely get a negative score (hate food waste), remember that VADER is optimized for succint social media data and it cannot get a very good grasp of the "context" of the phrases.
A similar approach to VADER is us in TextBlob, wich you can try withuot much work: https://textblob.readthedocs.io/en/dev/
Usually the supervised route gives better results, but you need a good pretrained model and good data.
Naive Bayes classifier in scikit-learn: https://www.datacamp.com/community/tutorials/simplifying-sentiment-analysis-python
Random Forest approach, always using scikit-learn: https://stackabuse.com/python-for-nlp-sentiment-analysis-with-scikit-learn/
Here is a recap on various approaches to sentiment analysis: https://towardsdatascience.com/fine-grained-sentiment-analysis-in-python-part-1-2697bb111ed4

- 718
- 8
- 22
-
but the data in my case is not labelled..so i have to use unsupervised approach – Kazama Jan 14 '20 at 10:42
-
This was just to illustrate what alternatives you have, if you want to try a similar approach to VAEDER try TextBlob https://textblob.readthedocs.io/en/dev/ – m.rp Jan 14 '20 at 11:41