OCR, translate, and generate bilingual PDFs from visa application document images.
Translate visa application document images to English and produce a bilingual PDF — original image on page 1, professional English translation on page 2.
When given an image file path, execute all steps automatically without asking for confirmation:
sips -s format png <input> --out <output><original_filename>_Translated.pdf in the same directoryRule: Complete the entire pipeline and report the final PDF location. Do not stop at intermediate steps.
macOS Vision (preferred on macOS):
import Vision
from Foundation import NSURL
Install: pip install pyobjc-framework-Vision pyobjc-framework-Quartz
EasyOCR (cross-platform, no Tesseract required):
pip install easyocr
Tesseract (fallback):
brew install tesseract tesseract-lang
pip install pytesseract
pip install pillow reportlab
Structure:
/visa-doc-translate RetirementCertificate.PNG
/visa-doc-translate BankStatement.HEIC
/visa-doc-translate EmploymentLetter.jpg
Suitable for visa applications to Australia, USA, Canada, UK, and other countries requiring translated documents.