You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucenenet.apache.org by Ed Jones <Ed...@warc.com> on 2006/05/18 11:07:34 UTC

Ranking and Scoring Hits

Hi,

 

I've only just downloaded Lucene.net and I've been doing some initial
work on it.

I've written an indexer and got a test button working to run queries to
find the results. So far I like it and it's wonderfully fast, however,
I'm trying to return the score for each returned result, mainly so I can
tell how relevant result 1 is over result 2. I've looked though the
documentation and can't find how to do this. Can anyone give me a
pointer? Also can somebody confirm that the default search results are
in relevance order?

 

Thanks

Ed


RE: Ranking and Scoring Hits

Posted by George Aroush <ge...@aroush.net>.
Hi Ed,

I have posted your question to lucene-net-user group.  Please subscribe to
this group so you can post yourself next time.

As for your question, a good place you can start is to get a copy of "Lucene
In Action" book.  It is written for Java Lucene, but the API's are the same
in the C# port except for the naming convention.

Regards,

-- George Aroush

-----Original Message-----
From: Ed Jones [mailto:Edmund.Jones@warc.com] 
Sent: Thursday, May 18, 2006 1:27 PM
To: lucene-net-user@incubator.apache.org
Subject: RE: Ranking and Scoring Hits

Thanks Jeff, that worked perfectly.

Now a follow up question, can anyone recommend a good source for examples of
code or how to do certain things like boost particular fields or even
better, re-weight fields when they contain a certain value?

Thanks
Ed

-----Original Message-----
From: Jeff Rodenburg [mailto:jeff.rodenburg@gmail.com]
Sent: 18 May 2006 17:08
To: lucene-net-dev@incubator.apache.org
Subject: Re: Ranking and Scoring Hits

Hi Ed -

For future reference, these questions are intended to be directed to the
lucene-net-user mailing list.

When iterating on your Hits collection, call Hits.Score() the same way you
call Hits.Doc() -- by passing it the index value (int) for your loop
iteration.

On 5/18/06, Ed Jones <Ed...@warc.com> wrote:
>
> Hi,
>
>
>
> I've only just downloaded Lucene.net and I've been doing some initial 
> work on it.
>
> I've written an indexer and got a test button working to run queries
to
> find the results. So far I like it and it's wonderfully fast, however, 
> I'm trying to return the score for each returned result, mainly so I
can
> tell how relevant result 1 is over result 2. I've looked though the 
> documentation and can't find how to do this. Can anyone give me a 
> pointer? Also can somebody confirm that the default search results are 
> in relevance order?
>
>
>
> Thanks
>
> Ed
>
>
>


RE: Ranking and Scoring Hits

Posted by Ed Jones <Ed...@warc.com>.
Thanks Jeff, that worked perfectly.

Now a follow up question, can anyone recommend a good source for
examples of code or how to do certain things like boost particular
fields or even better, re-weight fields when they contain a certain
value?

Thanks
Ed

-----Original Message-----
From: Jeff Rodenburg [mailto:jeff.rodenburg@gmail.com] 
Sent: 18 May 2006 17:08
To: lucene-net-dev@incubator.apache.org
Subject: Re: Ranking and Scoring Hits

Hi Ed -

For future reference, these questions are intended to be directed to the
lucene-net-user mailing list.

When iterating on your Hits collection, call Hits.Score() the same way
you
call Hits.Doc() -- by passing it the index value (int) for your loop
iteration.

On 5/18/06, Ed Jones <Ed...@warc.com> wrote:
>
> Hi,
>
>
>
> I've only just downloaded Lucene.net and I've been doing some initial
> work on it.
>
> I've written an indexer and got a test button working to run queries
to
> find the results. So far I like it and it's wonderfully fast, however,
> I'm trying to return the score for each returned result, mainly so I
can
> tell how relevant result 1 is over result 2. I've looked though the
> documentation and can't find how to do this. Can anyone give me a
> pointer? Also can somebody confirm that the default search results are
> in relevance order?
>
>
>
> Thanks
>
> Ed
>
>
>

Re: Ranking and Scoring Hits

Posted by Jeff Rodenburg <je...@gmail.com>.
Hi Ed -

For future reference, these questions are intended to be directed to the
lucene-net-user mailing list.

When iterating on your Hits collection, call Hits.Score() the same way you
call Hits.Doc() -- by passing it the index value (int) for your loop
iteration.

On 5/18/06, Ed Jones <Ed...@warc.com> wrote:
>
> Hi,
>
>
>
> I've only just downloaded Lucene.net and I've been doing some initial
> work on it.
>
> I've written an indexer and got a test button working to run queries to
> find the results. So far I like it and it's wonderfully fast, however,
> I'm trying to return the score for each returned result, mainly so I can
> tell how relevant result 1 is over result 2. I've looked though the
> documentation and can't find how to do this. Can anyone give me a
> pointer? Also can somebody confirm that the default search results are
> in relevance order?
>
>
>
> Thanks
>
> Ed
>
>
>