Skip to main content
Loss of provenance

A previous release had provenance metadata, but this release does not. View details.

Kokborok (Kókborok) Language Library for Python

PyPI Version Python Version License: MIT Language

Kokborok (Kókborok) is the first-ever comprehensive, standard-library-style Python NLP and linguistic preservation toolkit for Kokborok (Tripuri)—the official Sino-Tibetan / Bodo-Garo language of the state of Tripura in Northeast India.

Built with 105,151 quadri-lingual headwords (Kokborok-English-Hindi-Bengali), dynamic generation of 320,000+ morphological inflections, Roman <-> Bengali script transliteration, semantic numeral classifiers, and cultural preservation records.


🌟 Key Features

  1. 105,000+ Quadri-lingual Dictionary: Curated vocabulary with definitions in Kokborok, English, Hindi, and Bengali.
  2. 320,000+ Morphological Inflections: Decomposes and generates verbal aspects (-kha, -nai, -tong, -ya, -liya), nominal case postpositions (-no, -ni, -o, -bai, -ni-simi, -ha), and adjectival prefixation (kw- / k-).
  3. Roman & Bengali Script Support: High-accuracy bidirectional transliteration between official Roman Kokborok orthography and Bengali-Assamese script.
  4. Tone & Syllable Engine: High-tone pitch accent marking (á, é, í, ó, ú, ẃ), tone stripping, and syllable segmentation.
  5. Numeral & Classifier System: 1 to 1,000,000 numerals with human (khorok-), animal (kwtwi-), long (gong-), flat (tai-), and plant (phang-) classifiers.
  6. Universal Multi-Lingual Translation: Bidirectional translation across Kokborok, English, Hindi, and Bengali with dialect adaptation (Debbarma, Reang/Bru, Jamatia, Noatia).
  7. Tripura Cultural Heritage & Calendar: Complete documentation of Kokborok Day (19 January), 12 lunar-solar months, 7 days, 4 seasons, festivals (Garia Puja, Kharchi Puja, Ker Puja, Hojagiri), and epics (Rajmala, Chethuang).
  8. Command-Line Interface (CLI): Full CLI (kokborok translate, lookup, num, culture, stats).

📦 Installation

pip install kokborok

Or install from source:

git clone https://github.com/infoakshatsinghbisht-eng/kokborok-language-Library.git
cd kokborok-language-Library
pip install -e .

🚀 Quick Start Guide

1. Translation Across Dialects & Languages

import kokborok

# English -> Kokborok
res = kokborok.translate("How are you?")
print(res.text)  # "Nwng bahai tong?"

# Hindi -> Kokborok
res_hi = kokborok.translate("नमस्ते")
print(res_hi.text)  # "Khulumkha!"

# Bengali -> Kokborok
res_ben = kokborok.translate("ধন্যবাদ")
print(res_ben.text)  # "Hambai!"

# Dialect adaptation (Reang / Bru)
res_bru = kokborok.translate("How are you?", dialect="reang")
print(res_bru.text)

2. Dictionary Lookup & Morphological Analysis

# Exact or morphological root lookup
entry = kokborok.lookup("khulumkha")
print(entry)
# {'kokborok': 'khulumkha', 'english': 'Greetings / Hello', 'hindi': 'नमस्ते / प्रणाम', 'bengali': 'নমস্কার'}

# Search across languages
results = kokborok.search("water")
print(results[0])
# {'kokborok': 'twy', 'english': 'water', 'hindi': 'जल / पानी', 'bengali': 'জল / পানি'}

# Morphological decomposition
analysis = kokborok.analyze("thangkha")
print(analysis.root)    # "thang"
print(analysis.pos)     # "verb"
print(analysis.gloss)   # "Root 'thang' with suf:-kha:past_completive"

3. Grammar & Verbal Conjugation

# Verb conjugation across tenses and aspects
print(kokborok.conjugate("thang", tense="past", subject="ang"))
# "ang thang-kha" (I went)

print(kokborok.conjugate("thang", tense="future", subject="bo"))
# "bo thang-nai" (He/She will go)

print(kokborok.conjugate("thang", tense="present", subject="bo", negative=True))
# "bo thang-ya" (He/She does not go)

# Causative and Reciprocal forms
print(kokborok.causative("thang"))    # "thang-ri" (cause to go)
print(kokborok.reciprocal("hamjak"))  # "hamjak-lai" (love each other)

# Noun case declensions with postpositions
print(kokborok.decline_noun("borok", "accusative"))  # "borok-no"
print(kokborok.decline_noun("nok", "genitive"))       # "nok-ni"
print(kokborok.pluralize("borok"))                   # "borok-rok"

4. Numerals & Semantic Classifiers

# Numbers to words
print(kokborok.num_to_words(1))    # "sa"
print(kokborok.num_to_words(25))   # "rwichi-ba"
print(kokborok.num_to_words(100))  # "ra-sa"

# Words to numbers
print(kokborok.words_to_num("chi"))  # 10

# Applying numeral classifiers
print(kokborok.apply_classifier(2, "khorok"))  # "khorok-nwi" (2 persons)
print(kokborok.apply_classifier(3, "gong"))    # "gong-tham" (3 long items/pens)
print(kokborok.apply_classifier(4, "tai"))     # "tai-brwi" (4 flat items/clothes)

5. Script Transliteration & Phonetics

# Roman to Bengali script
print(kokborok.roman_to_bengali("borok"))
# "বরোক"

# Syllable segmentation
print(kokborok.syllables("bwkhorok"))
# ['bw', 'kho', 'rok']

# Tone handling
print(kokborok.has_high_tone("tẃy"))   # True
print(kokborok.strip_tone("tẃy"))      # "twy"

6. Cultural Heritage, Calendar & Epics

# Kokborok Day info
print(kokborok.KOKBOROK_DAY)  # "19 January (Kokborok Sal)"

# Traditional festivals
for f in kokborok.list_festivals():
    print(f"- {f['name']} ({f['season']}): {f['description'][:60]}...")

# Literary masters & epics
for a in kokborok.list_authors():
    print(f"- {a['name']}: {a['title']}")

# Kinship terms
ama = kokborok.get_kinship_term("ama")
print(ama)  # {'kokborok': 'Ama', 'english': 'Mother', 'role': 'Matriarch / life-giver'}

🖥️ Command-Line Interface (CLI)

# Check library stats
kokborok stats

# Translate
kokborok translate "Hello how are you?" --to kokborok

# Dictionary lookup
kokborok lookup "khulumkha"

# Convert numbers with classifiers
kokborok num 42 --classifier khorok

# Explore cultural topics
kokborok culture festivals
kokborok culture authors
kokborok culture kinship

👨‍💻 Author & Maintainer Profile


📜 License

This project is licensed under the MIT License — see the LICENSE file for full details.

Metadata

Release files for kokborok 1.0.1

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

Loss of provenance

These files do not have provenance metadata, despite files in a prior release including this data.

We recommend further investigation before installing these files. View details.

Source distribution (sdist)

Source distribution for kokborok 1.0.1
File Size Uploaded Provenance Actions
kokborok-1.0.1.tar.gz 1.6 MB Without provenance Details for kokborok-1.0.1.tar.gz

Built distribution (wheel)

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

Total release size: 3.2 MB

Release files / kokborok-1.0.1.tar.gz

Loss of provenance

This file belongs to a release without provenance metadata, despite a prior release including this data.

We recommend further investigation before installing this file. View details.

Download URL kokborok-1.0.1.tar.gz
Size 1.6 MB
Tags Source
SHA-256 checksum
How to use checksums
59a24b373be730a5cbcc38b8806d22d284c8117ea98af88c7c1e576b7a8226a4
BLAKE2b-256 checksum
How to use checksums
83b312ead2b73b9a5c3656b6c4c1d3b55d6054109c18e922174e06caa27e693e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.1

Release files / kokborok-1.0.1-py3-none-any.whl

Loss of provenance

This file belongs to a release without provenance metadata, despite a prior release including this data.

We recommend further investigation before installing this file. View details.

Download URL kokborok-1.0.1-py3-none-any.whl
Size 1.6 MB
Tags Python 3
SHA-256 checksum
How to use checksums
f0bf73ff8d3b42daa25d7b81986b28643a7924f1b234a23f9db05a192800da26
BLAKE2b-256 checksum
How to use checksums
e41221776243a62dd8db290817097268c72dcad3ff28cccdf329714dbbfaeee8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.1

Security for kokborok 1.0.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.

Loss of provenance

A previous release of these files had provenance metadata, but this release does not.

While this could reflect a routine change by the project maintainers, it may also indicate that the release files have been compromised.

Release comparison

  • Removed 1.0.0 2 files With provenance
  • Added 1.0.1 2 files Without provenance

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.

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