Fast multilingual text-to-phoneme converter for South East Asian languages.
Project description
🦭 SEA-G2P
Fast multilingual text-to-phoneme converter for South East Asian languages.
Author: Pham Nguyen Ngoc Bao
Installation
pip install sea-g2p
Requires espeak-ng only for fallback (built-in dictionary already covers ~99.9% of words).
Usage
Simple Pipeline
from sea_g2p import SEAPipeline
pipeline = SEAPipeline(lang="vi")
result = pipeline.run("Giá SP500 hôm nay là 4.200,5 điểm")
print(result)
Individual Modules
from sea_g2p import Normalizer, G2P
normalizer = Normalizer(lang="vi")
g2p = G2P(lang="vi")
text = "Giá SP500 hôm nay là 4.200,5 điểm"
normalized = normalizer.normalize(text)
phonemes = g2p.convert(normalized)
print(phonemes)
Features
- Fast dictionary-based lookup using SQLite.
- Vietnamese text normalization (numbers, dates, units).
- Bilingual support (Vietnamese/English).
- Batch processing for efficiency.
- eSpeak-NG fallback for unknown words.
Development
To install for development purposes:
-
Clone the repository:
git clone https://github.com/pnnbao97/sea-g2p cd sea-g2p
-
Install in editable mode:
pip install -e .
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sea_g2p-0.2.0.tar.gz.
File metadata
- Download URL: sea_g2p-0.2.0.tar.gz
- Upload date:
- Size: 38.0 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cf2937eafc0c9006fe80e44d56ec1811a247bb23e1b2e58cfa3a13ad6f768e56
|
|
| MD5 |
85b509076ac7c2e67c548235385bfebc
|
|
| BLAKE2b-256 |
730cd0418dd6713a0a102fc73795d0b3d42f54030f2a832d50b5b49cec8c8849
|
File details
Details for the file sea_g2p-0.2.0-py3-none-any.whl.
File metadata
- Download URL: sea_g2p-0.2.0-py3-none-any.whl
- Upload date:
- Size: 38.0 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9b840ea2f74bafcd553dc9143b90a0afe08e2901f5e5153b058112fd4a8c84e0
|
|
| MD5 |
b98962f7feff53fd9a519904c1e21b28
|
|
| BLAKE2b-256 |
9e03c4a560212960ddd02d478e297e1b8ebc49231a2b49e2cfe8c6d2740a3c06
|