manticoresoftware / manticoresearch

Easy to use open source fast database for search | Good alternative to Elasticsearch now | Drop-in replacement for E in the ELK soon
https://manticoresearch.com
GNU General Public License v3.0
9.04k stars 507 forks source link

add support of min ranking factor aggregation functions #2565

Open tomatolog opened 2 months ago

tomatolog commented 2 months ago

Proposal:

it could be better to add min ranking factor aggregation function along with max \ top ranking factor aggregation function Manticore already has to track down the first matching term in the complex query at the document or maybe add dedicated factor for that, ie similar to

doc_word_count | document | int | number of unique keywords matched in the document

Manticore could add a new factor

min_query_word | document | int | the first query term matched in the document

that allows to track down group that matched at the query and set custom weights for matched documents - for the query ( "test me up" ) | ( =test =me =up ) | ( "test me up"/1 ) document that matched 1st group to get on top

Checklist:

To be completed by the assignee. Check off tasks that have been completed or are not applicable.

- [ ] Implementation completed - [ ] Tests developed - [ ] Documentation updated - [ ] Documentation reviewed - [ ] [Changelog](https://docs.google.com/spreadsheets/d/1mz_3dRWKs86FjRF7EIZUziUDK_2Hvhd97G0pLpxo05s/edit?pli=1&gid=1102439133#gid=1102439133) updated - [x] OpenAPI YAML updated and issue created to rebuild clients