You can configure a collection to assign positive sentiment, negative sentiment, or no
sentiment to expressions in text when text is analyzed.
Before you begin
To identify sentiment when text is analyzed, you must enable sentiment analysis. If you did
not enable sentiment analysis when you created the collection, you can enable it by editing
the collection settings.
When you enable sentiment analysis, Annotation Administration Console
applies default analytics. If you want to customize or extend the default analysis, follow
the steps in this procedure to add or block additional text expressions.
When analysis results are returned to Watson Explorer
through the text analytics API, facets specific to sentiment analysis are included.
About this task
When you customize sentiment analysis, you specify words and phrases to help the system
categorize whether a sentence conveys sentiment and, if so, what the sentiment is. Add
expressions that are meaningful in your enterprise data that are not recognized by the
built-in sentiment analysis feature. Support for sentiment expressions differs between
languages and domains that use different jargons. For example, when you analyze sentiment
about food you use other expressions than when you analyze sentiment about cars or customer
service.
If a sentence does not contain enough expressions to convey positive or negative sentiment,
the sentence is classified as ambivalent.
Sentiment analysis depends on the source language:
- English and Japanese
- For these languages, the Sentiment facet generates three subfacets: Phrase,
Expression, and Target. The Target subfacet lets you analyze the targets of sentiment
expressions. For example, if a negative expression conveys "not like", you can analyze
the objects that are evaluated by the expression, such as not liking a particular book
or movie.
Consider this example sentence: "I don't like this car but I'm not sure
how he feels". Deep analysis captures the following elements:
- The phrase, I don't like this car (the text involved in analyzing
sentiment)
- The expression, NOT like (the expression that generates sentiment)
- The target, car (the object evaluated by the expressed sentiment)
Unlike shallow analysis, deep analysis can recognize direct relationships in
text. This means that the expression "don't like" and the target "car" are not just
in the same document or highly correlated, but that they occur in the same sentence
and have a syntactic relationship. Deep analysis provides very precise results, but
the coverage might not be as high; both the expression and the target must be
identified in order to analyze them as a pair.
- Shallow analysis: Chinese, Czech, Dutch, Hebrew, Russian, Spanish, and Turkish
- For these languages, only Phrase and Expression subfacets are generated for the
Sentiment facet. Analysts can explore correlations, see positive and negative
expressions in context, and so on, but expressions and their targets are not analyzed
as a pair.
Procedure
To customize how sentiment analysis is applied to a collection:
- On the Collections view, expand the collection that you want to
configure and click .
- On the Sentiment Analysis Configuration page, ensure that the
Enable sentiment analysis check box is selected, and then click
the edit icon for the language to be applied when content is analyzed.
- Specify at least one expression. If you specify more than one expression of a given type, enter each expression on a
separate line:
- Specify words and phrases that are to be recognized as positive expressions when
text is analyzed.
- Specify words and phrases that are to be recognized as negative expressions when
text is analyzed.
- Specify words and phrases that are to be blocked and not categorized as sentiment
when text is analyzed. For example, the phrase, "good night".
- Optional: Repeat these steps to specify expressions for a different language. The Sentiment Analysis Configuration page shows the number
of positive expressions, negative expressions, and blocked expressions that are defined
for each language.
- After you return to the Collections view, apply your changes by
clicking the icon to stop and restart the Text Analytics
session.