A demo full text search of English Wikipedia using the Rampart SQL module on Linux or MacOs. The search is powerful and efficient enough to be run on hardware as small as a Raspberry Pi Zero.
Running ./make_wiki-search.sh
will initiate the build. The script will provide some information and then:
- Download the latest wikipedia dump from dumps.wikipedia.org.
- Decompress the downloaded file.
- Execute WikiExtractor.py to extract the text from the decompressed wikitext file.
- Import the data using import.js.
- Create the index using mkindex.js
- Rampart JavaScript
- Python2
- Curl
- bzcat (part of the bzip2 package)
- pv (optional to display a progress bar while decompressing)
After the search is build, the webserver may be started in the 'web_server'
directory with ./start_wikipedia_web_server.sh
.
A demo running on the Raspberry Pi Zero can be found here.