Don't miss out Virtual Happy Hour this Friday (April 26).

Try our conversational search powered by Generative AI!

Lower weight of page type

Vote:
 

Is there a way to lower the weighting of an entire page type?

We're using a TypeSearch for a base page type, but would like to deprioritize (lower) one of it's grandchildren.  There are hundreds of pages of this type, and we're worried about it throwing off searches for other content.

Cheers,

Mark

#253302
Apr 15, 2021 20:30
Vote:
 

Hi Mark,

I think you can use "Boosting" here and apply a lower boost value for your page type-

.BoostMatching(x => x.MatchType(typeof(TestPage)),2)

https://world.episerver.com/documentation/Items/Developers-Guide/EPiServer-Find/11/DotNET-Client-API/Searching/Boosting-with-filters/

#253345
Apr 16, 2021 7:43
Vote:
 

Ravindra,

Thank you for taking the time to reply.  

I meant to add this here, I ended up doing this and it worked:

.BoostMatching(page => page.ContentTypeName().AnyWordBeginsWith("TEST"), 0.1)

This is doing the trick and moving all of the matching page types far down the list.

Cheers,

Mark

#253358
Apr 16, 2021 13:05
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.