What is best factor for wildcard search

Hi all,

I built a autocomplete search base on manticore, it worked great. However I’m trying change a few factors to get the suggested results more consistent. For example with the keyword “hang bo*” and the data I have:

hang bot
hang bo
hang bong

I want to put the result “hang bo” first because it is the best match, but now the weight() of these 3 results is the same and the order given is not what I expected. I tried adjusting a few factors but the weight() didn’t change. Is there any factor or method to get the result “hang bo” first with the keyword “hang bo*” ?

you could query for (hang bo* | "hang bo") to get additional weight for exact matches

thanks Tomat, i tried this but if in case there is a word in between then the case full match will not happen. Example: 36 hang bo* | “36 hang bo”’
in data, I have:

36 pho hang bot
36 pho hang bo
36 pho hang bong

you could use nested group instead of phrase (hang bo* | (hang bo))

thank you very much Tomat, although not as expected but it is a good approach.