lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fabritw <fabr...@gmail.com>
Subject SpellCheckComponent question
Date Thu, 19 Aug 2010 17:50:53 GMT

Hi,

I am having some trouble with SpellCheckComponent when using queries such as
"2galwy city".

The spellchecker seems to ignore the number and suggest "galway". This is
fine but in the collation it adds the number back onto the suggestion
"2galway". This causes problems for me as I'm using it for a search
suggestion tool.

Is there a way  to configure the spell checker to provide a collation
without the number ("galway city")?

Any advise would be much appreciated. Please find the query xml below:



<response>
	<lst name="responseHeader">
		<int name="status">0</int>
		<int name="QTime">9</int>
		<lst name="params">
			<str name="spellcheck">true</str>
			<str name="echoParams">all</str>
			<str name="spellcheck.extendedResults">true</str>
			<str name="spellcheck.dictionary">default</str>
			<str name="spellcheck.count">5</str>
			<str name="spellcheck.collate">true</str>
			<str name="spellcheck.onlyMorePopular">false</str>
			<str name="echoParams">all</str>
			<str name="q">2galwy city</str>
			<str name="rows">0</str>
		</lst>
	</lst>
	<result name="response" numFound="4047" start="0"/>
	<lst name="spellcheck">
		<lst name="suggestions">
			<lst name="galwy">
				<int name="numFound">5</int>
				<int name="startOffset">1</int>
				<int name="endOffset">6</int>
				<int name="origFreq">0</int>
				<arr name="suggestion">
					<lst>
						<str name="word">galway</str>
						<int name="freq">10095</int>
					</lst>
					<lst>
						<str name="word">galwey</str>
						<int name="freq">46</int>
					</lst>
					<lst>
						<str name="word">galwaya</str>
						<int name="freq">2</int>
					</lst>
					<lst>
						<str name="word">galwayi</str>
						<int name="freq">1</int>
					</lst>
					<lst>
						<str name="word">galway2</str>
						<int name="freq">1</int>
					</lst>
				</arr>
			</lst>
			<bool name="correctlySpelled">false</bool>
			<str name="collation">2galway city</str>
		</lst>
	</lst>
</response>

-- 
View this message in context: http://lucene.472066.n3.nabble.com/SpellCheckComponent-question-tp1229575p1229575.html
Sent from the Solr - User mailing list archive at Nabble.com.

Mime
View raw message