-RE: Using spellcheck component with query ( q and spellcheck.q )
Dyer, James 2011-10-20, 17:49
The bug you describe looks the same as SOLR-2726 (https://issues.apache.org/jira/browse/SOLR-2726) which doesn't seem to be part of 3.4. You might want to try applying the patch, or better yet, just use a fresh check-out on the 3.x branch as the current state (for un-released 3.5) isn't going to differ much from the released 3.4GA.
SpellCheckComponent doesn't support the fuzzy operator. What it does is break your query up into raw terms and then offer suggestions based on String Distance calculations between any original terms not in the index and terms that are in the index. Depending on which analyzers you're using for your spellcheck field, the ~ character may or may not be considered part of the term it was attached to. If it is considered part of the term, then its presence will potentially alter the results.
Also if you're using the Collate feature and have "spellcheck.maxCollationTries" set greater than zero, then SpellCheckComponent will plug any suggestions that it comes up with back into your original query to see how many hits the new terms generate. So an original query with "fuzzy" somewhere might get different collations than one without it.
Ingram Content Group
From: Mark Swinson [mailto:[EMAIL PROTECTED]]
Sent: Thursday, October 20, 2011 5:00 AM
To: [EMAIL PROTECTED]
Subject: Using spellcheck component with query ( q and spellcheck.q )
I am using solr 3.4.0 with spellcheck component.
When I try and search for pre built spelling dictionary for a given
mispelt word , it only works
if I specify BOTH the q and spellcheck.q parameters. If I miss out the q
parameter I get a NullPointerException
error. I believe I have seen reference to this before ( is this a bug ?
) and that it had been patched. However
I believe I have the most up to date release of solr.
The other thing I would like to clear up is , does the spellcheck
request handler handle the fuzzy operator ( ~ ) as I
have found I get different results when specifying the fuzzy operator as
opposed to when I don't.
This e-mail (and any attachments) is confidential and may contain personal views which are not the views of the BBC unless specifically stated.
If you have received it in error, please delete it from your system.
Do not use, copy or disclose the information in any way nor act in reliance on it and notify the sender immediately.
Please note that the BBC monitors e-mails sent or received.
Further communication will signify your consent to this.