One solution to your problem might be to build a custom autocomplete module that uses Solr's highlighting functionality. Instead of returning a particular Solr field like the current module does, you could instead return the results from Solr's highlighter. I believe you can configure the highlighter to control how many words surrounding the matched term are returned, etc. I'm not sure exactly how much work this would be - I'd have to look at the code to see if there are any serious difficulties, though there's a good chance it would be fairly straightforward. Let me know if you have any questions.
From: Viviane Ventura [mailto:vaventura1@...]
Sent: Thursday, January 10, 2013 12:06 PM
Subject: [VuFind-General] Autocomplete with words
Another question... you can change the behavior of the autocomplete so that it behaves like autocomplete google?
Ideally, the suggestions should not present the entire title, it confuses the user, but indexed words present in the text.
For example, in google.jpg we have suggestions to "Situ" (we are looking for Situação in portugese - Situation in English), and in vufind.jpg we have the entire titles suggested, with too many information.
One way to do this would make a handler based on user's queries, and suggest them in autocomplete. There is already some initiative in this direction?
We use Vufind as a repository of information (not just for the library), suggest words indexed sounds better than suggesting the title of the entire record in our case (like google does).
Thanks for help!
(and sorry for my english =)
Get latest updates about Open Source Projects, Conferences and News.