Skip to main content

Google Transliterate API for Python

Project description

Google Transliteration - Python API

A Python library to use Google Transliterate API which powers the G Input Tools.

Install using:

pip install google-transliteration-api

Note:

Usage

Check here for list of supported languages.

Get suggestions for a word

from google.transliteration import transliterate_word
suggestions = transliterate_word('America', lang_code='ja')
print(suggestions)

['アメリカ', '米国', '米', '亜米利加', '亜墨利加', '米利堅']

The above transliterates the word 'America' into Japanese script and returns a list of possible suggestions.

Transliterate a sentence or text

(Experimental)

from google.transliteration import transliterate_text
result = transliterate_text('Hello comrade!', lang_code='ru')
print(result)

хелло комраде!

Transliterate numerals

from google.transliteration import transliterate_numerals
result = transliterate_numerals('3210', lang_code='zh')
print(result)

三二一〇


Similar works


Please feel free to contribute by Pull Requests or raise an issue.


DMCA & Disclaimer

If you're Google and want us to take down the API, please raise an issue mentioning the main contributors.

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

google-transliteration-api-1.0.3.tar.gz (4.9 kB view hashes)

Uploaded Source

Built Distribution

Supported by

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