lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Hostetter <hossman_luc...@fucit.org>
Subject Re: retrieving matched slop
Date Wed, 21 Mar 2007 21:46:28 GMT

there's a few options...

you can define a custom SImilarity that makes the score based entirely on
the sloppyFreq ... it's not trivial, but it's certainly possible.

the other option is to call SpanQuery.getSpans directly, and then iterate
over it and compare end() - start() for each span.

: Date: Wed, 21 Mar 2007 00:44:07 -0400
: From: Ruslan Sivak <rsivak@istandfor.com>
: Reply-To: java-user@lucene.apache.org
: To: java-user@lucene.apache.org
: Subject: retrieving matched slop
:
: I have an app that searches a single document against many queries.
: Lets say the document was
:
: The quick brown fox jumped over the lazy dog.
:
: and my queries are
:
: SpanNearQuery("quick","brown",50)
: SpanNearQuery("quick","fox",50)
:
: I would like to retrieve the slop or some sort of score that was matched
: when I'm searching.  Since the first one requires no slop, it would
: return 0 or the highest score and the second query would return 1 for
: slop as fox is one word away from quick.  Is there any way to retrieve
: these values?
:
: Russ
:
:
: ---------------------------------------------------------------------
: To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
: For additional commands, e-mail: java-user-help@lucene.apache.org
:



-Hoss


---------------------------------------------------------------------
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