Bad behavior when accepting out-of-tagset recommendation on closed tagset
**Describe the bug**
When a recommender suggests a label which is not in the tagset associated with the predicted feature and when the tagset does not allow creating tags, then the annotation editor ends up in an undefined state.

**To Reproduce**
Steps to reproduce the behavior:
1. Create a project with a string matching recommender
2. Annotate a word with some tag - the word must occur multiple times in the text
3. edit the tagset for the annotation such that the tag is no longer part of it and make sure the tagset is not extensible
4. go back to the annotation screen and try accepting one of the suggestions of the string matching recommender

**Expected behavior**
If the suggestion cannot be accepted because the suggested label is not in the tagset, then the UI should remain stable - the annotation which was *not* created should not be displayed in the sidebar. 

**Screenshots**
When I accept a suggestion and force an update, e.g. opening the side bar, I get

```
java.lang.NullPointerException
     at org.apache.uima.cas.impl.CASImpl.ll_getFSForRef(CASImpl.java:3694)
     at de.tudarmstadt.ukp.clarin.webanno.api.annotation.util.WebAnnoCasUtil.selectByAddr(WebAnnoCasUtil.java:159)
     at de.tudarmstadt.ukp.clarin.webanno.api.annotation.util.WebAnnoCasUtil.selectByAddr(WebAnnoCasUtil.java:142)
     at de.tudarmstadt.ukp.clarin.webanno.ui.annotation.detail.AnnotationFeatureForm.lambda$createSelectedAnnotationTypeLabel$bdf80041$1(AnnotationFeatureForm.java:287)
     at org.apache.wicket.model.LoadableDetachableModel$1.load(LoadableDetachableModel.java:214)
     at org.apache.wicket.model.LoadableDetachableModel.getObject(LoadableDetachableModel.java:126)
     at org.apache.wicket.Component.getDefaultModelObject(Component.java:1574)
     at org.apache.wicket.Component.getDefaultModelObjectAsString(Component.java:1602)
     at org.apache.wicket.markup.html.basic.Label.onComponentTagBody(Label.java:115)
     at org.apache.wicket.markup.html.panel.DefaultMarkupSourcingStrategy.onComponentTagBody(DefaultMarkupSourcingStrategy.java:70)
     at org.apache.wicket.Component.internalRenderComponent(Component.java:2479)
     at org.apache.wicket.markup.html.WebComponent.onRender(WebComponent.java:60)
     at org.apache.wicket.Component.internalRender(Component.java:2287)
     at org.apache.wicket.Component.render(Component.java:2218)
     at org.apache.wicket.MarkupContainer.renderNext(MarkupContainer.java:1453)
     at org.apache.wicket.MarkupContainer.renderAll(MarkupContainer.java:1653)
     at org.apache.wicket.MarkupContainer.renderComponentTagBody(MarkupContainer.java:1628)
     at org.apache.wicket.MarkupContainer.onComponentTagBody(MarkupContainer.java:1586)
     at org.apache.wicket.markup.html.panel.DefaultMarkupSourcingStrategy.onComponentTagBody(DefaultMarkupSourcingStrategy.java:70)
     at org.apache.wicket.Component.internalRenderComponent(Component.java:2479)
     at org.apache.wicket.MarkupContainer.onRender(MarkupContainer.java:1592)
     at org.apache.wicket.Component.internalRender(Component.java:2287)
     at org.apache.wicket.Component.render(Component.java:2218)
     at org.apache.wicket.MarkupContainer.renderNext(MarkupContainer.java:1453)
     at org.apache.wicket.MarkupContainer.renderAll(MarkupContainer.java:1653)
     at org.apache.wicket.MarkupContainer.renderComponentTagBody(MarkupContainer.java:1628)
     at org.apache.wicket.MarkupContainer.onComponentTagBody(MarkupContainer.java:1586)
     at org.apache.wicket.markup.html.form.Form.onComponentTagBody(Form.java:1667)
     at org.apache.wicket.markup.html.panel.DefaultMarkupSourcingStrategy.onComponentTagBody(DefaultMarkupSourcingStrategy.java:70)
     at org.apache.wicket.Component.internalRenderComponent(Component.java:2479)
     at org.apache.wicket.MarkupContainer.onRender(MarkupContainer.java:1592)
     at org.apache.wicket.Component.internalRender(Component.java:2287)
     at org.apache.wicket.Component.render(Component.java:2218)
     at org.apache.wicket.MarkupContainer.renderNext(MarkupContainer.java:1453)
     at org.apache.wicket.MarkupContainer.renderAll(MarkupContainer.java:1653)
     at org.apache.wicket.MarkupContainer.renderComponentTagBody(MarkupContainer.java:1628)
     at org.apache.wicket.MarkupContainer.renderAssociatedMarkup(MarkupContainer.java:797)
     at org.apache.wicket.markup.html.panel.AssociatedMarkupSourcingStrategy.renderAssociatedMarkup(AssociatedMarkupSourcingStrategy.java:77)
     at org.apache.wicket.markup.html.panel.PanelMarkupSourcingStrategy.onComponentTagBody(PanelMarkupSourcingStrategy.java:112)
     at org.apache.wicket.Component.internalRenderComponent(Component.java:2479)
     at org.apache.wicket.MarkupContainer.onRender(MarkupContainer.java:1592)
     at org.apache.wicket.Component.internalRender(Component.java:2287)
     at org.apache.wicket.Component.render(Component.java:2218)
     at org.apache.wicket.MarkupContainer.renderNext(MarkupContainer.java:1453)
     at org.apache.wicket.MarkupContainer.renderAll(MarkupContainer.java:1653)
     at org.apache.wicket.MarkupContainer.renderComponentTagBody(MarkupContainer.java:1628)
     at org.apache.wicket.MarkupContainer.onComponentTagBody(MarkupContainer.java:1586)
     at org.apache.wicket.markup.html.panel.DefaultMarkupSourcingStrategy.onComponentTagBody(DefaultMarkupSourcingStrategy.java:70)
     at org.apache.wicket.Component.internalRenderComponent(Component.java:2479)
     at org.apache.wicket.MarkupContainer.onRender(MarkupContainer.java:1592)
     at org.apache.wicket.Component.internalRender(Component.java:2287)
     at org.apache.wicket.Component.render(Component.java:2218)
     at org.apache.wicket.MarkupContainer.renderNext(MarkupContainer.java:1453)
     at org.apache.wicket.MarkupContainer.renderAll(MarkupContainer.java:1653)
     at org.apache.wicket.Page.onRender(Page.java:858)
     at org.apache.wicket.markup.html.WebPage.onRender(WebPage.java:126)
     at org.apache.wicket.Component.internalRender(Component.java:2287)
     at org.apache.wicket.Component.render(Component.java:2218)
     at org.apache.wicket.Page.renderPage(Page.java:998)
     at org.apache.wicket.request.handler.render.WebPageRenderer.renderPage(WebPageRenderer.java:124)
     at org.apache.wicket.request.handler.render.WebPageRenderer.respond(WebPageRenderer.java:195)
     at org.apache.wicket.core.request.handler.RenderPageRequestHandler.respond(RenderPageRequestHandler.java:202)
     at org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:912)
     at org.apache.wicket.request.RequestHandlerExecutor.execute(RequestHandlerExecutor.java:65)
     at org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:283)
     at org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:253)
     at org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:221)
     at org.apache.wicket.protocol.http.WicketFilter.processRequestCycle(WicketFilter.java:262)
     at org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:204)
     at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:286)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.orm.jpa.support.OpenEntityManagerInViewFilter.doFilterInternal(OpenEntityManagerInViewFilter.java:185)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at de.tudarmstadt.ukp.clarin.webanno.support.logging.LoggingFilter.doFilter(LoggingFilter.java:52)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:82)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:200)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:116)
     at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:116)
     at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:200)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:116)
     at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:317)
     at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:116)
     at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:114)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:84)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:111)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.authentication.rememberme.RememberMeAuthenticationFilter.doFilter(RememberMeAuthenticationFilter.java:158)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:170)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:101)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:200)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:116)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:101)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:101)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:82)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:214)
     at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:185)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:317)
     at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:127)
     at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:114)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:137)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:111)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.authentication.rememberme.RememberMeAuthenticationFilter.doFilter(RememberMeAuthenticationFilter.java:158)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:170)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.authentication.www.BasicAuthenticationFilter.doFilterInternal(BasicAuthenticationFilter.java:158)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:200)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:116)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:66)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:56)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105)
     at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
     at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:214)
     at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:177)
     at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:357)
     at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:270)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.web.filter.HttpPutFormContentFilter.doFilterInternal(HttpPutFormContentFilter.java:112)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:93)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:200)
     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
     at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)
     at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
     at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:493)
     at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)
     at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)
     at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
     at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342)
     at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:800)
     at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
     at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:806)
     at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1498)
     at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
     at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1135)
     at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
     at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
     at java.base/java.lang.Thread.run(Thread.java:844)
```

**Please complete the following information:**
 - Version and build ID: e57af846e4a7c31a4001bbc27a9314fc2d647699

**Additional context**
Probably it would be sensible to filter out any recommendations which violate the tagset before even showing them to the user.
diff --git a/inception-active-learning/src/main/java/de/tudarmstadt/ukp/inception/active/learning/sidebar/ActiveLearningSidebar.java b/inception-active-learning/src/main/java/de/tudarmstadt/ukp/inception/active/learning/sidebar/ActiveLearningSidebar.java
index f58f2feec5..000a9398ff 100644
--- a/inception-active-learning/src/main/java/de/tudarmstadt/ukp/inception/active/learning/sidebar/ActiveLearningSidebar.java
+++ b/inception-active-learning/src/main/java/de/tudarmstadt/ukp/inception/active/learning/sidebar/ActiveLearningSidebar.java
@@ -1061,8 +1061,8 @@ public class ActiveLearningSidebar
             // Update visibility in case the annotation where the feature was set overlaps with 
             // any suggestions that need to be hidden now.
             PredictionTask.calculateVisibility(learningRecordService, annotationService,
-                    getAnnotationPage().getEditorCas(), state.getUser().getUsername(), aLayer,
-                    alState.getSuggestions(), state.getWindowBeginOffset(),
+                    getAnnotationPage().getEditorCas().getCas(), state.getUser().getUsername(),
+                    aLayer, alState.getSuggestions(), state.getWindowBeginOffset(),
                     state.getWindowEndOffset());
     
             // Update the suggestion in the AL sidebar, but do not jump or touch the right
diff --git a/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommender.java b/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommender.java
index e3c1c34fba..3cbd405625 100644
--- a/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommender.java
+++ b/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommender.java
@@ -302,4 +302,10 @@ public class ExternalRecommender
     {
         return Optional.empty();
     }
+    
+    @Override
+    public boolean requiresTraining()
+    {
+        return traits.isTrainable();
+    }
 }
diff --git a/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraits.java b/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraits.java
index d04d952705..24feab48d6 100644
--- a/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraits.java
+++ b/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraits.java
@@ -25,6 +25,7 @@ public class ExternalRecommenderTraits
     private static final long serialVersionUID = -3109239605741337123L;
 
     private String remoteUrl;
+    private boolean trainable;
 
     public String getRemoteUrl()
     {
@@ -35,4 +36,14 @@ public class ExternalRecommenderTraits
     {
         remoteUrl = aRemoteUrl;
     }
+
+    public boolean isTrainable()
+    {
+        return trainable;
+    }
+
+    public void setTrainable(boolean aTrainable)
+    {
+        trainable = aTrainable;
+    }
 }
diff --git a/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.html b/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.html
index ef8aa3e30c..823682274a 100644
--- a/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.html
+++ b/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.html
@@ -31,6 +31,16 @@
         </div>
       </div>
     </div>
+    <div class="form-group" wicket:enclosure="trainable">
+      <div class="col-sm-offset-3 col-sm-9">
+        <div class="checkbox">
+          <label wicket:for="trainable">
+            <input wicket:id="trainable" type="checkbox"/>
+            <wicket:label key="trainable"/>
+          </label>
+        </div>
+      </div>  
+    </div>
   </form>
 </wicket:panel>
 </html>
diff --git a/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.java b/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.java
index 7961521825..89c201fb4c 100644
--- a/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.java
+++ b/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.java
@@ -17,6 +17,7 @@
  */
 package de.tudarmstadt.ukp.inception.recommendation.imls.external;
 
+import org.apache.wicket.markup.html.form.CheckBox;
 import org.apache.wicket.markup.html.form.Form;
 import org.apache.wicket.markup.html.form.TextField;
 import org.apache.wicket.markup.html.panel.Panel;
@@ -63,6 +64,9 @@ public class ExternalRecommenderTraitsEditor
         remoteUrl.add(new UrlValidator());
         form.add(remoteUrl);
 
+        CheckBox trainable = new CheckBox("trainable");
+        form.add(trainable);
+
         add(form);
     }
 }
diff --git a/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.properties b/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.properties
index 630e93cb3d..5e8b9c31b7 100644
--- a/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.properties
+++ b/inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.properties
@@ -15,3 +15,4 @@
 # limitations under the License.
 
 remoteUrl=Remote URL
+trainable=Trainable
diff --git a/inception-recommendation-api/src/main/java/de/tudarmstadt/ukp/inception/recommendation/api/recommender/RecommendationEngine.java b/inception-recommendation-api/src/main/java/de/tudarmstadt/ukp/inception/recommendation/api/recommender/RecommendationEngine.java
index 5dc83e4ca8..ff85a7407f 100644
--- a/inception-recommendation-api/src/main/java/de/tudarmstadt/ukp/inception/recommendation/api/recommender/RecommendationEngine.java
+++ b/inception-recommendation-api/src/main/java/de/tudarmstadt/ukp/inception/recommendation/api/recommender/RecommendationEngine.java
@@ -83,4 +83,15 @@ public interface RecommendationEngine {
     {
         return Optional.of("score");
     }
+    
+    /**
+     * Whether or not this engine supports training. If training is not supported, the call to
+     * {@link #train} should be skipped and {@link #predict} should be called immediately. Note
+     * that the engine cannot expect a model to be present in the {@link RecommenderContext} if
+     * training is skipped - this is meant only for engines that use pre-trained models.
+     */
+    default boolean requiresTraining()
+    {
+        return true;
+    }
 }
diff --git a/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/render/RecommendationSpanRenderer.java b/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/render/RecommendationSpanRenderer.java
index 6abfb01c29..e32e3a8aec 100644
--- a/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/render/RecommendationSpanRenderer.java
+++ b/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/render/RecommendationSpanRenderer.java
@@ -111,8 +111,9 @@ public class RecommendationSpanRenderer
         String color = aColoringStrategy.getColor(null, null);
         String bratTypeName = TypeUtil.getUiTypeName(typeAdapter);
 
-        PredictionTask.calculateVisibility(learningRecordService, aAnnotationService, aJcas,
-                aState.getUser().getUsername(), layer, groups, windowBegin, windowEnd);
+        PredictionTask.calculateVisibility(learningRecordService, aAnnotationService,
+                aJcas.getCas(), aState.getUser().getUsername(), layer, groups, windowBegin,
+                windowEnd);
 
         Preferences pref = recommendationService.getPreferences(aState.getUser(),
                 layer.getProject());
diff --git a/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/tasks/PredictionTask.java b/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/tasks/PredictionTask.java
index 04b0b65a49..1459bb4319 100644
--- a/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/tasks/PredictionTask.java
+++ b/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/tasks/PredictionTask.java
@@ -40,13 +40,19 @@ import org.apache.commons.collections4.MultiValuedMap;
 import org.apache.commons.collections4.multimap.ArrayListValuedHashMap;
 import org.apache.uima.UIMAException;
 import org.apache.uima.cas.CAS;
+import org.apache.uima.cas.CASException;
 import org.apache.uima.cas.Feature;
 import org.apache.uima.cas.Type;
+import org.apache.uima.cas.admin.CASMgr;
+import org.apache.uima.cas.impl.CASCompleteSerializer;
+import org.apache.uima.cas.impl.Serialization;
 import org.apache.uima.cas.text.AnnotationFS;
 import org.apache.uima.fit.util.CasUtil;
 import org.apache.uima.fit.util.FSUtil;
 import org.apache.uima.fit.util.JCasUtil;
-import org.apache.uima.jcas.JCas;
+import org.apache.uima.resource.ResourceInitializationException;
+import org.apache.uima.resource.metadata.TypeSystemDescription;
+import org.apache.uima.util.CasCreationUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -104,8 +110,11 @@ public class PredictionTask
         Predictions model = new Predictions(project, getUser());
         List<SourceDocument> documents = documentService.listSourceDocuments(project);
 
+        log.info("[{}]: Starting prediction...", user.getUsername());
+        long startTime = System.currentTimeMillis();
         nextDocument: for (SourceDocument document : documents) {
-            Optional<JCas> jCas = Optional.empty();
+            Optional<CAS> originalCas = Optional.empty();
+            Optional<CAS> predictionCas = Optional.empty();
             nextLayer: for (AnnotationLayer layer : annoService.listAnnotationLayer(project)) {
                 if (!layer.isEnabled()) {
                     continue nextLayer;
@@ -115,6 +124,7 @@ public class PredictionTask
                     .getActiveRecommenders(user, layer);
 
                 nextRecommender: for (Recommender r : recommenders) {
+                    
                     // Make sure we have the latest recommender config from the DB - the one from
                     // the active recommenders list may be outdated
                     Recommender recommender;
@@ -150,10 +160,10 @@ public class PredictionTask
                     // We lazily load the CAS only at this point because that allows us to skip
                     // loading the CAS entirely if there is no enabled layer or recommender.
                     // If the CAS cannot be loaded, then we skip to the next document.
-                    if (!jCas.isPresent()) {
+                    if (!originalCas.isPresent()) {
                         try {
-                            jCas = Optional.of(documentService.readAnnotationCas(document,
-                                    user.getUsername()));
+                            originalCas = Optional.of(documentService.readAnnotationCas(document,
+                                    user.getUsername()).getCas());
                         }
                         catch (IOException e) {
                             log.error("Cannot read annotation CAS for user [{}] of document "
@@ -163,7 +173,7 @@ public class PredictionTask
                             continue nextDocument;
                         }
                         try {
-                            annoService.upgradeCasIfRequired(jCas.get().getCas(), document,
+                            annoService.upgradeCasIfRequired(originalCas.get(), document,
                                     user.getUsername());
                         }
                         catch (UIMAException | IOException e) {
@@ -173,10 +183,48 @@ public class PredictionTask
                                     project.getName(), project.getId(), e);
                             continue nextDocument;
                         }
+                        try {
+                            predictionCas = Optional.of(cloneCAS(originalCas.get()));
+                        }
+                        catch (UIMAException e) {
+                            log.error("Cannot clone annotation CAS for user [{}] of document "
+                                    + "[{}]({}) in project [{}]({}) - skipping document",
+                                    user.getUsername(), document.getName(), document.getId(),
+                                    project.getName(), project.getId(), e);
+                            continue nextDocument;
+                        }
                     }
                     
                     try {
-                        recommendationEngine.predict(ctx, jCas.get().getCas());
+                        Type predictionType = getAnnotationType(predictionCas.get(),
+                                recommendationEngine.getPredictedType());
+                        Feature labelFeature = predictionType
+                                .getFeatureByBaseName(recommendationEngine.getPredictedFeature());
+                        Optional<Feature> scoreFeature = recommendationEngine.getScoreFeature()
+                                .map(predictionType::getFeatureByBaseName);
+                        
+                        // Remove any annotations that will be predicted (either manually created
+                        // or from a previous prediction run) from the CAS
+                        removePredictions(predictionCas.get(), predictionType);
+                        
+                        // Perform the actual prediction
+                        recommendationEngine.predict(ctx, predictionCas.get());
+
+                        // Extract the suggestions from the data which the recommender has written 
+                        // into the CAS
+                        List<AnnotationSuggestion> predictions = extractSuggestions(user,
+                                predictionCas.get(), predictionType, labelFeature, scoreFeature,
+                                document, recommender);
+                        
+                        // Calculate the visbility of the suggestions. This happens via the original
+                        // CAS which contains only the manually created annotations and *not* the
+                        // suggestions.
+                        Collection<SuggestionGroup> groups = SuggestionGroup.group(predictions);
+                        calculateVisibility(learningRecordService, annoService, originalCas.get(),
+                                getUser().getUsername(), layer, groups, 0,
+                                originalCas.get().getDocumentText().length());
+                        
+                        model.putPredictions(layer.getId(), predictions);
                     }
                     catch (Throwable e) {
                         log.error("Error applying recommender [{}]({}) for user [{}] to document "
@@ -186,40 +234,27 @@ public class PredictionTask
                                 project.getId(), e);
                         continue nextRecommender;
                     }
-
-                    String predictedTypeName = recommendationEngine.getPredictedType();
-                    String predictedFeatureName = recommendationEngine.getPredictedFeature();
-                    Optional<String> scoreFeatureName = recommendationEngine.getScoreFeature();
-                    Type predictionType = getAnnotationType(jCas.get().getCas(), predictedTypeName);
-                    Feature labelFeature = predictionType
-                            .getFeatureByBaseName(predictedFeatureName);
-                    Optional<Feature> scoreFeature = scoreFeatureName
-                            .map(predictionType::getFeatureByBaseName);
-
-                    // Extract the suggestions from the data which the recommender has written into
-                    // the CAS
-                    List<AnnotationSuggestion> predictions = extractSuggestions(user,
-                            jCas.get().getCas(), predictionType, labelFeature, scoreFeature,
-                            document, recommender);
-                    
-                    // Calculate the visbility of the suggestions
-                    Collection<SuggestionGroup> groups = SuggestionGroup.group(predictions);
-                    calculateVisibility(learningRecordService, annoService, jCas.get(),
-                            getUser().getUsername(), layer, groups, 0,
-                            jCas.get().getDocumentText().length());
-                    
-                    model.putPredictions(layer.getId(), predictions);
-
-                    // In order to just extract the annotations for a single recommender, each
-                    // recommender undoes the changes applied in `recommendationEngine.predict`
-
-                    removePredictions(jCas.get().getCas(), predictionType);
                 }
             }
         }
+        log.info("[{}]: Prediction complete ({} ms)", user.getUsername(),
+                (System.currentTimeMillis() - startTime));
 
         recommendationService.putIncomingPredictions(getUser(), project, model);
     }
+    
+    private CAS cloneCAS(CAS aCAS) throws ResourceInitializationException, CASException
+    {
+        CAS clone = CasCreationUtils.createCas((TypeSystemDescription) null, null, null);
+        
+        CASCompleteSerializer ser = Serialization.serializeCASComplete((CASMgr) aCAS);
+        Serialization.deserializeCASComplete(ser, (CASMgr) clone);
+        
+        // Make sure JCas is properly initialized too
+        clone.getJCas();
+        
+        return clone;
+    }
 
     private List<AnnotationSuggestion> extractSuggestions(User aUser, CAS aCas, Type predictionType,
             Feature predictedFeature, Optional<Feature> aScoreFeature, SourceDocument aDocument,
@@ -281,13 +316,13 @@ public class PredictionTask
      * Goes through all AnnotationObjects and determines the visibility of each one
      */
     public static void calculateVisibility(LearningRecordService aLearningRecordService,
-            AnnotationSchemaService aAnnotationService, JCas aJcas, String aUser,
+            AnnotationSchemaService aAnnotationService, CAS aCas, String aUser,
             AnnotationLayer aLayer, Collection<SuggestionGroup> aRecommendations, int aWindowBegin,
             int aWindowEnd)
     {
         // Collect all annotations of the given layer within the view window
-        Type type = CasUtil.getType(aJcas.getCas(), aLayer.getName());
-        List<AnnotationFS> annotationsInWindow = select(aJcas.getCas(), type).stream()
+        Type type = CasUtil.getType(aCas, aLayer.getName());
+        List<AnnotationFS> annotationsInWindow = select(aCas, type).stream()
                 .filter(fs -> aWindowBegin <= fs.getBegin() && fs.getEnd() <= aWindowEnd)
                 .collect(toList());
         
diff --git a/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/tasks/TrainingTask.java b/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/tasks/TrainingTask.java
index cc1edf4932..b557aad2e3 100644
--- a/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/tasks/TrainingTask.java
+++ b/inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/tasks/TrainingTask.java
@@ -125,9 +125,19 @@ public class TrainingTask
                 RecommenderContext context = recommendationService.getContext(user, recommender);
                 RecommendationEngineFactory factory = recommendationService
                     .getRecommenderFactory(recommender);
-                RecommendationEngine recommendationEngine = factory.build(recommender);
 
                 try {
+                    RecommendationEngine recommendationEngine = factory.build(recommender);
+                    
+                    // If the engine does not require/support training, then we mark the context
+                    // as ready for prediction and skip the training step
+                    if (!recommendationEngine.requiresTraining()) {
+                        log.info("[{}][{}]: Engine does not require training",
+                                user.getUsername(), recommender.getName());
+                        context.markAsReadyForPrediction();
+                        continue;
+                    }
+                    
                     List<CAS> cassesForTraining = casses.get()
                             .stream()
                             .filter(e -> !recommender.getStatesIgnoredForTraining()
@@ -135,13 +145,21 @@ public class TrainingTask
                             .filter(e -> containsTargetAnnotation(recommender, e.cas))
                             .map(e -> e.cas)
                             .collect(Collectors.toList());
-                    log.info("[{}][{}]: Training model on [{}] out of [{}] documents ...",
-                            user.getUsername(), recommender.getName(), cassesForTraining.size(),
-                            casses.get().size());
 
-                    recommendationEngine.train(context, cassesForTraining);
-                    log.info("[{}][{}]: Training complete ({} ms)", user.getUsername(),
-                            recommender.getName(), (System.currentTimeMillis() - startTime));
+                    if (!cassesForTraining.isEmpty()) {
+                        log.info("[{}][{}]: Training model on [{}] out of [{}] documents ...",
+                                user.getUsername(), recommender.getName(), cassesForTraining.size(),
+                                casses.get().size());
+                        
+                        recommendationEngine.train(context, cassesForTraining);
+                        
+                        log.info("[{}][{}]: Training complete ({} ms)", user.getUsername(),
+                                recommender.getName(), (System.currentTimeMillis() - startTime));
+                    }
+                    else {
+                        log.info("[{}][{}]: There are annotations available to train on",
+                                user.getUsername(), recommender.getName());
+                    }
                 }
                 catch (Exception e) {
                     log.info("[{}][{}]: Training failed ({} ms)", user.getUsername(),
['inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.html', 'inception-recommendation-api/src/main/java/de/tudarmstadt/ukp/inception/recommendation/api/recommender/RecommendationEngine.java', 'inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/render/RecommendationSpanRenderer.java', 'inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/tasks/TrainingTask.java', 'inception-recommendation/src/main/java/de/tudarmstadt/ukp/inception/recommendation/tasks/PredictionTask.java', 'inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommender.java', 'inception-active-learning/src/main/java/de/tudarmstadt/ukp/inception/active/learning/sidebar/ActiveLearningSidebar.java', 'inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.properties', 'inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraits.java', 'inception-imls-external/src/main/java/de/tudarmstadt/ukp/inception/recommendation/imls/external/ExternalRecommenderTraitsEditor.java']