OpenNLP Chunker Engine

The OpenNLP Chunker Engine support the detection of Phrases (Noun, Verb, ...) within the parsed Text. For that it uses the OpenNLP Chunker feature. Detected Phrases are added as Chunks to the AnalyzedText content part. In addition added Chunks are annotated with an Phrase Annotation providing the type of the Phrase represented by the Chunk.

Consumed information


The OpenNLP Chunker Engine provides a default service instance (configuration policy is optional) that is configured to process all languages. For German the model parameter is set to '' a chunker model that only detects Noun Phrases. This model is included in the '' module. This Engine instance uses the name 'opennlp-chunker' and has a service ranking of '-100'.

This engine supports the default configuration for Enhancement Engines including the name ( and the ranking (service.ranking) In addition it is possible to configure the processed languages (org.apache.stanbol.enhancer.chunker.languages) and an parameter to specify the name of the chunker model used for a language.

1. Processed Language Configuraiton:

For the configuration of the processed languages the following syntax is used:


This would configure the Engine to only process German and English texts. It is also possible to explicitly exclude languages


This specifies that all Languages other than French and Italien are processed.

Values can be parsed as Array or Vector. This is done by using the ["elem1","elem2",...] syntax as defined by OSGI ".config" files. As fallback also ',' separated Strings are supported.

The following example shows the two above examples combined to a single configuration.


NOTE that the "processed language" configuration only specifies what languages are considered for processing. If "de" is enabled, but there is no sentence detection model available for that language, than German text will still not be processed. However if there is a POS model for "it" but the "processed language" configuration does not include Italian, than Italian text will NOT be processed.

2. Sentnece detection model parameter

The OpenNLP Sentence Detection engine supports the 'model' parameter to explicitly parse the name of the sentence detection model used for an language. Models are loaded via the Stanbol DataFile provider infrastructure. That means that models can be loaded from the {stanbol-working-dir}/stanbol/datafiles folder.

The syntax for parameters is as follows


As shown by the default configuration of this engine, to use "" for detecting sentences in German texts one can use a configuration like follows


By default OpenNLP chunker models are loaded from '{lang}-chunker.bin'. To use models with other names users need to use the 'model' parameter as described above.