main

57
CHAPTER 1 INTRODUCTION 1.1GENERAL In the recent years the use of e-commerce is grown very rapidly. Most retail Websites promotes consumers to write their feedbacks about products to express their opinions on various aspects of the products. An aspect, which can also be called as feature, refers to a component or an attribute of a certain product. A sample review “The sound quality of Sony Experia is amazing." reveals positive opinion on the aspect “sound quality" of product Sony Experia. Many forum Websites also provide a platform for consumers to post reviews on number of products. For example, CNet.com involves more than seven million product reviews; These numerous consumer reviews contain rich and valuable knowledge, which is becoming an important resource for both consumers and firms. Before purchasing a product, consumers commonly seek quality information from online reviews and firms can use these reviews as feedbacks for better product development, consumer relationship management and marketing. Generally, a product may have number of aspects. For example, a Smart Phone has hundreds of aspects such as “screen size," “camera," “memory size," ”sound quality.” one may say that some aspects are more important than the others, and have strong influence on the consumers’ decision making as well as firms’ product development strategies. For example, some aspects of Smart Phone .Hence, the identification of important product aspects plays an essential role in improving the usability of reviews which is beneficial to both consumers and firms. Consumers can easily make purchasing decision by paying attention to the important aspects, while firms can focus on the improvement of product quality so that product reputation is enhanced. However, manual identification of important aspects is impractical. Therefore, an approach to automatically identify the important aspects is highly demanded. Motivated by the above observations, we made a 1

Upload: techfi

Post on 12-Jul-2016

4 views

Category:

Documents


1 download

DESCRIPTION

product

TRANSCRIPT

Page 1: Main

CHAPTER 1

INTRODUCTION

1.1GENERAL

In the recent years the use of e-commerce is grown very rapidly. Most retail

Websites promotes consumers to write their feedbacks about products to express their

opinions on various aspects of the products. An aspect, which can also be called as

feature, refers to a component or an attribute of a certain product. A sample review

“The sound quality of Sony Experia is amazing." reveals positive opinion on the aspect

“sound quality" of product Sony Experia. Many forum Websites also provide a platform

for consumers to post reviews on number of products. For example, CNet.com involves

more than seven million product reviews; These numerous consumer reviews contain

rich and valuable knowledge, which is becoming an important resource for both

consumers and firms. Before purchasing a product, consumers commonly seek quality

information from online reviews and firms can use these reviews as feedbacks for better

product development, consumer relationship management and marketing. Generally, a

product may have number of aspects. For example, a Smart Phone has hundreds of

aspects such as “screen size," “camera," “memory size," ”sound quality.” one may say

that some aspects are more important than the others, and have strong influence on the

consumers’ decision making as well as firms’ product development strategies. For

example, some aspects of Smart Phone .Hence, the identification of important product

aspects plays an essential role in improving the usability of reviews which is beneficial

to both consumers and firms. Consumers can easily make purchasing decision by

paying attention to the important aspects, while firms can focus on the improvement of

product quality so that product reputation is enhanced. However, manual identification

of important aspects is impractical. Therefore, an approach to automatically identify the

important aspects is highly demanded. Motivated by the above observations, we made a

1

Page 2: Main

survey on different techniques used to find important product aspects automatically

from online consumer reviews.

1.2 OBJECTIVE

Consumers can easily make purchasing decision by paying attention to the

important aspects, while firms can focus on the improvement of product quality so that

product reputation is enhanced. However, manual identification of important aspects is

impractical. Therefore, an approach to automatically identify the important aspects is

highly demanded.

1.3 EXISTING SYSTEM

Existing techniques for aspect identification include supervised and unsupervised

methods. Supervised method learns an extraction model from a collection of labeled

reviews. The extraction model is used to identify aspects in new reviews. Unsupervised

methods have emerged recently and they assumed that product aspects are nouns and

noun phrases. The most informative content generally refers to the “most frequent" or

the “most favorably positioned" content from original review.

1.3.1 DISADVANTAGES OF EXISTING SYSTEM

1. The reviews are disorganized, leading to difficulties in information

navigation and knowledge acquisition.

2. The frequency-based solution is not able to identify the truly important

aspects of products which may lead to decrease in efficiency of the review.

2

Page 3: Main

CHAPTER 2

LITERATURE SURVEY

A literature survey represents a study of previously existing material

on the topic of report.

2.1 “Sentiment classification of reviews using SentiWordNet,” by B. Ohana and

B. Tierney.

The product aspect ranking is to predict the ratings on individual aspects. Wang

developed a latent aspect rating analysis model, which aims to infer reviewer’s latent

opinions on each aspect and the relative emphasis on different aspects. This work

concentrates on aspect-level opinion estimation and reviewer rating behavior analysis,

rather than on aspect ranking. Snyder and Barzilay formulated a multiple aspect ranking

problem. Justin Martineau and Tim Finin present Delta TFIDF, a general purpose

technique to efficiently weight word scores. This technique calculate the value of aspect

in document but does not take into account the frequency of words associated with

aspect with it.

2.2 “A survey of text summarization extractive techniques,”by V. Gupta and

G. S. Lehal.

In contrast, unsupervised approaches automatically extract product aspects from

customer reviews without using training examples. Hu and Liu's works [5, 6] focuses

on association rule mining based on the Apriori algorithm to mine frequent itemsets as

explicit product aspects. In association rule mining, the algorithm does not consider the

position of the words in the sentence. In order to remove incorrect frequent aspects, two

types of pruning criteria were used: compactness and redundancy pruning. The

technique isefficient which does not require the use of training examples or predefined

sets of domain-independent extraction patterns.

3

Page 4: Main

2.3 “Convergence of alternating optimization”, by J. C. Bezdek and R. J.

Hathaway

Existing product aspect identification techniques can be broadly classified into

two main approaches: supervised and unsupervised. Supervised learning technique

learns an extraction model which is called as aspect extractor, that aspect extractor is

then used to identify aspects in new reviews. For this task Hidden Markov Models and

Conditional Random Fields, Maximum Entropy, Class Association Rules and Naive

Bayes Classifier approaches have been used. Wong and Lam used a supervised learning

technique to train an aspect extractor.

2.4 “A survey of text summarization extractive techniques,”by V. Gupta and G. S.

Lehal,

Aspect sentiment classification can be done by using two approaches first

Lexicon based approach and second supervise learning approach. Lexicon based

approach is typically unsupervised. Lexicon consists of list of sentiment words, which

may be positive or negative. This method usually employs a bootstrap strategy to

generate high quality Lexicon. Hu and Liu have used this lexicon based method. They

obtained the sentimental lexicon by using synonym/antonym relation defined in

WordNet to bootstrap the seed word set. Hu’s method is improved by addressing two

issues: opinion of sentiment word would be content sensitive and conflict in review.

They derived the lexicon by using some constraints.

4

Page 5: Main

CHAPTER 3

SYSTEM ENGINEERING

3.1 PROPOSED SYSTEM

A product aspect ranking framework to automatically identify the important

aspects of products from numerous consumer reviews. The consumer reviews of a

product identify the aspects in the reviews and then analyze consumer opinions on the

aspects via a sentiment classifier. The ratings from different Websites separately, instead

of performing a uniform normalization. This strategy is expected to alleviate the

influence of the rating variance among different Websites an overall rating. The Pros

and Cons reviews are used to identify the aspects by extracting the frequent noun terms

in the reviews. Document-level sentiment classification and extractive review

significant performance improvements, which demonstrate the capacity of product

aspect ranking in facilitating real-world applications.We develop a probabilistic aspect

ranking algorithm to infer the importance of various aspects by simultaneously

exploiting aspect frequency and the influence of consumers’ opinions given to each

aspect over their overall opinions on the product.

3.1.1 ADVANTAGES OF PROPOSED SYSTEM

1. Identifies important aspects based on the product, which increases the efficiency

of the reviews.

2. The proposed framework and its components are domain-independent.

5

Page 6: Main

3.2 SYSTEM ARCHITECTURE

Fig 3.2 System architecture of proposed ststem

3.3 LIST OF MODULES

This project consists of mainly four modules.

1. Admin module,

2. Aspect Identification Module,

3. Sentiment Classification on Product Aspect,

4. Aspect Ranking.

3.4 MODULE DESCRIPTION

3.4.1 ADMIN MODULE

Admin will create all types of product Categories. In these Product categories we

will deal with only the electronic items like Mobile Phones, Laptops, and Cameras.

Besides the Admin will upload all the type of products based on categories respectively.

In that we divide product into product aspects to store and retrieve in the server.

6

Page 7: Main

3.4.2 PRODUCT ASPECT IDENTIFICATION

The consumer reviews are composed in different formats on different forum

Websites. The Websites like CNet.com require consumers to give an overall rating on

the product that describe concise positive and negative opinions on some product

aspects, as well as write a paragraph of entire review in free text. Some Websites,

example, Viewpoints.com, only ask for an overall rating and a paragraph of free-text

review. The others website like Reevoo.com just require entire rating and some concise

positive and negative opinions on certain aspects. For the Pros and Cons reviews,

identify the aspects by extracting the frequently occurred nouns in the consumer

reviews. For free text reviews, a straightforward solution is to apply an existing aspect

identification approach.

3.4.3 SENTIMENT CLASSIFICATION ON PRODUCT ASPECT

The task of analyzing the sentiments expressed on aspects is called as aspect-

level sentiment classification in literature. Exiting techniques include the supervised

learning approaches and the lexicon-based approaches that are typically unsupervised.

The lexicon-based methods utilize a sentiment lexicon has a list of sentiment words,

phrases and idioms, to determine the sentiment orientation on each aspect. While these

methods are easy to implement, their performance relies heavily on the quality of the

sentiment lexicon. Beyond this, the supervised learning methods train a sentiment

classifier based on training corpus. The classifier is then used to anticipate the sentiment

on each aspect.

3.4.4 ASPECT RANKING

Propose product aspect ranking frameworks which identify the main aspects of

products automatically from enormous consumer reviews. Develop an algorithm for

probabilistic aspect ranking to identify the importance of different aspects by

simultaneously exploiting aspect frequency and the influence of consumer’s opinions

given to every aspect over their overall opinions on the product. Demonstrate the

7

Page 8: Main

strength of aspect ranking in real-world applications. Excellent performance

improvements are obtained on applications of document-level sentiment classification

and their extractive review summarization by use of aspect ranking.

3.5 ALGORITHM

PROBABILISTIC ASPECT RANKING ALGORITHM

Terms used in Algorithm

1.D={r1, r2,r3…rn} be the set of reviews.

2.Ak= {a1, a2, a3,…… an} be the set of aspect

3.Ca,D is the number of times aspect term a occurs in review dataset D.

4.Pa is the number of comments in the positively labeled set with aspect term a.

5.|P| is the number of comments in the positively labeled set.

6.Na is the number of comments in the negatively labeled set with aspect term a.

7.|N| is the number of comments in the negatively labeled set.

8.Va,D is the feature value for aspect term a in review dataset D.

9.Let Φ = set of positive words

10. Φ= {P1, P2, P3 ... Pn}

11. Let ψ = set of negative words

12. ψ ={N1, N2, N3 ... Nn} 13. ( )=probability of Φ

14.

=probability of ψ

15. ω weight of aspect a

Calculate the value of aspect a,given by

8

Page 9: Main

Calculate the occurrence probability of each positively opinionated word

Calculate the occurrence probability of each negatively opinionated word

Calculate weight,

Page 10: Main

9

Page 11: Main

CHAPTER 4

SYSTEM REQUIREMENTS

4.1 FUNCTIONAL REQUIREMENTS

A functional requirement defines a function of a software system or its

components. A function is described as the set of inputs, the behavior and the outputs.

Functional requirement may be calculations, technical details, data manipulation and

other specific functionalities that show how a use case is to be full filled. They are

supported by non-functional requirements, which impose constraints on the design or

implementation.

4.2 NON-FUNCTIONAL REQUIREMENTS

Non-functional requirements are requirements that specify criteria that can be

used to judge the operation of the system, rather than specific behaviors. Non-functional

requirements are often called qualities of system.

4.3 HARDWARE REQUIREMENTS

System : Pentium IV 2.4 GHz.

Hard Disk : 40 GB.

Floppy Drive : 1.44 Mb.

Monitor : 15 VGA Colour.

Mouse : Logitech.

Ram : 512 Mb.

4.4 SOFTWARE REQUIREMENTS

Operating system : Windows XP/7.

Coding Language : PHP

Tool : Notepad++

Database : SQL SERVER 2008

10

Page 12: Main

CHAPTER 5

DESIGN ENGINEERING

5.1 USECASE DIAGRAMS

Use case diagrams model behavior within a system and helps the developers

understand of what the user require. The stick man represents what’s called an actor.

Use case diagram can be useful for getting an overall view of the system and clarifying

that can do and more importantly what they can’t do.

Fig 5.1 Usecase diagram of proposed system

Use case diagram consists of use cases and actors and shows the interaction between the

use case and actors.

1. The purpose is to show the interactions between the use case and actor.

2. To represent the system requirements from user’s perspective.

3. An actor could be the end-user of the system or an external system.

11

Page 13: Main

5.2 SEQUENCE DIAGRAM

Sequence diagram and collaboration diagram are called INTERACTION

DIAGRAMS. An interaction diagram shows an interaction, consisting of set of objects

and their relationship including the messages that may be dispatched among them.

A sequence diagram is an introduction that empathizes the time ordering of

messages. Graphically a sequence diagram is a table that shows objects arranged along

the X-axis and messages ordered in increasing time along the Y-axis.

Fig 5.2 Sequence diagram of proposed system

5.3 CLASS DIAGRAM

Class is nothing but a structure that contains both variables and methods. The

Class Diagram shows a set of classes, interfaces, and collaborations and their relating

ships. There is most common diagram in modeling the object oriented systems and are

used to give the static view of a system. It shows the dependency between the classes

Page 14: Main

12

Page 15: Main

that can be used in our system. The interactions between the modules or classes of our

projects are shown below. Each block contains Class Name, Variables and Methods.

Class Diagram for User:

Class Diagram for Admin:

Fig 5.3 class diagram of proposed system

5.4 ACTIVITY DIAGRAM

Activity diagram is another important diagram in UML to describe dynamic

aspects of the system.Activity diagram is basically a flow chart to represent the flow

form one activity to another activity. The activity can be described as an operation of

the system.So the control flow is drawn from one operation to another. This flow can be

sequential, branched or concurrent. Activity diagrams deals with all type of flow control

by using different elements like fork, join etc.

Page 16: Main

13

Page 17: Main

(a)(b)

Fig 5.4 (a) activity diagrams for user, (b) activity diagrams for admin

14

Page 18: Main

CHAPTER 6

DEVELOPMENT TOOLS

6.1 INTRODUCTION TO HTML FRAMEWORK

HyperText Markup Language, commonly referred to as HTML, is the

standard markup language used to create web pages. Along with CSS, and JavaScript,

HTML is a cornerstone technology used to create web pages, as well as to create user

interfaces for mobile and web applications. Web browsers can read HTML files and

render them into visible or audible web pages. HTML describes the structure of

a website semantically along with cues for presentation, making it a markup language,

rather than a programming language.

HTML elements form the building blocks of HTML pages. HTML

allows images and other objects to be embedded and it can be used to create interactive

forms. It provides a means to create structured documents by denoting structural

semantics for text such as headings, paragraphs, lists, links, quotes and other items.

HTML elements are delineated by tags, written using angle brackets. Tags such as

<img /> and <input /> introduce content into the page directly. Others such as

<p>...</p> surround and provide information about document text and may include

other tags as sub-elements. Browsers do not display the HTML tags, but use them to

interpret the content of the page.

HTML can embed scripts written in languages such as JavaScript which affect

the behavior of HTML web pages. HTML markup can also refer the browser to

Cascading Style Sheets (CSS) to define the look and layout of text and other material

15

Page 19: Main

6.2 CASCADING STYLE SHEETS (CSS)

CSS is a style sheet language used for describing the presentation of a document

written in a markup language. Although most often used to set the visual style of web

pages and user interfaces written in HTML and XHTML, the language can be applied

to any XML document, including plain XML, SVG andXUL, and is applicable to

rendering in speech, or on other media. Along with HTML and JavaScript, CSS is a

cornerstone technology used by most websites to create visually engaging webpages,

user interfaces for web applications, and user interfaces for many mobile applications.

CSS is designed primarily to enable the separation of document content from

document presentation, including aspects such as the layout, colors, and fonts. This

separation can improve content accessibility, provide more flexibility and control in the

specification of presentation characteristics, enable multiple HTML pages to share

formatting by specifying the relevant CSS in a separate .css file, and reduce complexity

and repetition in the structural content, such as semantically insignificant tables that

were widely used to format pages before consistent CSS rendering was available in all

major browsers. CSS makes it possible to separate presentation instructions from the

HTML content in a separate file or style section of the HTML file. For each matching

HTML element, it provides a list of formatting instructions. For example, a CSS rule

might specify that "all heading 1 elements should be bold", leaving pure semantic

HTML markup that asserts "this text is a level 1 heading" without formatting code such

as a<bold> tag indicating how such text should be displayed.

This separation of formatting and content makes it possible to present the same

markup page in different styles for different rendering methods, such as on-screen, in

print, by voice (when read out by a speech-based browser or screen reader) and on

Braille-based, tactile devices. It can also be used to display the web page differently

depending on the screen size or device on which it is being viewed. Although the author

of a web page typically links to a CSS file within the markup file, readers can specify a16

Page 20: Main

different style sheet, such as a CSS file stored on their own computer, to override the

one the author has specified. If the author or the reader did not link the document to a

style sheet, the default style of the browser will be applied. Another advantage of CSS

is that aesthetic changes to the graphic design of a document (or hundreds of

documents) can be applied quickly and easily, by editing a few lines in one file, rather

than by a laborious (and thus expensive) process of crawling over every document line

by line, changing markup.

The CSS specification describes a priority scheme to determine which style rules

apply if more than one rule matches against a particular element. In this so-called

cascade, priorities (or weights) are calculated and assigned to rules, so that the results

are predictable.

6.3 MYSQL SERVER

MYSQL is an open-source relational database management

system (RDBMS);[6] in July 2013, it was the world's second most widely used RDBMS,

and the most widely used open-source client–server model RDBMS. It is named after co-

founder Michael Widenius's daughter, My. The SQL acronym stands for Structured Query

Language. The MYSQL development project has made its source code available under the

terms of the GNU General Public License, as well as under a variety of proprietary

agreements. MYSQL was owned and sponsored by a single for- profit firm, the Swedish

company MYSQL AB, now owned by Oracle Corporation. For proprietary use, several

paid editions are available, and offer additional functionality.

6.4 PHP

PHP is a server-side scripting language designed for web development but also

used as a general-purpose programming language. Originally created by Rasmus

Lerdorf in 1994, the PHP reference implementation is now produced by The PHP

17

Page 21: Main

Group. PHP originally stood for Personal Home Page, but it now stands for the

recursive backronym PHP: Hypertext Preprocessor.

PHP code may be embedded into HTML code, or it can be used in combination

with various web template systems, web content management system and web

frameworks. PHP code is usually processed by a PHP interpreter implemented as

a module in the web server or as a Common Gateway Interface (CGI) executable. The

web server combines the results of the interpreted and executed PHP code, which may

be any type of data, including images, with the generated web page. PHP code may also

be executed with a command-line interface (CLI) and can be used to

implement standalone graphical applications.

The standard PHP interpreter, powered by the Zend Engine, is free

software released under the PHP License. PHP has been widely ported and can be

deployed on most web servers on almost every operating system and platform, free of

charge.

The PHP language evolved without a written formal specification or standard

until 2014, leaving the canonical PHP interpreter as a de facto standard. Since 2014

work has gone on to create a formal PHP specification.

6.5 ANGULAR JAVA SCRIPT

Angular JS (commonly referred to as "Angular" or "Angular.js") is an open-

source web application framework mainly maintained by Google and by a community

of individuals and corporations to address many of the challenges encountered in

developing single-page applications. It aims to simplify both the development and the

testing of such applications by providing a framework for client-side model–view–

controller (MVC) and model–view–view model(MVVM) architectures, along with

components commonly used in rich Internet applications.

The Angular JS framework works by first reading the HTML page, which has

embedded into it additional custom tag attributes. Angular interprets those attributes as18

Page 22: Main

directives to bind input or output parts of the page to a model that is represented by

standard JavaScript variables. The values of those JavaScript variables can be manually

set within the code, or retrieved from static or dynamic JSON resources.

According to JavaScript analytics service Libscore, Angular JS is used on the

websites of Wolfram Alpha, NBC, Walgreens, Intel, Sprint, ABC News, and

approximately 8,400 other sites out of 1 million tested in July 2015.

Angular JS is the frontend part of the MEAN stack, consisting

of MongoDB database, Express.js web application server framework, Angular.js itself,

and Node.js runtime environment.

19

Page 23: Main

CHAPTER 7

IMPLEMENTATION

7.1 CODING

Test_count.php

<?php

/*********************

1*** Nandhini S *****

2*** Sep 9, 2015 ****

**********************/

/* Following code will match user login credentials

*/ // array for JSON response

$response = array();

// include db connect class

require_once __DIR__ .

'/db_connect.php'; // connecting to db

$db = new DB_CONNECT();

$get_word = "Good";

// get results from student table

$result = mysql_query("SELECT * FROM review_rating WHERE site=2 AND

product='samsung'");

// check for empty result

if(mysql_num_rows($result))

{

$response = array();

while($Rating = mysql_fetch_array($result))

{

20

Page 24: Main

$rating = array();

$rating = $Rating["review_comments"];

array_push($response,$rating);

}

//echo json_encode($response);

$string = implode($response);

$count = substr_count($string,"".$get_word."");

$data = array();

$data["count"] = $count;

$output['data'] = array();

array_push($output['data'],$data);

echo json_encode($output);

}

?>

Db_config.php

<?php

/*********************

1*** Nandhini S *****

2*** July 6, 2015 ****

**********************/

/* All database connection variables */

define('DB_USER', "root"); // db user

define('DB_PASSWORD', ""); // db password (mention your db password here)

define('DB_DATABASE', "ranking"); // database name

define('DB_SERVER', "localhost"); // db server

21

Page 25: Main

?>

Db_connect.php

<?php

/*********************

1*** Nandhini S *****

2*** July 6, 2015 ****

**********************/

/* A class file to connect to database */

class DB_CONNECT {

// constructor

function __construct()

{ // connecting to

database $this-

>connect();

}

// destructor

function __destruct()

{ // closing db

connection $this-

>close();

}

/**

1* Function to connect with database

*/

function connect() {

1/ import database connection variables

require_once __DIR__ . '/db_config.php';

2/ Connecting to mysql database

Page 26: Main

22

Page 27: Main

$con = mysql_connect(DB_SERVER, DB_USER, DB_PASSWORD) or

die(mysql_error());

$db = mysql_select_db(DB_DATABASE) or die(mysql_error()) or die(mysql_error());

return $con;

}

/**

* Function to close db

connection */

function close() {

// closing db connection

mysql_close();

}

}

?>

Frequency.html

<html ng-

app=""> <head>

<title>Admin Panel</title>

<!-- Custom Theme files -->

<meta name="viewport" content="width=device-width, initial-

scale=1"> <meta http-equiv="Content-Type" content="text/html;

charset=utf-8" /> <!-- Custom CSS files -->

<style type="text/css">@import url("css/style.css");</style>

<link href="css/style.css" rel="stylesheet" type="text/css" media="all" />

<link href="css/bootstrap.css" rel="stylesheet" type="text/css" media="all" />

<!-- Custom JS files -->

<script type="text/javascript" src="js/jquery-1.11.0.min.js"></script>

23

Page 28: Main

<script type="text/javascript" src="js/jquery.min.js"></script>

</head>

<body ng-controller="myUserReview">

<div class="">

<div class="top">

<div class="logo">

<h1>Reviews</h1>

</div>

<div class="top-left-

grid"> <ul>

<li><a href="index.html"><h1 class="gk">Ratings</h1></a></li>

<li><a class="selected" href="frequency.html"><h1

class="questions">Frequency</h1></a></li>

<div class="clearfix"></div>

</ul>

</div>

</div>

<!-- moto --> <div

class="text">

<h1>Moto G (3rd gen)</h1>

</div>

<div class="about-right-list">

<h1>Aspect Ranking</h1>

<!-- moto site 1 -->

<table class="table table-striped">

<h1 style="color:#fff;font-weight:700;font-

size:1.2em;background:#008080;height:50px;padding:15px">Ecom Reviews</h1>

24

Page 29: Main

<form>

<div class="contact-form">

<h1>Positive & Negative Word Frequency</h1>

<input type="text" ng-model="mword1" placeholder="Enter

word"> <input type="submit" ng-click="get_mcount1()"

value="Find"> </div>

</form>

<tbody ng-hide="myVar" style="color:#555;">

<tr>

<td style="width:5%;height:auto;border:none;font-weight:700;">Count</td>

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">{{

mcount1 }}</td>

</tr>

</tbody>

<tbody style="color:#555;">

<tr ng-repeat="x in maspect1">

<td style="width:5%;height:auto;border:none;font-weight:700;">{{ x.aspect }}</td>

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">

{{ x.aspect_rating }}</td>

</tr>

</tbody>

</table>

<!-- moto site 2 -->

<table class="table table-striped">

<h1 style="color:#fff;font-weight:700;font-

size:1.2em;background:#e42217;height:50px;padding:15px"><i>mReviews</i></h1>

<form>

25

Page 30: Main

<div class="contact-form">

<h1>Positive & Negative Word Frequency</h1>

<input type="text" ng-model="mword2" placeholder="Enter

word"> <input type="submit" ng-click="get_mcount2()"

value="Find"> </div>

</form>

<tbody ng-hide="myVar">

<tr>

<td style="width:5%;height:auto;border:none;font-weight:700;">Count</td>

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">

{{ mcount2 }}</td

> </tr>

</tbody>

<tbody style="color:#555;">

<tr ng-repeat="x in maspect2">

<td style="width:5%;height:auto;border:none;font-weight:700;">{{ x.aspect }}</td>

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">

{{ x.aspect_rating }}</td>

</tr>

</tbody>

</table>

</div>

<!-- iphone -->

<div class="text">

<h1>iPhone 7</h1>

</div>

<div class="about-right-list">

26

Page 31: Main

<h1>Aspect Ranking</h1>

<!-- iphone site 1 -->

<table class="table table-striped">

<h1 style="color:#fff;font-weight:700;font-

size:1.2em;background:#008080;height:50px;padding:15px">Ecom

Reviews</h1> <form>

<div class="contact-form">

<h1>Positive & Negative Word Frequency</h1>

<input type="text" ng-model="iword1" placeholder="Enter

word"> <input type="submit" ng-click="get_icount1()"

value="Find"> </div>

</form>

<tbody ng-hide="myVar">

<tr>

<td style="width:5%;height:auto;border:none;font-weight:700;">Count</td>

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">

{{ icount1 }}</td>

</tr>

</tbody>

<tbody style="color:#555;">

<tr ng-repeat="x in iaspect1">

<td style="width:5%;height:auto;border:none;font-weight:700;">{{ x.aspect }}</td>

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">

{{ x.aspect_rating }}</td>

</tr>

</tbody>

</table>

27

Page 32: Main

<!-- iphone site 2 -->

<table class="table table-striped">

<h1 style="color:#fff;font-weight:700;font-

size:1.2em;background:#e42217;height:50px;padding:15px"><i>mReviews</i></h1>

<form>

<div class="contact-form">

<h1>Positive & Negative Word Frequency</h1>

<input type="text" ng-model="iword2" placeholder="Enter

word"> <input type="submit" ng-click="get_icount2()"

value="Find"> </div>

</form>

<tbody ng-hide="myVar">

<tr>

<td style="width:5%;height:auto;border:none;font-weight:700;">Count</td>

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">{{

icount2 }}</td>

</tr>

</tbody>

<tbody style="color:#555;">

<tr ng-repeat="x in iaspect2">

<td style="width:5%;height:auto;border:none;font-weight:700;">{{ x.aspect }}</td>

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">{{

x.aspect_rating }}</td>

</tr>

</tbody>

</table>

</div>

28

Page 33: Main

<!-- samsung -->

<div class="text">

<h1>Samsung Galaxy

Note5</h1> </div>

<div class="about-right-list">

<h1>Aspect Ranking</h1>

<!-- samsung site 1 -->

<table class="table table-striped">

<h1 style="color:#fff;font-weight:700;font-

size:1.2em;background:#008080;height:50px;padding:15px">Ecom

Reviews</h1> <form>

<div class="contact-form">

<h1>Positive & Negative Word Frequency</h1>

<input type="text" ng-model="sword1" placeholder="Enter word">

<input type="submit" ng-click="get_scount1()" value="Find">

</div>

</form>

<tbody ng-hide="myVar" style="color:#555;">

<tr>

<td style="width:5%;height:auto;border:none;font-weight:700;">Count</td>

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">{{

scount1 }}</td>

</tr>

</tbody>

<tbody style="color:#555;">

<tr ng-repeat="x in saspect1">

<td style="width:5%;height:auto;border:none;font-weight:700;">{{ x.aspect }}</td>

29

Page 34: Main

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">{{

x.aspect_rating }}</td>

</tr>

</tbody>

</table>

<!-- samsung site 2 -->

<table class="table table-striped">

<h1 style="color:#fff;font-weight:700;font-

size:1.2em;background:#e42217;height:50px;padding:15px"><i>mReviews</i></h1>

<form>

<div class="contact-form">

<h1>Positive & Negative Word Frequency</h1>

<input type="text" ng-model="sword2" placeholder="Enter word">

<input type="submit" ng-click="get_scount2()" value="Find">

</div>

</form>

<tbody ng-hide="myVar" style="color:#555;">

<tr>

<td style="width:5%;height:auto;border:none;font-weight:700;">Count</td>

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">{{

scount2 }}</td>

</tr>

</tbody>

<tbody style="color:#555;">

<tr ng-repeat="x in saspect2">

<td style="width:5%;height:auto;border:none;font-weight:700;">{{ x.aspect }}</td>

30

Page 35: Main

<td style="width:9%;height:auto;border:none;font-weight:400;text-align:center;">{{

x.aspect_rating }}</td>

</tr>

</tbody>

</table>

</div>

<script type="text/javascript" src="js/angular_data.js"></script>

<script type="text/javascript" src="js/angular-1.0.7.js"></script>

</div>

</body>

</html>

Get_iaspect.php

<?php

/*********************

1*** Nandhini S *****

2*** Sep 9, 2015 ****

**********************/

/* Following code will match user login credentials

*/ // array for JSON response

$response = array();

// include db connect class

require_once __DIR__ .

'/db_connect.php'; // connecting to db

$db = new

DB_CONNECT(); // get

results from student table

Page 36: Main

31

Page 37: Main

$result = mysql_query("SELECT AVG(camera_rating) AS Rating,

AVG(battery_rating) AS Rating1, AVG(storage_rating) AS Rating2,

AVG(price_rating) AS Rating3,

AVG(usability_rating) AS Rating4, AVG(apps_rating) AS Rating5, AVG(3g_rating) AS

Rating6 FROM review_rating WHERE site=1 AND product='iphone'");

1/ check for empty result

if(mysql_num_rows($result))

{

$AverageRating = mysql_fetch_array($result);

$rating = array();

$rating["camera_rating"] = $AverageRating["Rating"].':Camera';

$rating["battery_rating"] = $AverageRating["Rating1"].':Battery';

$rating["storage_rating"] = $AverageRating["Rating2"].':Storage';

$rating["price_rating"] = $AverageRating["Rating3"].':Price';

$rating["usability_rating"] = $AverageRating["Rating4"].':Usability';

$rating["apps_rating"] = $AverageRating["Rating5"].':Apps';

$rating["3g_rating"] = $AverageRating["Rating6"].':3G';

2/ sort value in descending order

arsort($rating); //

print_r($rating);

1/ making value to

string $string = array();

$string = implode(",",$rating);

2/ making string value to

array $array1 = array();

$array1 = explode(",",$string);

3/ count length of array

32

Page 38: Main

$len =

count($array1); $i=0;

$response['rating']=

array(); while($i<$len)

{

$array2 = array();

$array2 = explode(":",$array1[$i]);

$rating=array();

$rating["aspect_rating"] = $array2[0];

$rating["aspect"] = $array2[1];

$i++; array_push($response['rating'],

$rating);

}

echo json_encode($response);

}

?>

Get_ifrequency1.html

<?php

/*********************

1*** Nandhini S *****

2*** Sep 9, 2015 ****

**********************/

/* Following code will match user login credentials

*/ // array for JSON response

$response = array();

// include db connect class

require_once __DIR__ . '/db_connect.php';

33

Page 39: Main

// connecting to db

$db = new

DB_CONNECT(); // check for

post data

$data = json_decode(file_get_contents("php://input"));

$get_word = mysql_real_escape_string($data->word); //

get results from student table

$result = mysql_query("SELECT * FROM review_rating WHERE site=1 AND

product='iphone'");

// check for empty result

if(mysql_num_rows($result))

{

$response = array();

while($Rating = mysql_fetch_array($result))

{

$rating = array();

$rating = $Rating["review_comments"];

array_push($response,$rating);

}

//echo json_encode($response);

$string = implode($response);

$count = substr_count($string,"".$get_word."");

$data = array();

$data["count"] = $count; //

$output['data'] = array();

//array_push($output['data'],$data);

echo json_encode($data);?>

Page 40: Main

34

Page 41: Main

Get_irating1.php

<?php

/*********************

1*** Nandhini S *****

2*** Sep 9, 2015 ****

**********************/

/* Following code will match user login credentials */

// array for JSON response

$response = array();

// include db connect class

require_once __DIR__ .

'/db_connect.php'; // connecting to db

$db = new

DB_CONNECT(); // get

results from student table

$result = mysql_query("SELECT

AVG(((camera_rating+battery_rating+storage_rating+price_rating+usability_rating+ap

ps_rating+3g_rating)/0.7)/7)

AS Rating FROM review_rating WHERE site=1 AND product='iphone'");

// check for empty result

if(mysql_num_rows($result))

{

$response['rating'] = array();

while($Rating = mysql_fetch_array($result))

{

$rating = array();

$rating["rating"] = $Rating["Rating"];

array_push($response['rating'],$rating);

Page 42: Main

35

Page 43: Main

//echo json_encode($response);

$string = implode($response);

$count = substr_count($string,"".$get_word."");

$data = array();

$data["count"] = $count; //

$output['data'] = array();

//array_push($output['data'],$data);

echo json_encode($data);

}

// success //

$response["success"] = 1; //

echoing JSON response

echo json_encode($response);

}

?>

36

Page 44: Main

CHAPTER 8

SNAPSHOTS

8.1 USER LOGIN

Fig 8.1 login screen for website1

8.2 ECOM REVIEWS FOR PRODUCTS

Fig 8.2 ecom reviews

Page 45: Main

37

Page 46: Main

8.3 USER LOGIN

Fig 8.3 login screen for website2

8.4 MREVIEWS FOR PRODUCTS

Fig 8.4 mReview

Page 47: Main

38

Page 48: Main

8.5 FREQUENCY FOR ECOM REVIEWS OF PRODUCTS

Fig 8.5 frequency for ecom reviews

8.6 FREQUENCY FOR MREVIEWS OF PRODUCTS

Fig 8.6 frequency for mreviews

Page 49: Main

39

Page 50: Main

8.7 OVERALL RATING OF PRODUCTS

Fig 8.7 Overall Rating

40

Page 51: Main

CHAPTER 9

SOFTWARE TESTING

9.1 GENERAL

The purpose of testing is to discover errors. Testing is the process of trying to

discover every conceivable fault or weakness in a work product. It provides a way to

check the functionality of components, sub assemblies, assemblies and/or a finished

product It is the process of exercising software with the intent of ensuring that then

Software system meets its requirements and user expectations and does not fail in an

unacceptable manner. There are various types of test. Each test type addresses a specific

testing requirement.

9.2 UNIT TESTING

Unit testing is usually conducted as part of a combined code and unit test phase of

the software lifecycle, although it is not uncommon for coding and unit testing to be

conducted as two distinct phases.

TEST STRATEGY AND APPROACH

Field testing will be performed manually and functional tests will be written in

detail.

TEST OBJECTIVES

1. All field entries must work properly.

2. Pages must be activated from the identified link.

3. The entry screen, messages and responses must not be delayed.

FEATURES TO BE TESTED

1. Verify that the entries are of the correct format

2. No duplicate entries should be allowed

3. All links should take the user to the correct page.

41

Page 52: Main

9.3 INTEGRATION TESTING

Software integration testing is the incremental integration testing of two or more

integrated software components on a single platform to produce failures caused by

interface defects.

The task of the integration test is to check that components or software

applications, e.g. components in a software system or – one step up – software

applications at the company level – interact without error.

TEST RESULTS: All the test cases mentioned above passed successfully. No defects

encountered.

9.4 ACCEPTANCE TESTING

User Acceptance Testing is a critical phase of any project and requires significant

participation by the end user. It also ensures that the system meets the functional

requirements.

TEST RESULTS: All the test cases mentioned above passed successfully. No defects

encountered.

9.5 FUNCTIONAL TESTING

Functional tests provide systematic demonstrations that functions tested are

available as specified by the business and technical requirements, system

documentation, and user manuals.

Functional testing is centered on the following items:

Valid Input : identified classes of valid input must be accepted.

Invalid Input : identified classes of invalid input must be rejected.

Functions : identified functions must be exercised.

Output : identified classes of application outputs must be exercised.

Systems/Procedures : interfacing systems or procedures must be invoked.

42

Page 53: Main

Organization and preparation of functional tests is focused on requirements, key

functions, or special test cases. In addition, systematic coverage pertaining to identify

Business process flows; data fields, predefined processes, and successive processes

must be considered for testing. Before functional testing is complete, additional tests are

identified and the effective value of current tests is determined.

9.6 SYSTEM TESTING

System testing ensures that the entire integrated software system meets

requirements. It tests a configuration to ensure known and predictable results. An

example of system testing is the configuration oriented system integration test. System

testing is based on process descriptions and flows, emphasizing pre-driven process links

and integration points.

9.7 WHITE BOX TESTING

White Box Testing is a testing in which in which the software tester has

knowledge of the inner workings, structure and language of the software, or at least its

purpose. It is purpose. It is used to test areas that cannot be reached from a black box

level.

9.8 BLACK BOX TESTING

Black Box Testing is testing the software without any knowledge of the inner

workings, structure or language of the module being tested. Black box tests, as most

other kinds of tests, must be written from a definitive source document, such as

specification or requirements document, such as specification or requirements

document. It is a testing in which the software under test is treated, as a black box .you

cannot “see” into it. The test provides inputs and responds to outputs without

considering how the software works.

43

Page 54: Main

CHAPTER 10

APPLICATIONS

Aspect ranking is useful to a wide range of real world applications. We here

investigate its ability in two applications, i.e. document-level sentiment classification on

review documents, and extractive review summarization. Paying more attention to the

important aspect is very useful while taking decisions about product.Firms can focus on

improving and enhancing the quality of product aspect and enhance the reputation of

the product more effective. The goal of document-level sentiment classification is to

determine the overall opinion of a given review document. A review document often

expresses various opinions on multiple aspects of a certain product. The opinions on

different aspects might be in contrast to each other, and have different degree of impacts

on the overall opinion of the review document. As aforementioned, for a particular

product, there is an abundance of consumer reviews available on the internet. However,

the reviews are disorganized. It is impractical for user to grasp the overview of

consumer reviews and opinions on various aspects of a product from such enormous

reviews.

44

Page 55: Main

CONCLUSION

In this project, we have surveyed the reference paper releated to Aspect

identification, Sentiment classification. We have planned to identify the important

aspects of a product from online consumer reviews. Our supposition is that the

important aspects of a product should be the aspects that are frequently commented by

consumers and consumers opinions on the important aspects greatly pressure their

overall opinions on the product. Based on this assumption, we will try to develop an

aspect ranking algorithm which will identify the important aspects by concurrently

considering the aspect frequency and the pressure of consumers’ opinions given to each

aspect on their overall opinions. This work introduces a method to extract features from

the product reviews, classify into positive, negative or neutral and rank aspects based on

consumer's opinion. By aspect ranking, consumer's can conveniently make a wise

purchasing decisions by paying more attentions to the important aspects, while firms

can focus on improving the quality of aspects and thus enhance product reputation

effectively.

FUTURE ENCHANCEMENT

In this paper, we have surveyed the reference paper related to Aspect

identification, Sentiment classification. We have planned to identify the important

aspects of a product from online consumer reviews. Our supposition is that the

important aspects of a product should be the aspects that are frequently commented by

consumers and consumers’ opinions on the important aspects greatly pressure their

overall opinions on the product. Based on this assumption, we will try to develop an

aspect ranking algorithm which will identify the important aspects by concurrently

considering the aspect frequency and the pressure of consumers’ opinions given to each

aspect on their overall opinions.

45

Page 56: Main

REFERENCES

[1]. Zheng-JunZha, Jianxing Yu, Jinhui Tang,Meng Wang, and Tat-Seng Chua,

“Product AspectRanking and Its Applications”, IEEETRANSACTION ON

KNOWLEDGE AND DATA ENGINEERING, vol.26,no.5, May 2014

[2]. Rutuja Tikait, Ranjana Badre and Mayura Kinikar, “Product aspect Ranking

Techniques A Survey”, IJIRCCE, Nov 2014.

[3]. T. L. Wong and W. Lam, “Hot item mining and summarization from multiple

auction web sites,” in Proc. 5th IEEE ICDM,Washington, DC, USA, 2005, pp. 797–

800.

[4]. Wong, T.L., Lam, W.: Learning to extract and summarize hot item features from

multiple auction web sites. Knowl. Inf. Syst. 14(2), lexical and syntactic features. In:

Proc. of the IEEE International 143{160 (2008).

[5]. M. Hu and B. Liu, “Mining and summarizing customer reviews,” inProc. SIGKDD,

Seattle, WA, USA, 2004, pp. 168–177.

[6]. Hu, M., Liu, B.: Mining opinion features in customer reviews. In: Proc. of

American Association for Artificial Intelligence Conference. pp. 755{760 (2004).

[7]T. L. Wong and W. Lam, “Hot item mining and summarization from multiple

auction web sites,” in Proc. 5th IEEE ICDM, Washington, DC, USA, 2005, pp. 797–

800.

46

Page 57: Main

[8] O. Etzioni et al., “Unsupervised named-entity extraction from the web: An

experimental study,” J. Artif. Intell., vol. 165, no. 1, pp.91–134. Jun. 2005.

[9] Bing Liu, “Sentiment Analysis and Opinion Mining” pp.7-140,2012.

[10] V. Gupta and G. S. Lehal, “A survey of text summarization extractive techniques,”

J. Emerg. Technol. Web Intell., vol. 2, no. 3, pp. 258–268, 2010.

47