You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Craig Stadler <cs...@hotmail.com> on 2011/10/22 03:26:59 UTC

Date boosting with dismax question

Solr Specification Version: 1.4.0
Solr Implementation Version: 1.4.0 833479 - grantingersoll - 2009-11-06 
12:33:40
Lucene Specification Version: 2.9.1
Lucene Implementation Version: 2.9.1 832363 - 2009-11-03 04:37:25

<fieldType name="tdate" class="solr.TrieDateField" omitNorms="true" 
precisionStep="6" positionIncrementGap="0"/>

<field name="created" type="tdate" multiValued="false" indexed="true" 
stored="false" omitNorms="true"  required="false" 
omitTermFreqAndPositions="true" />

I am using 'created' as the name of the date field.

My dates are being populated as such :
1980-01-01T00:00:00Z

Search handler (solrconfig) :

<requestHandler name="/dismax" class="solr.SearchHandler">
<lst name="defaults">
<str name="defType">dismax</str>
<str name="echoParams">explicit</str>
<str name="tie">0.1</str>
<str name="qf">name0^20000 other ^10000</str>
<str name="pf">name0^20000 other ^10000</str>
<str name="qs">3</str>
<str name="ps">3</str>
<str name="q.alt">*:*</str>
</lst>
</requestHandler>

----------------------------------------------

Query :

/solr/ftf/dismax/?q=libya
&debugQuery=off
&hl=true
&start=
&rows=10
----------------------------------------------

I am trying to factor in created to the SCORE. (boost) I have tried a 
million ways to do this, no success. I know the dates are populating 
correctly because I can sort by them. Can anyone help me implement date 
boosting with dismax under this scenario???

-Craig 


Re: Date boosting with dismax question

Posted by Erik Hatcher <er...@gmail.com>.
Also, those boosts on your qf and pf are a red flag and may be causing you issues.  Look at explains provided with debugQuery=true output to see how your field/phrase boosts are working in conjunction with your date boosting attempts.

	Erik

On Oct 23, 2011, at 17:15 , Erick Erickson wrote:

> Define "not working". Show what you're getting and what you
> expect to find. Show your data. Note that the example given
> boosts on quite coarse dates, it *tends* to make documents
> published in a particular *year* score higher.
> 
> You might review:
> http://wiki.apache.org/solr/UsingMailingLists
> 
> Best
> Erick
> 
> On Sun, Oct 23, 2011 at 11:08 PM, Craig Stadler <cs...@hotmail.com> wrote:
>> Yes I have and I cannot get it to work. Perhaps something is out of version
>> for my setup?
>> I tried for 3 hours to get ever example I could find to work.
>> 
>> ----- Original Message ----- From: "Erick Erickson"
>> <er...@gmail.com>
>> To: <so...@lucene.apache.org>
>> Sent: Sunday, October 23, 2011 5:07 PM
>> Subject: Re: Date boosting with dismax question
>> 
>> 
>> Have you seen this?
>> 
>> http://wiki.apache.org/solr/SolrRelevancyFAQ#How_can_I_boost_the_score_of_newer_documents
>> 
>> Best
>> Erick
>> 
>> 
>> On Sat, Oct 22, 2011 at 3:26 AM, Craig Stadler <cs...@hotmail.com>
>> wrote:
>>> 
>>> Solr Specification Version: 1.4.0
>>> Solr Implementation Version: 1.4.0 833479 - grantingersoll - 2009-11-06
>>> 12:33:40
>>> Lucene Specification Version: 2.9.1
>>> Lucene Implementation Version: 2.9.1 832363 - 2009-11-03 04:37:25
>>> 
>>> <fieldType name="tdate" class="solr.TrieDateField" omitNorms="true"
>>> precisionStep="6" positionIncrementGap="0"/>
>>> 
>>> <field name="created" type="tdate" multiValued="false" indexed="true"
>>> stored="false" omitNorms="true" required="false"
>>> omitTermFreqAndPositions="true" />
>>> 
>>> I am using 'created' as the name of the date field.
>>> 
>>> My dates are being populated as such :
>>> 1980-01-01T00:00:00Z
>>> 
>>> Search handler (solrconfig) :
>>> 
>>> <requestHandler name="/dismax" class="solr.SearchHandler">
>>> <lst name="defaults">
>>> <str name="defType">dismax</str>
>>> <str name="echoParams">explicit</str>
>>> <str name="tie">0.1</str>
>>> <str name="qf">name0^20000 other ^10000</str>
>>> <str name="pf">name0^20000 other ^10000</str>
>>> <str name="qs">3</str>
>>> <str name="ps">3</str>
>>> <str name="q.alt">*:*</str>
>>> </lst>
>>> </requestHandler>
>>> 
>>> ----------------------------------------------
>>> 
>>> Query :
>>> 
>>> /solr/ftf/dismax/?q=libya
>>> &debugQuery=off
>>> &hl=true
>>> &start=
>>> &rows=10
>>> ----------------------------------------------
>>> 
>>> I am trying to factor in created to the SCORE. (boost) I have tried a
>>> million ways to do this, no success. I know the dates are populating
>>> correctly because I can sort by them. Can anyone help me implement date
>>> boosting with dismax under this scenario???
>>> 
>>> -Craig
>>> 
>> 
>> 


Re: Date boosting with dismax question

Posted by Erick Erickson <er...@gmail.com>.
Define "not working". Show what you're getting and what you
expect to find. Show your data. Note that the example given
boosts on quite coarse dates, it *tends* to make documents
published in a particular *year* score higher.

You might review:
http://wiki.apache.org/solr/UsingMailingLists

Best
Erick

On Sun, Oct 23, 2011 at 11:08 PM, Craig Stadler <cs...@hotmail.com> wrote:
> Yes I have and I cannot get it to work. Perhaps something is out of version
> for my setup?
> I tried for 3 hours to get ever example I could find to work.
>
> ----- Original Message ----- From: "Erick Erickson"
> <er...@gmail.com>
> To: <so...@lucene.apache.org>
> Sent: Sunday, October 23, 2011 5:07 PM
> Subject: Re: Date boosting with dismax question
>
>
> Have you seen this?
>
> http://wiki.apache.org/solr/SolrRelevancyFAQ#How_can_I_boost_the_score_of_newer_documents
>
> Best
> Erick
>
>
> On Sat, Oct 22, 2011 at 3:26 AM, Craig Stadler <cs...@hotmail.com>
> wrote:
>>
>> Solr Specification Version: 1.4.0
>> Solr Implementation Version: 1.4.0 833479 - grantingersoll - 2009-11-06
>> 12:33:40
>> Lucene Specification Version: 2.9.1
>> Lucene Implementation Version: 2.9.1 832363 - 2009-11-03 04:37:25
>>
>> <fieldType name="tdate" class="solr.TrieDateField" omitNorms="true"
>> precisionStep="6" positionIncrementGap="0"/>
>>
>> <field name="created" type="tdate" multiValued="false" indexed="true"
>> stored="false" omitNorms="true" required="false"
>> omitTermFreqAndPositions="true" />
>>
>> I am using 'created' as the name of the date field.
>>
>> My dates are being populated as such :
>> 1980-01-01T00:00:00Z
>>
>> Search handler (solrconfig) :
>>
>> <requestHandler name="/dismax" class="solr.SearchHandler">
>> <lst name="defaults">
>> <str name="defType">dismax</str>
>> <str name="echoParams">explicit</str>
>> <str name="tie">0.1</str>
>> <str name="qf">name0^20000 other ^10000</str>
>> <str name="pf">name0^20000 other ^10000</str>
>> <str name="qs">3</str>
>> <str name="ps">3</str>
>> <str name="q.alt">*:*</str>
>> </lst>
>> </requestHandler>
>>
>> ----------------------------------------------
>>
>> Query :
>>
>> /solr/ftf/dismax/?q=libya
>> &debugQuery=off
>> &hl=true
>> &start=
>> &rows=10
>> ----------------------------------------------
>>
>> I am trying to factor in created to the SCORE. (boost) I have tried a
>> million ways to do this, no success. I know the dates are populating
>> correctly because I can sort by them. Can anyone help me implement date
>> boosting with dismax under this scenario???
>>
>> -Craig
>>
>
>

Re: Date boosting with dismax question

Posted by Craig Stadler <cs...@hotmail.com>.
Yes I have and I cannot get it to work. Perhaps something is out of version 
for my setup?
I tried for 3 hours to get ever example I could find to work.

----- Original Message ----- 
From: "Erick Erickson" <er...@gmail.com>
To: <so...@lucene.apache.org>
Sent: Sunday, October 23, 2011 5:07 PM
Subject: Re: Date boosting with dismax question


Have you seen this?

http://wiki.apache.org/solr/SolrRelevancyFAQ#How_can_I_boost_the_score_of_newer_documents

Best
Erick


On Sat, Oct 22, 2011 at 3:26 AM, Craig Stadler <cs...@hotmail.com> 
wrote:
> Solr Specification Version: 1.4.0
> Solr Implementation Version: 1.4.0 833479 - grantingersoll - 2009-11-06
> 12:33:40
> Lucene Specification Version: 2.9.1
> Lucene Implementation Version: 2.9.1 832363 - 2009-11-03 04:37:25
>
> <fieldType name="tdate" class="solr.TrieDateField" omitNorms="true"
> precisionStep="6" positionIncrementGap="0"/>
>
> <field name="created" type="tdate" multiValued="false" indexed="true"
> stored="false" omitNorms="true" required="false"
> omitTermFreqAndPositions="true" />
>
> I am using 'created' as the name of the date field.
>
> My dates are being populated as such :
> 1980-01-01T00:00:00Z
>
> Search handler (solrconfig) :
>
> <requestHandler name="/dismax" class="solr.SearchHandler">
> <lst name="defaults">
> <str name="defType">dismax</str>
> <str name="echoParams">explicit</str>
> <str name="tie">0.1</str>
> <str name="qf">name0^20000 other ^10000</str>
> <str name="pf">name0^20000 other ^10000</str>
> <str name="qs">3</str>
> <str name="ps">3</str>
> <str name="q.alt">*:*</str>
> </lst>
> </requestHandler>
>
> ----------------------------------------------
>
> Query :
>
> /solr/ftf/dismax/?q=libya
> &debugQuery=off
> &hl=true
> &start=
> &rows=10
> ----------------------------------------------
>
> I am trying to factor in created to the SCORE. (boost) I have tried a
> million ways to do this, no success. I know the dates are populating
> correctly because I can sort by them. Can anyone help me implement date
> boosting with dismax under this scenario???
>
> -Craig
>


Re: Date boosting with dismax question

Posted by Erick Erickson <er...@gmail.com>.
Have you seen this?

http://wiki.apache.org/solr/SolrRelevancyFAQ#How_can_I_boost_the_score_of_newer_documents

Best
Erick


On Sat, Oct 22, 2011 at 3:26 AM, Craig Stadler <cs...@hotmail.com> wrote:
> Solr Specification Version: 1.4.0
> Solr Implementation Version: 1.4.0 833479 - grantingersoll - 2009-11-06
> 12:33:40
> Lucene Specification Version: 2.9.1
> Lucene Implementation Version: 2.9.1 832363 - 2009-11-03 04:37:25
>
> <fieldType name="tdate" class="solr.TrieDateField" omitNorms="true"
> precisionStep="6" positionIncrementGap="0"/>
>
> <field name="created" type="tdate" multiValued="false" indexed="true"
> stored="false" omitNorms="true"  required="false"
> omitTermFreqAndPositions="true" />
>
> I am using 'created' as the name of the date field.
>
> My dates are being populated as such :
> 1980-01-01T00:00:00Z
>
> Search handler (solrconfig) :
>
> <requestHandler name="/dismax" class="solr.SearchHandler">
> <lst name="defaults">
> <str name="defType">dismax</str>
> <str name="echoParams">explicit</str>
> <str name="tie">0.1</str>
> <str name="qf">name0^20000 other ^10000</str>
> <str name="pf">name0^20000 other ^10000</str>
> <str name="qs">3</str>
> <str name="ps">3</str>
> <str name="q.alt">*:*</str>
> </lst>
> </requestHandler>
>
> ----------------------------------------------
>
> Query :
>
> /solr/ftf/dismax/?q=libya
> &debugQuery=off
> &hl=true
> &start=
> &rows=10
> ----------------------------------------------
>
> I am trying to factor in created to the SCORE. (boost) I have tried a
> million ways to do this, no success. I know the dates are populating
> correctly because I can sort by them. Can anyone help me implement date
> boosting with dismax under this scenario???
>
> -Craig
>