[Xapian-devel] Sorting results by a "sort expression"

Elliot Winkler elliot.winkler at gmail.com
Thu Oct 9 16:16:04 BST 2008


Olly,

We currently use Sphinx for our website search function, but we're planning
on using Xapian instead for a few of the extra features it has. Our website
is written in Ruby on Rails, so of course we're using Xapian with Ruby
bindings. I don't know if you're familiar with Sphinx but Sphinx allows you
to pass a sort expression when you execute the search that will be evaluated
against each result in the result set to calculate the final weight of the
result [1]. You can refer to the already calculated weight in the expression
(which in this case would be the default BM25 weight) as well as any of the
values matched along with that document.

In fact, this[2] is pretty much what we're looking for. In it I notice that
you refer to "bias match" functionality and Rusty Conover's
ExternalSourcePostList patch. Judging from past discussions [3] and svn [4]
it appears that the bias match stuff was never really stable or something,
so it was removed a while ago. Was ExternalSourcePostList meant to be
dropped in as a replacement at some point in the future? I found two posts
that Rusty made about it [5,6], but that's all -- have you heard from Rusty
about it since? If so, how difficult would it be to integrate this with
Xapian? (Unfortunately I am by no means a C++ expert -- it's been difficult
enough just to stumble through the source code.)

Thanks for any insight you can give...

-- Elliot

[1] http://sphinxsearch.com/doc.html#sort-expr
[2] http://thread.gmane.org/gmane.comp.search.xapian.general/4075
[3] http://thread.gmane.org/gmane.comp.search.xapian.general/4774
[4] http://trac.xapian.org/changeset/8296
[5] http://thread.gmane.org/gmane.comp.search.xapian.devel/741
[6] http://thread.gmane.org/gmane.comp.search.xapian.general/4061
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.xapian.org/pipermail/xapian-devel/attachments/20081009/dc15f5fb/attachment.htm 


More information about the Xapian-devel mailing list