Re: Autocomplete with Solr 3.1

2011-07-30 Thread O. Klein
According to
http://www.lucidimagination.com/blog/2011/04/08/solr-powered-isfdb-part-9/
it should be possible to set spellcheck.maxCollations to 5.

This doesn't work for me in 4.0, nor does it work with the regular
spellchecker, unless I set spellcheck.maxCollationTries to a value like 10.

Then I get a list of collations.

However adding these parameters to the suggester doesn't do anything.

Is this common behavior? Or is my Solr borked?

--
View this message in context: 
http://lucene.472066.n3.nabble.com/Autocomplete-with-Solr-3-1-tp3202214p3211775.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Autocomplete with Solr 3.1

2011-07-28 Thread scorpking
Nobody can help me

--
View this message in context: 
http://lucene.472066.n3.nabble.com/Autocomplete-with-Solr-3-1-tp3202214p3206095.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Autocomplete with Solr 3.1

2011-07-27 Thread O. Klein
I know the solution, just not how to actually implement it, but maybe
somebody can help with that :)

From Wiki:

If you want to use a dictionary file that contains phrases (actually,
strings that can be split into multiple tokens by the default
QueryConverter) then define a different QueryConverter like this:

  
  queryConverter name=queryConverter
class=org.apache.solr.spelling.MySpellingQueryConverter/

--
View this message in context: 
http://lucene.472066.n3.nabble.com/Autocomplete-with-Solr-3-1-tp3202214p3203191.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Autocomplete with Solr 3.1

2011-07-27 Thread scorpking
Hi Klein, 
Thanks for your reply. But i tried some suggestion with solr, and results
return is good. But i want to using search component with solr 3.1. Now i
have had some problems with Suggester. i think my problem perhaps about in
schema file. This is schema file: 

fieldType name=text class=solr.TextField positionIncrementGap=100
analyzer type=index
charFilter class=solr.HTMLStripCharFilterFactory/
tokenizer class=solr.WhitespaceTokenizerFactory/
filter class=solr.StopFilterFactory ignoreCase=true
words=stopwords.txt enablePositionIncrements=true/
filter class=solr.WordDelimiterFilterFactory 
generateWordParts=1
generateNumberParts=1 catenateWords=1 catenateNumbers=1
catenateAll=0 splitOnCaseChange=1/
filter class=solr.LowerCaseFilterFactory/
/analyzer
analyzer type=query
charFilter class=solr.HTMLStripCharFilterFactory/
tokenizer class=solr.WhitespaceTokenizerFactory/
filter class=solr.SynonymFilterFactory 
synonyms=synonyms.txt
ignoreCase=true expand=true/
filter class=solr.StopFilterFactory ignoreCase=true
words=stopwords.txt enablePositionIncrements=true/
filter class=solr.WordDelimiterFilterFactory 
generateWordParts=1
generateNumberParts=1 catenateWords=0 catenateNumbers=0
catenateAll=0 splitOnCaseChange=1/
filter class=solr.LowerCaseFilterFactory/
/analyzer
/fieldType

And i defined fields: 
field name=s_SongId type=string indexed=true stored=true/
field name=s_SongName type=text indexed=true stored=true/
field name=search_autocomplete type=text_auto indexed=true
stored=true multiValued=true/

where: 
fieldType with text_auto:
fieldType class=solr.TextField name=text_auto
positionIncrementGap=100
 analyzer type=index
tokenizer class=solr.KeywordTokenizerFactory/
filter class=solr.LowerCaseFilterFactory/
 /analyzer
 analyzer type=query
tokenizer class=solr.KeywordTokenizerFactory/
filter class=solr.LowerCaseFilterFactory/
 /analyzer
/fieldType
In file solrconfig.xml i defined: 
searchComponent name=spellcheck-autocomplete
class=solr.SpellCheckComponent
 lst name=spellchecker
  str name=namesuggest/str
  str name=classnameorg.apache.solr.spelling.suggest.Suggester/str
  str
name=lookupImplorg.apache.solr.spelling.suggest.tst.TSTLookup/str
  str name=fieldsearch_autocomplete/str
  str name=buildOnCommittrue/str
 /lst
/searchComponent
  
  requestHandler name=/autocomplete
class=org.apache.solr.handler.component.SearchHandler
lst name=defaults
str name=spellchecktrue/str
str name=spellcheck.dictionarysuggest/str
str name=spellcheck.count10/str
str name=spellcheck.collatetrue/str
/lst
arr name=components
strspellcheck-autocomplete/str
/arr
  /requestHandler

Can any one help???

--
View this message in context: 
http://lucene.472066.n3.nabble.com/Autocomplete-with-Solr-3-1-tp3202214p3204176.html
Sent from the Solr - User mailing list archive at Nabble.com.


Autocomplete with Solr 3.1

2011-07-26 Thread scorpking
Hi all, 
when i use autocomplete to suggest like google:
http://www.google.com/webhp?complete=1hl=en and follow this url
http://solr.pl/en/2010/11/15/solr-and-autocomplete-part-2/ to config my
project, but when i tested with more two terms in my query, it's not right,
i don't know why? 
Can anyone tell me ? 
Thanks for help.

 

--
View this message in context: 
http://lucene.472066.n3.nabble.com/Autocomplete-with-Solr-3-1-tp3202214p3202214.html
Sent from the Solr - User mailing list archive at Nabble.com.