I was wondering if anybody knew of any good Perl modules and/or Java classes for sentiment analysis. I have read about LingPipe, but the program would eventually need to be used for commercial use so something open-source would be better. I also looked into GATE, but their documentation on sentiment analysis is sparse at best.
3 Answers
Have a look at Rate_Sentiment in the WebService::GoogleHack module at CPAN. There's more information about the project at SourceForge.

- 4,672
- 1
- 19
- 31
-
1I saw this, but it doesn't have any ratings and I was worried about scalability since it mentions using the Google API. Do you have any experience with it yourself? – user387049 Nov 15 '10 at 19:10
-
No, I've never used it. However, [Ted Pedersen](http://www.d.umn.edu/~tpederse/) seems to be one of the authors. He's a [pretty major figure](http://search.cpan.org/~tpederse/) in Perl NLP. – Pedro Silva Nov 15 '10 at 19:14
I just added a sentiment analysis library to my Social Media Analytics Research Toolkit. The blog post / announcement is here. It's in R, not in Java, but there's a good interface between R and Java in the toolkit, so you can write your "glue code" in Java to call the R library. There's also an R - Python interface in the toolkit.
There's supposed to be an R / Perl interface too, but I haven't been able to contact the maintainer about bugs, so I took it out of the build.

- 31
- 1
You might want to take a look at LingPipe (Java) based sentiment analysis at:
http://alias-i.com/lingpipe/demos/tutorial/sentiment/read-me.html
and GATE (http://gate.ac.uk/sentiment/)
For more generalized NLP parsers see The Stanford parser (http://nlp.stanford.edu/software/lex-parser.shtml), NLTK (Python) (http://www.nltk.org/), etc.
I'm not aware of any similar open source tools for Perl, although there are some good basic references out there to get you started, e.g.:
Billisoly, R. (2008) Practical Text Mining with Perl. Wiley. ISBN 978-0-470-17643-6.

- 69
- 3