Skip to content

DIlkhush00/Sentiment-Analyzer

Repository files navigation

Evaluate a News Article with NLP

This project is made for Udacity's Front End Developer Nanodegree Program.

Table of Contents

Description

This application does a sentiment analysis of an article using MeaningCloud's Sentiment Analysis API and article's URL is provided by the user using this application's user-friendly interface.

Technology Used

This application is mainly built with:

  • HTML
  • SCSS
  • JavaScript
  • Node.js
  • Express.js
  • MeaningCloud's Sentiment Analysis API version 2.1
  • Webpack
  • Jest
  • Workbox

Preview

Preview

Prerequisite

  • You must have Node.js installed on your computer
  • Get your personal API key from MeaningCloud

Installation

  1. Clone the repo
git clone https://github.com/DIlkhush00/Evaluate-An-Article-With-NLP/
  1. Run the following Command in terminal to install necessary dependencies
npm install
  1. Create a file with .env extension and copy below code and paste it into that file. Now replace ***** with your personal API key
API_KEY = ***** //Replace ***** with your personal API key
  1. Run following command in terminal to build dist folder
npm run build-prod
  1. Finally, run following command in terminal
npm run start
  1. Open any browser and visit the following url http://localhost:8081/
  2. There you go 🚀

Development Mode

To run the project in development mode run following command in the terminal

npm run build-dev

Now open any browser and visit http://localhost:8080/

Testing

Testing is done using Jest framework. To perform unit testing, run following command in the terminal

npm run test