https://github.com/uiur/kanji_to_hanzi
Translate Japanese Kanji to Chinese Hanzi (simplified and traditional)
https://github.com/uiur/kanji_to_hanzi
chinese japanese
Last synced: 4 months ago
JSON representation
Translate Japanese Kanji to Chinese Hanzi (simplified and traditional)
- Host: GitHub
- URL: https://github.com/uiur/kanji_to_hanzi
- Owner: uiur
- License: mit
- Created: 2020-02-28T09:13:23.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2024-08-28T05:26:02.000Z (9 months ago)
- Last Synced: 2025-02-01T17:01:54.282Z (4 months ago)
- Topics: chinese, japanese
- Language: Ruby
- Homepage:
- Size: 47.9 KB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# KanjiToHanzi
Translate Japanese Kanji to Chinese Hanzi (simplified and traditional)```ruby
KanjiToHanzi.kanji_to_simplified('焼肉')
#=> '烧肉'
KanjiToHanzi.kanji_to_traditional('焼肉')
#=> '燒肉'KanjiToHanzi.simplified_to_kanji('烧肉')
#=> '焼肉'
KanjiToHanzi.traditional_to_kanji('燒肉')
#=> '焼肉'
```The chinese character mapping table is attributed to:
http://lotus.kuee.kyoto-u.ac.jp/~chu/pubdb/LREC2012/kanji_mapping_table.txt
```
Chenhui Chu, Toshiaki Nakazawa and Sadao Kurohashi:
Chinese Characters Mapping Table of Japanese, Traditional Chinese and Simplified Chinese
In Proceedings of the Eighth Conference on International Language Resources and Evaluation
(LREC2012), pp.2149-2152, Istanbul, Turkey, (2012.5).
```## Installation
Add this line to your application's Gemfile:
```ruby
gem 'kanji_to_hanzi'
```And then execute:
$ bundle
Or install it yourself as:
$ gem install kanji_to_hanzi
## License
The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).