A desktop application that provides real-time translation of selected screen areas using OCR technology and AI-powered translation.
- Real-time screen capture and translation
- Support for multiple languages (English, Japanese, Traditional Chinese)
- Customizable translation area selection
- Movable and resizable translation overlay
- Integration with Ollama for AI-powered translation
- Adjustable screen scaling factor
- GPU acceleration support for OCR (when available)
demo.mp4
- Python 3.9.19
- PyQt6
- PaddleOCR
- Ollama
- Other dependencies listed in
requirements.txt
- Clone this repository:
git clone https://github.com/Travsh/paddleocr-ollama-translator.git cd paddleocr-ollama-translator
- Install the required Python packages:
pip install -r requirements.txt
- Ensure Ollama is installed and running on your system. You can download it from https://ollama.ai/
- Start the application:
python Translator.py
-
Select the source language (English or Japanese) from the dropdown menu.
-
Choose the target language for translation (Traditional Chinese or English).
-
Adjust the scale factor if necessary (default is 150%).
-
Click "Choose Area" and select the screen area you want to translate.
-
Click "Show Translation" to start the real-time translation.
-
The translated text will appear in a movable overlay window near the selected area.
-
You can drag the translation window to reposition it as needed.
- Scale Factor: Adjust this if your display scaling is different from the default (150%).
- Translation Model: Select the Ollama model you want to use for translation. (Recommended: "gemma2")
If you encounter any issues:
- Ensure Ollama is running and accessible at
http://localhost:11434
. - Check that all required Python packages are installed correctly.
- Verify that your selected Ollama model supports the languages you're translating between.
Contributions are welcome! Please feel free to submit a Pull Request.