[Xapian-devel] Added a python example to the community page

aarsh shah aarshkshah1992 at gmail.com
Sat Mar 2 21:12:00 GMT 2013


Hey James , Hi :) Thanks for your review of the example. I saw some
questions on IRC,Help Wanted and in the FAQ about indexing single terms and
stemming strategies.Is it okay if I rewrite the example to answer those
questions ? We don't have any example currently which explains
doc.add_term( ) and stemming strategies .

-Regards
-Aarsh

On Fri, Feb 8, 2013 at 3:11 AM, James Aylett <james-xapian at tartarus.org>wrote:

> On 27 Jan 2013, at 20:09, aarsh shah <aarshkshah1992 at gmail.com> wrote:
>
> > Hey guys,I have added a python indexer example to the SampleCode page of
> our wiki.Please do  have a look.The code can also be found  here :-
> >
> >
> https://github.com/aarshkshah1992/xapian/blob/efcf443527b74326119bbc0935fc41a002ce60db/xapian-bindings/python/docs/examples/simpleindexgrep.py/
>
> Aarsh — what are you actually trying to do here? Because what your
> comments say you're doing isn't what the code does. Three problems:
>
> 1) English uses capitals at the start of sentences, so you're actually
> just indexing more or less everything
>
> 2) you're running xapian.TermGenerator.index_text() on single words, which
> isn't really what it's designed to do (it has its own word-splitting
> algorithm)
>
> 3) you don't support sentences broken across lines, which doesn't match
> the majority of use cases — although you may have a particular one in mind
>
> Does what you're trying to do show how to use an aspect of Xapian that we
> don't already show in the existing examples? Or at least show it more
> clearly?
>
> J
>
> --
>  James Aylett, occasional trouble-maker
>  xapian.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xapian.org/pipermail/xapian-devel/attachments/20130303/86621f2e/attachment.htm>


More information about the Xapian-devel mailing list