CDRH / api

Codenamed "Apium": An API to access all public Center for Digital Research in the Humanities resources
https://cdrhdev1.unl.edu/api_frontend
MIT License
3 stars 1 forks source link

Weight of titles #115

Open karindalziel opened 3 years ago

karindalziel commented 3 years ago

In archives with an item and things about that item, for example the story "The Wife of His Youth" and "Review of the Wife of His Youth", the actual item gets buried in search results.

One proposed solution would be to add a "search boost" field to elevate the rankings or particular items (perhaps items with a particular author, etc)

On the schema and datura side, we would need to add the field, on the API side, we would need to have it recognize that field to boost results (see: https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-boost.html)

We will also need to figure out how to handle multiple languages, so one search boost field per text language field?

Related to https://github.com/CDRH/chesnutt/issues/87

jduss4 commented 3 years ago

Pardon my intrusion. I agree it looks like to use that boost on a text field you'd have to be using something like title_text_en and title_text_es in order to get the value out of it, unless if there's some way to include keyword fields in a text search. You'd also need to change it somewhere in the orchid bridge default settings, the orchid config, or have the API automatically assume that any text searches should include those new text fields with the boosted value. I would think some combination so that you could override the settings would be good, because I feel like multiple languages could get kinda funky unless if orchid bridge was smart enough to know "oh, you're searching text_es so you must also need title_text_es or something like that.