Repolode
BigDawnGhost

BigDawnGhost/wenyi

A desktop app for translating books and long-form writing with whole-book context, a live glossary, and evidence-based review.

Open-source alternative to:DeepLGoogle Translate

Stars
2,788
Forks
217
Open issues
27
Last commit
yesterday

What is it?

Wenyi translates books and long-form texts using LLMs, starting with a whole-book prescan that builds per-chapter digests and a book-level synopsis injected into every translation batch. Terms and proper names are extracted as translation proceeds, conflicting translations are flagged for resolution, and later batches use the updated glossary to keep terminology consistent.

The project ships as a local desktop app with a Python engine bundled in packaged releases, and it also offers a CLI and an optional self-hosted web workspace. Supported inputs include EPUB, FB2, TXT, Markdown, HTML, PDF, DOCX and SRT subtitles, with outputs in EPUB (monolingual or bilingual), TXT, HTML, Markdown, DOCX and SRT. Completed batches and chapter progress are saved, so interrupted projects can resume from checkpoints.

Quality control is staged: translation can be followed by optional polishing with a stronger model and a whole-book AI review. Multiple providers are supported, including DeepSeek, OpenAI, Gemini, Ollama, vLLM and OpenAI-compatible endpoints.

Key features

  • 01Whole-book prescan that builds chapter digests and a synopsis for every batch.
  • 02Real-time glossary extraction with conflict detection.
  • 03Optional polishing and evidence-driven whole-book review.
  • 04Resumable projects that save batch and chapter checkpoints.
  • 05EPUB output that writes translations back into original XHTML and keeps styles, images and TOC where possible.
  • 06Bilingual source-and-translation output and multiple LLM providers.

Use cases

  • Translating a novel while keeping character names and terms consistent across chapters.
  • Translating a long nonfiction monograph with chapter-level context.
  • Producing bilingual EPUB editions for side-by-side reading.
  • Translating subtitle files with a lightweight SRT workflow.

Quick start

  1. 1

    Install dependencies from the repository root with uv

    uv sync --locked
  2. 2

    Set your DeepSeek API key

    export DEEPSEEK_API_KEY="YOUR_DEEPSEEK_API_KEY"
  3. 3

    Translate a book

    uv run wenyi translate book.epub

Things to know

  • Multilingual translation is experimental.
  • Polishing and whole-book review are the most expensive stages.
  • PDF input requires a MinerU API key for the initial conversion.
  • Translation quality depends on the chosen LLM model.

Topics

FAQ

What is wenyi?
A desktop app for translating books and long-form writing with whole-book context, a live glossary, and evidence-based review. Wenyi translates books and long-form texts using LLMs, starting with a whole-book prescan that builds per-chapter digests and a book-level synopsis injected into every translation batch. Terms and proper names are extracted as translation proceeds, conflicting translations are flagged for resolution, and later batches use the updated glossary to keep terminology consistent.
Is wenyi free to use? What license does it have?
wenyi is open source under the MIT license. Check the license terms before using it in commercial products.
Is wenyi still maintained?
Actively maintained. The last commit to wenyi was on Oct 19, 2026.
What can I use wenyi for?
Translating a novel while keeping character names and terms consistent across chapters. Translating a long nonfiction monograph with chapter-level context. Producing bilingual EPUB editions for side-by-side reading. Translating subtitle files with a lightweight SRT workflow.
How do I install wenyi?
Install dependencies from the repository root with uv: uv sync --locked Set your DeepSeek API key: export DEEPSEEK_API_KEY="YOUR_DEEPSEEK_API_KEY" Translate a book: uv run wenyi translate book.epub
Where can I get wenyi?
The source code and installation instructions are on GitHub: https://github.com/BigDawnGhost/wenyi

Summary generated by AI from the project's README. GitHub stats refresh daily.

Related projects