yisan0429/itranslation — explained in plain English
Analysis updated 2026-05-18
Translate a full novel or nonfiction book from English into Chinese while keeping terminology consistent.
Convert a PDF or EPUB book into a translated version in the same file format.
Estimate translation cost in dollars and yuan before committing to a full book run.
| yisan0429/itranslation | 0petru/sentimo | alingalingling/akasha-wechat | |
|---|---|---|---|
| Stars | 17 | 17 | 17 |
| Language | Python | Python | Python |
| Setup difficulty | moderate | moderate | hard |
| Complexity | 2/5 | 3/5 | 4/5 |
| Audience | general | developer | developer |
Figures from each repo's GitHub metadata at analysis time.
Requires a DeepSeek API key or another OpenAI-compatible endpoint to run.
Itranslation is a command-line tool for translating entire books into Chinese using AI language models. It accepts PDF, EPUB, plain text, and Markdown files and produces translated output in those same formats. The current release (1.1.4) is command-line only, a desktop graphical interface existed previously but is temporarily unavailable while a threading bug is being fixed. The tool's main selling point compared to simpler approaches is how it handles long texts. Rather than cutting a book into fixed-size blocks of lines, it splits at sentence boundaries and creates overlapping chunks where each chunk shares a few sentences with the next one. This prevents a sentence from being cut in half mid-thought. When assembling the final output, it keeps only the first occurrence of each overlapping sentence and discards the duplicates, so the result reads cleanly. During translation, the tool tracks how each specialized term is being translated across the whole document and checks periodically whether the same term is being rendered consistently. If a term's translation has drifted below 80% consistency, it raises an alert. Translation is done through the DeepSeek AI API (with two pricing tiers: a higher-quality Pro model and a faster Flash model), or through any API that uses the same interface as OpenAI's, including locally hosted models. The tool shows real-time cost estimates per chunk and tracks total spending in both dollars and Chinese yuan. For a 100,000-word novel, the estimated cost on the Pro model is around $0.20. For PDFs specifically, the tool supports two extraction methods: a basic one using PyMuPDF that handles standard single-column layouts with around 60-70% accuracy, and an optional higher-quality method using a downloadable AI model called Marker that reaches 90% accuracy on complex layouts like multi-column pages and tables. EPUB files extract at close to 100% accuracy. The tool translates chapters in parallel using multiple worker threads (four by default) and saves progress after each chapter, so an interrupted translation can be resumed from where it stopped rather than starting over. It runs on Windows, macOS, and Linux with Python 3.11 or newer, and is released under the MIT license.
A command-line tool that translates whole books into Chinese with AI, using overlapping chunks to avoid cutting sentences mid-thought.
Mainly Python. The stack also includes Python, PyMuPDF, DeepSeek API.
Use freely for any purpose, including commercial use, as long as you keep the copyright notice.
Setup difficulty is rated moderate, with roughly 30min to a first successful run.
Mainly general.
This repo across BitVibe Labs
Verify against the repo before relying on details.