Languages and Dialects transliteration
Project description
3aransia
Languages and Dialects transliteration
Prerequisites
Installation
pip install aaransia
Usage
Get all alphabets codes
from aaransia import get_alphabets_codes
print(get_alphabets_codes())
>>> ['ma', 'ar', 'la', 'ab', 'gr']
Get all alphabets
from aaransia import get_alphabets
print(get_alphabets())
>>> {
>>> 'ab': 'Abjadi Alphabet',
>>> 'ar': 'Arabian Alphabet',
>>> 'gr': 'Greek Alphabet',
>>> 'la': 'Latin Alphabet',
>>> 'ma': 'Moroccan Alphabet'
>>> }
Transliterate from a language or dialect to another
s_ar = "كتب بلعربيا هنايا شحال ما بغيتي"
print(transliterate(s_ar, source='ar', target='ma'))
>>> ktb bl3rbya hnaya ch7al ma bghiti
Transliterate from all languages to all languages
from aaransia import transliterate, SourceLanguageException
s_ma = "ktb bl3rbya hnaya ch7al ma bghiti"
s_ar = "كتب بلعربيا هنايا شحال ما بغيتي"
s_la = "ktb bl'rbya hnaya chhal ma bghiti"
s_ab = "ktb bl'rbya hnaya chḥal ma bghiti"
s_gr = "κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι"
strings = [s_ma, s_ar, s_la, s_ab, s_gr]
for s in strings:
for source_language in get_alphabets_codes():
for target_language in get_alphabets_codes():
try:
print(f'{s}\n{source_language} ==> {target_language}\n{transliterate(s, source_language, target_language)}\n')
except SourceLanguageException as sle:
print(f'{p}, {sle}')
>>> ktb bl3rbya hnaya ch7al ma bghiti
>>> ma ==> ma
>>> ktb bl3rbya hnaya ch7al ma bghiti
>>>
>>> ktb bl3rbya hnaya ch7al ma bghiti
>>> ma ==> ar
>>> كتب بلعربيا هنايا شحال ما بغيتي
>>>
>>> ktb bl3rbya hnaya ch7al ma bghiti
>>> ma ==> la
>>> ktb bl'rbya hnaya chhal ma bghiti
>>>
>>> ktb bl3rbya hnaya ch7al ma bghiti
>>> ma ==> ab
>>> ktb bl'rbya hnaya chḥal ma bghiti
>>>
>>> ktb bl3rbya hnaya ch7al ma bghiti
>>> ma ==> gr
>>> κτμπ μπλ'ρμπυα χναυα σχαλ μα μπγιτι
>>>
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: ar
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: ar
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: ar
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: ar
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: ar
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: la
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: la
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: la
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: la
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: la
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: ab
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: ab
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: ab
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: ab
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: ab
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: gr
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: gr
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: gr
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: gr
>>> ktb bl3rbya hnaya ch7al ma bghiti Source language doesn't match the input text: gr
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: ma
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: ma
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: ma
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: ma
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: ma
>>> كتب بلعربيا هنايا شحال ما بغيتي
>>> ar ==> ma
>>> ktb bl3rbya hnaya ch7al ma bghyty
>>>
>>> كتب بلعربيا هنايا شحال ما بغيتي
>>> ar ==> ar
>>> كتب بلعربيا هنايا شحال ما بغيتي
>>>
>>> كتب بلعربيا هنايا شحال ما بغيتي
>>> ar ==> la
>>> ktb bl'rbya hnaya chhal ma bghyty
>>>
>>> كتب بلعربيا هنايا شحال ما بغيتي
>>> ar ==> ab
>>> ktb bl'rbya hnaya chḥal ma bghyty
>>>
>>> كتب بلعربيا هنايا شحال ما بغيتي
>>> ar ==> gr
>>> κτμπ μπλ'ρμπυα χναυα σχαλ μα μπγυτυ
>>>
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: la
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: la
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: la
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: la
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: la
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: ab
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: ab
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: ab
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: ab
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: ab
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: gr
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: gr
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: gr
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: gr
>>> كتب بلعربيا هنايا شحال ما بغيتي Source language doesn't match the input text: gr
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: ma
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: ma
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: ma
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: ma
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: ma
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: ar
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: ar
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: ar
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: ar
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: ar
>>> ktb bl'rbya hnaya chhal ma bghiti
>>> la ==> ma
>>> ktb bl3rbya hnaya chhal ma bghiti
>>>
>>> ktb bl'rbya hnaya chhal ma bghiti
>>> la ==> ar
>>> كتب بلعربيا هنايا شهال ما بغيتي
>>>
>>> ktb bl'rbya hnaya chhal ma bghiti
>>> la ==> la
>>> ktb bl'rbya hnaya chhal ma bghiti
>>>
>>> ktb bl'rbya hnaya chhal ma bghiti
>>> la ==> ab
>>> ktb bl'rbya hnaya chhal ma bghiti
>>>
>>> ktb bl'rbya hnaya chhal ma bghiti
>>> la ==> gr
>>> κτμπ μπλ'ρμπυα χναυα σχαλ μα μπγιτι
>>>
>>> ktb bl'rbya hnaya chhal ma bghiti
>>> ab ==> ma
>>> ktb bl3rbya hnaya chhal ma bghiti
>>>
>>> ktb bl'rbya hnaya chhal ma bghiti
>>> ab ==> ar
>>> كتب بلعربيا هنايا شهال ما بغيتي
>>>
>>> ktb bl'rbya hnaya chhal ma bghiti
>>> ab ==> la
>>> ktb bl'rbya hnaya chhal ma bghiti
>>>
>>> ktb bl'rbya hnaya chhal ma bghiti
>>> ab ==> ab
>>> ktb bl'rbya hnaya chhal ma bghiti
>>>
>>> ktb bl'rbya hnaya chhal ma bghiti
>>> ab ==> gr
>>> κτμπ μπλ'ρμπυα χναυα σχαλ μα μπγιτι
>>>
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: gr
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: gr
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: gr
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: gr
>>> ktb bl'rbya hnaya chhal ma bghiti Source language doesn't match the input text: gr
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: ma
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: ma
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: ma
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: ma
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: ma
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: ar
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: ar
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: ar
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: ar
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: ar
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: la
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: la
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: la
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: la
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: la
>>> ktb bl'rbya hnaya chḥal ma bghiti
>>> ab ==> ma
>>> ktb bl3rbya hnaya ch7al ma bghiti
>>>
>>> ktb bl'rbya hnaya chḥal ma bghiti
>>> ab ==> ar
>>> كتب بلعربيا هنايا شحال ما بغيتي
>>>
>>> ktb bl'rbya hnaya chḥal ma bghiti
>>> ab ==> la
>>> ktb bl'rbya hnaya chhal ma bghiti
>>>
>>> ktb bl'rbya hnaya chḥal ma bghiti
>>> ab ==> ab
>>> ktb bl'rbya hnaya chḥal ma bghiti
>>>
>>> ktb bl'rbya hnaya chḥal ma bghiti
>>> ab ==> gr
>>> κτμπ μπλ'ρμπυα χναυα σχαλ μα μπγιτι
>>>
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: gr
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: gr
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: gr
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: gr
>>> ktb bl'rbya hnaya chḥal ma bghiti Source language doesn't match the input text: gr
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ma
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ma
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ma
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ma
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ma
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ar
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ar
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ar
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ar
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ar
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: la
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: la
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: la
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: la
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: la
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ab
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ab
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ab
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ab
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι Source language doesn't match the input text: ab
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι
>>> gr ==> ma
>>> ktb bl3rbya hnaya chhal ma bghiti
>>>
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι
>>> gr ==> ar
>>> كتب بلعربيا هنايا شهال ما بڭهيتي
>>>
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι
>>> gr ==> la
>>> ktb bl'rbya hnaya chhal ma bghiti
>>>
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι
>>> gr ==> ab
>>> ktb bl'rbya hnaya chhal ma bghiti
>>>
>>> κτμπ μπλ'ρμπυα χναυα σχχαλ μα μπγχιτι
>>> gr ==> gr
>>> κτμπ μπλ'ρμπυα χναυα σχαλ μα μπγχιτι
Other related projects
- 3aransia.api The api of 3aransia
- 3aransia.web The web application of 3aransia
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
aaransia-0.3.tar.gz
(8.9 kB
view details)
File details
Details for the file aaransia-0.3.tar.gz
.
File metadata
- Download URL: aaransia-0.3.tar.gz
- Upload date:
- Size: 8.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.4.2 requests/2.19.1 setuptools/40.2.0 requests-toolbelt/0.9.1 tqdm/4.26.0 CPython/3.7.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
3e7d11ec77d253938bcda9a6e3239e196980beb4e814fc0ed59cf1be08a8b384
|
|
MD5 |
9df70e016f28ddfa62a79ff661d38dee
|
|
BLAKE2b-256 |
74fddf5ac0eec62c6db87cd2682a7f45d8e1bc917efff5b7383b6e04b63bfb7d
|