How can I use dates to boost my results?

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

How can I use dates to boost my results?

dma_bamboo
Hi

For my search use, the document freshness is a relevant aspect that should
be considered to boost results.

I have a field in my index like this:

<field name="created" type="date" indexed="true" stored="true" />

How can I make a good use of this to boost my results?

I'm using the DisMaxRequestHandler to boost other textual fields based on
the query, but it would improve the results quality a lot if the date where
considered to define the score.


Best Regards,
Daniel


http://www.bbc.co.uk/
This e-mail (and any attachments) is confidential and may contain personal views which are not the views of the BBC unless specifically stated.
If you have received it in error, please delete it from your system.
Do not use, copy or disclose the information in any way nor act in reliance on it and notify the sender immediately.
Please note that the BBC monitors e-mails sent or received.
Further communication will signify your consent to this.
                                       
Reply | Threaded
Open this post in threaded view
|

Re: How can I use dates to boost my results?

Nick Jenkin-2
Hi Daniel
You can use a boosting function,

In the dismax request handler insert the following:

<str name="bf">
        recip(rord(created),1,1000,1000)
</str>

Obviously you will need to modify the values a bit, more info here:
http://wiki.apache.org/solr/FunctionQuery

-Nick

On 6/9/07, Daniel Alheiros <[hidden email]> wrote:

> Hi
>
> For my search use, the document freshness is a relevant aspect that should
> be considered to boost results.
>
> I have a field in my index like this:
>
> <field name="created" type="date" indexed="true" stored="true" />
>
> How can I make a good use of this to boost my results?
>
> I'm using the DisMaxRequestHandler to boost other textual fields based on
> the query, but it would improve the results quality a lot if the date where
> considered to define the score.
>
>
> Best Regards,
> Daniel
>
>
> http://www.bbc.co.uk/
> This e-mail (and any attachments) is confidential and may contain personal views which are not the views of the BBC unless specifically stated.
> If you have received it in error, please delete it from your system.
> Do not use, copy or disclose the information in any way nor act in reliance on it and notify the sender immediately.
> Please note that the BBC monitors e-mails sent or received.
> Further communication will signify your consent to this.
>
>
Reply | Threaded
Open this post in threaded view
|

Re: How can I use dates to boost my results?

dma_bamboo
Hi Nick.

I was exactly what I was looking for.

Thanks,
Daniel


On 9/6/07 13:12, "Nick Jenkin" <[hidden email]> wrote:

> Hi Daniel
> You can use a boosting function,
>
> In the dismax request handler insert the following:
>
> <str name="bf">
>         recip(rord(created),1,1000,1000)
> </str>
>
> Obviously you will need to modify the values a bit, more info here:
> http://wiki.apache.org/solr/FunctionQuery
>
> -Nick
>
> On 6/9/07, Daniel Alheiros <[hidden email]> wrote:
>> Hi
>>
>> For my search use, the document freshness is a relevant aspect that should
>> be considered to boost results.
>>
>> I have a field in my index like this:
>>
>> <field name="created" type="date" indexed="true" stored="true" />
>>
>> How can I make a good use of this to boost my results?
>>
>> I'm using the DisMaxRequestHandler to boost other textual fields based on
>> the query, but it would improve the results quality a lot if the date where
>> considered to define the score.
>>
>>
>> Best Regards,
>> Daniel
>>
>>
>> http://www.bbc.co.uk/
>> This e-mail (and any attachments) is confidential and may contain personal
>> views which are not the views of the BBC unless specifically stated.
>> If you have received it in error, please delete it from your system.
>> Do not use, copy or disclose the information in any way nor act in reliance
>> on it and notify the sender immediately.
>> Please note that the BBC monitors e-mails sent or received.
>> Further communication will signify your consent to this.
>>
>>


http://www.bbc.co.uk/
This e-mail (and any attachments) is confidential and may contain personal views which are not the views of the BBC unless specifically stated.
If you have received it in error, please delete it from your system.
Do not use, copy or disclose the information in any way nor act in reliance on it and notify the sender immediately.
Please note that the BBC monitors e-mails sent or received.
Further communication will signify your consent to this.