yihong0618/bilingual_book_maker

Make bilingual epub books Using AI translate

What it solves

This tool simplifies the process of creating bilingual versions of books and documents. It allows users to translate public domain works in various formats (EPUB, TXT, MD, SRT, PDF) into a target language while preserving the original structure and formatting, resulting in a a side-by-side or integrated bilingual output.

How it works

The tool processes input files and sends text segments to a chosen AI translation service. It supports a wide array of models including OpenAI's GPT series, Claude, Gemini, Qwen, and others via liteLLM or custom API providers. Users can control the translation process through parameters like --use_context to maintain consistency in tone and flow, and a "Plan mode" that intelligently partitions text nodes for translation, especially for non-standard layouts like poetry.

Who it’s for

Readers and researchers who want to read public domain books in their native language alongside the original text, and developers who need to translate formatted documents without losing their layout.

Highlights

  • Broad Format Support: Handles EPUB, TXT, MD, SRT, and PDF files.
  • Extensive Model Compatibility: Integrates with numerous LLMs (GPT, Claude, Gemini, Qwen) and traditional translation services (DeepL, Google Translate).
  • Context-Aware Translation: Maintains a running summary of the work to improve consistency across long documents.
  • Intelligent Text Partitioning: Includes a "Plan mode" to handle complex layouts like poetry or non-standard HTML tags in EPUBs.
  • Flexible Prompting: Supports custom prompts via text, JSON, or PromptDown markdown files.

Related

  • Project
  • Project
  • Project
  • Project
  • Project