synonym expansion for boolean prefixes.

David Bremner david at tethera.net
Tue Jan 5 12:43:13 GMT 2016


Olly Betts <olly at survex.com> writes:

> A better option for this is probably a FieldProcessor - you set one for
> a prefix and the it gets passed the value and returns a Query object
> for it.  E.g. in lua (where you can just pass an anon function for the
> FieldProcessor - we ought to support C++11 lambdas for such things):
[snip]
> To achieve this with synonyms in a configurable way you'd need to
> rewrite the synonyms in the database to match the current configuration,
> so it's not as dynamic as the above.

Well, the configuration needs to be somewhere.  Would it make sense to
from a performance point of view to be looking up foo_tag_term in
document metadata? That was one of the attractions of using synonyms
that there is already a persistent/atomic/configurable way of storing
them. With a field processor we'd have to manage that ourselves, and I'm
hoping to avoid managing my own cache, at least in the first revision.

> FieldProcessor isn't in 1.2.x, but then support for synonyms for boolean
> terms isn't in any version.

[ Debian specific discussion follows; non-Debian users might find it
boring and incomrehensible ]

Yeah. I guess if there were 1.3 packages in Debian (experimental?), I'd
consider optionally depending on them.  There are several places where
field processors could be useful for notmuch.  I see the packages exist
in Ubuntu, so I guess there wouldn't be that much packaging work?  I
guess this would be a perfect application of so-called "bike sheds", but
who knows when these will actually become live. Would it help anything
if I filed an RFP bug?

d



More information about the Xapian-discuss mailing list