lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Giulio Cesare Solaroli <>
Subject Re: How to extract matching terms for a document given a query
Date Wed, 16 Jun 2004 20:25:58 GMT
Hi Mark,

On Wed, 16 Jun 2004 21:06:03 +0100,
<> wrote:
> >>The reason the current highlighter is not suitable for me, is that the
> >>content of the document is not stored in the index
> That shouldn't present a problem.
> The working code example below was from a recent email discussion I had with someone
who was storing
> text in a database. This simple example works shows highlighting working with no index
in sight.
[code removed]

your code works fine, but I we work with much more complex query that
are not easily translatable into Terms.

Here is a sample query:
 +(corporat* firm? business* compan* invest* entrepren* enterprise?))

(+(ethic* solid*)
 +(corporat* firm? business* compan* invest* entrepren* enterprise?))

 +(corporat* firm? business* compan* invest* entrepren* enterprise?))

Given this query, I suppose you need the index to expand all the terms
and get the real word that match the results.

I can expand all the terms with the query rewrite method, but I
usually get huge results.

I was trying to reduce the amount of work to do out of Lucene, in
order to take full advantage of the performace of Lucene that I doubt
I can improve.


Giulio Cesare Solaroli

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message