Online use: (Free 1000 pages per month)
BabelDOC focuses on translating scientific papers and can accurately handle complex typography such as mathematical formulas and data tables.
This project is sponsored by funstory.ai (http://funstory.ai/) Development, the company mainly provides online text overseas services, so it has certain advantages in translating long documents
1. Project Introduction
BabelDOC (Yet Another Document Translator, YADT for short) is a translation tool specifically designed for scientific papers and complex PDF documents. It supports command-line operations and Python APIs, and can be used independently or embedded in other programs. Its core advantages are:
- Retain the structure and typesetting of the original PDF and generate high-quality bilingual or monolingual PDFs.
- Supports multiple translation engines, including OpenAI, Bing and Google.
- Provides plug-in architecture to facilitate the expansion of OCR, renderer and other modules.
In addition, BabelDOC also provides an online service (Immersive Translate-BabelDOC), which translates 1000 pages for free per month.citeturn0search2
2. Installation and use
Installation method:
- Install via PyPI:
uv tool install --python 3.12 BabelDOC
babeldoc --help
- Install from source code:
git clone https://github.com/funstory-ai/BabelDOC
cd BabelDOC
uv run babeldoc --help
Basic usage examples:
babeldoc --openai --files example.pdf
Or use the OpenAI model:
uv run babeldoc --files example.pdf --openai --openai-model "gpt-4o-mini" --openai-base-url "https://api.openai.com/v1" --openai-api-key "your-api-key-here"
Description of commonly used parameters:
- –lang-in / –lang-out: Set the source language and target language (default English-to-Chinese translation).
- –qps: Limit the number of queries per second (default 4).
- –no-dual / –no-mono: Controls the output of bilingual or monolingual PDFs.
- –ignore-cache: Ignore caching and force re-translation.
- –config: Use a configuration file in TOML format to centrally manage parameters.
III. Core Structure and Advantages
BabelDOC adopts a dual-stage architecture of “parsing + rendering”:
- Parsing stage:Extract structural information such as text blocks, images, and tables from PDF.
- Rendering stage (Rendering):Generate a new PDF based on the parsing results, retaining the original layout.
Compared with other tools such as Mathpix or Adobe PDF Parser, BabelDOC has the following advantages:
- Retain the original typesetting to avoid loss of structure.
- Support plug-in extensions for easy integration with new models or OCR tools.
- Adapt to mobile device reading and improve user experience.
4. Development plan and known issues
Development Plan:
- Support the analysis of lines and tables.
- To achieve page spread/hurdle paragraph processing.
- Enhance typesetting functions and support advanced features such as outlines.
- Target translation languages include Simplified Chinese, Traditional Chinese, Japanese and Spanish.
- Strive to have a typographical error rate below 1% and a content loss rate below 1%.
Known issues:
- There may be errors in the interpretation of the author and reference sections and will be merged into one paragraph after translation.
- Lines and drop caps are not currently supported.
- Large pages may be skipped.
5. Applicable scenarios and recommended groups
BabelDOC is available for the following users:
- Researchers and students who need high-quality PDF translations.
- Want to retain the original typesetting technical document translation requirements.
- Developers and engineers who need to process PDF documents in batches.
- Professional users with high requirements for translation quality and typesetting.
For ordinary users, it is recommended to use its online service (Immersive Translate – BabelDOC), which can translate 1000 pages for free per month.citeturn0search2
6. How to participate and contribute
BabelDOC encourages community participation and contribution:
- Welcome to submit code, documentation or test feedback.
- Active contributors can receive Immersive Translate’s Pro membership redemption code rewards.
- For more information, please refer to the project’scontribution guidelines。
VII. Project links
- GitHub repository:https://github.com/funstory-ai/BabelDOC
- Online services:https://app.immersivetranslate.com/babel-doc/
Github:https://github.com/funstory-ai/BabelDOC
Oil tubing: