Full Text Search with Whistlepig
bugsplat.info
bugsplat.info
The way it works is that doc build time it generates a index file that contains various terms, performs stemming, stop word elimination etc. When you do a search the client javascript downloads the index, performs stemming on the search terms and does the lookup in the index. This is what the index looks like for that site in JSONP format http://sphinx-doc.org/searchindex.js
It's actually quite simple to do from scratch anyway. My solution involved being able to search non-consecutive terms on a page and return paragraphs containing those terms. AFAIK, in-browser search cannot do this, which is a shame.
The source files for Sphinx are plain text in rst format (like markdown but with more functionality). It generates HTML from that, but (by default) the original plain text files are also included in the output. The search index tells it which pages match and the javascript grabs the plain text and shows paragraph matches.
http://fallabs.com/tokyodystopia/ is similar to this btw.