Trunk has much more data in its spellcheck response, see http://
wiki.apache.org/solr/SpellCheckerRequestHandler .
-Mike
On 7-Dec-07, at 3:46 PM, Matthew Runo wrote:
I'll give it a try. Seems like the Spellcheck response type is
pretty basic.
Thanks!
Matthew Runo
Software Developer
702.943.7833
On Dec 7, 2007, at 11:23 AM, Ryan McKinley wrote:
Matthew Runo wrote:
Hello!
Please forgive my newbie question about SolrJ, but I was unable
to find my answer in the SOLRJ source code or the wiki (I'll add
it if someone helps).
Would anyone be so kind as to provide a quick example of using
the Spellcheck handler and the MoreLikeThis handler with SOLR-J?
With spellcheck, you will be in new water (I think)... you can get
the response as a NamedList, but there is not anything that puts
that into user friendly functions.
SolrQuery q = new SolrQuery( "foo" );
q.setQueryType( "spelling" );
q.set( "anyparam", value );
QueryResponse rsp = solr.query( q )
NamedList nl = rsp.getResponse();
you will have to pick stuff out of the NamedList manually. If you
want to contribute a SpellCheckRequest/Response that would be great!
For MLT, the standard QueryRequest should work. in 1.3-dev, both
standard and dismax support mlt queries. Perhaps we should add
getters and setters to SolrQuery so you don't have to call:
q.set( MoreLikeThisParams.MLT, true );
ryan