8000 GitHub - Kajen5/furigana: Generate furigana from Japanese
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Kajen5/furigana

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

furigana

Generate furigana(振り仮名) from Japanese

It uses pykakasi(http://kakasi.namazu.org/) (a Natural Language Toolkit) to split Japanese into words, and superscript it with furigana (振り仮名).

Example:

input

from furigana.furigana import to_html
print_html('澱んだ街角で僕らは出会った')

output

よど ん だ 街角まちかどぼく ら は っ た

input

from furigana.furigana import to_html
print(to_html('お茶にお煎餅、よく合いますね'))

output

ちゃ に お 煎餅せんべい 、 よく い ます ね

Usage

$ python3 furigana.py '活版印刷の流れを汲む出版作業では'

Dependency

See https://pypi.org/project/pykakasi/2.0.0/
run below commands on ubuntu

sudo pip install six semidbm pykakasi 

Conflict with Anaconda Python

Please use Ubuntu's original python3, not to use with Anaconda Python3

About

Generate furigana from Japanese

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 100.0%
0