Mailing List Archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlug] oneliners, Was: Moving on from xterm

Thank you for introdution of kakasi, I am a kakasi maintainer.

At Mon, 22 Aug 2016 13:41:01 +0200,
Christian Horn wrote:
> I use kakasi for a quick attempt to convert Kanji into Hiragana:
> [chris@спутник ~]$ echo 例文文章です。 | kakasi -JH -i utf8 -f -w
> 例文[れいぶん] 文章[ぶんしょう] です 。
> [chris@спутник ~]$ 
> [chris@спутник ~]$ qq 例文文章です。
> 例文文章です。
> 例文[れいぶん] 文章[ぶんしょう] です 。
> [chris@спутник ~]$ 

kakasi has some problem.
* the dictionary is too old
* not good for complex sentence

MeCab is also useful for such situation.

% echo 例文文章です。|mecab -Oyomi
% echo 例文文章です。|mecab --node-format='%pS%m[%f[7]]' --eos-format='\n'

mecab-ipadic-neologd is a good dictionary for MeCab.

To append the following to dicrc, you can use -Oyomi2 option with MeCab:

; yomi2
node-format-yomi2 = %pS%m[%f[7]]
unk-format-yomi2 = %M
eos-format-yomi2 = \n

Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links