Skip to content

nalgeon/iuliia

Repository files navigation

Iuliia

Transliterate Cyrillic → Latin in every possible way

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 easy as calling iuliia.translate() in your favorite programming language.

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.

Supported schemas

Actual schemas:

And deprecated ones:

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

Supported languages

This repo contains schema descriptions. It is not intended to be used directly. If you want to add another schema — send a PR! See schema.jsd for JSON Schema definition and wikipedia.json as a reference.

Issues and limitations

In general:

  • Only Russian subset of Cyrillic is supported.
  • Does not support composite Unicode characters (e.g., Ё, but not Ё).

Schema-specific:

  • BS 2979:1958. This schema defines two alternative translations for Ы: ЫȲ (used by the Oxford University Press) and ЫUI (used by the British Library). iuliia uses ЫȲ.
  • GOST R 7.0.34-2014. This schema defines alternatives for many letters, but does not specify when to use which. Therefore, iuliia uses the first of suggested translations for each such letter.
  • MVD-310. This schema defines "С between two vowels → SS" rule. There is no such rule in other schemas, and MVD-310 itself is deprecated, so I decided to ignore this specific rule for the sake of code simplicity.

About

Transliterate Cyrillic → Latin in every possible way

Topics

Resources

License

Stars

Watchers

Forks