{'fraction_non_alphanumeric': 0.01383203076541372, 'fraction_numerical': 0.0012405408758218582, 'mean_word_length': 4.877870944221655, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
A Supervised Learning Technique for Classifying Amazon Product Reviews based on Buyers Sentiments

A number of applications using internet provide vary essential services. Among them social media and ecommerce platforms are very common. These platforms include a large amount of data which is generated by the users. That data is available in the form of opinion about some post or review. Means the text with emotions which is contain the buyers or user sentiment about some kind of product or service. In this presented work a data mining model is introduced that offers sentiment based text classification for the Amazon product reviews. The proposed data model first preprocesses data and extract the actual review text, in next phase of preprocess the stop words and special characters are removed. The refined text is further utilized with two feature selection techniques first is based on TF-IDF which is used for selecting intense keywords from the review text. Additionally the second feature is selected using NLP text parser. That parser basically performs the POS (Part Of Speech) tagging of review text. Using the obtained POS tags the NLP feature is contracted. Both the features are combined in next and two supervised learners are used namely SVM (support vector machine) and SVR (support vector regression). The experimental results of both the model is measured and compared. The performance study demonstrates the proposed SVM based classifier performs classification accurately and efficiently as compared to SVR based classifier.


INTRODUCTION
In recent years the internet based services are become very common. Among e-commerce, social media and video publishing websites are much common. These applications generating a bulk amount of data and it contains significant amount of information. Mining such data with some context is a task of Natural Language Processing (NLP). In this work the NLP based applications are investigated. Additionally to demonstrate the functional aspects of NLP, An application of review based text classification is proposed to implement and analyze. In this application a product review based text data is used for training and recognizing the buyer sentiments about the product. Basically in ecommerce platforms the product reviews are very influential factor which can motivate a buyer to buy a product or reject it. On the other hand supplier or product designers are always interested to know the buyer sentiments about the product. But reading all the product reviews is a complicated task.
Thus the review classification techniques help us to identify the negative sentiments among entire text. It is working like a filter to identify the reviews which are needed to be attention because the negative reviews can reduce the demand of target product or service. Thus this work is motivated to design an Amazon product review analysis system to classify the reviews into two classes negative and positive. Using this classification a product vendor can work with the negative feedbacks and improve their quality of work and product. In order to achieve this goal we proposed an extended feature model which combines two kinds of features for identifying more crucial reviews about the product and services.

PROPOSED WORK
The proposed work is intended to analyze the Amazon product review and classify the data according to the hidden sentiments in terms of positive and negative. This chapter offers the detailed understanding about the proposed work carried out for designing the required data model.

System Overview
Communication technology is growing frequently additionally the consumption of IT services are also growing. In this context various real world applications (Facebook, Amazon, twitter and others), are used in every age groups. During this a significant amount of data is generated by users. Such kind of data analysis needs significant efforts therefore computational algorithms are used for analyzing the data. That data can be used for various business intelligence application purposes. Basically, the users express their emotions by using social media post or any product review. During that time what the key emotions it is need to be understand. The understanding about the emotions is a research domain of NLP (natural language processing) and machine learning. Therefore to classify the text according to their sentiments we need to implement the NLP based technique for analysis of Amazon product review. The proposed technique extracts the product reviews and preprocesses the content. During the preprocessing the noise contents are removed from input text. After preprocessing the feature extraction technique is taken place. During this the keywords are selected which are having potential sentiments. Further the features are transformed into a fixed amount of sentiment attributes using a NLP parser. These attributes are used for training and testing of the employed classifier. The classifiers are after learning able to classify the text, according to emotions positive or negative. This section provides the basic overview of the proposed work, in next section explains the required data model.

Proposed Methodology
The proposed data model for Amazon product review classification technique is demonstrated in figure 1. In this diagram the different components of sentiment classification is associated for performing required task.

Amazon Product Review
The proposed system is a machine learning model for classifying the product review according to their sentiments. The model is a supervised learning model which is needed to be learnt first. The learned model is used to identify the similar class data instances. In this context the provision is made to accept the Amazon product review dataset which contains the product review relevant various attributes.

Text Preprocessing
The input dataset contains various attributes but we need only one attribute which contains the text reviews for target products. Thus the preprocessing technique is applied first which remove the attribute which are not necessary for the proposed system implementation. The remaining attributes are used further for keyword extraction and other task. Before this step the extracted review text is preprocessed for removing the noisy contents such as stop words and special characters. In this context the model accepts two lists first contain a list of stop words defined by the experimenter and a list of special characters. The system replaces each stop word and special character which is available in the input list. After this text processing the data is produced in next phase.

Intense Keyword Scoring
In a number of applications the feature selection techniques are used for extracting potential keywords from the text data. In this context the TF-IDF (Term Frequency-Inverted Document Frequency) concept is implemented. In order to calculate the term frequency the following function can be used: Where, is the total count of a token, and T is termed as total word in a document.
Additionally to calculate the IDF the following function is used: Where the N is the number of document and number of document contains that token.

NLP Parser
After text refinement the intense keywords are preserved separately additionally the NLP parser is applied. The NLP features are used for tagging of the text in terms of POS (Part Of Speech) tags. The NLP parser accepts the Amazon product review text one by one and find out their relevant part of speech information. In order to understand we can take an example: "The product was good" Or "Article Noun conjunction pronoun" Using this example we can prepare a 2D vector such as:

Combining Features
In this place two previously discussed features intense keywords which is selected on the basis of TF-IDF weight and the POS tag based extracted features are combined in a common 2D vector. Using this process the text data is transformed into a 2D vector or in a tabular format. That 2D vector is used further for training or learning process.

SVM Training
After reforming the text dataset the supervised learning classifier is applied with the approach of one-vs.-all. That is basically a technique where binary SVM classifier is utilized for classifying multiple class labels. Thus combined data is processed using the SVM classifier for training of classifier and after training of SVM (support vector machine) the test samples are classified for identifying the sentiment class labels.

Class Label Prediction
The proposed model accepts the input test dataset which contains the data instances and their class labels. The test data instances are produced to the trained SVM algorithm which computes their prediction of class. The predicted class labels and actual class labels are compared to find the prediction is correct or not. If the classifier prediction is correct then the accuracy is increases otherwise the error rate. In this manner the performance of a classifier is evaluated in terms of accuracy and error rate. At the same time the time required and memory utilized is also measured for demonstrating efficiency of the system.

Proposed Algorithm
This section provides the summary of the entire process involved for classifying the Amazon product review in terms of positive and negative classes. The proposed algorithm is demonstrated in table 2. 3.

RESULT ANALYSIS
This chapter includes the results analysis and performance of the implemented algorithms which are used for developing model for Amazon text review sentiment analysis. Therefore a detailed discussion about the results and their measured parameters are reported.

Accuracy
The accuracy can be explained as the measurement of algorithm classification correctness. That can be measured using the ratio of total correctly classified and the total patterns to be classified. That can also be represented using the following equation.

Fig.2 Accuracy (%)
The proposed data model is evaluated with the two different classifiers with the same data set and data model. The obtained performance in terms of accuracy for both the models is given in figure 2. The X axis of this line graph shows the dataset size in terms of instances and the Y axis contains the accuracy of both the classifiers in terms of percentage (%). According to the line graph we can easily identify the SVM (support vector machine) model perform better then the SVM (support vector regression). Thus the proposed model improves the classification accuracy of the existing model.

Error Rate
The error rate of an algorithm demonstrates the misclassification rate of the algorithm as a performance parameter. That can be calculated using the following equation. Reducing error rate is a good indicator of learning algorithm. In this experiment the SVM and SVR algorithm is compared for the error rate. Both the algorithm demonstrates the reducing error rate with increasing amount of data. The line graph for the performance of the system is given in figure 3 and the observation values are reported in table 4. The X axis of the diagram shows the experimental data instances and Y axis shows the percentage error rate produced. According to the experimental analysis the SVM algorithm produces less error rate as compared to SVR algorithm.

Memory Usage
The memory usages are also an essential parameter for performance evaluation of a data mining algorithm. The amount of total memory utilized for execution of an algorithm is measured here as the memory consumption or usages. The memory usages of the algorithm are computed using the following equation. The memory usages are the indicator of the system efficiency.

Fig.4 Memory Usage
The measured memory usages for both the models are demonstrated in figure 4. It is measured here in terms of KB (kilobytes). The memory usages of the SVM algorithm are consistent as compared to SVR algorithm. But the SVM algorithm requires higher amount of memory as compared to SVM. To demonstrate the performance line graph 3 .3 displays  the values of table 5. Here the X axis shows the amount of data instances used for experiments and Y axis shows the used memory.

Time Consumption
The time consumption is also termed as the time complexity. The amount of time consumed for classification is also calculated in this section using the following formula. The time consumption of the proposed Amazon text review analysis using two different data mining algorithms namely SVM and SVR. The figure 5 shows the line graph for demonstrating time requirements of algorithms in terms milliseconds (MS). The X axis of this line graph shows the data instances used during the experiment and Y axis shows the time consumption. According to the line graph the SVR consumes higher time as compared to SVM. Thus the SVM shows efficiency as compared to SVR.

CONCLUSION & FUTURE WORK
The proposed work is aimed to find an efficient and accurate method for analyzing the Amazon product reviews. Additionally aim to classify the reviews to recognize which of the reviews are potentially negative or positive. This chapter offers the summary of the efforts made and the promising future extensions.

Conclusion
The proposed work is an investigation of the sentiment based text classification. The classification of text is a problem of text data mining but the classification of the text according to the text sentiments or emotions are known as the NLP (Natural Language Processing). In this work the application of NLP is demonstrated for identifying the reviews about a product offered by some e-commerce. Now in these days the NLP is being applied in various real world problems such as social media text analysis, student help and support system, branding of product and various other business and research subjects. The key application of the sentiment based text analysis is to understand the feeling of an author who posted a block of text using machine learning and data mining algorithms. Therefore a model using the techniques of text mining and NLP is presented.
That model first refines the contents of posted reviews on the target platform. Thus review extraction and preprocessing of review text is the initial step of the proposed data model. In next process the features are computed. In this work we considered two kinds of feature set namely the TF-IDF based weights and the POS (part of speech) tags. Further we utilized with two supervised learning techniques namely SVM and SVR. Among the SVM is modified for accepting the multiclass classification problem using the One-Vs-All technique.
The trained model us to classify the raw test datasets. The classification outcomes of the test data is used for the performance assessment. The proposed model is implemented using the JAVA technology and using the WEKA machine learning library. The evaluated performance of the implemented review classification model is summarized in  The given performance summary demonstrate the proposed working model which works with SVM and one vs. all scenario is producing higher accurate results as compared to SVR based method. Additionally SVM and one vs. all method are efficient in terms of less time consumption but costly for the memory resource consumption. Therefore according to the overall performance the proposed SVM based Amazon product review classification system is an accurate and efficient technique.

Future Work
The key aim of the proposed investigation is achieved successfully. The implemented data model is a promising model which can be extended further other kinds of text analysis by using small modifications. Some essential extension ideas are provided for work in future is given as: 1. The proposed work can also be used for analyzing the consumer's sentiments in other real world applications 2. The proposed work just utilizing the NLP parser thus in near future need to explore other suitable and effective NLP tools for improving the proposed model 3. The proposed work includes the experimental datasets, in near future we are tried to experiment using the real world data.