dkpro / dkpro-core

Collection of software components for natural language processing (NLP) based on the Apache UIMA framework.
https://dkpro.github.io/dkpro-core
Other
196 stars 67 forks source link

Integrate Stanford sentiment analyzer #424

Closed reckart closed 1 year ago

reckart commented 9 years ago
Stanford CoreNLP 3.3.1 and above provides a module for sentiment analysis of sentences.
It gives five scores for very negative, negative, neutral, positive, and very positive
(a distribution).

It can be easily integrated to stanfordnlp-gpl, but at the moment, it is quite slower
as it runs the whole Stanford pipeline independent of previous annotations done in
DKPro (we leave it as open issue for now).

There are two patches attached:

dkpro-asl:
* new submodule de.tudarmstadt.ukp.dkpro.core.api.sentiment-asl with typesystem (not
a general typesystem for sentiment, only one exact matching the scores provided by
Stanford analyzer; can be refactored if needed)

dkpro-gpl:
* de.tudarmstadt.ukp.dkpro.core.stanfordnlp.StanfordSentimentAnalyzer and a simple
test case

Original issue reported on code.google.com by ivan.habernal on 2014-07-18 11:56:51


reckart commented 9 years ago
There is a method called de.tudarmstadt.ukp.dkpro.core.stanfordnlp.util.TreeUtils.createStanfordTree(Annotation,
TreeFactory) that should help to transform a DKPro Core constituent tree into the Stanford
representation. 

Maybe that helps, but maybe it takes us only half the way. Do you know what information
the Stanford sentiment analyzer requires? Only the parse tree or more?

Original issue reported on code.google.com by richard.eckart on 2014-07-21 20:07:38

reckart commented 9 years ago
The dependency on the models artifact seems to be required right now because the sentiment
component does not use the DKPro Core model provisioning mechanism.

This mechanism should be used and the dependency on the models should be removed:

        <dependency>
            <groupId>edu.stanford.nlp</groupId>
            <artifactId>stanford-corenlp</artifactId>
            <version>3.4</version>
            <classifier>models</classifier>
        </dependency>

Original issue reported on code.google.com by richard.eckart on 2014-07-30 08:52:36

reckart commented 9 years ago
(No text was entered with this change)

Original issue reported on code.google.com by richard.eckart on 2014-08-14 10:05:39

reckart commented 9 years ago
(No text was entered with this change)

Original issue reported on code.google.com by richard.eckart on 2014-10-02 21:32:33