brew install mecab
brew install mecab-ipadic
sudo apt-get install -y mecab libmecab-dev mecab-ipadic-utf8
git clone --depth 1 https://github.com/neologd/mecab-ipadic-neologd.git
cd mecab-ipadic-neologd
./bin/install-mecab-ipadic-neologd -n -y
echo dicdir = `mecab-config --dicdir`"/mecab-ipadic-neologd" > mecabrc
sudo cp mecabrc /usr/local/etc
pip install numpy mecab-python3 sklearn
python3 tool/data-creator/qa-similarity.py data/faq/faq.json 3 > data/faq/similarity.json
data/faq/faq.json
- input file
3
- count of similar questions
data/faq/faq-similarity.json
- output file