Skip to content

A classifier for sentiment analysis of product reviews using Python language

Notifications You must be signed in to change notification settings

asalimw/Automatic_Review_Analyzer

Repository files navigation

Automatic_Review_Analyzer

A classifier for sentiment analysis of product reviews using Python language

Project done by Willianto Asalim on Feb - March 2021

The goal of this project is to design a classifier to use for sentiment analysis of product reviews. The training set consists of reviews written by Amazon customers for various food products. The reviews, originally given on a 5 point scale, have been adjusted to a +1 or -1 scale, representing a positive or negative review, respectively.

Below are two example entries from our dataset. Each entry consists of the review and its label. The two reviews were written by different customers describing their experience with a sugar-free candy.

Review label

Negative remarks - Nasty No flavor. The candy is just red, No flavor. Just plan and chewy. I would never buy them again −1 Positive remarks - YUMMY! You would never guess that they're sugar-free and it'��s so great that you can eat them pretty much guilt free! i was so impressed that i've ordered some for myself (w dark chocolate) to take to the office. These are just EXCELLENT! 1

Three types of linear classifiers: the perceptron algorithm, the average perceptron algorithm, and the Pegasos algorithm.

Setup Details: For this project, I will be using the NumPy numerical toolbox, and the matplotlib plotting toolbox.

The repo contains the following files:

project1.py contains various useful functions and function templates that will be used to implement learning algorithms.

main.py is a script skeleton where these functions are called and the experiments.

utils.py contains utility functions.

test.py is a script which runs tests on a few of the methods you will implement. Note that these tests are provided to help debug my implementation and are not necessarily representative of the tests used for online grading. Feel free to add more test cases locally to further validate the correctness of your code before submitting to the online graders in the codeboxes.


About

A classifier for sentiment analysis of product reviews using Python language

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published