zimankit
zimankit logo: the deq tree-of-life sign with the sun of the flag of Kurdistan zimankit logo: the deq tree-of-life sign with the sun of the flag of Kurdistan

Kurdish, written well.

zimankit is a language toolkit for Central Kurdish (Sorani) and Northern Kurdish (Kurmanji): normalisation, IPA, transliteration, morphology, full verb paradigms, ergativity checking, language identification and clean wordlists, as a Python library and a command-line tool.

زمانکیت · zimankit · ziman means “language”

Everything a Kurdish text needs

Every skill works for both written varieties and needs nothing but the Python standard library. The language is detected from the script, or you choose it.

Aa

Orthography

Normalise Arabic and Persian look-alike letters, Hawar Latin spellings and invisible characters, and validate words against the alphabet.

كوردي → کوردی
/ə/

IPA and syllables

Grapheme-to-phoneme rules for both varieties, including the unwritten Sorani vowel (bizroke), with syllable boundaries.

کتێبەکەم → k(ɯ).teː.bæ.kæm
⇄

Transliteration

Sorani from the Arabic-based script to Latin, and Kurmanji from Hawar Latin to the Arabic-based script.

Îro hewa xweş e → ئیرۆ هەوا خوەش ئە
+

Morphology

Segment and analyse words into lemma, part of speech, definiteness, number, case, gender and enclitics, with ranked analyses.

ماڵەکانمان → ماڵ+ەکان+مان
∑

Verb paradigms

Conjugate any verb through every tense, mood, person and polarity, including compound verbs and verbs not in the reference list.

zimankit conjugate کردن
⚖

Ergativity

Check Kurmanji split ergativity: in past transitive clauses the verb agrees with the object, and zimankit says when it does not.

Min tu dîtim. → agreement_ok: false
?

Language identification

Tell Sorani, Kurmanji, Zazaki and Gorani apart from each other and from Persian, Arabic, Turkish and English.

Ma yew roje … → zza 0.995
≡

Wordlists and data

Build clean wordlists, lemma tables and grammar rules from dictionaries, wiki dumps and corpora, and export a flat Kaggle dataset.

python run_pipeline.py
✎

Learn Kurdish

Two complete courses, Sorani and Kurmanji, 23 lessons each, from the alphabet to ergativity. Their tables are generated by zimankit.

docs/tutorials/

See it

Real output of the zimankit command. Run the same commands in the playground, no installation needed.

$ zimankit ipa پیاوەکە کتێبەکەم jinekê dîtin
pjaːwækæ
k(ɯ)teːbækæm
ʒɪnɛkeː
diːtɯn

$ zimankit translit "ئەمڕۆ هەوا خۆشە" "Îro hewa xweş e"
emrro hewa xoşe
ئیرۆ هەوا خوەش ئە

$ zimankit lid "Ma yew roje şima ra vat ke ziwanê ma zaf rind o"
zza	0.995	Ma yew roje şima ra vat ke ziwanê ma zaf rind o
$ zimankit analyze ماڵەکانمان jinekê
ماڵەکانمان  ماڵ  NOUN  ماڵ+ەکان+مان  STEM+DEF.PL+1PL
jinekê     jin  NOUN  jin+ekê      STEM+INDEF.OBL.F

$ zimankit conjugate کردن | head -4
دەکەم	tense=present,mood=indicative,person=1sg
ناکەم	tense=present,mood=indicative,person=1sg,polarity=neg
بکەم	tense=present,mood=subjunctive,person=1sg
نەکەم	tense=present,mood=subjunctive,person=1sg,polarity=neg

$ echo "Min tu dîtim." | zimankit ergativity
… "alignment": "ergative", "agreement_ok": false,
"notes": ["verb ending marks 1sg but object 'tu' is 2sg"]

Install

zimankit 0.1.0 needs Python 3.11 or newer and has no dependencies. Every file is on the latest release.

pip, from the release

Any system with Python 3.11+.

pip install https://github.com/0xdolan/zimankit/releases/download/v0.1.0/zimankit-0.1.0-py3-none-any.whl

pip, from GitHub

A tagged version, or the latest main.

pip install "git+https://github.com/0xdolan/zimankit.git@v0.1.0"

Debian, Ubuntu, Kali (.deb)

Installs the library and the zimankit command system-wide.

sudo apt install ./python3-zimankit_0.1.0-1_all.deb

From source

With the docs, tutorials, data pipeline and tests (.zip or .tar.gz on the release).

git clone https://github.com/0xdolan/zimankit.git
cd zimankit && pip install -e ".[dev]"
python -m pytest -q

Check a download with sha256sum -c SHA256SUMS. Optional extras: [data] to read .mdx and .zim files, [kaggle] for the Parquet export.

Use it from Python

from zimankit import analyze, normalize, to_ipa, identify

analyze("کتێبەکەم")[0].segmentation   # 'کتێب+ەکە+م'
to_ipa("jinekê")                        # 'ʒɪnɛkeː'
normalize("كوردي")                      # 'کوردی'
identify("Îro hewa xweş e").lang        # 'kmr'
  1. Install with pip or the .deb.
  2. Try the command: zimankit --help lists every skill, and every command reads from arguments or standard input.
  3. Read the guide for each command, the Python API, the wordlist pipeline and the Kaggle dataset.
  4. Learn the grammar behind it in the developer chapters and the tutorials.

A sun at the heart of a sign of life

The logo is a deq sign, the traditional hand-poked tattoo of Kurdish women: the figure read as the tree of life. At its heart shines Roj, the 21-rayed sun of the flag of Kurdistan. Roj means both “sun” and “day”.

Read the story

the deq sign plus the sun of the flag of Kurdistan makes the zimankit logo