lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Giulio Cesare Solaroli <giulio.ces...@gmail.com>
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, markharw00d@yahoo.co.uk
<markharw00d@yahoo.co.uk> 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:
//---------------------------------------
(+responsib* 
 +social*
 +(corporat* firm? business* compan* invest* entrepren* enterprise?))

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

(+CSR
 +(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.

Regards,

Giulio Cesare Solaroli

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


Mime
View raw message