Hi,
I have configured LTR in my solr collection and I am able to see my feature and
model file. To test things out I have kept only two features and a very basic
model file. I have attached both the files.
I am able to retrieve the features using the following query :
localhost:8983/solr/waterstest/query?q=*:*&fl=title,id,description,score,[features
store=myWatersFeatureStore efi.boostedTitle=columns
efi.boostedDescription=Heater]<http://localhost:8983/solr/waterstest/query?q=*:*&fl=title,id,description,score,%5bfeatures%20store=myWatersFeatureStore%20efi.boostedTitle=columns%20efi.boostedDescription=Heater%5d>
The above works fine. I am able to retrieve the feature and the score with the
data
The problem comes when I try to rerank the results with the uploaded model.
Here are the queries I have tried to rerank the results
localhost:8983/solr/waterstest/query?q=title:columns&rq={!ltr
model=myWatersModel reRankDocs=100 efi.boostedTitle=columns
efi.boostedDescription=Heater}&fl=id,score<http://localhost:8983/solr/waterstest/query?q=title:columns&rq=%7b!ltr%20model=myWatersModel%20reRankDocs=100%20efi.boostedTitle=columns%20efi.boostedDescription=Heater%7d&fl=id,score>
Response
{
"responseHeader":{
"zkConnected":true,
"status":400,
"QTime":28,
"params":{
"q":"title:columns",
"fl":"id,score",
"rq":"{!ltr model=myWatersModel reRankDocs=100 efi.boostedTitle=columns
efi.boostedDescription=Heater}"}},
"error":{
"metadata":[
"error-class","org.apache.solr.common.SolrException",
"root-error-class","org.apache.solr.common.SolrException",
"error-class","org.apache.solr.client.solrj.impl.BaseHttpSolrClient$RemoteSolrException",
"root-error-class","org.apache.solr.client.solrj.impl.BaseHttpSolrClient$RemoteSolrException"],
"msg":"Error from server at null: cannot find model myWatersModel",
"code":400}}
There is nothing in logs just the same error there
org.apache.solr.client.solrj.impl.BaseHttpSolrClient$RemoteSolrException: Error
from server at null: cannot find model myWatersModel
at
org.apache.solr.client.solrj.impl.Http2SolrClient.processErrorsAndResponse(Http2SolrClient.java:742)
at
org.apache.solr.client.solrj.impl.Http2SolrClient.request(Http2SolrClient.java:412)
at
org.apache.solr.client.solrj.impl.Http2SolrClient.request(Http2SolrClient.java:761)
at org.apache.solr.client.solrj.SolrClient.request(SolrClient.java:1290)
at
org.apache.solr.handler.component.HttpShardHandler.request(HttpShardHandler.java:78)
at
org.apache.solr.handler.component.ShardRequestor.call(ShardRequestor.java:130)
at
org.apache.solr.handler.component.ShardRequestor.call(ShardRequestor.java:41)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at
com.codahale.metrics.InstrumentedExecutorService$InstrumentedRunnable.run(InstrumentedExecutorService.java:180)
at
org.apache.solr.common.util.ExecutorUtil$MDCAwareThreadPoolExecutor.lambda$execute$0(ExecutorUtil.java:212)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
I am able to retrieve the model store also :
localhost:8983/solr/waterstest/schema/model-store<http://localhost:8983/solr/waterstest/schema/model-store>
{
"responseHeader":{
"status":0,
"QTime":1},
"models":[{
"name":"myWatersModel",
"class":"org.apache.solr.ltr.model.LinearModel",
"store":"myWatersFeatureStore",
"features":[{
"name":"isboostedTitle",
"norm":{"class":"org.apache.solr.ltr.norm.IdentityNormalizer"}},
{
"name":"isboostedDescription",
"norm":{"class":"org.apache.solr.ltr.norm.IdentityNormalizer"}}],
"params":{"weights":{
"isboostedTitle":0.4,
"isboostedDescription":0.2}}}]}
If the feature query works and I am able to retrieve the model as well then why
am I getting the model null error. I know the error handling part is not apt
here so can someone help me to point out what all could have gone wrong here?
Thanks and Regards
Yatin Grover
------------------------------------------------------------------------
Disclaimer The information in this email and any attachments may contain
proprietary and confidential information that is intended for the addressee(s)
only. If you are not the intended recipient, you are hereby notified that any
disclosure, copying, distribution, retention or use of the contents of this
information is prohibited. When addressed to our clients or vendors, any
information contained in this e-mail or any attachments is subject to the terms
and conditions in any governing contract. If you have received this e-mail in
error, please immediately contact the sender and delete the e-mail.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]