Full text search of Chinese text, with eXist-db and lucene
This gist contains some sample files showing how to configure full text queries on Chinese text with eXist.
It assumes you have already installed eXist 3.5.0+.
The default eXist installation does not ship with the "SmartCN" analyzer for Lucene, so you need to install it. To do so, download the full distribution of Lucene, being sure to download the same version of Lucene as is bundled with eXist. For eXist 3.5.0, the version of Lucene is 4.10.4, so download
lucene-4.10.4.zip from http://archive.apache.org/dist/lucene/java/4.10.4/. Expand the archive, and find
lucene-analyzers-smartcn-4.10.4.jar in the
analysis/smartcn folder. Place this
jar file into
EXIST_HOME/extensions/indexes/lucene/lib. With this
jar file in place, start eXist.