You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by darniz <rn...@edmunds.com> on 2009/12/23 00:50:06 UTC

Re: Synonym questions

i have a similar use case where i want to preserve original words forexamplei
have one way mapping at index time
monsoon,sony,levinson => audio system
when i index document for example with word sony i want ot index audio
system as well as the brand name ie sony.
so if some one types category:sony i want highlighted resutls.
if user types category:audio system i want the same document too.

i initially thought there might be some property like preserveOriginal for
synonym filter too like we had for worddelimiter tokeniser.

please let me know is there any alternative.

Thanks
darniz


hossman wrote:
> 
> 
> : 1) For some of my synonyms, it seems to make senses to simply replace
> the
> : original word with the other (e.g. "theatre" => "theater", so searches
> for
> : either will find either). For others, I want to add an alternate term
> while
> : preserving the original (e.g. "cirque" => "circus", so searches for
> "circus"
> : find Cirque du Soleil, but searches for "cirque" only match "cirque",
> not
> : "circus".
> 
> the simplest way i can think of to achieve something like this off the top
> of my head is to do synonym injecting when idexing and don't use the
> synonym filter at all when querying...
> 
> theatre, theater => theatre, theater
> circus => circus, cirque
> 
> (but i haven't tested this to be sure it does what i think it does, and i
> haven't thought about SynonymFilter very hard for a while now so i may be
> forgetting something subtle)
> 
> 
> 
> -Hoss
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Synonym-questions-tp12078428p26896098.html
Sent from the Solr - User mailing list archive at Nabble.com.