All Projects → nalgeon → iuliia-py

nalgeon / iuliia-py

Licence: MIT license
Transliterate Cyrillic → Latin in every possible way

Programming Languages

python
139335 projects - #7 most used programming language
Makefile
30231 projects

Projects that are alternatives of or similar to iuliia-py

Lexical Sort
Sort Unicode strings lexicographically
Stars: ✭ 23 (-73.26%)
Mutual labels:  transliteration
Mrz
Machine Readable Zone generator and checker for official travel documents sizes 1, 2, 3, MRVA and MRVB (Passports, Visas, national id cards and other travel documents)
Stars: ✭ 119 (+38.37%)
Mutual labels:  transliteration
Transliterate
Bi-directional transliterator for Python. Transliterates (unicode) strings according to the rules specified in the language packs.
Stars: ✭ 193 (+124.42%)
Mutual labels:  transliteration
Crx Jtrans
jTransliter - the roman to unicode transliter as Google chrome extension
Stars: ✭ 13 (-84.88%)
Mutual labels:  transliteration
Lipika Ime
Input Method Engine (IME) for Mac OS X with built-in support for all Indic Languages
Stars: ✭ 76 (-11.63%)
Mutual labels:  transliteration
Transliterate
Convert Unicode characters to Latin characters using transliteration
Stars: ✭ 152 (+76.74%)
Mutual labels:  transliteration
Slug Generator
Slug Generator Library for PHP, based on Unicode’s CLDR data
Stars: ✭ 740 (+760.47%)
Mutual labels:  transliteration
iuliia-go
Transliterate Cyrillic → Latin in every possible way
Stars: ✭ 36 (-58.14%)
Mutual labels:  transliteration
Cyrillic To Translit Js
Ultra-lightweight JavaScript library for converting Cyrillic symbols to Translit and vice versa
Stars: ✭ 91 (+5.81%)
Mutual labels:  transliteration
Slugify
Slugify a string
Stars: ✭ 2,110 (+2353.49%)
Mutual labels:  transliteration
Deeptranslit
Efficient and easy to use transliteration for Indian languages
Stars: ✭ 41 (-52.33%)
Mutual labels:  transliteration
Speakingurl
Generate a slug – transliteration with a lot of options
Stars: ✭ 1,056 (+1127.91%)
Mutual labels:  transliteration
Avspeechsynthesizer Example
A companion project to the NSHipster article about AVSpeechSynthesizer
Stars: ✭ 157 (+82.56%)
Mutual labels:  transliteration
Cyr2lat
Converts Cyrillic characters in post, page and term slugs to Latin characters. Useful for creating human-readable URLs.
Stars: ✭ 25 (-70.93%)
Mutual labels:  transliteration
transliteration-php
🇺🇦 🇬🇧 🔡 🐘 PHP library for transliteration.
Stars: ✭ 34 (-60.47%)
Mutual labels:  transliteration
Hanbaobao
Mandarin Chinese text segmentation and mobile dictionary Android app (中文分词)
Stars: ✭ 17 (-80.23%)
Mutual labels:  transliteration
Inflected
A port of ActiveSupport's inflector to Node.js and the browser.
Stars: ✭ 144 (+67.44%)
Mutual labels:  transliteration
iuliia
Transliterate Cyrillic → Latin in every possible way
Stars: ✭ 62 (-27.91%)
Mutual labels:  transliteration
carakanjs
Convert/transliterate Latin script into Javanese script, also known as Aksara Jawa or Carakan.
Stars: ✭ 23 (-73.26%)
Mutual labels:  transliteration
Neural japanese transliterator
Can neural networks transliterate Romaji into Japanese correctly?
Stars: ✭ 170 (+97.67%)
Mutual labels:  transliteration

Iuliia

Transliterate Cyrillic → Latin in every possible way

PyPI Version Build Status Code Coverage Code Quality

Transliteration means representing Cyrillic data (mainly names and geographic locations) with Latin letters. It is used for international passports, visas, green cards, driving licenses, mail and goods delivery etc.

Iuliia makes transliteration as easy as:

>>> import iuliia
>>> iuliia.translate("Юлия Щеглова", schema=iuliia.WIKIPEDIA)
'Yuliya Shcheglova'

Why use Iuliia

  • 20 transliteration schemas (rule sets), including all main international and Russian standards.
  • Correctly implements not only the base mapping, but all the special rules for letter combinations and word endings (AFAIK, Iuliia is the only library which does so).
  • Simple API and zero third-party dependencies.

For schema details and other information, see iuliia.ru (in Russian).

Issues and limitations

Installation

pip install iuliia

Usage

List all supported schemas:

>>> import iuliia
>>> import iuliia
>>> for name, schema in iuliia.Schemas.items():
...     print("{0:<20}{1}".format(name, schema.description))
...
ala_lc              ALA-LC transliteration schema.
ala_lc_alt          ALA-LC transliteration schema.
bgn_pcgn            BGN/PCGN transliteration schema
bgn_pcgn_alt        BGN/PCGN transliteration schema
bs_2979             British Standard 2979:1958 transliteration schema
bs_2979_alt         British Standard 2979:1958 transliteration schema
gost_16876          GOST 16876-71 (aka GOST 1983) transliteration schema
gost_16876_alt      GOST 16876-71 (aka GOST 1983) transliteration schema
gost_52290          GOST R 52290-2004 transliteration schema
gost_52535          GOST R 52535.1-2006 transliteration schema
gost_7034           GOST R 7.0.34-2014 transliteration schema
gost_779            GOST 7.79-2000 (aka ISO 9:1995) transliteration schema
gost_779_alt        GOST 7.79-2000 (aka ISO 9:1995) transliteration schema
icao_doc_9303       ICAO DOC 9303 transliteration schema
iso_9_1954          ISO/R 9:1954 transliteration schema
iso_9_1968          ISO/R 9:1968 transliteration schema
iso_9_1968_alt      ISO/R 9:1968 transliteration schema
mosmetro            Moscow Metro map transliteration schema
mvd_310             MVD 310-1997 transliteration schema
mvd_310_fr          MVD 310-1997 transliteration schema
mvd_782             MVD 782-2000 transliteration schema
scientific          Scientific transliteration schema
telegram            Telegram transliteration schema
ungegn_1987         UNGEGN 1987 V/18 transliteration schema
wikipedia           Wikipedia transliteration schema
yandex_maps         Yandex.Maps transliteration schema
yandex_money        Yandex.Money transliteration schema

Transliterate using specified schema:

>>> source = "Юлия Щеглова"
>>> iuliia.translate(source, schema=iuliia.ICAO_DOC_9303)
'Iuliia Shcheglova'

Or pick schema by name

>>> schema = iuliia.Schemas.get("wikipedia")
>>> iuliia.translate(source, schema)
'Yuliya Shcheglova'

Command line:

$ iuliia icao_doc_9303 "Юлия Щеглова"
Iuliia Shcheglova

Development setup

$ python3 -m venv env
$ . env/bin/activate
$ make deps schemas
$ tox

Development tasks:

$ make help
Usage: make [task]

task                 help
------               ----
changelog            Generate changelog
coverage             Run tests with coverage
deps                 Install dependencies
lint                 Lint and static-check code
pull                 Pull code and schemas
push                 Push commits and tags
schemas              Update schemas
test                 Run tests
help                 Show help message

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Make sure to add or update tests as appropriate.

Use Black for code formatting and Conventional Commits for commit messages.

Changelog

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].