Sesam Catalogue search need functionality to have catalogue queries with geographical criteria "expand" to a wider area when there are no hits. E.g. searching for "marina torshov" would expand to "marina oslo".

When there are no hits, Fast returns a suggested new transformed query based on synonyms, in this case the suggestion would be just "oslo", and Fast could also re-run the new query automatically after a change of config. However, changing the query and re-run in java would would give better control over what happens.

The method CatalogueSearchCommand.execute() seems to be a good place to start. This method calls AbstractSimpleFastSearchCommand.execute() which performs the actual call to Fast. The result is then "collected" and returned to CatalogeSearchCommand.execute(). Depending on modes.xml various parts of the Fast result is parsed and passed along. Turning on the relevant-queries=true flag in modes.xml will trigger AbstractFastSearchCommand.collectRelevantQueries(), and this will attempt to collect the synonym query, based on the fact that it is named "FastQT_Synonym" and has messageID=8. However the query value string is assumed to be more complex than just "oslo", and the parsing throws an ArrayIndexOutOfBoundsException when it tries to parse and store the value in a BasicWeightedSuggestion.

I guess this specific kind of synonym transform will never need to put a weight on the suggestions, due to the hierarchical structure of geo-areas. So I would like to add a new collect method ... collectSimpleRelevantQueries or something ... but then I'd need more fine-grained criteria to separate "SimpleRelevantQuerues" from the other "RelevantQueres". I also need to know what collectRelevantQueries() actually is intended to do so that I don't interfer with that functionality.

Does anyone know more about this, or have any pointers to relevant docs?

--
martin s.
Sesam Media AS




begin:vcard
fn:Jon Martin Solaas
n:Solaas;Jon Martin
email;internet:[EMAIL PROTECTED]
tel;work:+47 92468511
tel;home:+47 92468511
tel;cell:+47 92468511
version:2.1
end:vcard

_______________________________________________
Kernel-development mailing list
[email protected]
http://sesat.no/mailman/listinfo/kernel-development

Reply via email to