DEV Community

DarkDev
DarkDev

Posted on

DeepManga — Open Source Manga Translation Tool with PaddleOCR & Gemini AI

I open-sourced a manga/manhwa translation tool that automates the entire localization pipeline while preserving the original visual layout.

Tech Stack

  • Python + Flask + Flask-SocketIO
  • PaddleOCR / RapidOCR for text detection
  • Google Gemini AI + Cerebras API for translation
  • OpenCV for smart text cleaning (inpainting)
  • CustomTkinter Desktop GUI

Key Features

  • Advanced OCR: PaddleOCR and RapidOCR for accurate text detection in manga/manhwa panels
  • AI Translation: Google Gemini + Cerebras API support with intelligent context-aware translation
  • Dual Interface: Modern Web UI (Flask + Socket.IO) and Desktop GUI (CustomTkinter)
  • Smart Text Cleaning: OpenCV inpainting for clean bubble erasure without damaging artwork
  • Custom Glossary: Define your own translation term mappings for consistent terminology
  • Webtoon Viewer: Auto-generates a clean reader site with one-command Netlify deployment
  • Multi-API Key Rotation: Automatically rotates through multiple API keys to bypass rate limits
  • Notifications: Discord webhook and Telegram bot integration

How It Works

  1. Upload manga pages (supports standard manga and webtoon formats)
  2. PaddleOCR detects and extracts text regions
  3. Text is sent to Gemini AI for context-aware translation
  4. Original text is cleaned using OpenCV inpainting
  5. Translated text is placed back preserving the original layout
  6. Output can be viewed in the built-in webtoon reader

GitHub

https://github.com/a2ngell/DeepManga

The project is fully open source under MIT license. Contributions, bug reports, and feature requests are welcome!


Built with Python, PaddleOCR, and Google Gemini AI.

Top comments (0)