You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@solr.apache.org by Alessandro Benedetti <a....@sease.io> on 2023/08/02 08:16:13 UTC

Re: knn parser not working as expected

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.benedetti@sease.io


*Sease* - Information Retrieval Applied
Consulting | Training | Open Source

Website: Sease.io <http://sease.io/>
LinkedIn <https://linkedin.com/company/sease-ltd> | Twitter
<https://twitter.com/seaseltd> | Youtube
<https://www.youtube.com/channel/UCDx86ZKLYNpI3gzMercM7BQ> | Github
<https://github.com/seaseltd>

[image: Mailtrack]
<https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&>
Sender
notified by
Mailtrack
<https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&>
02/08/23,
10:12:48

On Mon, 31 Jul 2023 at 22:19, gnandre <ar...@gmail.com> wrote:

> Any pointers where should I look to resolve this issue? Thanks!
>
> On Thu, Jul 27, 2023 at 9:25 PM gnandre <ar...@gmail.com> wrote:
>
> > But the q parameter is still not working. I am stumped.
> >
> > On Fri, Jul 21, 2023 at 1:43 AM gnandre <ar...@gmail.com> 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" -d '{
> >>   "params": {
> >>     "q": "*:*", "fq": "{!knn f=dense_vector
> >>
> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
> >> "fl": "url,score"
> >>   }
> >> }' http://localhost:8983/solr/doc/select
> >>
> >> On Wed, Jul 19, 2023 at 3:25 AM Matthias Krüger <
> >> mkrueger@opensourceconnections.com> wrote:
> >>
> >>> 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 <ar...@gmail.com>
> wrote:
> >>>
> >>> > 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,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
> >>> > "fl": "url,score"
> >>> >   }
> >>> > }' http://localhost:8983/solr/doc/select
> >>> >
> >>> > It returns the results but the results seem to be matching to knn as
> a
> >>> word
> >>> > instead of treating it as a parser. The search query vector is not
> >>> related
> >>> > to any knn topic. Am I missing something?
> >>> > I am using post request because if I use get request then I run into
> a
> >>> URI
> >>> > too long issue.
> >>> >
> >>>
> >>
>

Re: knn parser not working as expected

Posted by gnandre <ar...@gmail.com>.
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 not matter for dense vector search right? like qf, pf, tie etc shown
below?
I might as well just use an empty request handler for the dense vector
search.

<requestHandler name="/select" class="solr.SearchHandler"> <!-- default
values for query parameters --> <lst name="defaults"> <str name=
"lowercaseOperators">true</str> <str name="echoParams">explicit</str> <float
name="tie">0.01</float> <str name="qf"> body^0.5 title^1.2 </str> <str name=
"pf"> body^0.5 title^1.2 site^1.5 </str> <int name="ps">100</int> <str name=
"q.op">AND</str> </lst> </requestHandler>

On Mon, Aug 7, 2023 at 8:35 PM Joel Bernstein <jo...@gmail.com> wrote:

> 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 <jo...@gmail.com> wrote:
>
> > 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 gnandre <ar...@gmail.com> wrote:
> >
> >> 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":"*:*",
> >>         "fq":"{!knn f=dense_vector
> >>
> >>
> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
> >>         "fl":"url,score",
> >>         "debug":"query"}},
> >>     "QParser":"ExtendedDismaxQParser",
> >>     "altquerystring":null,
> >>     "boost_queries":null,
> >>     "parsed_boost_queries":[],
> >>     "boostfuncs":null,
> >>     "filter_queries":["{!knn f=dense_vector
> >>
> >>
> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]"],
> >>
> >>
> >>
> "parsed_filter_queries":["KnnVectorQuery(KnnVectorQuery:dense_vector[0.06525743,...][1])"]}}
> >>
> >> On Fri, Aug 4, 2023 at 12:04 PM gnandre <ar...@gmail.com>
> wrote:
> >>
> >> >
> >> > Thanks for your replies. Debug output is very large. I added it to a
> >> file
> >> > and attached it to this email.
> >> >
> >> > And here is the config for select request handler
> >> >
> >> > <requestHandler name="/select" class="solr.SearchHandler"> <!--
> default
> >> > values for query parameters --> <lst name="defaults"> <str
> >> name="defType">
> >> > edismax</str> <str name="lowercaseOperators">true</str> <str name=
> >> > "echoParams">explicit</str> <float name="tie">0.01</float> <str
> >> name="qf">
> >> > body^0.5 title^1.2 </str> <str name="pf"> body^0.5 title^1.2 site^1.5
> </
> >> > str> <int name="ps">100</int> <str name="q.op">AND</str> </lst> </
> >> > requestHandler>
> >> >
> >> >
> >> > On Wed, Aug 2, 2023 at 4:16 AM Alessandro Benedetti <
> >> a.benedetti@sease.io>
> >> > wrote:
> >> >
> >> >> 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.benedetti@sease.io
> >> >>
> >> >>
> >> >> *Sease* - Information Retrieval Applied
> >> >> Consulting | Training | Open Source
> >> >>
> >> >> Website: Sease.io <http://sease.io/>
> >> >> LinkedIn <https://linkedin.com/company/sease-ltd> | Twitter
> >> >> <https://twitter.com/seaseltd> | Youtube
> >> >> <https://www.youtube.com/channel/UCDx86ZKLYNpI3gzMercM7BQ> | Github
> >> >> <https://github.com/seaseltd>
> >> >>
> >> >> [image: Mailtrack]
> >> >> <
> >> >>
> >>
> https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&
> >> >> >
> >> >> Sender
> >> >> notified by
> >> >> Mailtrack
> >> >> <
> >> >>
> >>
> https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&
> >> >> >
> >> >> 02/08/23,
> >> >> 10:12:48
> >> >>
> >> >> On Mon, 31 Jul 2023 at 22:19, gnandre <ar...@gmail.com>
> wrote:
> >> >>
> >> >> > Any pointers where should I look to resolve this issue? Thanks!
> >> >> >
> >> >> > On Thu, Jul 27, 2023 at 9:25 PM gnandre <ar...@gmail.com>
> >> >> wrote:
> >> >> >
> >> >> > > But the q parameter is still not working. I am stumped.
> >> >> > >
> >> >> > > On Fri, Jul 21, 2023 at 1:43 AM gnandre <arnoldbronley@gmail.com
> >
> >> >> 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" -d '{
> >> >> > >>   "params": {
> >> >> > >>     "q": "*:*", "fq": "{!knn f=dense_vector
> >> >> > >>
> >> >> >
> >> >>
> >>
> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
> >> >> > >> "fl": "url,score"
> >> >> > >>   }
> >> >> > >> }' http://localhost:8983/solr/doc/select
> >> >> > >>
> >> >> > >> On Wed, Jul 19, 2023 at 3:25 AM Matthias Krüger <
> >> >> > >> mkrueger@opensourceconnections.com> wrote:
> >> >> > >>
> >> >> > >>> 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 <
> arnoldbronley@gmail.com
> >> >
> >> >> > wrote:
> >> >> > >>>
> >> >> > >>> > 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,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
> >> >> > >>> > "fl": "url,score"
> >> >> > >>> >   }
> >> >> > >>> > }' http://localhost:8983/solr/doc/select
> >> >> > >>> >
> >> >> > >>> > It returns the results but the results seem to be matching to
> >> knn
> >> >> as
> >> >> > a
> >> >> > >>> word
> >> >> > >>> > instead of treating it as a parser. The search query vector
> is
> >> not
> >> >> > >>> related
> >> >> > >>> > to any knn topic. Am I missing something?
> >> >> > >>> > I am using post request because if I use get request then I
> run
> >> >> into
> >> >> > a
> >> >> > >>> URI
> >> >> > >>> > too long issue.
> >> >> > >>> >
> >> >> > >>>
> >> >> > >>
> >> >> >
> >> >>
> >> >
> >>
> >
>

Re: knn parser not working as expected

Posted by Joel Bernstein <jo...@gmail.com>.
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 <jo...@gmail.com> wrote:

> 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 gnandre <ar...@gmail.com> wrote:
>
>> 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":"*:*",
>>         "fq":"{!knn f=dense_vector
>>
>> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
>>         "fl":"url,score",
>>         "debug":"query"}},
>>     "QParser":"ExtendedDismaxQParser",
>>     "altquerystring":null,
>>     "boost_queries":null,
>>     "parsed_boost_queries":[],
>>     "boostfuncs":null,
>>     "filter_queries":["{!knn f=dense_vector
>>
>> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]"],
>>
>>
>> "parsed_filter_queries":["KnnVectorQuery(KnnVectorQuery:dense_vector[0.06525743,...][1])"]}}
>>
>> On Fri, Aug 4, 2023 at 12:04 PM gnandre <ar...@gmail.com> wrote:
>>
>> >
>> > Thanks for your replies. Debug output is very large. I added it to a
>> file
>> > and attached it to this email.
>> >
>> > And here is the config for select request handler
>> >
>> > <requestHandler name="/select" class="solr.SearchHandler"> <!-- default
>> > values for query parameters --> <lst name="defaults"> <str
>> name="defType">
>> > edismax</str> <str name="lowercaseOperators">true</str> <str name=
>> > "echoParams">explicit</str> <float name="tie">0.01</float> <str
>> name="qf">
>> > body^0.5 title^1.2 </str> <str name="pf"> body^0.5 title^1.2 site^1.5 </
>> > str> <int name="ps">100</int> <str name="q.op">AND</str> </lst> </
>> > requestHandler>
>> >
>> >
>> > On Wed, Aug 2, 2023 at 4:16 AM Alessandro Benedetti <
>> a.benedetti@sease.io>
>> > wrote:
>> >
>> >> 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.benedetti@sease.io
>> >>
>> >>
>> >> *Sease* - Information Retrieval Applied
>> >> Consulting | Training | Open Source
>> >>
>> >> Website: Sease.io <http://sease.io/>
>> >> LinkedIn <https://linkedin.com/company/sease-ltd> | Twitter
>> >> <https://twitter.com/seaseltd> | Youtube
>> >> <https://www.youtube.com/channel/UCDx86ZKLYNpI3gzMercM7BQ> | Github
>> >> <https://github.com/seaseltd>
>> >>
>> >> [image: Mailtrack]
>> >> <
>> >>
>> https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&
>> >> >
>> >> Sender
>> >> notified by
>> >> Mailtrack
>> >> <
>> >>
>> https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&
>> >> >
>> >> 02/08/23,
>> >> 10:12:48
>> >>
>> >> On Mon, 31 Jul 2023 at 22:19, gnandre <ar...@gmail.com> wrote:
>> >>
>> >> > Any pointers where should I look to resolve this issue? Thanks!
>> >> >
>> >> > On Thu, Jul 27, 2023 at 9:25 PM gnandre <ar...@gmail.com>
>> >> wrote:
>> >> >
>> >> > > But the q parameter is still not working. I am stumped.
>> >> > >
>> >> > > On Fri, Jul 21, 2023 at 1:43 AM gnandre <ar...@gmail.com>
>> >> 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" -d '{
>> >> > >>   "params": {
>> >> > >>     "q": "*:*", "fq": "{!knn f=dense_vector
>> >> > >>
>> >> >
>> >>
>> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
>> >> > >> "fl": "url,score"
>> >> > >>   }
>> >> > >> }' http://localhost:8983/solr/doc/select
>> >> > >>
>> >> > >> On Wed, Jul 19, 2023 at 3:25 AM Matthias Krüger <
>> >> > >> mkrueger@opensourceconnections.com> wrote:
>> >> > >>
>> >> > >>> 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 <arnoldbronley@gmail.com
>> >
>> >> > wrote:
>> >> > >>>
>> >> > >>> > 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,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
>> >> > >>> > "fl": "url,score"
>> >> > >>> >   }
>> >> > >>> > }' http://localhost:8983/solr/doc/select
>> >> > >>> >
>> >> > >>> > It returns the results but the results seem to be matching to
>> knn
>> >> as
>> >> > a
>> >> > >>> word
>> >> > >>> > instead of treating it as a parser. The search query vector is
>> not
>> >> > >>> related
>> >> > >>> > to any knn topic. Am I missing something?
>> >> > >>> > I am using post request because if I use get request then I run
>> >> into
>> >> > a
>> >> > >>> URI
>> >> > >>> > too long issue.
>> >> > >>> >
>> >> > >>>
>> >> > >>
>> >> >
>> >>
>> >
>>
>

Re: knn parser not working as expected

Posted by Joel Bernstein <jo...@gmail.com>.
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 gnandre <ar...@gmail.com> wrote:

> 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":"*:*",
>         "fq":"{!knn f=dense_vector
>
> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
>         "fl":"url,score",
>         "debug":"query"}},
>     "QParser":"ExtendedDismaxQParser",
>     "altquerystring":null,
>     "boost_queries":null,
>     "parsed_boost_queries":[],
>     "boostfuncs":null,
>     "filter_queries":["{!knn f=dense_vector
>
> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]"],
>
>
> "parsed_filter_queries":["KnnVectorQuery(KnnVectorQuery:dense_vector[0.06525743,...][1])"]}}
>
> On Fri, Aug 4, 2023 at 12:04 PM gnandre <ar...@gmail.com> wrote:
>
> >
> > Thanks for your replies. Debug output is very large. I added it to a file
> > and attached it to this email.
> >
> > And here is the config for select request handler
> >
> > <requestHandler name="/select" class="solr.SearchHandler"> <!-- default
> > values for query parameters --> <lst name="defaults"> <str
> name="defType">
> > edismax</str> <str name="lowercaseOperators">true</str> <str name=
> > "echoParams">explicit</str> <float name="tie">0.01</float> <str
> name="qf">
> > body^0.5 title^1.2 </str> <str name="pf"> body^0.5 title^1.2 site^1.5 </
> > str> <int name="ps">100</int> <str name="q.op">AND</str> </lst> </
> > requestHandler>
> >
> >
> > On Wed, Aug 2, 2023 at 4:16 AM Alessandro Benedetti <
> a.benedetti@sease.io>
> > wrote:
> >
> >> 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.benedetti@sease.io
> >>
> >>
> >> *Sease* - Information Retrieval Applied
> >> Consulting | Training | Open Source
> >>
> >> Website: Sease.io <http://sease.io/>
> >> LinkedIn <https://linkedin.com/company/sease-ltd> | Twitter
> >> <https://twitter.com/seaseltd> | Youtube
> >> <https://www.youtube.com/channel/UCDx86ZKLYNpI3gzMercM7BQ> | Github
> >> <https://github.com/seaseltd>
> >>
> >> [image: Mailtrack]
> >> <
> >>
> https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&
> >> >
> >> Sender
> >> notified by
> >> Mailtrack
> >> <
> >>
> https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&
> >> >
> >> 02/08/23,
> >> 10:12:48
> >>
> >> On Mon, 31 Jul 2023 at 22:19, gnandre <ar...@gmail.com> wrote:
> >>
> >> > Any pointers where should I look to resolve this issue? Thanks!
> >> >
> >> > On Thu, Jul 27, 2023 at 9:25 PM gnandre <ar...@gmail.com>
> >> wrote:
> >> >
> >> > > But the q parameter is still not working. I am stumped.
> >> > >
> >> > > On Fri, Jul 21, 2023 at 1:43 AM gnandre <ar...@gmail.com>
> >> 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" -d '{
> >> > >>   "params": {
> >> > >>     "q": "*:*", "fq": "{!knn f=dense_vector
> >> > >>
> >> >
> >>
> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
> >> > >> "fl": "url,score"
> >> > >>   }
> >> > >> }' http://localhost:8983/solr/doc/select
> >> > >>
> >> > >> On Wed, Jul 19, 2023 at 3:25 AM Matthias Krüger <
> >> > >> mkrueger@opensourceconnections.com> wrote:
> >> > >>
> >> > >>> 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 <ar...@gmail.com>
> >> > wrote:
> >> > >>>
> >> > >>> > 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,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
> >> > >>> > "fl": "url,score"
> >> > >>> >   }
> >> > >>> > }' http://localhost:8983/solr/doc/select
> >> > >>> >
> >> > >>> > It returns the results but the results seem to be matching to
> knn
> >> as
> >> > a
> >> > >>> word
> >> > >>> > instead of treating it as a parser. The search query vector is
> not
> >> > >>> related
> >> > >>> > to any knn topic. Am I missing something?
> >> > >>> > I am using post request because if I use get request then I run
> >> into
> >> > a
> >> > >>> URI
> >> > >>> > too long issue.
> >> > >>> >
> >> > >>>
> >> > >>
> >> >
> >>
> >
>

Re: knn parser not working as expected

Posted by gnandre <ar...@gmail.com>.
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":"*:*",
        "fq":"{!knn f=dense_vector
topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
        "fl":"url,score",
        "debug":"query"}},
    "QParser":"ExtendedDismaxQParser",
    "altquerystring":null,
    "boost_queries":null,
    "parsed_boost_queries":[],
    "boostfuncs":null,
    "filter_queries":["{!knn f=dense_vector
topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]"],

"parsed_filter_queries":["KnnVectorQuery(KnnVectorQuery:dense_vector[0.06525743,...][1])"]}}

On Fri, Aug 4, 2023 at 12:04 PM gnandre <ar...@gmail.com> wrote:

>
> Thanks for your replies. Debug output is very large. I added it to a file
> and attached it to this email.
>
> And here is the config for select request handler
>
> <requestHandler name="/select" class="solr.SearchHandler"> <!-- default
> values for query parameters --> <lst name="defaults"> <str name="defType">
> edismax</str> <str name="lowercaseOperators">true</str> <str name=
> "echoParams">explicit</str> <float name="tie">0.01</float> <str name="qf">
> body^0.5 title^1.2 </str> <str name="pf"> body^0.5 title^1.2 site^1.5 </
> str> <int name="ps">100</int> <str name="q.op">AND</str> </lst> </
> requestHandler>
>
>
> On Wed, Aug 2, 2023 at 4:16 AM Alessandro Benedetti <a....@sease.io>
> wrote:
>
>> 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.benedetti@sease.io
>>
>>
>> *Sease* - Information Retrieval Applied
>> Consulting | Training | Open Source
>>
>> Website: Sease.io <http://sease.io/>
>> LinkedIn <https://linkedin.com/company/sease-ltd> | Twitter
>> <https://twitter.com/seaseltd> | Youtube
>> <https://www.youtube.com/channel/UCDx86ZKLYNpI3gzMercM7BQ> | Github
>> <https://github.com/seaseltd>
>>
>> [image: Mailtrack]
>> <
>> https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&
>> >
>> Sender
>> notified by
>> Mailtrack
>> <
>> https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&
>> >
>> 02/08/23,
>> 10:12:48
>>
>> On Mon, 31 Jul 2023 at 22:19, gnandre <ar...@gmail.com> wrote:
>>
>> > Any pointers where should I look to resolve this issue? Thanks!
>> >
>> > On Thu, Jul 27, 2023 at 9:25 PM gnandre <ar...@gmail.com>
>> wrote:
>> >
>> > > But the q parameter is still not working. I am stumped.
>> > >
>> > > On Fri, Jul 21, 2023 at 1:43 AM gnandre <ar...@gmail.com>
>> 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" -d '{
>> > >>   "params": {
>> > >>     "q": "*:*", "fq": "{!knn f=dense_vector
>> > >>
>> >
>> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
>> > >> "fl": "url,score"
>> > >>   }
>> > >> }' http://localhost:8983/solr/doc/select
>> > >>
>> > >> On Wed, Jul 19, 2023 at 3:25 AM Matthias Krüger <
>> > >> mkrueger@opensourceconnections.com> wrote:
>> > >>
>> > >>> 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 <ar...@gmail.com>
>> > wrote:
>> > >>>
>> > >>> > 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,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
>> > >>> > "fl": "url,score"
>> > >>> >   }
>> > >>> > }' http://localhost:8983/solr/doc/select
>> > >>> >
>> > >>> > It returns the results but the results seem to be matching to knn
>> as
>> > a
>> > >>> word
>> > >>> > instead of treating it as a parser. The search query vector is not
>> > >>> related
>> > >>> > to any knn topic. Am I missing something?
>> > >>> > I am using post request because if I use get request then I run
>> into
>> > a
>> > >>> URI
>> > >>> > too long issue.
>> > >>> >
>> > >>>
>> > >>
>> >
>>
>

Re: knn parser not working as expected

Posted by gnandre <ar...@gmail.com>.
Thanks for your replies. Debug output is very large. I added it to a file
and attached it to this email.

And here is the config for select request handler

<requestHandler name="/select" class="solr.SearchHandler"> <!-- default
values for query parameters --> <lst name="defaults"> <str name="defType">
edismax</str> <str name="lowercaseOperators">true</str> <str name=
"echoParams">explicit</str> <float name="tie">0.01</float> <str name="qf">
body^0.5 title^1.2 </str> <str name="pf"> body^0.5 title^1.2 site^1.5 </str>
<int name="ps">100</int> <str name="q.op">AND</str> </lst> </requestHandler>


On Wed, Aug 2, 2023 at 4:16 AM Alessandro Benedetti <a....@sease.io>
wrote:

> 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.benedetti@sease.io
>
>
> *Sease* - Information Retrieval Applied
> Consulting | Training | Open Source
>
> Website: Sease.io <http://sease.io/>
> LinkedIn <https://linkedin.com/company/sease-ltd> | Twitter
> <https://twitter.com/seaseltd> | Youtube
> <https://www.youtube.com/channel/UCDx86ZKLYNpI3gzMercM7BQ> | Github
> <https://github.com/seaseltd>
>
> [image: Mailtrack]
> <
> https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&
> >
> Sender
> notified by
> Mailtrack
> <
> https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&
> >
> 02/08/23,
> 10:12:48
>
> On Mon, 31 Jul 2023 at 22:19, gnandre <ar...@gmail.com> wrote:
>
> > Any pointers where should I look to resolve this issue? Thanks!
> >
> > On Thu, Jul 27, 2023 at 9:25 PM gnandre <ar...@gmail.com> wrote:
> >
> > > But the q parameter is still not working. I am stumped.
> > >
> > > On Fri, Jul 21, 2023 at 1:43 AM gnandre <ar...@gmail.com>
> 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" -d '{
> > >>   "params": {
> > >>     "q": "*:*", "fq": "{!knn f=dense_vector
> > >>
> >
> topK=1}[0.06525743007659912,0.015727980062365532,0.003069591475650668,-0.016254400834441185,0.003478930564597249,-0.02475954219698906,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
> > >> "fl": "url,score"
> > >>   }
> > >> }' http://localhost:8983/solr/doc/select
> > >>
> > >> On Wed, Jul 19, 2023 at 3:25 AM Matthias Krüger <
> > >> mkrueger@opensourceconnections.com> wrote:
> > >>
> > >>> 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 <ar...@gmail.com>
> > wrote:
> > >>>
> > >>> > 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,0.020238326862454414,0.010255611501634121,0.05522076040506363,0.020635411143302917,0.05825875699520111,-0.05110647529363632,-0.04696913808584213,0.05991407483816147,-0.0003015052934642881,0.03625837340950966,-0.044656239449977875,-0.06582673639059067,-0.06842341274023056,-0.022927379235625267,0.048230838030576706,-0.12659960985183716,-0.019311215728521347,-0.04432906210422516,0.03600681200623512,0.010301047936081886,0.08415472507476807,0.04727723449468613,-0.0584205724298954,-0.045265913009643555,0.012285877950489521,0.0034233061596751213,-0.00982636958360672,-0.013216182589530945,-0.038882751017808914,-0.05872005969285965,-0.029350444674491882,0.04930287227034569,0.0022274062503129244,0.01728842593729496,-0.033338762819767,-0.045831114053726196,0.072530098259449,0.03804686293005943,0.0021682181395590305,-0.05424166098237038,-0.004494055639952421,0.05843663960695267,0.058729417622089386,0.016252348199486732,0.0019551776349544525,-0.012190568260848522,-0.08235936611890793,-0.003848800901323557,0.028969185426831245,0.047798849642276764,-0.04074695333838463,-0.10175333172082901,0.06699151545763016,-0.06788542866706848,-0.01607389748096466,0.07294511049985886,0.007754810154438019,0.039606861770153046,0.07451225817203522,-0.029679888859391212,0.014015864580869675,0.08055979013442993,0.0010412412229925394,0.13284511864185333,-0.013288799673318863,-0.05446619912981987,-0.03510258346796036,-0.12459734082221985,-0.017629574984312057,-0.04287091642618179,-0.019087448716163635,0.027409998700022697,-0.040427371859550476,-0.1713477075099945,-0.0035959691740572453,0.01750982739031315,-0.06452985852956772,0.10622204840183258,-0.06865541636943817,0.06022517383098602,0.03378240391612053,0.02320132404565811,0.02072194404900074,0.03390982002019882,0.0051648980006575584,0.05843415856361389,-0.07012602686882019,0.046549294143915176,0.005304296966642141,0.09183698892593384,0.060101959854364395,-0.031673040241003036,0.03126641735434532,0.10213921219110489,0.07624002546072006,-0.09995660930871964,0.03316718339920044,-0.040208760648965836,-0.016963355243206024,-0.01603076048195362,-0.00566966412588954,0.0570228286087513,0.006566803902387619,0.028397461399435997,-0.03737075999379158,-0.03357473015785217,-0.05060608312487602,0.0882791057229042,0.14182551205158234,0.01651209406554699,0.047577112913131714,-0.028357332572340965,-0.12397051602602005,0.03264006972312927,0.030581200495362282,0.025287700816988945,-0.08509892970323563,0.0323619470000267,-0.06732083112001419,0.0193667970597744,0.07096285372972488,-5.732041797079612e-33,0.033934514969587326,0.029480531811714172,-0.024119360372424126,0.03248802572488785,0.060654137283563614,-0.04089922457933426,-0.06845896691083908,0.015865417197346687,-0.03816983848810196,0.12768638134002686,-0.047979939728975296,0.01888129487633705,0.01966758444905281,-0.021792754530906677,-0.00209379056468606,-0.060791824012994766,0.07595516741275787,-0.05137578397989273,-0.020345840603113174,0.02730456180870533,-0.08421282470226288,0.0052170781418681145,-0.0396740548312664,0.013655638322234154,0.043763574212789536,0.0368662029504776,-0.021710995584726334,0.03603581339120865,0.04991370812058449,-0.007524373475462198,0.033250145614147186,0.0669487863779068,-0.012807670049369335,-0.08904062211513519,-0.04803512617945671,-0.0461772084236145,0.018098553642630577,0.01096352282911539,0.0617918036878109,0.014066621661186218,-0.03305654972791672,-0.08129353821277618,-0.025270603597164154,0.03537251427769661,0.06029881164431572,0.06169535592198372,0.0355769582092762,0.03534447401762009,-0.047377053648233414,0.053076375275850296,-0.019250469282269478,-0.03837420791387558,-0.00834209006279707,0.031550273299217224,0.004682184662669897,0.0590718574821949,0.0326957181096077,-0.041941817849874496,-0.04179370403289795,-0.010403091087937355,0.11914990842342377,-0.049126915633678436,0.015761952847242355,-0.012162514962255955,-0.05942496284842491,0.04794146493077278,-0.06834675371646881,-0.03294386342167854,0.02242257259786129,0.0774146020412445,-0.10922225564718246,0.023828692734241486,0.054935190826654434,0.0202674251049757,-0.057155776768922806,-0.009578827768564224,-0.051850661635398865,0.09117215871810913,-0.07315851002931595,-0.0019339871359989047,-0.05835318937897682,-0.058747921139001846,-0.05519327148795128,-0.014699703082442284,-0.0020833320450037718,-0.05721793323755264,0.055632084608078,0.006448595318943262,0.0034963993821293116,-0.031087594106793404,-0.09541762620210648,0.03679275885224342,-0.012651922181248665,-0.038976479321718216,-0.013171667233109474,3.5278054836115376e-33,-0.057552605867385864,0.15763822197914124,0.008786757476627827,0.029096176847815514,-0.011134237051010132,0.030201362445950508,0.011168091557919979,-0.04709974676370621,0.02930905669927597,0.03612598031759262,-0.08490683138370514,-0.04587208107113838,0.026682967320084572,0.014088774099946022,0.12396419048309326,-0.02699090726673603,0.06637927889823914,-0.00968120340257883,-0.06504733115434647,-0.046170640736818314,-0.0315704420208931,-0.006762056145817041,-0.06794849783182144,-0.05884737893939018,0.019797949120402336,0.06054931879043579,-0.0051581417210400105,-0.07172201573848724,-0.062175147235393524,-0.027868494391441345,-0.04836481809616089,-0.0633273720741272,0.038408178836107254,-0.033431489020586014,-0.029036421328783035,0.10334699600934982,0.07340064644813538,-0.05352650582790375,-0.024468276649713516,-0.1379987597465515,0.011022605933248997,-0.053774841129779816,-0.017590248957276344,-0.0311097614467144,-0.07848616689443588,0.008732111193239689,0.10567928850650787,0.04568629711866379,0.03746163100004196,0.08157836645841599,-0.0313052162528038,0.017187103629112244,0.033370643854141235,-0.0736677274107933,-0.004571310244500637,-0.04278911277651787,0.054205141961574554,-0.039158374071121216,-0.03453123942017555,0.005338840652257204,-0.029657498002052307,-0.04535561427474022,0.012918487191200256,-0.01397792249917984,-0.07244236022233963,-0.0954984650015831,0.020682185888290405,-0.08599267154932022,0.004027918446809053,0.03545455262064934,0.027814850211143494,0.037980157881975174,-0.00435393862426281,-0.03923747316002846,0.06498643010854721,-0.05458350107073784,-0.10386372357606888,0.025570711120963097,0.00179905048571527,-0.031069142743945122,0.03851190581917763,-0.08406459540128708,0.07572455704212189,0.046933528035879135,-0.07090593874454498,0.031075317412614822,-0.04400062933564186,0.05749618634581566,0.01515665277838707,-0.018395880237221718,0.004246047232300043,0.03683602809906006,-0.04758144170045853,0.013303630985319614,0.0962936133146286,-1.5709828105059387e-08,0.014924479648470879,-0.06025020405650139,0.06000112369656563,-0.018823325634002686,0.041810885071754456,0.06487725675106049,0.06641139090061188,-0.021548083052039146,-0.02588818594813347,0.03283391520380974,-0.00884958729147911,0.001129995915107429,-0.008003215305507183,0.018085693940520287,-0.05119175836443901,0.031176671385765076,0.07230234146118164,0.032498497515916824,-0.0025777993723750114,-0.0019794004037976265,0.02181226573884487,-0.0016418211162090302,-0.02154039964079857,0.028868690133094788,0.0014479466481134295,0.03514840081334114,-0.006448715925216675,0.008944591507315636,-0.054123785346746445,0.10694637149572372,0.0021145630162209272,-0.07010398805141449,-0.008952338248491287,-0.008070561103522778,0.007294138893485069,-0.03885028138756752,0.0015082887839525938,0.06998642534017563,0.005765285808593035,0.03876836970448494,-0.02309378795325756,0.07376298308372498,0.040780749171972275,0.00683277752250433,0.06138405576348305,0.07280934602022171,0.00022122319205664098,-0.07384920120239258,-0.027288105338811874,0.021829331293702126,-0.023778259754180908,-0.034616678953170776,0.019565943628549576,0.020267367362976074,-0.008654153905808926,0.006412972696125507,-0.031085995957255363,0.06110243499279022,-0.04396197944879532,0.021046791225671768,-0.04995771124958992,0.09614221751689911,-0.03452020138502121,-0.07397083938121796]",
> > >>> > "fl": "url,score"
> > >>> >   }
> > >>> > }' http://localhost:8983/solr/doc/select
> > >>> >
> > >>> > It returns the results but the results seem to be matching to knn
> as
> > a
> > >>> word
> > >>> > instead of treating it as a parser. The search query vector is not
> > >>> related
> > >>> > to any knn topic. Am I missing something?
> > >>> > I am using post request because if I use get request then I run
> into
> > a
> > >>> URI
> > >>> > too long issue.
> > >>> >
> > >>>
> > >>
> >
>