-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: how to change documents boost dynamatically in hb search?
PostPosted: Tue Jan 18, 2011 12:02 pm 
Beginner
Beginner

Joined: Mon Oct 27, 2008 6:26 am
Posts: 36
Hi gurus,

With Hibernate search is there anyway to affect the whole documents boost?

i.e.

doc #1 ->setBoost( 1.1f );
doc #2 ->setBoost( 1.5f );


I need to implement book search based on publisher type, bookname, book tags etc. There are three publisher type: A500, B500 and C500. I need book of publisher type A500 have lowest rank in search.

I think there would be two ways to do that: set boost to document and define boost factors in query.

for the second option, I generated query as following:

+activeBook:true +(publisherType:A500^0.001 accountType:B500^0.4 accountType:C500^2.2) +(bookName:java^5.0 bookTags:java^1.0 ...)

But I still can see A500 book show up as first records. Any way to improve that?

IF not, I have to try boost in document. any hints or tips on how to affect the whole documents boost?


Top
 Profile  
 
 Post subject: Re: how to change documents boost dynamatically in hb search?
PostPosted: Wed Jan 19, 2011 8:40 am 
Hibernate Team
Hibernate Team

Joined: Thu Apr 05, 2007 5:52 am
Posts: 1689
Location: Sweden
Have a look at the @DynamicBoost annotation. It sounds this is what you are looking for - http://docs.jboss.org/hibernate/stable/ ... e/#d0e2829

--Hardy


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.