A comprehensive Python-based application for language processing tasks, featuring both a GUI interface and REST API. The toolkit provides advanced document translation, audio transcription, text-to-speech conversion, and multimedia processing capabilities.
python main.pypython api_server.pyAccess points:
- GUI Application: Desktop interface
- API Server: http://localhost:8000
- API Documentation: http://localhost:8000/docs
- PPTX Translation: Translate PowerPoint presentations with full formatting preservation
- Text Translation: Multi-language text file translation using DeepL
- Audio Transcription: Convert audio to text using OpenAI Whisper
- Text-to-Speech: Generate natural speech from text using ElevenLabs
- PPTX to PDF: Convert presentations to PDF format
- Video Merging: Combine audio and images into video files
- Transcript Cleaning: Advanced text processing and formatting
- Reward Evaluation: Assess text quality based on custom metrics
- Batch processing with recursive directory support
- Real-time progress tracking
- Multi-language support (30+ languages)
- Asynchronous task processing
- Smart file handling (single files or ZIP archives)
The Language Toolkit supports 29 languages across translation (txt/pptx) and text-to-speech (TTS) services.
| Language | Code | Translation Provider | TXT | PPTX | ElevenLabs TTS |
|---|---|---|---|---|---|
| Czech | cs | DeepL | β | β | β |
| German | de | DeepL | β | β | β |
| English | en | DeepL | β | β | β |
| Spanish | es | DeepL | β | β | β |
| Estonian | et | DeepL | β | β | β |
| Farsi | fa | OpenAI | β | β | β |
| Finnish | fi | DeepL | β | β | β |
| French | fr | DeepL | β | β | β |
| Hindi | hi | β | β | β | |
| Indonesian | id | DeepL | β | β | β |
| Italian | it | DeepL | β | β | β |
| Japanese | ja | DeepL | β | β | β |
| Korean | ko | DeepL | β | β | β |
| Norwegian | nb-NO | DeepL | β | β | β |
| Dutch | nl | DeepL | β | β | β |
| Polish | pl | DeepL | β | β | β |
| Portuguese | pt | DeepL | β | β | β |
| Rundi | rn | β | β | β | |
| Romanian | ro | DeepL | β | β | β |
| Russian | ru | DeepL | β | β | β |
| Sinhala | si | OpenAI | β | β | β |
| Serbian (Latin) | sr-Latn | OpenAI | β | β | β |
| Swedish | sv | DeepL | β | β | β |
| Swahili | sw | β | β | β | |
| Thai | th | OpenAI | β | β | β |
| Turkish | tr | DeepL | β | β | β |
| Vietnamese | vi | β | β | β | |
| Chinese Simplified | zh-Hans | DeepL | β | β | β |
| Chinese Traditional | zh-Hant | DeepL | β | β | β |
Translation Providers:
- DeepL (21 languages): Premium European & Asian language translation
- Google Translate (4 languages): Broad language coverage for Hindi, Rundi, Swahili, Vietnamese
- OpenAI GPT-4 (4 languages): Context-aware translation for Farsi, Sinhala, Serbian, Thai
Text-to-Speech:
- ElevenLabs Multilingual V2 (20 languages): Natural voice synthesis with high quality
- Not Supported (9 languages): Estonian, Farsi, Norwegian, Rundi, Sinhala, Serbian, Swahili, Thai, Vietnamese
- Translation (TXT/PPTX): All 29 languages supported with automatic provider selection
- TTS: 20 languages supported via ElevenLabs multilingual_v2 model
- Provider Selection: Automatic based on target language (see
language_provider.json) - Configuration: See
elevenlabs_languages.jsonfor TTS language mapping
- Python 3.8 or higher
- API keys for:
- DeepL (translation)
- OpenAI (transcription)
- ElevenLabs (text-to-speech)
- ConvertAPI (PDF conversion)
- Anthropic (optional, for reward evaluation)
git clone https://github.com/Asi0Flammeus/Language-Toolkit.git
cd Language-Toolkit# Create virtual environment
python3 -m venv env
# Activate environment
source env/bin/activate # Linux/Mac
.\env\Scripts\activate # Windows
# Install dependencies
pip3 install -r requirements.txtCopy the example environment file and add your API keys:
cp .env.example .envThen edit .env with your API keys:
# API Keys
DEEPL_API_KEY=your-deepl-api-key
OPENAI_API_KEY=your-openai-api-key
ELEVENLABS_API_KEY=your-elevenlabs-api-key
CONVERTAPI_SECRET=your-convertapi-secret
ANTHROPIC_API_KEY=your-anthropic-api-keyCreate supported_languages.json:
{
"source_languages": {
"en": "English",
"fr": "French",
"de": "German",
"es": "Spanish"
},
"target_languages": {
"en": "English",
"fr": "French",
"de": "German",
"es": "Spanish"
}
}Use the provided script to pull latest changes and start the application:
Linux/Mac:
./start_app.shWindows:
start_app.batThe startup script will:
- Pull latest changes from git
- Detect and activate the virtual environment (venv or env)
- Update dependencies from requirements.txt
- Start the GUI application
- Launch the application:
python main.py - Select the desired tool tab
- Choose processing mode (single file or folder)
- Select languages (for translation tools)
- Choose input files and output directory
- Click "Process" to start
- Start the server:
python api_server.py - Access documentation at http://localhost:8000/docs
- Use authentication token for API requests
- Monitor task progress via task endpoints
Language-Toolkit/
βββ main.py # GUI application entry point
βββ api_server.py # FastAPI server
βββ ui/ # GUI components
β βββ base_tool.py # Base tool class
β βββ mixins.py # Shared UI mixins
βββ tools/ # Tool implementations
β βββ text_to_speech.py
β βββ audio_transcription.py
β βββ pptx_translation.py
β βββ ...
βββ services/ # Business logic
β βββ translation.py
β βββ transcription.py
β βββ ...
βββ utils/ # Utility functions
βββ docs/ # Documentation
β βββ api/ # API documentation
β βββ deployment/ # Deployment guides
β βββ development/ # Development guides
βββ tests/ # Test suite
- API Reference - Complete API endpoint documentation
- Authentication Guide - JWT authentication setup
- Deployment Guide - Production deployment instructions
- Docker Setup - Container deployment
- Development Guide - Contributing and development setup
- Testing Guide - Test suite documentation
# Run test suite
pytest tests/
# Run with coverage
pytest --cov=. tests/# Build and run with Docker Compose
docker-compose up --build
# Or use individual containers
docker build -t language-toolkit .
docker run -p 8000:8000 language-toolkitWe welcome contributions! Please see our Development Guide for details on:
- Setting up your development environment
- Code style guidelines
- Testing requirements
- Pull request process
This project is licensed under the MIT License - see the LICENSE file for details.
- Issues: GitHub Issues
- Documentation: Full Documentation
- API Reference: http://localhost:8000/docs (when running)
Made with β€οΈ by asi0 and Claude agents