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 "Beach, Joel" <jt...@qualcomm.com> on 2012/03/06 05:25:59 UTC

Creating a query-able dictionary using Solr

Hi there,

Am looking at using Solr to perform the following tasks:

1. Push a lot of PDF documents into SOLR.
2. Build a database of all the words encountered in those documents.
3. Be able to query for a list of words matching a string like "a*"

For example, if the collection contains the words aardvark, apple, doctor and zebra,
I would expect a query of "a*" to return the list:

[ aardvark, apple ]

I have done a google around for this in Solr and found similar things involving
spell-checkers, but nothing that seems exactly the same.

Anyone, already done this or something similar in Solr willing to point me in the
right direction?

Cheers,

Joel

Re: Creating a query-able dictionary using Solr

Posted by Serdyn du Toit <du...@gmail.com>.
Hi Joel,

Not an advanced Solr user myself - only been looking at it for a while.
 Still, maybe you are looking to use a "suggester"?

http://wiki.apache.org/solr/Suggester (the examples at the bottom of the
page is very helpful)

I haven't worked with Pdf documents in Solr yet but the "suggester" does
seem to have the behavior you're looking for (when generating the
suggestions from an index).

Kind regards,
Serdyn du Toit


On Tue, Mar 6, 2012 at 6:25 AM, Beach, Joel <jt...@qualcomm.com> wrote:

> Hi there,
>
> Am looking at using Solr to perform the following tasks:
>
> 1. Push a lot of PDF documents into SOLR.
> 2. Build a database of all the words encountered in those documents.
> 3. Be able to query for a list of words matching a string like "a*"
>
> For example, if the collection contains the words aardvark, apple, doctor
> and zebra,
> I would expect a query of "a*" to return the list:
>
> [ aardvark, apple ]
>
> I have done a google around for this in Solr and found similar things
> involving
> spell-checkers, but nothing that seems exactly the same.
>
> Anyone, already done this or something similar in Solr willing to point me
> in the
> right direction?
>
> Cheers,
>
> Joel