Brahvi Conformer G2P

Brahvi Conformer G2P converts Pakistani Brahvi text written in the Perso-Arabic script into broad IPA-style phoneme strings. This character-level NVIDIA NeMo Conformer CTC model is intended for TTS preprocessing, pronunciation-label bootstrapping, and speech-corpus quality checks.

First Public Brahvi G2P Release

To the best of our knowledge, this is the world's first publicly released model dedicated to Brahvi grapheme-to-phoneme conversion. At release time, no open Brahvi-specific G2P model or comparable public model resource could be found in the Hugging Face G2P catalog or the model-focused literature search used for this release. Published resources describe Brahvi phonetics and its phoneme inventory, but they are not trained G2P models.

This release provides a practical starting point for a severely under-resourced language. The claim above is intentionally qualified because no search can prove that an unindexed or private system does not exist.

This model belongs to the Pakistani Languages G2P Family alongside the Pashto Conformer G2P, Sindhi Conformer G2P, and Balochi Conformer G2P.

Architecture

  • Framework: NVIDIA NeMo
  • Objective: character-level CTC grapheme-to-phoneme conversion
  • Encoder: 8-layer Conformer
  • Hidden size: 192
  • Attention heads: 4
  • Convolution kernel: 15
  • Output: broad IPA-style phoneme sequence
  • Default source expansion: each non-space input character is repeated three times for CTC alignment
  • Maximum expanded source length: 1024 characters

Evaluation

Corpus PER is calculated as the total IPA character edit distance divided by the total number of reference IPA characters.

Split Corpus PER
Validation 9.99%
Held-out test after reference adjudication 9.39%

The public repository does not include evaluation rows or reference data.

Quick Start

Install the dependencies:

pip install -r requirements.txt

Run from a cloned repository:

python inference.py --text "پریشانی تو کارہ بریرہ نا؟ تسلی کبو۔ نم داسہ آرام کبو، آرام کبو۔ قمبر شاہ، شعیب آرام اٹ خاچو۔"

Example output:

pareːʃaːniː t̪oː kaːra bareːra naː t̪asaliː kaboː num daːsaː aːraːm kaboː aːraːm kaboː qambar ʃaːh ʃoeːb aːraːm aʈ xaːt͡ʃoː

Another example:

python inference.py --text "اوڑے ننا کسر اٹ ننا قوم ئے اور ننا براہوئی زبانی اینو اسکان انت فائدہ نم رسفیرے؟ صاحب ننتو تینا سماج کے سیاسی و سماجی انتس کہ ننا مطلب قوت آک ارے"
oːɽeː nanaː kasar aʈ nanaː qowm eː awr nanaː braːhoːiː zubaːniː eːnoː iskaːn ant faːjdaː num rasfeːreː saːhib nantoː teːnaː samaːd͡ʒ keː sijaːsiː oː samaːd͡ʒiː antas ki nanaː matlab quawt aːk areː

Or let the script download the model from Hugging Face:

python inference.py \
  --repo-id TBOGamer22/nemo-brahvi-g2p-conformer \
  --model-path missing.nemo \
  --text "پریشانی تو کارہ بریرہ نا؟ تسلی کبو۔ نم داسہ آرام کبو، آرام کبو۔ قمبر شاہ، شعیب آرام اٹ خاچو۔"

For multiple inputs, save one sentence per line in a UTF-8 file:

python inference.py --text-file inputs.txt --json

Model Files

File Purpose
brahvi_conformer_g2p.nemo Portable NeMo model with embedded tokenizer vocabularies
model_config.yaml Human-readable architecture configuration
tokenizers/ Brahvi grapheme and IPA character vocabularies
inference.py Local and Hub-backed inference CLI
requirements.txt Python dependencies
LICENSE MIT License

The public repository intentionally contains only inference files. It does not include datasets, data splits, manifests, prediction tables, training logs, evaluation summaries, or trainer checkpoints.

Intended Use

Use this model to obtain broad IPA-style pronunciation sequences for Pakistani Brahvi text, especially as a preprocessing component for speech synthesis and corpus tooling. Review predictions before treating them as authoritative linguistic annotations.

Limitations

  • Brahvi has orthographic and pronunciation variation; a spelling can have more than one valid pronunciation.
  • The output is broad, model-predicted IPA rather than narrow phonetic transcription.
  • Code-switching, uncommon spellings, foreign names, punctuation-heavy text, and unseen characters may reduce reliability.
  • The model is not a substitute for review by Brahvi speakers or trained linguists.

License and Author

Released under the MIT License.

Author: Talha Bin Omar

Citation

@misc{omar2026brahvig2p,
  author       = {Talha Bin Omar},
  title        = {Brahvi Conformer G2P},
  year         = {2026},
  publisher    = {Hugging Face},
  howpublished = {\url{https://huggingface.co/TBOGamer22/nemo-brahvi-g2p-conformer}}
}
Downloads last month
11
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Collection including TBOGamer22/nemo-brahvi-g2p-conformer