lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Miles Barr <mi...@runtime-collective.com>
Subject Re: lucene index with structured fields
Date Wed, 09 Mar 2005 18:00:21 GMT
On Wed, 2005-03-09 at 18:29 +0100, Nicolas Maisonneuve wrote:
> I would like use a index with structured search field.
> 
> - flat index (lucene type)
> searchfield1
> searchfield2
> searchffield3
> ...
> -structured index 
> search1
>    search2
>    	search4
>    search3
> 	search5
> 
> to allow simple extensions of some search features: 
> - the query TermQuery("search2", "coco" )  search in search2 and
> search4 fields,
> - The score depend of the depth where the word is found : A document
> where "coco" is found in search4 field has a score lower than a
> document with "coco" found in search2
> 
> How {do with,hack} lucene to integrated easily this notion of
> structured field  ? (no fuzzy methods allow because of the
> performance) ?

If you know the structure of the index ahead of time and the weights you
want to place on the different levels I'd do a query expansion. i.e.

search2:coco

would become

search2:coco^4 OR search4:coco

but actually creating the query objects rather than generating the
string to be parsed by the QueryParser.


-- 
Miles Barr <miles@runtime-collective.com>
Runtime Collective Ltd.


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