@@ -90,6 +90,7 @@ python batch_translate.py glossary-sync --target-langs es pt # Export gl
9090** Step-by-Step:**
9191``` bash
9292python batch_translate.py sync --source-dir en/travel --target-langs es pt # Extract changed files
93+ python batch_translate.py sync --target-langs it --force-incomplete # Force extraction for incomplete languages
9394python batch_translate.py validate-csv # Pre-import validation
9495python batch_translate.py import # Import validated CSVs
9596python batch_translate.py generate --target-langs es --require-complete # Generate HTML
@@ -130,10 +131,20 @@ GLOSSARY_DIR = "../photography"
130131
131132Pipeline Options:
132133``` bash
133- --target-langs es pt # Languages to process
134- --auto-import # Skip "Import now?" prompt, auto-import if valid
135- --skip-generation # Stop after import, don't generate HTML
136- --force # Force re-extract all files (ignore change detection)
134+ --target-langs es pt # Languages to process
135+ --auto-import # Skip "Import now?" prompt, auto-import if valid
136+ --skip-generation # Stop after import, don't generate HTML
137+ --force # Force re-extract all files (ignore change detection)
138+ ```
139+
140+ Sync Options:
141+ ``` bash
142+ --target-langs es pt # Languages to process
143+ --source-dir PATH # Source directory (default: en/photography)
144+ --workers N # Parallel workers (default: 4)
145+ --force # Force re-extract all files (ignore change detection)
146+ --force-incomplete # Force extraction for incomplete languages (below coverage threshold)
147+ --coverage-threshold PCT # Coverage %% below which --force-incomplete triggers (default: 80.0)
137148```
138149
139150## Path Mappings (Required for Generation)
@@ -210,7 +221,14 @@ Output: Detailed pipeline report with all metrics
210221
2112221 . ** Extract Changed Files** :
212223 ``` bash
224+ # Normal sync: Extract only changed files (uses SHA256 change detection)
225+ python batch_translate.py sync --source-dir en/travel --target-langs es pt
226+
227+ # Force sync: Extract all files regardless of changes
213228 python batch_translate.py sync --source-dir en/travel --target-langs es pt --force
229+
230+ # Force incomplete: Extract all files for languages below coverage threshold (useful for new languages)
231+ python batch_translate.py sync --target-langs it --force-incomplete --coverage-threshold 80.0
214232 ```
215233 Output: CSVs in ` translations_pending/ `
216234
@@ -510,8 +528,31 @@ Glossaries include context awareness via suggestion system.
510528
511529** Pipeline stops at import prompt** : Type "yes" to import, "no" to review CSVs first
512530
531+ ** "No changes detected" error on new language** : Use ` --force-incomplete ` flag
532+ ``` bash
533+ python batch_translate.py sync --target-langs it --force-incomplete
534+ # This forces extraction even when source files haven't changed
535+ # Useful for new languages with low coverage
536+ ```
537+
513538## Advanced Workflows
514539
540+ ** New language onboarding (incomplete translation coverage):**
541+ ``` bash
542+ # When adding a new language with low coverage, use --force-incomplete
543+ # Example: Italian language only has 32% coverage, normal sync would skip it
544+ python batch_translate.py sync --target-langs it --force-incomplete
545+ # Output:
546+ # [WARNING] [SYNC] it: coverage 32.0% < 80.0% => forcing extraction
547+ # [INFO] Changed files: 0
548+ # [INFO] Files extracted: 150
549+ # [INFO] Translations: 3520
550+
551+ # You can customize the coverage threshold:
552+ python batch_translate.py sync --target-langs it --force-incomplete --coverage-threshold 95.0
553+ # Forces extraction if coverage is below 95%
554+ ```
555+
515556** Skip import, review only:**
516557``` bash
517558python batch_translate.py pipeline --skip-generation
@@ -530,6 +571,19 @@ python batch_translate.py pipeline --force
530571# Extracts all files, even unchanged ones
531572```
532573
574+ ** Mixed: Force incomplete + manual edits:**
575+ ``` bash
576+ # 1. Register manual edits done outside the pipeline
577+ python batch_translate.py register-manual-edit it/index.html --lang it
578+
579+ # 2. Force extraction for remaining untranslated strings
580+ python batch_translate.py sync --target-langs it --force-incomplete --coverage-threshold 95.0
581+
582+ # 3. Continue with normal pipeline workflow
583+ python batch_translate.py serve --port 8000 # Review in dashboard
584+ python batch_translate.py pipeline --target-langs it
585+ ```
586+
533587## Performance Notes
534588
535589- ** Sync Command** : ~ 20-30 files/second with 4 workers
0 commit comments