solr - Prioritize results sandwiched in tags -
i have documents indexed like
{ "content":"lots of text , html", "file_type": "application/pdf", "id": "path_to_file", "comp": "irrelevant fields", "_version_": 1506272321148522231 }
i want solr prioritize results contain queried keyword in <abc>
, </abc>
tags. how can done? have searched lot , didn't relevant answer.
you might able boost @ query-time using regex query.
however, instead, i'd suggest parsing innertext of <abc>something</abc>
it's own field @ index-time (making easy boost @ query-time).
this pre-processing can either done hand, or using patterncapturegroupfilterfactory in custom analysis chain.
Comments
Post a Comment