A cultural nuance translator for Sheng and Dholuo with AI support
Project description
Sheng-Dholuo Translator SDK
A cultural nuance translator for Sheng (Kenyan urban slang) and Dholuo (Luo language), built with tech swagger. Translate phrases, capture vibes, and even train AI models with your own data.
Features
- Translation using CSV lookup, fuzzy matching, and AI (
facebook/m2m100_418M). - Context-aware translations (
casual,formal,romantic). - Sentiment-based vibe prediction.
- Interactive CLI with commands like
translate,add,history,clear,search-vibe,random,stats,export,train. - Fine-tune the AI model with custom data.
Upcoming Features
- Integration with advanced AI like Grok for more nuanced translations.
- Real-time data collection from X posts to expand the phrase database.
Installation
Install via pip:
pip install sheng-dholuo-translator
Requirements
Python 3.8+,
pandas, colorama, fuzzywuzzy, transformers, torch, datasets, sentencepiece
Usage
Translate a Phrase
from sheng_dholuo_translator import CulturalTranslator
translator = CulturalTranslator("phrases.csv")
result = translator.translate("Mambo vipi?", lang_filter="Sheng-English")
print(result['translation']) # Output: What’s up?
print(result['vibe']) # Output: Casual, greeting
Add a New Phrase
translator.add_phrase("Niko freshi", "I’m fresh", "Sheng-English", "Confident, stylish")
More Features
Reverse translation (English to Sheng/Dholuo) Search by vibe (e.g., "hype") Get stats on your phrase collection Export data for AI training
Contributing
Add more Sheng and Dholuo phrases by using the add_phrase method or submitting a pull request on GitHub.
Author
Built by Kevin Omondi Jr. with Kenyan pride and AI dreams.
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 sheng_dholuo_translator-0.1.0.tar.gz.
File metadata
- Download URL: sheng_dholuo_translator-0.1.0.tar.gz
- Upload date:
- Size: 13.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
36a5c3a94048d9fe1f13b732c45b1c4b28dd194ae29abaa843938e97cffcc0f0
|
|
| MD5 |
8b9acbacb7f553fd6320fe6ca3786a24
|
|
| BLAKE2b-256 |
f773a43bac43c17b52dc6fe063e12f5a01d73dbf07756c716296d0d28e845d16
|
File details
Details for the file sheng_dholuo_translator-0.1.0-py3-none-any.whl.
File metadata
- Download URL: sheng_dholuo_translator-0.1.0-py3-none-any.whl
- Upload date:
- Size: 15.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
06782389b8f66f3cedc0bf4a8c805dbf3a4256d1e30944b5814991babc93fd81
|
|
| MD5 |
1ffdd6b2d2dd77371554fe424415e53d
|
|
| BLAKE2b-256 |
723b892d67c82d4b1f3a3764ae89100c12a97a9b12b7873f7b6d78664d692912
|