|
From: | John Swensen |
Subject: | Re: Graphical help browser |
Date: | Mon, 24 Nov 2008 14:41:29 -0500 |
On Nov 23, 2008, at 3:56 PM, Søren Hauberg wrote:
søn, 23 11 2008 kl. 15:47 -0500, skrev John Swensen:How do you do your search? I was using a library called xapian (http://xapian.org/ ) to generate a search index from a bunch of HTML. It seems to do a very good job and is very quick. I was using Webkit also for my help browser.I don't do searching right now. If my rewrite of the help system intom-files get accepted, then Octave will generate caches of all help texts(for 'lookfor'). It will be dead easy to just search these caches from the help browser, and it'll be quite fast. So, I'm waiting to see whathappens with my rewrite of the help system, before I implement searchingin the help browser. Søren
I think I will probably stick with Xapian for now, since it does an indexing of the HTML files and all of their content. When searching it also gives a percentage that tries to indicate how "good" of a match it is. For example, when I search for FFT, it comes up with the FFT function as the top of the list, but FFT2 is second and a slew of functions that involve the FFT (e.g. fftshift) and lists them in according to their rank.
As far as I can tell from the help on lookfor(), it will probably return all the same results as Xapian, but doesn't try to rank them in any terms of relevance. That being said, Xapian uses an algorithm call the BM25 Weighting Scheme for ranking results. See http://xapian.org/docs/bm25.html
John Swensen
[Prev in Thread] | Current Thread | [Next in Thread] |