Re: [Zope] Indexing: ZopeSplitter and numbers
Zope 2.4.X allows to have multiple splitters. So you can write your own splitter. The only disadvantage is that there is currently no offical API (except monkeypatching) to add custom splitters (but there is a already a proposal in the fishbowl to address this problem). Andreas ----- Original Message ----- From: "Casey Duncan" <c.duncan@nlada.org> To: "Andreas Jung" <andreas@andreas-jung.com>; <richard@bizarsoftware.com.au>; <zope@zope.org> Sent: Tuesday, November 13, 2001 13:52 Subject: Re: [Zope] Indexing: ZopeSplitter and numbers
On Tuesday 13 November 2001 07:05 am, Andreas Jung allegedly wrote:
The answer is - as always - in the sources ;-) The splitting algorithm is pretty dumb. Roughly spoken it splits the text in words but not into numbers. To test the splitter try this:
from ZopeSplitter import ZopeSplitter print list(ZopeSplitter('abc 123 t353 nmj'))
gives ['abc', 't353', 'nmj']
Andreas
Has there been any thought in changing this behavior? I smell a fish bowl prop...
/---------------------------------------------------\ Casey Duncan, Sr. Web Developer National Legal Aid and Defender Association c.duncan@nlada.org \---------------------------------------------------/
On Wednesday 14 November 2001 06:07, Andreas Jung wrote:
Zope 2.4.X allows to have multiple splitters. So you can write your own splitter. The only disadvantage is that there is currently no offical API (except monkeypatching) to add custom splitters (but there is a already a proposal in the fishbowl to address this problem).
_and_ the default splitters are written in C, and therefore very fast. Also, what's the level of zcatalog-fu that's needed to write a splitter, or even modify an existing one? I'd hazard to say it's pretty high... Oh, look... another "How do I get a catalog to index numbers correctly?" post since I sent my question. Hrm. Are you sure there's not a better answer to the reasoning for this behaviour than "it's dumb"? Richard
participants (2)
-
Andreas Jung -
Richard Jones