Hi!
I am working now on Lexeme fulltext search. One of the unclear moments I
have encountered is how to display Lexemes as search results. I am
basing on assumption that we want to match both Lemmas and Forms (please
tell me if I'm wrong). Having the match, I plan to display Lemma match
like this:
title (LN)
Synthetic description
e.g.
color/colour (L123)
English noun
Meaning, the first line with link would be standard lexeme link
generated by Lexeme code (which also deals with multiple lemmas) and the
description line is generated description of the Lexeme - just like in
completion search. The problem here, however, is since the link is
generated by the Lexeme code, which has no idea about search, we can not
properly highlight it. This can be solved with some trickery, probably,
e.g. to locate search matches inside generated string and highlight
them, but first I'd like to ensure this is the way it should be looking.
More tricky is displaying the Form (representation) match. I could
display here the same as above, but I feel this might be confusing.
Another option is to display Form data, e.g. for "colors":
color/colour (L123)
colors: plural for color (L123): English noun
The description line features matched Form's representation and
synthetic description for this form. Right now the matched part is not
highlighted - because it will otherwise always be highlighted, as it is
taken from the match itself, so I am not sure whether it should be or not.
So, does this display look as what we want to produce for Lexemes? Is
there something that needs to be changed or improved? Would like to hear
some feedback.
Thanks,
--
Stas Malyshev
smalyshev(a)wikimedia.org