Class SentimentConfig
java.lang.Object
com.norconex.importer.handler.parser.impl.SentimentConfig
Tika sentiment analysis configuration (via Tika's
SentimentAnalysisParser).
Sentiment analysis is disabled by default because the parser downloads a model from the network the moment Tika is initialized, regardless of whether any document actually needs sentiment analysis. This can slow down or fail startup when the model URL is unreachable.
To enable it, set enabled to true and optionally
override the default model path with modelPath
(default: "https://raw.githubusercontent.com/USCDataScience/SentimentAnalysisParser/master/sentiment-models/src/main/resources/edu/usc/irds/sentiment/en-netflix-sentiment.bin").
- Since:
- 4.0.0
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanbooleaninthashCode()booleansetEnabled(boolean enabled) setModelPath(String modelPath) toString()
-
Field Details
-
DEFAULT_MODEL_PATH
Default Tika sentiment model URL.- See Also:
-
-
Constructor Details
-
SentimentConfig
public SentimentConfig()
-
-
Method Details