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 Geoff Hendrey <gh...@decarta.com> on 2009/05/22 20:11:35 UTC

analyzing a matched document

Let's say I have a Query that produces a set of hits in TopDocs.
 
Now, let's say the Query is a complex boolean query, but mainly it looks
at a single Field in candidate Documents.
 
Said Field may have multiple (hundreds) of values in a given Document.
For example, imaging a Field called "state" in a document representing a
Country. For the USA, the "state" field would have 50 values.
 
I would like to determine which value in the "state" Field contributed
to the score most heavily. I guess I am looking for the information
model/object that is underneath the Explanation Object. Another way to
explain my question might be like this:
 
Imagine I wanted to highlight the relevant portions of a piece of text,
that contain information that matched the query, for presentation to a
human reader. How would I find the positions in a given Field of a
Document, that were considered to be relevant to the positive search
result?
 
-geoff