Hi!
When doing a search we want to have a have parameters that we set of how to
boost different
scores. for example we want to have the ability to boost newer items in some
case and in some not,
like a sliding scale from only time to only relevancy.
What is the best way of doing this, using Solrj?
Regards Erik
Erik Holstad's gravatar image asked Nov 10 2008 at 20:25 in Lucene-Solr-User by Erik Holstad

1 Answers

My gut tells me that multiplying a function of the date field with the full-text relevancy score will work better than adding a function of the date field. BoostedQuery can do this via BoostQParserPlugin http://lucene.apache.org/solr/api/org/apache/solr/search/BoostQParserPlugin.html
And for the function, you could make it flatter or steeper depending on how much you wanted date to influence the score. Might try a recip function or a linear function on the ord of the date field. We don't yet have any functions that work on the actual date values.
http://wiki.apache.org/solr/FunctionQuery
-Yonik
Yonik Seeley's gravatar image answered Nov 10 2008 at 22:59 by Yonik Seeley

Related Discussions

  • Boosting Top Selling Items in Lucene-solr-user

  • I have been working to try and identify top selling items in an eCommerce app and boost those in the results. The struggle I am having is that our catalog stores products and parts in the same taxonomy. Since parts are ordered more frequently when you search for something like TV you see cables and antennas first. My theory is that someone needs to tag products as Top Selling as a facet then use faceted...

  • How Does Negative Query Boosting Works In Solr 3.6.1 in Lucene-solr-user

  • I am using a negative query boosting for a particular field as given in the solr wiki (*:* -field1:ABC XYZ)^1000 When I do a search now, the top results does not contain value "ABC XYZ" from field1. When I give a search value as ABC DEF and accordingly change the negative query boosting in bq parameter, I notice that the 1st result fetched has the value "ABC DEF" in field1. My question is will...

  • How To Boosting Fisrt Substring In A String Solr. in Lucene-solr-user

  • Hi , In solr, If i m search for for string like Yoga Teacher, it should search for yoga as well as yoga teacher, but it should not search for just teacher like maths teacher or science teacher and any other teacher. How can i do this in solr. Please any one can give me solution to this question. -- Regards, Veena. Banglore....

  • Searching Items With In The Search Results With SOLR in Lucene-solr-user

  • Hi, Is it possible to "Search items with in the search results" using SOLR. If so how? Thanks in advance, Regards, Dilip...

  • Special Character Search In Solr And Boosting Without Altering The Resultset in Lucene-solr-user

  • Hi friends, I am facing a strange problem, When I search a term eg .Net , the solr searches for Net and not includes '.' Is dot a special character in Solr? I tried escaping it with backslash in the url call to solr, but no use same resultset, Also , is there a way to boost some terms within a resultset. I mean I want to boost a term within a result and I don't want to fire...

  • Solr Advanced Boosting in Lucene-solr-user

  • Hello everyone! I am new to Solr and I have been doing a bit of reading about boosting search results. My search index consists of products with different attributes like a title, a description, a brand, a price, a discount percent and so on. I would like to do a fairly complex boosting, so that for example a hit on the brand name, a low price, a high discount percent is boosted compared to a hit...

  • Solr Edismax Field Boosting in Lucene-solr-user

  • Hi We are trying to boost certain fields with relevancy. However we are not getting results as per expectation. Below is the configuration in solr-config.xml. Even though the title field has a lesser boost than metatag.description results for title field are coming higher. We even created test data that have data only in description in metatag.description and title. Example , page 1 has foo...

  • Boosting In Version 1.2 in Lucene-solr-user

  • Hello, Our documents contain three fields. title, keywords, content. What we want is to give priority to the field keywords, than title and last content. So we did the following in our xml file that is to be indexed we put the following letters This is a test foobar This is a test letters foobar This is a test In our schema.xml we have put text No when we do...

  • Can This Type Of Sorting/boosting Be Done By Solr in Lucene-solr-user

  • Hi, I have a journal article citation schema like this: { AT - article_title AID - article_id (Unique id) AREFS - article_references_list (List of article id's referred/cited in this article. Multi-valued) AA - Article Abstract --- other_article_stuff ... } So for example, in order to search for all those articles that refer(cite) article id 51643, I simply need to search for ...

  • Boosting Tips in Lucene-solr-user

  • Hi there! I'm starting with Solr (had previous experience with lucene before). I'm using the Apache Solr 3 Enterprise Search Server book as reference, and the musicbrainz sample data. I deviate from the examples by creating multiple cores (artits,tracks, albums) my boost is: song^4 artist^4 album song artist^4 artist^8 One thing that is being tough is coming with the right boosting...

  • Personalized Boosting in Lucene-solr-user

  • Hello All, I have a requirement or a pre=requirement for our search application. Basically the engine will be on a website with plenty of users and more than 20 different fields, including location. So basically, the question is this: Is it possible to let user's define their position in search when location is queried? Let's say that I am UserA and when you make a search with Moscow, my default...

  • Score Boosting in Lucene-solr-user

  • Hi everyone, I have a requirement to achieve, but i can't figure out how to do it. Hope someone could help me. Here is the requirement: A book has several keyphrases (available to use in searching). The author could buy the search result position with these keyphrases or simply add keyphrases related to this book. Here, I need to implement the search affected by the position field. I'm not so sure...

  • Dynamic Boosting in Lucene-solr-user

  • My problem is a little complex, so please bear with me. I currently have a set of documents that need to be "tiered", and depending on what tier they are in, a configurable boost should be applied, essentially affecting the score and ordering of the search results. My first idea was to create 10 different fields in my schema for these tiers: ... Each document may be part of 0 or 1 tiers. ...

  • Solr Substring Search Yields All Indexed Results in Lucene-solr-user

  • To do a substring search, I have added a new fieldType - "Text" with NgramFilter. It works fine perfectly but downside is this problem Example name = ['Apple','Samy','And','a'] When I do a search name:a, then all the above items gets pulled up. Even when search changes to "App". All the above items are pulled. How can I fix this issue? View this...

  • Boosting Documents Based On Search Term/phrase in Lucene-solr-user

  • Is there a way to boost documents based on the search term/phrase?...

  • Search Specific Boosting in Lucene-solr-user

  • I'm implementing a feature where admins have the ability to control the order of the results by adding a boost to any specific search. The search is a faceted interface (no text input) and which we take a hash of the search parameters (to form a unique search id) and then boost that field for the document. The field is a wild card field so that it might look like this: true The problem is that...

  • Boosting Of Search Results in Lucene-solr-user

  • HI, I want to boost / block search results, i don't want to use boosting of fields/ term of dismaxrequest handler. I have seen some post saying "setting a value to the key $docBoost via transformer", but i am not sure how to use / set doc boost via transformer. http://www.nabble.com/Boosting-Code-td22119017.html#a22119017 Please let me know how should we use docboost or is there any other way...

  • Duplicate Items In Distributed Search in Lucene-solr-user

  • Hi, I'm after a bit of clarification about the 'limitations' section of the distributed search page on the wiki. The first two limitations say: * Documents must have a unique key and the unique key must be stored (stored="true" in schema.xml) * When duplicate doc IDs are received, Solr chooses the first doc and discards subsequent ones Does 'doc ID' in the second point refer to the unique key...

  • Boosting In Query Level The Relevance Based In Content Of Any Fields in Lucene-solr-user

  • Hello, How can I boost in query level the relevance of documents based in content of any fields? Example, I have 5 documents with fields: name and city: name | city Jose | Campinas Jose | São Paulo Jose | Rio de Janeiro Jose | Rio Branco Jose | Ourinhos In search by "Jose", I wish return on top the documents (Jose | São Paulo and Jose | Rio de Janeiro). I don´t want create a third field "important...

  • Boosting The Whole Documents in Lucene-solr-user

  • Hi, I have the following problem. I would like to give a boost to the whole documents as I index them. I am sending to solr xml in the form: .... But it does't seem to alter the search scores in any way. I would expect that to multiply the final search score by two, am I correct? Probably I would need to alter schema.xml, but I found only information on how to do that for specific fields (just ...