SlideShare una empresa de Scribd logo
1 de 25
Descargar para leer sin conexión
Sentiment Classification with
        RapidMiner




 Bruno Ohana and Brendan Tierney
     DIT School of Computing
            June 2011
Our Talk

 Introduction to Sentiment Analysis
 Supervised Learning Approaches
 Case Study with RapidMiner
Motivation
 “81% of US internet users (60 of population) have
                             60%
 used the internet to perform research on a product they
 intended to purchase, as of 2007.”

 “Over 30% of US internet users have at one time
          %
 posted a comment or online review about a product or
 service they’ve purchased.”
                                             (Horrigan, 2008)
Motivation
A lot of online content is subjective in nature.
  User Generated Content: Product reviews, blog
  posts, twitter, etc.
  epinions.com, Amazon, RottenTomatoes.com.
  Sheer volume of opinion data calls for automated
  analytical methods.
Why Are Automated Methods Relevant?
 Search and Recommendation Engines.
   Show me only positive/negative/neutral.

 Market Research.
   What is being said about brand X on Twitter?

 Contextual Ad Placement.

 Mediation of online communities.
A Growing Industry




 Opinion Mining offerings
   Voice of Customer analytics
   Social Media Monitoring
   SaaS or embedded in data mining packages
Opinion Mining – Sentiment Classification
  For a given Text Document, Determine Sentiment
  Orientation
      Positive or Negative, Favorable or Unfavorable, etc.
      Binary or along a scale (e.g. 1 stars)
                                    1-5
      Data is unstructured text format. From sentence to
      document level.

Ex: Positive or Negative?
“This is by far the worst hotel experience i've ever had. the owner
  overbooked while i was staying there (even though i booked the room
  two months in advance) and made me move to another room, but that
  room wasn't even a hotel room!”
Supervised Learning for Text
  Train a classifier algorithm based on a training
  data set.
     Raw data will be text.

  Approach: Use term presence information as
  features.
     A plain text document becomes a word vector.
Supervised Learning for Text
     A word vector can be used to train a classifier.
     Building a Word Vector
           Unit of tokenization: uni/bi/n
                                 uni/bi/n-gram
           Term presence metric
            Binary, tf-idf, frequency
                       idf,
           Stemming
           Stop Words Removal


                                        Word     Train Classifier
                 Tokenize   Stemming
                                        Vector



IMDB Data Set
  (Plain Text)
Opinion Mining – Sentiment Classification
Challenges of Data Driven Approaches

  Domain dependence.
     “chuck norris” might be a good sentiment
                   ”
     predictor, but on movies only
  We lose discourse information.
     Ex: negation detection
     “This comedy is not really funny.”
  NLP techniques might help.
RapidMiner Case Study
 Sentiment Classification based on Word Vectors.

 Convert Text data to Word Vectors
   Using RapidMiner’s Text Processing Extension.

 Use it to Train/Test a Learner Model.
   Using Cross-Validation.
   Using Correlation and Parameter Testing to pick better
   features.

 Our data set is a collection of Film reviews from IMDB
 presented in (Pang et al, 2004).
RapidMiner Case Study


                        Selects document collectio
                        From a directory.



                         From text to list of tokens




                         Convert word variations t
                         Their stem.
RapidMiner Case Study
              Parameter Testing
              - Filter “top K” most correlated attributes.
              - K is a macro iterated using Parameter
                Testing.
                Testing
RapidMiner Case Study
Cross Validation - Training Step.
   Calculate Attribute Weights and Normalize.
   Pass models on “through port” to Testing.
   Select “top k” attributes by weight and train SVM.
RapidMiner Case Study
Cross Validation – Testing Step
Case Study – Adding More Features
  Pre-Computed features based on text statistics.
      Computed
     Document, Word and Sentence Sizes, Part
                                           Part-of-speech
     Presence, Stop words ratio, Syllable Count.

  Features based on scoring using a sentiment lexicon.
    (Ohana & Tierney ‘09).
    Used SentiWordNet as the Lexicon (Esuli et al, 09).

  In RapidMiner we can merge those data sets using a
  known unique ID (File name in our case).
Opinion Lexicons
  Opinion Lexicons.
    A database of terms and opinion information they carry.
     Some terms and expressions carry “a priori” opinion
     bias, relatively independent from context.
       Ex: good, excellent, bad, poor.

  To build the data set:
     Score document based on terms found.
     Total positive/negative scores.
     Per part-of-speech.
     Per document section.
Lexicon Based Approach


                                                    Document Scores
                 POS     Negation
                                        Scoring      SWN Features
                Tagger   Detection



MDB Data Set
 (Plain Text)




                                     SentiWordNet
Part of Speech Tagging

 The computer-animated comedy " shrek " is designed to be enjoyed on
                 animated
 different levels by different groups . for children , it offers imaginative
 visuals , appealing new characters mixed with a host of familiar faces ,
 loads of action and a barrage of big laughs



  The/DT computer-animated/JJ comedy/NN ''/'' shrek/NN ''/'' is/VBZ
 designed/VBN to/TO be/VB enjoyed/VBN on/IN different/JJ levels/NNS by/IN
 different/JJ groups/NNS ./. for/IN children/NNS ,/, it/PRP offers/VBZ
 imaginative/JJ visuals/NNS ,/, appealing/VBG new/JJ characters/NNS
 mixed/VBN with/IN a/DT host/NN of/IN familiar/JJ faces/NNS ,/, loads/NNS of/IN
 action/NN and/CC a/DT barrage/NN of/IN big/JJ laughs/NNS
Negation Detection

 NegEx (Chapman et al ’01).
 Look for negating expressions
   Pseudo-negations.
     “no wonder”, “no change”, “not only”
   Forward and Backward Scope.
     “don’t”, “not”, “without”, “unlikely to”, etc…
Case Study – Adding More Features
  Data Set Merging
Results - Accuracy

Average Accuracy using 10-fold Cross
                          fold Cross-validation

Method                                    Accuracy %   Feature Count
Baseline word vector                      85.39        6739
Baseline less uncorrelated attributes     85.49        1800
Document Stats (S)                        68.73        22
SentiWordNet features (SWN)               67.40        39
Merging (S) + (N)                         72.79        61
Merging Baseline + (S) + (SWN) and        86.39        1800
removing uncorrelated attributes
Opinion Mining – Sentiment Classification
    Some results from the field (IMDB data set).

Method                               Accuracy   Source
Support Vector Machines and          77.10%     (Pang et al, 2002)
Bigrams word vector
Word Vector Naïve Bayes + Parts of   77.50%     (Salvetti et al, 2004)
Speech
Support Vector Machines and          82.90%     (Pang et al, 2002)
Unigrams word vector
Unigrams + Subjectivity Detection    87.15%     (Pang et al, 2004)
SVM + stylistic features             87.95%     (Abbasi et al, 2008)
SVM + GA feature selection           95.55%     (Abbasi et al, 2008)
Results – Term Correlation

                   Terms (after Stemming)
Most Correlated    didn, georg, add, wast, bore, guess, bad, son, stupid,
                   masterpiece, perform, stereotyp, if, adventur, oscar,
                   worst, blond, mediocr
Least Correlated   already, face, which, put, same, without, someth, must
                   manag, someon, talent, get, goe, sinc, abrupt
Thank You

Más contenido relacionado

La actualidad más candente

Evaluation Datasets for Twitter Sentiment Analysis: A survey and a new datase...
Evaluation Datasets for Twitter Sentiment Analysis: A survey and a new datase...Evaluation Datasets for Twitter Sentiment Analysis: A survey and a new datase...
Evaluation Datasets for Twitter Sentiment Analysis: A survey and a new datase...
Knowledge Media Institute - The Open University
 
Tag And Tag Based Recommender
Tag And Tag Based RecommenderTag And Tag Based Recommender
Tag And Tag Based Recommender
gu wendong
 
NLP based Mining on Movie Critics
NLP based Mining on Movie Critics NLP based Mining on Movie Critics
NLP based Mining on Movie Critics
supraja reddy
 

La actualidad más candente (20)

Evaluation Datasets for Twitter Sentiment Analysis: A survey and a new datase...
Evaluation Datasets for Twitter Sentiment Analysis: A survey and a new datase...Evaluation Datasets for Twitter Sentiment Analysis: A survey and a new datase...
Evaluation Datasets for Twitter Sentiment Analysis: A survey and a new datase...
 
Sentiment analysis using naive bayes classifier
Sentiment analysis using naive bayes classifier Sentiment analysis using naive bayes classifier
Sentiment analysis using naive bayes classifier
 
Semantic Patterns for Sentiment Analysis of Twitter
Semantic Patterns for Sentiment Analysis of TwitterSemantic Patterns for Sentiment Analysis of Twitter
Semantic Patterns for Sentiment Analysis of Twitter
 
Collaborative Filtering
Collaborative FilteringCollaborative Filtering
Collaborative Filtering
 
Tag And Tag Based Recommender
Tag And Tag Based RecommenderTag And Tag Based Recommender
Tag And Tag Based Recommender
 
MTech Seminar Presentation [IIT-Bombay]
MTech Seminar Presentation [IIT-Bombay]MTech Seminar Presentation [IIT-Bombay]
MTech Seminar Presentation [IIT-Bombay]
 
Lac presentation
Lac presentationLac presentation
Lac presentation
 
Sentiment analysis of Twitter Data
Sentiment analysis of Twitter DataSentiment analysis of Twitter Data
Sentiment analysis of Twitter Data
 
Declarative analysis of noisy information networks
Declarative analysis of noisy information networksDeclarative analysis of noisy information networks
Declarative analysis of noisy information networks
 
Sentiment analyzer and opinion mining
Sentiment analyzer and opinion miningSentiment analyzer and opinion mining
Sentiment analyzer and opinion mining
 
Sentiment Analysis on Twitter
Sentiment Analysis on TwitterSentiment Analysis on Twitter
Sentiment Analysis on Twitter
 
Email Classification - Why Should it Matter to You?
Email Classification - Why Should it Matter to You?Email Classification - Why Should it Matter to You?
Email Classification - Why Should it Matter to You?
 
Question Answering System using machine learning approach
Question Answering System using machine learning approachQuestion Answering System using machine learning approach
Question Answering System using machine learning approach
 
SentiCircles for Contextual and Conceptual Semantic Sentiment Analysis of Twi...
SentiCircles for Contextual and Conceptual Semantic Sentiment Analysis of Twi...SentiCircles for Contextual and Conceptual Semantic Sentiment Analysis of Twi...
SentiCircles for Contextual and Conceptual Semantic Sentiment Analysis of Twi...
 
Summary of a Recommender Systems Survey paper
Summary of a Recommender Systems Survey paperSummary of a Recommender Systems Survey paper
Summary of a Recommender Systems Survey paper
 
sentiment analysis
sentiment analysis sentiment analysis
sentiment analysis
 
Collaborative Filtering using KNN
Collaborative Filtering using KNNCollaborative Filtering using KNN
Collaborative Filtering using KNN
 
Meta-evaluation of machine translation evaluation methods
Meta-evaluation of machine translation evaluation methodsMeta-evaluation of machine translation evaluation methods
Meta-evaluation of machine translation evaluation methods
 
NLP based Mining on Movie Critics
NLP based Mining on Movie Critics NLP based Mining on Movie Critics
NLP based Mining on Movie Critics
 
Email Classification
Email ClassificationEmail Classification
Email Classification
 

Destacado

The Role of Process Development in Automation Presentation
The Role of Process Development in Automation PresentationThe Role of Process Development in Automation Presentation
The Role of Process Development in Automation Presentation
Advent Design Corporation
 
Lean Manufacturing Brings Products Back from China
Lean Manufacturing Brings Products Back from ChinaLean Manufacturing Brings Products Back from China
Lean Manufacturing Brings Products Back from China
Advent Design Corporation
 
Implementing Automation After Making Lean Improvements
Implementing Automation After Making Lean ImprovementsImplementing Automation After Making Lean Improvements
Implementing Automation After Making Lean Improvements
Advent Design Corporation
 
Integrating Six Sigma and Lean Manufacturing the Challenges & Benefits
Integrating Six Sigma and Lean Manufacturing the Challenges & BenefitsIntegrating Six Sigma and Lean Manufacturing the Challenges & Benefits
Integrating Six Sigma and Lean Manufacturing the Challenges & Benefits
Advent Design Corporation
 
Integrated Vision System & Robot Streamline Production
Integrated Vision System & Robot Streamline ProductionIntegrated Vision System & Robot Streamline Production
Integrated Vision System & Robot Streamline Production
Advent Design Corporation
 
Applying Lean Concepts in a Warehouse Operation
Applying Lean Concepts in a Warehouse OperationApplying Lean Concepts in a Warehouse Operation
Applying Lean Concepts in a Warehouse Operation
Advent Design Corporation
 

Destacado (12)

The Role of Process Development in Automation Presentation
The Role of Process Development in Automation PresentationThe Role of Process Development in Automation Presentation
The Role of Process Development in Automation Presentation
 
Lean Manufacturing Brings Products Back from China
Lean Manufacturing Brings Products Back from ChinaLean Manufacturing Brings Products Back from China
Lean Manufacturing Brings Products Back from China
 
SEMA - 2016 Meter Farms, New Tools for AMR and AMI Meters
SEMA - 2016 Meter Farms, New Tools for AMR and AMI MetersSEMA - 2016 Meter Farms, New Tools for AMR and AMI Meters
SEMA - 2016 Meter Farms, New Tools for AMR and AMI Meters
 
Speed to Market through Program Management
Speed to Market through Program ManagementSpeed to Market through Program Management
Speed to Market through Program Management
 
Dr. Paul Houser - A vision for an ultra-high resolution integrated water cycl...
Dr. Paul Houser - A vision for an ultra-high resolution integrated water cycl...Dr. Paul Houser - A vision for an ultra-high resolution integrated water cycl...
Dr. Paul Houser - A vision for an ultra-high resolution integrated water cycl...
 
Implementing Automation After Making Lean Improvements
Implementing Automation After Making Lean ImprovementsImplementing Automation After Making Lean Improvements
Implementing Automation After Making Lean Improvements
 
Integrating Six Sigma and Lean Manufacturing the Challenges & Benefits
Integrating Six Sigma and Lean Manufacturing the Challenges & BenefitsIntegrating Six Sigma and Lean Manufacturing the Challenges & Benefits
Integrating Six Sigma and Lean Manufacturing the Challenges & Benefits
 
Integrated Vision System & Robot Streamline Production
Integrated Vision System & Robot Streamline ProductionIntegrated Vision System & Robot Streamline Production
Integrated Vision System & Robot Streamline Production
 
Designing Products for Cellular Assembly
Designing Products for Cellular AssemblyDesigning Products for Cellular Assembly
Designing Products for Cellular Assembly
 
Applying Lean Concepts in a Warehouse Operation
Applying Lean Concepts in a Warehouse OperationApplying Lean Concepts in a Warehouse Operation
Applying Lean Concepts in a Warehouse Operation
 
Facebook API
Facebook APIFacebook API
Facebook API
 
Advent Designs
Advent DesignsAdvent Designs
Advent Designs
 

Similar a RCOMM 2011 - Sentiment Classification

Mining Product Reputations On the Web
Mining Product Reputations On the WebMining Product Reputations On the Web
Mining Product Reputations On the Web
feiwin
 
Proceedings Template - WORD
Proceedings Template - WORDProceedings Template - WORD
Proceedings Template - WORD
butest
 
2005 Web Content Mining 4
2005 Web Content Mining   42005 Web Content Mining   4
2005 Web Content Mining 4
George Ang
 

Similar a RCOMM 2011 - Sentiment Classification (20)

IRJET- Survey of Classification of Business Reviews using Sentiment Analysis
IRJET- Survey of Classification of Business Reviews using Sentiment AnalysisIRJET- Survey of Classification of Business Reviews using Sentiment Analysis
IRJET- Survey of Classification of Business Reviews using Sentiment Analysis
 
Supervised Sentiment Classification using DTDP algorithm
Supervised Sentiment Classification using DTDP algorithmSupervised Sentiment Classification using DTDP algorithm
Supervised Sentiment Classification using DTDP algorithm
 
Mining Product Reputations On the Web
Mining Product Reputations On the WebMining Product Reputations On the Web
Mining Product Reputations On the Web
 
Proceedings Template - WORD
Proceedings Template - WORDProceedings Template - WORD
Proceedings Template - WORD
 
A SURVEY OF SENTIMENT CLASSSIFICTION TECHNIQUES
A SURVEY OF SENTIMENT CLASSSIFICTION TECHNIQUESA SURVEY OF SENTIMENT CLASSSIFICTION TECHNIQUES
A SURVEY OF SENTIMENT CLASSSIFICTION TECHNIQUES
 
REVIEW PPT.pptx
REVIEW PPT.pptxREVIEW PPT.pptx
REVIEW PPT.pptx
 
Analyse de sentiment et classification par approche neuronale en Python et Weka
Analyse de sentiment et classification par approche neuronale en Python et WekaAnalyse de sentiment et classification par approche neuronale en Python et Weka
Analyse de sentiment et classification par approche neuronale en Python et Weka
 
Imtiaz khan data_science_analytics
Imtiaz khan data_science_analyticsImtiaz khan data_science_analytics
Imtiaz khan data_science_analytics
 
Sentiment+Analysis.ppt
Sentiment+Analysis.pptSentiment+Analysis.ppt
Sentiment+Analysis.ppt
 
DEEP LEARNING SENTIMENT ANALYSIS OF AMAZON.COM REVIEWS AND RATINGS
DEEP LEARNING SENTIMENT ANALYSIS OF AMAZON.COM REVIEWS AND RATINGSDEEP LEARNING SENTIMENT ANALYSIS OF AMAZON.COM REVIEWS AND RATINGS
DEEP LEARNING SENTIMENT ANALYSIS OF AMAZON.COM REVIEWS AND RATINGS
 
From Linked Data to Semantic Applications
From Linked Data to Semantic ApplicationsFrom Linked Data to Semantic Applications
From Linked Data to Semantic Applications
 
Project prSentiment Analysis of Twitter Data Using Machine Learning Approach...
Project prSentiment Analysis  of Twitter Data Using Machine Learning Approach...Project prSentiment Analysis  of Twitter Data Using Machine Learning Approach...
Project prSentiment Analysis of Twitter Data Using Machine Learning Approach...
 
Veda Semantics - introduction document
Veda Semantics - introduction documentVeda Semantics - introduction document
Veda Semantics - introduction document
 
TasteWeights: Visual Interactive Hybrid Recommendations
TasteWeights: Visual Interactive Hybrid RecommendationsTasteWeights: Visual Interactive Hybrid Recommendations
TasteWeights: Visual Interactive Hybrid Recommendations
 
Overfitting and-tbl
Overfitting and-tblOverfitting and-tbl
Overfitting and-tbl
 
Sentiment Analysis Using Hybrid Approach: A Survey
Sentiment Analysis Using Hybrid Approach: A SurveySentiment Analysis Using Hybrid Approach: A Survey
Sentiment Analysis Using Hybrid Approach: A Survey
 
A Multifaceted Look At Faceting - Ted Sullivan, Lucidworks
A Multifaceted Look At Faceting - Ted Sullivan, LucidworksA Multifaceted Look At Faceting - Ted Sullivan, Lucidworks
A Multifaceted Look At Faceting - Ted Sullivan, Lucidworks
 
Fyp ca2
Fyp ca2Fyp ca2
Fyp ca2
 
Siddhesh Dilip Rumde Resume
Siddhesh Dilip Rumde ResumeSiddhesh Dilip Rumde Resume
Siddhesh Dilip Rumde Resume
 
2005 Web Content Mining 4
2005 Web Content Mining   42005 Web Content Mining   4
2005 Web Content Mining 4
 

Último

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 

Último (20)

The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 

RCOMM 2011 - Sentiment Classification

  • 1. Sentiment Classification with RapidMiner Bruno Ohana and Brendan Tierney DIT School of Computing June 2011
  • 2. Our Talk Introduction to Sentiment Analysis Supervised Learning Approaches Case Study with RapidMiner
  • 3. Motivation “81% of US internet users (60 of population) have 60% used the internet to perform research on a product they intended to purchase, as of 2007.” “Over 30% of US internet users have at one time % posted a comment or online review about a product or service they’ve purchased.” (Horrigan, 2008)
  • 4. Motivation A lot of online content is subjective in nature. User Generated Content: Product reviews, blog posts, twitter, etc. epinions.com, Amazon, RottenTomatoes.com. Sheer volume of opinion data calls for automated analytical methods.
  • 5. Why Are Automated Methods Relevant? Search and Recommendation Engines. Show me only positive/negative/neutral. Market Research. What is being said about brand X on Twitter? Contextual Ad Placement. Mediation of online communities.
  • 6. A Growing Industry Opinion Mining offerings Voice of Customer analytics Social Media Monitoring SaaS or embedded in data mining packages
  • 7. Opinion Mining – Sentiment Classification For a given Text Document, Determine Sentiment Orientation Positive or Negative, Favorable or Unfavorable, etc. Binary or along a scale (e.g. 1 stars) 1-5 Data is unstructured text format. From sentence to document level. Ex: Positive or Negative? “This is by far the worst hotel experience i've ever had. the owner overbooked while i was staying there (even though i booked the room two months in advance) and made me move to another room, but that room wasn't even a hotel room!”
  • 8. Supervised Learning for Text Train a classifier algorithm based on a training data set. Raw data will be text. Approach: Use term presence information as features. A plain text document becomes a word vector.
  • 9. Supervised Learning for Text A word vector can be used to train a classifier. Building a Word Vector Unit of tokenization: uni/bi/n uni/bi/n-gram Term presence metric Binary, tf-idf, frequency idf, Stemming Stop Words Removal Word Train Classifier Tokenize Stemming Vector IMDB Data Set (Plain Text)
  • 10. Opinion Mining – Sentiment Classification Challenges of Data Driven Approaches Domain dependence. “chuck norris” might be a good sentiment ” predictor, but on movies only We lose discourse information. Ex: negation detection “This comedy is not really funny.” NLP techniques might help.
  • 11. RapidMiner Case Study Sentiment Classification based on Word Vectors. Convert Text data to Word Vectors Using RapidMiner’s Text Processing Extension. Use it to Train/Test a Learner Model. Using Cross-Validation. Using Correlation and Parameter Testing to pick better features. Our data set is a collection of Film reviews from IMDB presented in (Pang et al, 2004).
  • 12. RapidMiner Case Study Selects document collectio From a directory. From text to list of tokens Convert word variations t Their stem.
  • 13. RapidMiner Case Study Parameter Testing - Filter “top K” most correlated attributes. - K is a macro iterated using Parameter Testing. Testing
  • 14. RapidMiner Case Study Cross Validation - Training Step. Calculate Attribute Weights and Normalize. Pass models on “through port” to Testing. Select “top k” attributes by weight and train SVM.
  • 15. RapidMiner Case Study Cross Validation – Testing Step
  • 16. Case Study – Adding More Features Pre-Computed features based on text statistics. Computed Document, Word and Sentence Sizes, Part Part-of-speech Presence, Stop words ratio, Syllable Count. Features based on scoring using a sentiment lexicon. (Ohana & Tierney ‘09). Used SentiWordNet as the Lexicon (Esuli et al, 09). In RapidMiner we can merge those data sets using a known unique ID (File name in our case).
  • 17. Opinion Lexicons Opinion Lexicons. A database of terms and opinion information they carry. Some terms and expressions carry “a priori” opinion bias, relatively independent from context. Ex: good, excellent, bad, poor. To build the data set: Score document based on terms found. Total positive/negative scores. Per part-of-speech. Per document section.
  • 18. Lexicon Based Approach Document Scores POS Negation Scoring SWN Features Tagger Detection MDB Data Set (Plain Text) SentiWordNet
  • 19. Part of Speech Tagging The computer-animated comedy " shrek " is designed to be enjoyed on animated different levels by different groups . for children , it offers imaginative visuals , appealing new characters mixed with a host of familiar faces , loads of action and a barrage of big laughs The/DT computer-animated/JJ comedy/NN ''/'' shrek/NN ''/'' is/VBZ designed/VBN to/TO be/VB enjoyed/VBN on/IN different/JJ levels/NNS by/IN different/JJ groups/NNS ./. for/IN children/NNS ,/, it/PRP offers/VBZ imaginative/JJ visuals/NNS ,/, appealing/VBG new/JJ characters/NNS mixed/VBN with/IN a/DT host/NN of/IN familiar/JJ faces/NNS ,/, loads/NNS of/IN action/NN and/CC a/DT barrage/NN of/IN big/JJ laughs/NNS
  • 20. Negation Detection NegEx (Chapman et al ’01). Look for negating expressions Pseudo-negations. “no wonder”, “no change”, “not only” Forward and Backward Scope. “don’t”, “not”, “without”, “unlikely to”, etc…
  • 21. Case Study – Adding More Features Data Set Merging
  • 22. Results - Accuracy Average Accuracy using 10-fold Cross fold Cross-validation Method Accuracy % Feature Count Baseline word vector 85.39 6739 Baseline less uncorrelated attributes 85.49 1800 Document Stats (S) 68.73 22 SentiWordNet features (SWN) 67.40 39 Merging (S) + (N) 72.79 61 Merging Baseline + (S) + (SWN) and 86.39 1800 removing uncorrelated attributes
  • 23. Opinion Mining – Sentiment Classification Some results from the field (IMDB data set). Method Accuracy Source Support Vector Machines and 77.10% (Pang et al, 2002) Bigrams word vector Word Vector Naïve Bayes + Parts of 77.50% (Salvetti et al, 2004) Speech Support Vector Machines and 82.90% (Pang et al, 2002) Unigrams word vector Unigrams + Subjectivity Detection 87.15% (Pang et al, 2004) SVM + stylistic features 87.95% (Abbasi et al, 2008) SVM + GA feature selection 95.55% (Abbasi et al, 2008)
  • 24. Results – Term Correlation Terms (after Stemming) Most Correlated didn, georg, add, wast, bore, guess, bad, son, stupid, masterpiece, perform, stereotyp, if, adventur, oscar, worst, blond, mediocr Least Correlated already, face, which, put, same, without, someth, must manag, someon, talent, get, goe, sinc, abrupt