Dictionary Based Sentiment (Documents)
Synopsis
This operator creates a sentiment model from an annotated list of words. It expects a list of words with a weight (value) attribute describing how negative or positive a word is. This can later be used in an Apply Dictionary Based Sentiment operator to score tokenized documents. This operator takes a list of Key (nominal) Value (numerical) pairs and translates them into an applicable model.
This operator also supports negations. It is possible to add a negation dictionary to the neg port. If a negation is x words before any given word, its weights will be inversed. x can be defined with the negation window size parameter. It is possible to define the strength of negation using the negation strength option. If this setting is left empty, weights of 1 are used. Note that negation weights are defined as positive numbers.
Additionally to the concept of negativity this operator supports also intensifiers. Intensifier are words which increase or decrese the sentiment of another word. This means you can enhance the sentiment of the word "good" with a word like "very". If the corresponding weight is smaller than 1 than this is a "de-itensifier". An example would be the word "relatively". If words are already negated, intensifiers are ignored.
Input
exa
Input ExampleSet with a Key and a Value Attribute.
neg
Example Set providing a list of negation words like "not" and their weight.
int
Example Set providing a list of intensifiers like "very" and their weight.
Output
mod
The resulting model.
ori
The passed through input ExampleSet.
Parameters
Key attribute
The attribute with the key (word) in it .
Value attribute
The attribute with the value (score) in it .
Negation attribute
Attribute in the negation ExampleSet which holds the individual words.
Negation strength
Attribute in the negation ExampleSet which holds the weight of negation. Weights are defined as positive numbers!
Negation window size
Window size for negation. 1 means that the word needs to be directly in front of other words.
Use symmetric negation window
If set to true, negation will not just be applied to succeeding, but also to proceeding tokens. This covers sentences like "The crisis is not as bad as forecasted", where you maybe want to invert both crisis and bad.
Use intensifier
If set to true, you can define intensifiers
Intensifier word
Attribute in the intensifier ExampleSet which holds the individual words.
Intensifier value
Attribute in the negation ExampleSet which holds the weight of intensifier. Weights are defined as positive numbers!
Intensifier window size
Window size for intensifier. 1 means that the word needs to be directly in front of other words.
Use symmetric intensifier window
If set to true, intensifier will not just be applied to succeeding, but also to proceeding tokens.