Daniel Yoo wrote: > > Here you go: > > http://hkn.eecs.berkeley.edu/~dyoo/python/ahocorasick/ > > This provides an 'ahocorasick' Python C extension module for doing > matching on a set of keywords. I'll start writing out the package > announcements tomorrow. >
Looks good. However: tree.search("I went to alpha beta the other day to pick up some spam") could use a startpos (default=0) argument for efficiently restarting the search after finding the first match -- http://mail.python.org/mailman/listinfo/python-list