How to use JavaScript for sentiment analysis in text?