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 "Sophie M." <so...@beezik.com> on 2010/04/21 14:58:46 UTC

Improving my Did You Mean

Hello !

Firstly, english is not my native language. 

I use solr to find artists and tracks. I built a new field type for my did
you mean that checks words. That field type has some standard filter for
query and analysis ans the phoneticFilterFactory (please see file, there is
the type definition). http://n3.nabble.com/file/n739848/a.txt a.txt 

The Did You Mean works quite well but the Did You Mean can't make a good
suggestion sometimes.

For example, the artist Coldplay. When I misspell it, like COLPLAY. My Did
You Mean suggests "Global".

I saw using the analysis that Colplay is translated KLPL by the
phoneticFilter and ColdPlay is translated KLTP. So it doesn't match.

I really tried to find a way in Solr books, but I founded nothing better.

Thanks in advance.



-- 
View this message in context: http://n3.nabble.com/Improving-my-Did-You-Mean-tp739848p739848.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: Improving my Did You Mean

Posted by MitchK <mi...@web.de>.
This is the package-description:

http://commons.apache.org/codec/api-release/org/apache/commons/codec/language/package-summary.html

However, there is no example given. Maybe you will find something by
searching in one of your favorite search engines.

Another solution for your problem might be N-Grams. 

For example Coldplay is split into::

cold play
oldp lay
ldpl ay
dpla y
play

If you are now searching for colplay (missing the d)
your query would be split into

colp lay
olpl ay
lplay
play

That makes two matches (->ay and play).

Have a look at the Edge-N-Gram-Filter.
Does this fit your needs?

Kind regards from German,
- Mitch
-- 
View this message in context: http://n3.nabble.com/Improving-my-Did-You-Mean-tp739848p740031.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: Improving my Did You Mean

Posted by "Sophie M." <so...@beezik.com>.
Hello MitchK,

I tried Refined Soundex (sorry I forgot to mention it) but It wasn't much
better. And I didn't find any refence about the caverphone filter even here
:
http://wiki.apache.org/solr/caverphone?action=fullsearch&context=180&value=caverphone&fullsearch=Texte

Thanks
-- 
View this message in context: http://n3.nabble.com/Improving-my-Did-You-Mean-tp739848p739948.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: Improving my Did You Mean

Posted by MitchK <mi...@web.de>.
Hi Sophie,

the only thing which I would suggest is to create more fields but with other
filters.
What about soundex and caverphone? Maybe those ones are working a little bit
different from DoubleMetaphone and fit your needs?

Kind regards
- Mitch
-- 
View this message in context: http://n3.nabble.com/Improving-my-Did-You-Mean-tp739848p739911.html
Sent from the Solr - User mailing list archive at Nabble.com.