Class DefaultWrapperModel

  • All Implemented Interfaces:
    org.apache.lucene.util.Accountable

    public class DefaultWrapperModel
    extends WrapperModel
    A scoring model that fetches the wrapped model from SolrResourceLoader.

    This model uses SolrResourceLoader.openResource(String) for fetching the wrapped model. If you give a relative path for params/resource, this model will try to load the wrapped model from the instance directory (i.e. ${solr.solr.home}). Otherwise, seek through classpaths.

    Example configuration:

     {
       "class": "org.apache.solr.ltr.model.DefaultWrapperModel",
       "name": "myWrapperModelName",
       "params": {
         "resource": "models/myModel.json"
       }
     }
     
    See Also:
    SolrResourceLoader.openResource(String)