SentimentAnalysisPlugin
Sentiment Analysis Module Comparison
Modules
- EmotionsMultiLang
- Salient
- Sediment
- Sentiment
- Sentimental
- SentimentAlyze
- SentiWord
Installation
npm install sentiment-analysis-comparison
Usage
To use the sentiment analysis module comparison you have to create a SentimentAnalyzer object with at least a SentimentAnalysingModule of your choice (default is sentiment). You can also choose a language (if supported) for your SentimentAnalyzer.
Now you can call the analyzeForJsonResult function with your input as parameter to run the selected sentiment analyzer.
import { SentimentAnalyzer } from 'sentiment-analysis-comparison';
import { Language } from 'sentiment-analysis-comparison';
import { SentimentAnalysingModule } from 'sentiment-analysis-comparison';
const EXAMPLE_INPUT = 'This is good';
let sentimentAnalyzer = new SentimentAnalyzer(SentimentAnalysingModule.SentiWord);
sentimentAnalyzer.analyzeForJsonResult("This is good").then(result => console.log(result));