Skip to main content

Potnia is an open-source Python library designed to convert Romanized transliterations of ancient texts into Unicode representations of ther respective native scripts..

Project description

https://raw.githubusercontent.com/AncientNLP/potnia/main/docs/_static/img/PotniaLogo.png

pypi badge testing badge coverage badge docs badge git3moji badge black badge

Potnia is an open-source Python library designed to convert Romanized transliterations of ancient texts into Unicode representations of ther respective native scripts.

Currently, the scripts supported by Potnia are: - Linear A - Linear B - Hittite cuneiform - Arabic

Functionality for Luwian hieroglyphs, Sumero-Akkadian cuneiform and Etruscan is in development.

Contributions are welcome! Please see the CONTRIBUTING.rst file for more information.

Installation

To install Potnia, run the following command:

pip install potnia

To install the latest version from the repository, you can use this command:

pip install git+https://github.com/AncientNLP/potnia.git

Usage

To convert transliterated Linear B to Linear B Unicode, use the following code:

>>> from potnia import linear_b
>>> linear_b("a-ri-to-jo")
'𐀀𐀪𐀵𐀍'

If you wish to regularize the text to remove additional annotations present in the LiBER <https://liber.cnr.it/index> and DĀMOS <https://damos.hf.uio.no/about/content/>` transliterations, use the following code:

>>> linear_b("e-ke-qe ]-o-na-to , ke-ke-me-na⌞ ⌟ko-to-na GRA qs ] vac.", regularize=True)
'𐀁𐀐𐀤 %𐀃𐀙𐀵 𐀐𐀐𐀕𐀙 𐀒𐀵𐀙 𐂎 %'

Note that uncertain/missing signs or sections of text are presently being replaced with a wildcard ‘%’ character.

To tokenize transliterated Linear B texts without converting it to Unicode, use the following code:

>>> linear_b.tokenize_transliteration("]wa VIR 1 MUL 2 'ko-wa 1' ko-wo 1")
[']', 'wa', ' ', 'VIR', ' ', '1', ' ', 'MUL', ' ', '2', ' ', "'", 'ko', 'wa', ' ', '1', "'", ' ', 'ko', 'wo', ' ', '1']

Command Line Interface (CLI)

Potnia also provides a command line interface (CLI).

To convert transliterated Linear B to Unicode, use the following command:

potnia linear-b "a-ri-to-jo"

To regularize the text, use the following command:

potnia linear-b "e-ke-qe ]-o-na-to , ke-ke-me-na⌞ ⌟ko-to-na GRA qs ] vac." --regularize

To see the full set of commands available in the CLI, use the following command:

potnia --help

Graphical User Interface (GUI)

https://raw.githubusercontent.com/AncientNLP/potnia/main/docs/_static/img/potnia-gui.png

Potnia also provides a graphical user interface (GUI). To start it, run:

potnia gui

This will show a link in the terminal that you can click on to open the GUI in your browser.

Credits

Potnia is developed by:

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

potnia-0.3.0.tar.gz (26.3 kB view details)

Uploaded Source

Built Distribution

potnia-0.3.0-py3-none-any.whl (30.0 kB view details)

Uploaded Python 3

File details

Details for the file potnia-0.3.0.tar.gz.

File metadata

  • Download URL: potnia-0.3.0.tar.gz
  • Upload date:
  • Size: 26.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.10.12 Linux/6.5.0-1025-azure

File hashes

Hashes for potnia-0.3.0.tar.gz
Algorithm Hash digest
SHA256 d82e7e9e79f01b4948d746bf3ea55e903f0e5823e160f909634919133059244a
MD5 ba4f5f3db064a01a6d2f8461ed9b8ce7
BLAKE2b-256 ac1b1cad58b91d252d9453176b7b6e7f6d6bc667ca9e23c02bfd3c0dbc1c8b85

See more details on using hashes here.

File details

Details for the file potnia-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: potnia-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 30.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.10.12 Linux/6.5.0-1025-azure

File hashes

Hashes for potnia-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4f8f779dcc34f9dc05d7178ab17f65cbd7c6d6d93032963f45ec1872f24b3974
MD5 d110f0c098dc57971f9ed2175372e9ac
BLAKE2b-256 7db00b2d1e9f8cb767b4035253d05e3df2a7469087da38e40023e1244eb38ee2

See more details on using hashes here.

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