-
Notifications
You must be signed in to change notification settings - Fork 61
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Get search working with lunr.js plugin. #68
Conversation
Get search working with lunr.js plugin.
Thanks again for working through this. Impressive bit of work. Nice to have a functional implementation in any event. If nothing else, this does highlight the strength of Marran's stemming approach (currently implemented in my search bar) which is crazy fast by comparison: http://www.marran.com/tech/jquery-full-text-indexing-on-jekyll/. Unfortunately, the search itself using Marran's is pretty crappy, since it sorts only by number of occurrences and doesn't even index the title or tag text at all. Ideally it would both index and weight these values. It would still be impossible to search for whole phrases, but at least the results might be a little better. It's weird to put in almost the exact the title of a post and not even find the post among the results. Even google site search does better, and your algorithm nails this. (e.g. search for my "data management plan" on the site). Well well, thanks again for a cool plugin and all the help. For the time being I think I will include this as a separate search page with a note, and maybe think about hacking some revisions into Marran's code to at least pull in and up-weight title text. |
One future enhancement to the search plugin that I'm considering is to exclude stop words from the index. Should be straightforward enough and hopefully would reduce the file size by a significant amount. |
Cool, that's brilliant. I don't suppose that it would have much of a On Wed, Mar 13, 2013 at 2:07 AM, Ben Smith notifications@github.com wrote:
Carl Boettiger |
Get search working with lunr.js plugin.
Get search working with lunr.js plugin.
Only a couple of tweaks needed to get search working.
Unfortunately it ran very slowly, due to the search index json file weighing in at 1.4MB. The search page took a while to initially load and searching was also slow.