Details
-
New Feature
-
Status: Open
-
Major
-
Resolution: Unresolved
-
2.0.0
-
None
-
None
Description
With Stanbol 2.0 several changes to EnhancementProperties introduced by STANBOL-488 will be introduced:
Enhancement Engine API change
With version 2.0 EnhancementProperties will be parsed as additional parameter to the computeEnhancement(..) method.
@Override public final void computeEnhancements(ContentItem ci, Map<String,Object> enhancemntProps) throws EngineException { [..] }
TODO: check if they should also be parsed to the canEnhance method.
Request Scope Enhancement Properties
Request Scope Enhancement Properties will no longer use a ContentPart but instead be directly added to the `em:ChainExecution` and `em:EngineExecution` nodes of the Execution Metadata.
The EnhancementJob API will also provide means to add enhancement properties. The following listing shows a possible API for adding execution scoped properties to an EnhancementJob.
@Reference EnhancementJobFactory ejf; @Reference EnhancementJobManager ejm; ContentSource content; //the parsed content Chain chain; //the requested enhancement chain ejm.enhance(ejf.create() .source(content) .chain(chain) .setProperty("enhancer.minConfidence",0.75) .setProperty("linking","enhancer.maxSuggestions",10) .build());
TODO: further definitions