You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by John Seer <pu...@yahoo.com> on 2009/07/07 20:31:10 UTC

Multi Value field

Hello,

I  have 100k index with documents with one searchable field in it. That
field has multiple values for example

doc( search: X search : X Y search: X Y Z id:1)
doc( search: X Y K id:2)

I am using Standard Analyzer for building and searching, and having problem
with scores

if the term is "X Y" the document 2 is getting higher score then document 1.


Please can someone suggest way that doc 1 will score higher? 
Maybe I need to use some specific query type? 

Thanks



-- 
View this message in context: http://www.nabble.com/Multi-Value-field-tp24378975p24378975.html
Sent from the Lucene - Java Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Re: Multi Value field

Posted by Mark Harwood <ma...@yahoo.co.uk>.
> I just try norms idea as well no change

You'll need to look at searcher.explain() for the two docs or post a  
Junit or code example that can be executed which shows the issue


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Re: Multi Value field

Posted by John Seer <pu...@yahoo.com>.

I already tried to use custom similarity (I set all methods to return 1f)- 
doesn't work.
I just try norms idea as well no change


markharw00d wrote:
> 
>> if the term is "X Y" the document 2 is getting higher score then  
>> document 1.
> 
> 
> That may be length normalisation at play. Doc 2 is shorter so may be  
> seen as a better match for that reason.
> Using the "explain" function helps illustrate the break down of scores  
> in matches.
> 
> You could try indexing that field without "norms" or use a custom  
> Similarity at query time to ignore the length normalisation factor.
> 
> Cheers
> Mark
> 
> 
> 
> On 7 Jul 2009, at 19:31, John Seer wrote:
> 
>>
>> Hello,
>>
>> I  have 100k index with documents with one searchable field in it.  
>> That
>> field has multiple values for example
>>
>> doc( search: X search : X Y search: X Y Z id:1)
>> doc( search: X Y K id:2)
>>
>> I am using Standard Analyzer for building and searching, and having  
>> problem
>> with scores
>>
>> if the term is "X Y" the document 2 is getting higher score then  
>> document 1.
>>
>>
>> Please can someone suggest way that doc 1 will score higher?
>> Maybe I need to use some specific query type?
>>
>> Thanks
>>
>>
>>
>> -- 
>> View this message in context:
>> http://www.nabble.com/Multi-Value-field-tp24378975p24378975.html
>> Sent from the Lucene - Java Users mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
>> For additional commands, e-mail: java-user-help@lucene.apache.org
>>
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Multi-Value-field-tp24378975p24381024.html
Sent from the Lucene - Java Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Re: Multi Value field

Posted by Mark Harwood <ma...@yahoo.co.uk>.
> if the term is "X Y" the document 2 is getting higher score then  
> document 1.


That may be length normalisation at play. Doc 2 is shorter so may be  
seen as a better match for that reason.
Using the "explain" function helps illustrate the break down of scores  
in matches.

You could try indexing that field without "norms" or use a custom  
Similarity at query time to ignore the length normalisation factor.

Cheers
Mark



On 7 Jul 2009, at 19:31, John Seer wrote:

>
> Hello,
>
> I  have 100k index with documents with one searchable field in it.  
> That
> field has multiple values for example
>
> doc( search: X search : X Y search: X Y Z id:1)
> doc( search: X Y K id:2)
>
> I am using Standard Analyzer for building and searching, and having  
> problem
> with scores
>
> if the term is "X Y" the document 2 is getting higher score then  
> document 1.
>
>
> Please can someone suggest way that doc 1 will score higher?
> Maybe I need to use some specific query type?
>
> Thanks
>
>
>
> -- 
> View this message in context: http://www.nabble.com/Multi-Value-field-tp24378975p24378975.html
> Sent from the Lucene - Java Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org