Last active
December 29, 2022 13:06
-
-
Save jfahrenkrug/5f6b2ac6086f004caaa7e47b7e9688a8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const Sentiment = require('sentiment') | |
export class Analyzer { | |
static analyze(phrase) { | |
let sentiment = new Sentiment() | |
let result = sentiment.analyze(phrase) | |
return result['score'] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment