Skip to main content

A lightweight tool to convert English and romanized Japanese words into Katakana.

Project description

english2kana

english2kana is a Python library designed to convert English words and romanized Japanese text into their Katakana representations. It leverages a sequence-to-sequence model with an attention mechanism, trained on data derived from English company names and their corresponding Katakana forms found on the Japan Corporate Number Publication Site.

Key Features:

  • Converts English words to Katakana.
  • Employs a seq2seq model architecture with attention.
  • Achieves high accuracy with the given dataset.

Model Performance:

  • Test Loss: 0.1440
  • Test Accuracy: 0.9552

Requirements

Python 3.11 or higher

Installation

pip install english2kana

Usage

from english2kana import english2kana

# Initialize the translator
e2k = english2kana()
# Load the pretrained model
e2k.load_model()

# Translate an English word into Katakana
e2k.translate('simple')
print(output)  # シンプル

Data

The training data is sourced from the Japan Corporate Number Publication Site. The dataset includes a wide array of English corporate names along with their correct Katakana representations, ensuring the model is exposed to various letter combinations and phonetic patterns.

Contributing

Contributions are welcome! Feel free to open issues or submit pull requests to help improve this library.

License

The MIT License (MIT)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

english2kana-0.1.5.tar.gz (8.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

english2kana-0.1.5-py3-none-any.whl (10.4 kB view details)

Uploaded Python 3

File details

Details for the file english2kana-0.1.5.tar.gz.

File metadata

  • Download URL: english2kana-0.1.5.tar.gz
  • Upload date:
  • Size: 8.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.8.16 Darwin/22.3.0

File hashes

Hashes for english2kana-0.1.5.tar.gz
Algorithm Hash digest
SHA256 676cf8cb50a5989bb1417fae5fec6b7cd2d536b9d85abb35f0d3964a2a522939
MD5 31e7ccadcc66e5d73b8e42864837f31d
BLAKE2b-256 5164654ee5949cb2eb2f4ce402b1ba0a75bf9ee3395a9946510431aa0df28a63

See more details on using hashes here.

File details

Details for the file english2kana-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: english2kana-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 10.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.8.16 Darwin/22.3.0

File hashes

Hashes for english2kana-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 6f6ccfe056d24e4e9acdeb0211f77b20174fe54594a3d07145433071cfa2777a
MD5 c4fa433f070eecadcc6bef1e25ea907b
BLAKE2b-256 b9f7953bbdae75e0fa922420ffb1bed6ed42d2516b2c6a34712aa713c2a6ee20

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page