Skip to main content

turkmen-num2words

Spell out integers in Turkmen: 1234 → "müň iki ýüz otuz dört".

CI License: MIT Python 3.9+ Node 18+ Zero dependencies

A zero-dependency library and CLI that converts integers into Turkmen cardinal-number words, in the modern Latin alphabet. Useful for text-to-speech, language learning, receipts and invoices, and spelling out amounts. Available for both Python and JavaScript/TypeScript.

$ tm-num 1352647
bir million üç ýüz elli iki müň alty ýüz kyrk ýedi
$ tm-num 0 100 1000 -5
nol
ýüz
müň
minus bäş

Why trust the output

The numbers come straight from primary sources, and the library reproduces the one authoritative worked example exactly:

1 352 647 → bir million üç ýüz elli iki müň alty ýüz kyrk ýedi — A Short Descriptive Grammar of Turkmen, R. Gray (SIL).

Every spelling and composition decision — why 100 is ýüz (not bir ýüz) but 1 000 000 is bir million, which spelling of 90 and zero are standard, where the range stops — is documented in docs/numbers.md, with the alternatives listed for transparency.

Install

pipx install turkmen-num2words     # for the tm-num command
# or
pip install turkmen-num2words      # for the library

Python 3.9+, no third-party dependencies.

Use

from turkmen_num2words import number_to_turkmen

number_to_turkmen(21)  # 'ýigrimi bir'
number_to_turkmen(100)  # 'ýüz'
number_to_turkmen(2000)  # 'iki müň'
number_to_turkmen(1000000)  # 'bir million'
number_to_turkmen(-5)  # 'minus bäş'
tm-num 42                    # one number
tm-num 7 42 100              # several (one line each)
echo "99 100" | tm-num       # from stdin

JavaScript / TypeScript

The npm package @garag0l/turkmen-num2words (in js/) shares the same rules and test values.

npm install @garag0l/turkmen-num2words
import { numberToTurkmen } from "@garag0l/turkmen-num2words";

numberToTurkmen(1234); // "müň iki ýüz otuz dört"
numberToTurkmen(-5); // "minus bäş"
npx tm-num 1234              # müň iki ýüz otuz dört

Range

Supports -(10¹²) < n < 10¹². Values at or beyond 10¹² raise ValueError, because the Turkmen word for a trillion isn't reliably attested — the library refuses to guess rather than print something wrong.

Tested

  • A table of known values from 0 through 999 999 999 999, the Gray compound example, the ýüz/müň drop-"bir" rule vs million/milliard keep-"bir", negatives, range limits, and type errors.
  • The CLI (args, stdin, multiple numbers, error exit codes).
  • CI on Linux/macOS/Windows across Python 3.9–3.13.

Roadmap

  • Ordinals (birinji, ikinji, …) with correct vowel harmony.
  • Pairs well with turkmen-translit for full Turkmen text handling.

Contributing

Issues and PRs welcome — especially sourced corrections to spellings or the trillion-and-up scale words.

python -m venv .venv && . .venv/bin/activate
pip install -e ".[dev]"
pytest && ruff check .

License

MIT. Built by Murat Bekgi.

Metadata

Release files for turkmen-num2words 0.1.1

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

Source distribution (sdist)

Source distribution for turkmen-num2words 0.1.1
File Size Uploaded Provenance Actions
turkmen_num2words-0.1.1.tar.gz 12.9 kB With provenance Details for turkmen_num2words-0.1.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for turkmen-num2words 0.1.1
File Interpreter ABI Platform Actions
turkmen_num2words-0.1.1-py3-none-any.whl Python 3 none any Details for turkmen_num2words-0.1.1-py3-none-any.whl

Total release size: 20.0 kB

Release files / turkmen_num2words-0.1.1.tar.gz

Download URL turkmen_num2words-0.1.1.tar.gz
Size 12.9 kB
Tags Source
SHA-256 checksum
How to use checksums
bffa5b0ceb5d28778a776fcc9612b3f67bb403a8019dd7996d82899fe26aced3
BLAKE2b-256 checksum
How to use checksums
d3303dd052f3455b50aac891496da9afb56d9e425883289ef846ec6149dc7cf7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 22, 2026.

Transparency log

Release files / turkmen_num2words-0.1.1-py3-none-any.whl

Download URL turkmen_num2words-0.1.1-py3-none-any.whl
Size 7.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8c6304640e40f0c91d08c83d99635838d2976a45cbda97d46f8b8abec55aaf14
BLAKE2b-256 checksum
How to use checksums
d5d01fbb701865cf721f62027d2861243ebee82a3818c28bb4b3fadd2aab5de3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 22, 2026.

Transparency log

Security for turkmen-num2words 0.1.1

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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for turkmen_num2words-0.1.1.tar.gz

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 Nov 22, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files Full provenance

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