lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "luocanrao" <luocan19826...@sohu.com>
Subject 答复: another question about phrasequery?
Date Tue, 23 Mar 2010 13:00:53 GMT
Hi , Ian Lea
I mean that query for "little boy" will match the both document. 
the Document that only has terms "boy" and "little" will match the query.
the document one add some sore because it exactly match the query(term position totally match).
do I describe clearly?
 
for example
Document 1: little boy is running
Document 2:boy is little
Document 1 add score 100(Exact match),
but Document 2 add score 0( not Exact match)

-----邮件原件-----
发件人: luocan19826164@sohu.com [mailto:luocan19826164@sohu.com] 
发送时间: 2010年3月23日 11:24
收件人: java-user
主题: Re: another question about phrasequery?(thanks again)

sorry, describle again.I mean that query for "little boy" will match the both document.the
Document that only has term "boy" and "little" will match the query.the document&nbsp;one
add some sore beacuse it exactly match the query(term position totally match).do I describe
clearly?
for example:Document 1: little boy is running
Document 2:boy is little
when I query "little boy",Document&nbsp;1 add score 100(Exact match),but Document 2 add
score 0( not Exact match)



----- 原文 ----- 发件人: luocan19826164@sohu.com 主 题: Re: another question about
phrasequery?(thanks again)时 间: 2010年3月23日 8:59:57
sorry, describle again.&amp;nbsp;Document 1: little boy is runningDocument 2:boy is littleI
mean that a&amp;nbsp; query for "little boy" will match the both document.the Document
that only has term "boy" and "little" will match the query.the document 1 add some sore beacuse
it exactly match the query(term position totally match).do I describe clearly?&amp;nbsp;&amp;nbsp;for
example:Document 1: little boy is runningDocument 2:boy is littleI query "little boy"Document
1 add score 100(Exact match)Document 2 add score 0( not Exact match)----- 原文 ----- 发件人:
Ian Lea 主 题: Re: another question about phrasequery?(thanks again)时 间: 2010年3月22日
22:35:39I'm not clear what exactly you are asking. With your examples:Document 1: little boy
is runningDocument 2:boy is littlea phrase query for "little boy" will match the first and
not thesecond. Is that what you want?a phrase query for "litter boy" won't match either, but
a generalquery might match on boy depending on how you set your must/shouldqualifiers.So maybe
you should have a 2 phase approach: do a phrase query andstop if you get hits or do a general
non-phrase query if you don't.Alternatively issue both at the same time but with the phrase
queryboosted.--Ian.On Mon, Mar 22, 2010 at 2:13 PM, luocanrao &amp;lt;luocan19826164@sohu.com&amp;gt;
wrote:&amp;gt; I don't think the current phrasequery can meet my requirement.&amp;gt;&amp;gt;
Can someone help me implement such a phrasequery?&amp;gt;&amp;gt;&amp;gt;&amp;gt;
Exact match document add some score&amp;gt;&amp;gt; All other match document add 0
score.(no matter how big slop is)&amp;gt;&amp;gt;&amp;gt;&amp;gt; For example:&amp;gt;&amp;gt;
Document 1: little boy is running&amp;gt;&amp;gt; Document 2:boy is little&amp;gt;&amp;gt;&amp;gt;&amp;gt;
I query "little boy"&amp;gt;&amp;gt; Document 1 add score 100(Exact match)&amp;gt;&amp;gt;
Document 2 add score 0( not Exact match)&amp;gt;&amp;gt; But the two document can
match the query.&amp;gt;&amp;gt; user that search "litter boy" should see both the
Document,&amp;gt;&amp;gt; but the Document 1 is on the top!!&amp;gt;&amp;gt;&amp;gt;&amp;gt;---------------------------------------------------------------------To
unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.orgFor 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


Mime
View raw message