Skip to main content

egypttranslit

PyPI

A small Python library for converting Egyptological transliteration into clean Unicode.

It is intended for researchers, digital-humanities projects and scripts that need reliable Manuel de Codage-style transliteration conversion without a larger toolchain.

Starting with 1.1.0, the default presentation follows the plain-text forms commonly used in IFAO material: ȝ, ʿ and ỉ. This avoids the raised-looking ꜣ, ꜥ and ꞽ glyphs that some fonts render awkwardly.

A web version built on top of this library for non-technical users is planned for a future release.

Install

Requires Python 3.10 or newer.

python -m pip install egypttranslit

Quick guide

API Use case Profile Example Result
parse(text) Conservative automatic detection IFAO default parse("nTr mAat") "nṯr mȝʿt"
parse_mdc(text) Known MdC transliteration IFAO default parse_mdc("nTr Htp xpr") "nṯr ḥtp ḫpr"
parse_mdc_profiled(text, profile="ifao") Explicit IFAO plain-text output ifao parse_mdc_profiled("mAat", profile="ifao") "mȝʿt"
parse_mdc_profiled(text, profile="unicode-canonical") Previous 1.0.x canonical glyphs unicode-canonical parse_mdc_profiled("mAat", profile="unicode-canonical") "mꜣꜥt"
parse_mdc_profiled(text, profile="gardiner-1957") MdC with Gardiner-style j/q output gardiner-1957 parse_mdc_profiled("jr qd", profile="gardiner-1957") "ꞽr ḳd"
parse_mdc_many(texts) Batch of known MdC strings IFAO default parse_mdc_many(["nTr", "mAat"]) ("nṯr", "mȝʿt")
normalize_unicode(text) Explicit canonical Unicode normalization canonical normalize_unicode("ȝ ʿ ỉ") "ꜣ ꜥ ꞽ"
analyze(text, mode=...) Detection + diagnostics selected mode analyze("mAat", mode="mdc") structured result
validate(text) Reject dangerous mixed encodings none validate("mAꜥt") raises ValueError

convert(text) is an alias for parse(text).

IFAO-style plain text by default

The default output intentionally uses regular plain-text forms instead of the Unicode Egyptological aleph/ayin characters that can look like superscripts in some fonts.

from egypttranslit import parse, parse_mdc

assert parse("nTr mAat") == "nṯr mȝʿt"
assert parse_mdc("A a H x X S T D") == "ȝ ʿ ḥ ḫ ẖ š ṯ ḏ"

Already-transliterated IFAO-style text is stable under the default parser:

from egypttranslit import parse

text = (
    "ḏd-ḥr mȝʿ-ḫrw sȝ n ʿnḫ-ḥr sȝ ỉrỉ-pʿt ḥȝtỉ-ʿ wr ʿȝ n mšwš "
    "ḥȝtỉ-ʿỉmỉ-rȝ ḥmw-nṯr n bȝ-nb-ḏw ḏd-ḥr mwt=f nbt pr šp-n-spdt mȝʿ-ḫr"
)

assert parse(text) == text

The HTML entity  , sometimes copied after such text, is just a space entity and is not part of the transliteration itself.

Automatic conversion

from egypttranslit import parse

assert parse("nTr mAat") == "nṯr mȝʿt"
assert parse("A taxi on the X axis.") == "A taxi on the X axis."

parse() is intentionally conservative: ambiguous ASCII is preserved rather than guessed.

Explicit MdC

from egypttranslit import parse_mdc

assert parse_mdc("nTr Htp xpr mAat") == "nṯr ḥtp ḫpr mȝʿt"
assert parse_mdc("A1-nTr-D36-Htp-T3") == "A1-nṯr-D36-ḥtp-T3"

Common default mappings:

MdC IFAO-style Unicode MdC IFAO-style Unicode
A ȝ a ʿ
H ḥ x ḫ
X ẖ S š
T ṯ D ḏ
3 ȝ

Gardiner/JSesh sign identifiers such as A1, D36 and T3 are preserved.

Canonical Unicode when you need it

The IFAO-style default is a presentation choice. The library still supports the canonical Egyptological Unicode characters explicitly.

For already-Unicode text, use normalize_unicode():

from egypttranslit import normalize_unicode

assert normalize_unicode("ȝ ʿ ỉ") == "ꜣ ꜥ ꞽ"

For known MdC input, use the unicode-canonical profile to reproduce the 1.0.x output convention without rewriting plain j or q:

from egypttranslit.converter import parse_mdc_profiled

assert parse_mdc_profiled(
    "jr qd nTr mAat",
    profile="unicode-canonical",
) == "jr qd nṯr mꜣꜥt"

Batch conversion

Use the batch helpers when each transliteration is a separate record. They preserve input order and return a tuple. Lists, tuples and generators are accepted.

from egypttranslit.batch import parse_mdc_many, parse_mdc_profiled_many

texts = ["nTr Htp", "xpr mAat", "jr qd"]

assert parse_mdc_many(texts) == (
    "nṯr ḥtp",
    "ḫpr mȝʿt",
    "jr qd",
)

assert parse_mdc_profiled_many(
    texts,
    profile="gardiner-1957",
) == (
    "nṯr ḥtp",
    "ḫpr mꜣꜥt",
    "ꞽr ḳd",
)

parse_many() and normalize_unicode_many() provide the same batch behavior for conservative automatic parsing and canonical Unicode normalization.

Profiles

The default behavior uses IFAO-style ȝ, ʿ and ỉ, while leaving plain j and q unchanged because editorial conventions differ.

Profile Behavior Notes
default same as ifao default since 1.1.0
ifao ꜣ → ȝ, ꜥ → ʿ, ꞽ → ỉ (and uppercase equivalents) plain-text IFAO-style presentation
unicode-canonical keeps canonical ꜣ, ꜥ, ꞽ; preserves j and q compatibility path for 1.0.x MdC output
gardiner-1957 j → ꞽ, q → ḳ Gardiner-style output described in Unicode UAX #57
legacy-diacritics same as gardiner-1957 backward-compatible alias
from egypttranslit.converter import parse_mdc_profiled

assert parse_mdc_profiled(
    "jr qd nTr mAat",
    profile="default",
) == "jr qd nṯr mȝʿt"

assert parse_mdc_profiled(
    "jr qd nTr mAat",
    profile="ifao",
) == "jr qd nṯr mȝʿt"

assert parse_mdc_profiled(
    "jr qd nTr mAat",
    profile="gardiner-1957",
) == "ꞽr ḳd nṯr mꜣꜥt"

Profile metadata can be inspected programmatically:

from egypttranslit.profiles import get_profile_info, list_profile_info

info = get_profile_info("ifao")
assert ("ꜣ", "ȝ") in info.mapping
assert info.alias_of is None

available = tuple(profile.name for profile in list_profile_info())
# ("default", "ifao", "unicode-canonical", "gardiner-1957", "legacy-diacritics")

Diagnostics

from egypttranslit.diagnostics import analyze, validate

result = analyze("mAat", mode="mdc")
assert result.text == "mȝʿt"
assert result.detected == "mdc"
assert result.warnings == ()

validate("mAꜥt")  # raises ValueError

detected is one of mdc, unicode, mixed, ambiguous or none. confidence is a deterministic heuristic score, not a philological probability.

Command line

egypttranslit "nTr mAat"
# nṯr mȝʿt

egypttranslit --mode mdc "nTr Htp xpr"
# nṯr ḥtp ḫpr

egypttranslit --mode mdc --profile unicode-canonical "nTr mAat"
# nṯr mꜣꜥt

egypttranslit --mode mdc --profile gardiner-1957 "jr qd nTr"
# ꞽr ḳd nṯr

egypttranslit --mode unicode "ȝ ʿ ỉ"
# ꜣ ꜥ ꞽ

For pipelines:

cat input.txt | egypttranslit --mode mdc > output.txt

Modes are auto (default IFAO-style output), mdc and unicode (canonical normalization). Non-default profiles are valid only with --mode mdc.

Citation

Citation metadata is provided in CITATION.cff.

Barrios, E. J. egypttranslit [Computer software]. https://github.com/edujbarrios/egypttranslit

References

License

Apache-2.0. Attribution information is provided in NOTICE and citation metadata in CITATION.cff.

Metadata

Release files for egypttranslit 1.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for egypttranslit 1.1.0
File Size Uploaded
egypttranslit-1.1.0.tar.gz 40.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for egypttranslit 1.1.0
File Interpreter ABI Platform
egypttranslit-1.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 61.6 kB

Release files / egypttranslit-1.1.0.tar.gz

Download URL egypttranslit-1.1.0.tar.gz
Size 40.8 kB
Tags Source
SHA-256 checksum
How to use checksums
e49198e4c50d4c9f4813d74654872940244eee4ebe87355c0f277c7d2174dd2f
BLAKE2b-256 checksum
How to use checksums
432f830aeb7f61cab599de01b26b2d2327c13a6a6329e8bca079dab4e4085edd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 30, 2026.

Transparency log

Release files / egypttranslit-1.1.0-py3-none-any.whl

Download URL egypttranslit-1.1.0-py3-none-any.whl
Size 20.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
60c437fddd9462682efbcb50fa63da5ed2307e4d198ac3f4b8d27c0ae2af00d5
BLAKE2b-256 checksum
How to use checksums
65e4b1bbf02557d582521569eb125f957834c3a516e64f177432d8daac99a724
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 30, 2026.

Transparency log

Release history Release notifications | RSS feed

1.1.1

2 release files

This release

1.1.0 This release

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page