Re: knn parser not working as expected

2023-08-08 Thread gnandre
Thanks! That was it! The config defType was taking the precedence. After removing that, it started working fine. Shouldn't the parser mentioned in the query take precedence over what is mentioned in the config file? And just one related question, the other config inside this request handler does

Re: knn parser not working as expected

2023-08-07 Thread Joel Bernstein
Oh wait, I just saw your post above with the config. I suspect it's the hardcoded defType that is causing this problem. Try testing with this removed to confirm. Joel Bernstein http://joelsolr.blogspot.com/ On Mon, Aug 7, 2023 at 8:32 PM Joel Bernstein wrote: > So, the knn query is being parse

Re: knn parser not working as expected

2023-08-07 Thread Joel Bernstein
So, the knn query is being parsed into an edismax query in the attached debug output. So something is definitely not working as expected. In your solrconfig.xml do you have a hardcoded qparser for the request handler? Joel Bernstein http://joelsolr.blogspot.com/ On Fri, Aug 4, 2023 at 12:09 PM g

Re: knn parser not working as expected

2023-08-04 Thread gnandre
Also, here is the debug output for that workaround with fq I mentioned. This debug output is not big. "debug":{ "rawquerystring":"*:*", "querystring":"*:*", "parsedquery":"+(+MatchAllDocsQuery(*:*)) ()", "parsedquery_toString":"+(+*:*) ()", "json":{"params":{ "q":"*:*

Re: knn parser not working as expected

2023-08-02 Thread Alessandro Benedetti
Can you post the debug section related to query parsing? You can get it using 'debug=query'. What's your select request handler configuration? Cheers -- *Alessandro Benedetti* Director @ Sease Ltd. *Apache Lucene/Solr Committer* *Apache Solr PMC Member* e-mail: a.benede...

Re: knn parser not working as expected

2023-07-31 Thread gnandre
Any pointers where should I look to resolve this issue? Thanks! On Thu, Jul 27, 2023 at 9:25 PM gnandre wrote: > But the q parameter is still not working. I am stumped. > > On Fri, Jul 21, 2023 at 1:43 AM gnandre wrote: > >> Thanks. If I move the knn parser syntax and value to fq param and make

Re: knn parser not working as expected

2023-07-27 Thread gnandre
But the q parameter is still not working. I am stumped. On Fri, Jul 21, 2023 at 1:43 AM gnandre wrote: > Thanks. If I move the knn parser syntax and value to fq param and make q > as *:*, it works and starts giving relevant results instantly. > > curl -X POST -H "Content-Type: application/json"

Re: knn parser not working as expected

2023-07-20 Thread gnandre
Thanks. If I move the knn parser syntax and value to fq param and make q as *:*, it works and starts giving relevant results instantly. curl -X POST -H "Content-Type: application/json" -d '{ "params": { "q": "*:*", "fq": "{!knn f=dense_vector topK=1}[0.06525743007659912,0.015727980062365532,

Re: knn parser not working as expected

2023-07-19 Thread Matthias Krüger
The query format looks correct. You can add "debug": true to the posted JSON to verify whether your suspicion about Solr not using the KnnQParser is correct. On Wed, Jul 19, 2023 at 7:04 AM gnandre wrote: > Hi, > > I am trying to use the knn parser in Solr 9.2.1 as follows: > > curl -X POST -H "

knn parser not working as expected

2023-07-18 Thread gnandre
Hi, I am trying to use the knn parser in Solr 9.2.1 as follows: curl -X POST -H "Content-Type: application/json" -d '{ "params": { "q": "{!knn f=dense_vector topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906