Can elasticsearch return boolean flags if a certain query matches? -


i'm using elasticsearch find documents bool-query multiple 'should' clauses. clauses represent different "attributes" relative query.

close enough example: index books , want return attributes "title_matches_perfectly", "title_matches_fuzzy_2", "title_matches_slop_2", "author_matches_perfectly", "author_matches_90%", "publisher..." idea.

right 'encode' attributes using score king of 'bitmap' in "function_score" query.

is there better way achieve that?

"script_fields" don't seem allow that.

having script in "script_score" modify result document didn't seem work either. (it resulted in 'unsupported_operation_exception'.)

i know sounds weird use case. elasticsearch made retrieval of documents in list ordered relevancy score , not reasoning why hit hit.

and yet need ...

the solution think of writing custom plugin.

are there other options?


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -