1010## 🌟 Key Features
1111
1212- ** 🌍 Translation** - High-quality translation using DeepL's next-gen LLM
13+ - ** 🔄 Continuous Localization (` deepl sync ` )** - Incremental i18n file sync with 11 format parsers
1314- ** 📄 Document Translation** - Translate PDF, DOCX, PPTX, XLSX with formatting preservation
14- - ** 🎙️ Voice Translation** - Real-time speech translation via WebSocket streaming (Voice API)
15+ - ** 🎙️ Voice Translation (Pro/Enterprise) ** - Real-time speech translation via WebSocket streaming (Voice API)
1516- ** 👀 Watch Mode** - Real-time file watching with auto-translation
1617- ** ✍️ Writing Enhancement** - Grammar, style, and tone suggestions (DeepL Write API)
1718- ** 💾 Smart Caching** - Local SQLite cache with LRU eviction
@@ -31,26 +32,27 @@ For security policy and vulnerability reporting, see [SECURITY.md](SECURITY.md).
3132 - [ Verbose Mode] ( #verbose-mode )
3233 - [ Quiet Mode] ( #quiet-mode )
3334 - [ Custom Configuration Files] ( #custom-configuration-files )
35+ - [ Configuration Paths] ( #configuration-paths )
36+ - [ Proxy Configuration] ( #proxy-configuration )
37+ - [ Retry and Timeout Configuration] ( #retry-and-timeout-configuration )
3438- [ Usage] ( #-usage )
3539 - ** Core Commands:** [ Translation] ( #translation ) | [ Writing Enhancement] ( #writing-enhancement ) | [ Voice Translation] ( #voice-translation )
36- - ** Resources:** [ Glossaries] ( #glossaries )
40+ - ** Resources:** [ Glossaries] ( #glossaries ) | [ Translation Memories ] ( #translation-memories )
3741 - ** Workflow:** [ Watch Mode] ( #watch-mode ) | [ Git Hooks] ( #git-hooks )
3842 - ** Configuration:** [ Setup Wizard] ( #setup-wizard ) | [ Authentication] ( #authentication ) | [ Configure Defaults] ( #configure-defaults ) | [ Cache Management] ( #cache-management ) | [ Style Rules] ( #style-rules )
39- - ** Information:** [ Usage Statistics] ( #api-usage-statistics ) | [ Language Detection] ( #language-detection ) | [ Languages] ( #supported-languages ) | [ Shell Completion] ( #shell-completion )
43+ - ** Information:** [ Usage Statistics] ( #api-usage-statistics ) | [ Language Detection] ( #language-detection ) | [ Languages] ( #supported-languages ) | [ Shell Completion] ( #shell-completion ) | [ Command Suggestions ] ( #command-suggestions )
4044 - ** Administration:** [ Admin API] ( #admin-api )
4145- [ Development] ( #-development )
4246- [ Architecture] ( #-architecture )
47+ - [ Testing] ( #-testing )
48+ - [ Documentation] ( #-documentation )
49+ - [ Environment Variables] ( #-environment-variables )
50+ - [ Security & Privacy] ( #-security--privacy )
4351- [ Contributing] ( #-contributing )
4452- [ License] ( #-license )
4553
4654## 📦 Installation
4755
48- ### From npm (Coming Soon)
49-
50- ``` bash
51- npm install -g deepl-cli
52- ```
53-
5456### From Source
5557
5658``` bash
@@ -69,7 +71,7 @@ npm link
6971
7072# Verify installation
7173deepl --version
72- # Output: 1.0.0
74+ # Output: deepl-cli 1.x.x
7375```
7476
7577> ** Note:** This project uses [ ` better-sqlite3 ` ] ( https://github.com/WiseLibs/better-sqlite3 ) for local caching, which requires native compilation. If ` npm install ` fails with build errors, ensure you have:
@@ -78,6 +80,12 @@ deepl --version
7880> - ** Linux** : ` python3 ` , ` make ` , and ` gcc ` (` apt install python3 make gcc g++ ` )
7981> - ** Windows** : Visual Studio Build Tools or ` windows-build-tools ` (` npm install -g windows-build-tools ` )
8082
83+ ### From npm (not yet published)
84+
85+ An npm package is not yet published; install from source until then.
86+
87+ > ** CI examples below** (and generated hook output) assume a published npm package; source-installed users should substitute the source-install path.
88+
8189## 🚀 Quick Start
8290
8391### 1. Get Your DeepL API Key
@@ -288,13 +296,13 @@ deepl translate locales/en.json --to es,fr,de --output locales/
288296
289297** Smart Caching for Text Files:**
290298
291- Small text-based files (under 100 KB ) automatically use the cached text translation API for faster performance and reduced API calls. Larger files automatically fall back to the document translation API (not cached).
299+ Small text-based files (under 100 KiB ) automatically use the cached text translation API for faster performance and reduced API calls. Larger files automatically fall back to the document translation API (not cached).
292300
293- - ** Cached formats:** ` .txt ` , ` .md ` , ` .html ` , ` .htm ` , ` .srt ` , ` .xlf ` , ` .xliff ` (files under 100 KB only)
301+ - ** Cached formats:** ` .txt ` , ` .md ` , ` .html ` , ` .htm ` , ` .srt ` , ` .xlf ` , ` .xliff ` (files under 100 KiB only)
294302- ** Structured formats:** ` .json ` , ` .yaml ` , ` .yml ` — parsed and translated via batch text API (no size limit)
295- - ** Large file fallback:** Files ≥100 KB use document API (not cached, always makes API calls)
303+ - ** Large file fallback:** Files ≥100 KiB use document API (not cached, always makes API calls)
296304- ** Binary formats:** ` .pdf ` , ` .docx ` , ` .pptx ` , ` .xlsx ` always use document API (not cached)
297- - ** Performance:** Only small text files (<100 KB ) benefit from instant cached translations
305+ - ** Performance:** Only small text files (<100 KiB ) benefit from instant cached translations
298306- ** Cost savings:** Only small text files avoid repeated API calls
299307
300308``` bash
@@ -840,6 +848,8 @@ deepl init
840848# - Basic configuration
841849```
842850
851+ > To configure continuous localization for an existing project, see also [ ` deepl sync init ` ] ( #sync-init ) or run the wizard directly.
852+
843853#### Authentication
844854
845855``` bash
@@ -1040,7 +1050,7 @@ DeepL CLI includes built-in retry logic and timeout handling for robust API comm
10401050- ✅ Automatic retry on transient failures
10411051- ✅ Exponential backoff to avoid overwhelming the API
10421052- ✅ Smart error detection (retries 5xx, not 4xx)
1043- - ✅ Configurable timeout and retry limits (programmatic API only)
1053+ - ✅ Configurable via library-consumer options; not exposed as a CLI flag
10441054- ✅ Works across all DeepL API endpoints
10451055
10461056** Retry Behavior Examples:**
@@ -1313,7 +1323,7 @@ Cache location: `~/.cache/deepl-cli/cache.db` (or `~/.deepl-cli/cache.db` for le
13131323
13141324### Prerequisites
13151325
1316- - Node.js >= 20.0 .0
1326+ - Node.js >= 20.19 .0
13171327- npm >= 9.0.0
13181328- DeepL API key
13191329
@@ -1387,25 +1397,33 @@ deepl translate "Hello" --to es
13871397DeepL CLI follows a layered architecture:
13881398
13891399```
1390- CLI Interface (Commands, Parsing, Help)
1391- ↓
1392- Core Application (Command Handlers, Interactive Shell)
1400+ CLI Commands (translate, write, voice, sync, watch, glossary, tm, …)
13931401 ↓
1394- Service Layer (Translation, Write, Cache, Watch, Glossary)
1402+ Service Layer (Translation, Write, Voice, Batch, Watch, Glossary,
1403+ TranslationMemory, StyleRules, Admin, Document,
1404+ GitHooks, Usage, Detect, Languages)
1405+ ↓ ↓
1406+ Sync Engine (src/sync) Format Parsers (src/formats — 11 i18n formats)
1407+ ↓ ↓
1408+ API Client (Translate, Write, Glossary, Document, Voice,
1409+ StyleRules, Admin, TMS)
13951410 ↓
1396- API Client (DeepL Translate, Write, Glossary APIs)
1397- ↓
1398- Storage (SQLite Cache, Config, Translation Memory)
1411+ Storage (SQLite Cache, Config) + Static Data (src/data — language registry)
13991412```
14001413
14011414### Key Components
14021415
1403- - ** Translation Service** - Core translation logic with caching and preservation
1404- - ** Write Service** - Grammar and style enhancement
1405- - ** Cache Service** - SQLite-based cache with LRU eviction
1406- - ** Preservation Service** - Preserves code blocks, variables, formatting
1407- - ** Watch Service** - File watching with debouncing
1408- - ** Glossary Service** - Glossary management and application
1416+ - ** Translation Service** — core translation with caching and text preservation
1417+ - ** Write Service** — grammar, style, and tone suggestions
1418+ - ** Voice Service** — real-time speech translation over WebSocket
1419+ - ** Sync Engine** — continuous localization: scan, diff, translate, write, lock
1420+ - ** Format Parsers** — 11 i18n parsers (JSON, YAML, TOML, PO, Android XML, iOS Strings, xcstrings, ARB, XLIFF, Properties, Laravel PHP) with format-preserving reconstruct
1421+ - ** Batch Service** — parallel multi-file translation
1422+ - ** Watch Service** — file watching with debouncing
1423+ - ** Glossary Service** — glossary management and application
1424+ - ** Translation Memory Service** — reuse approved translations (` --translation-memory ` )
1425+ - ** Cache** — SQLite cache with LRU eviction (` src/storage/cache.ts ` )
1426+ - ** Preservation utilities** — ` src/utils/ ` helpers for code blocks, variables, and ICU MessageFormat
14091427
14101428## 🧪 Testing
14111429
@@ -1452,6 +1470,10 @@ npm run examples:fast
14521470| ` DEEPL_CONFIG_DIR ` | Override config and cache directory |
14531471| ` XDG_CONFIG_HOME ` | Override XDG config base (default: ` ~/.config ` ) |
14541472| ` XDG_CACHE_HOME ` | Override XDG cache base (default: ` ~/.cache ` ) |
1473+ | ` HTTP_PROXY ` | HTTP proxy URL for outbound DeepL API traffic |
1474+ | ` HTTPS_PROXY ` | HTTPS proxy URL (takes precedence over ` HTTP_PROXY ` ) |
1475+ | ` TMS_API_KEY ` | API key for the configured TMS server (` sync push ` /` pull ` ) |
1476+ | ` TMS_TOKEN ` | Alternative auth token for the configured TMS server |
14551477| ` NO_COLOR ` | Disable colored output |
14561478| ` FORCE_COLOR ` | Force colored output even when terminal doesn't support it. Useful in CI. ` NO_COLOR ` takes priority if both are set. |
14571479| ` TERM=dumb ` | Disables colored output and progress spinners. Automatically set by some CI environments and editors. |
@@ -1464,12 +1486,14 @@ See [docs/API.md#environment-variables](./docs/API.md#environment-variables) for
14641486- ** Local caching** - All cached data stored locally in SQLite, never shared
14651487- ** No telemetry** - Zero usage tracking or data collection
14661488- ** Environment variable support** - Use ` DEEPL_API_KEY ` environment variable for CI/CD
1467- - ** GDPR compliant ** - Follows DeepL's GDPR compliance guidelines
1489+ - ** GDPR-aligned with DeepL's DPA ** - Follows DeepL's Data Processing Agreement terms
14681490
14691491## 📄 License
14701492
14711493This project is licensed under the MIT License - see the [ LICENSE] ( LICENSE ) file for details.
14721494
1495+ DeepL® is a registered trademark of DeepL SE.
1496+
14731497---
14741498
14751499_ Powered by DeepL's next-generation language model_
0 commit comments