Translate visa application documents (images) to English and create a bilingual PDF with original and translation
You are helping translate visa application documents for visa applications.
When the user provides an image file path, AUTOMATICALLY execute the following steps WITHOUT asking for confirmation:
Image Conversion: If the file is HEIC, convert it to PNG using sips -s format png <input> --out <output>
Image Rotation:
OCR Text Extraction:
Translation:
PDF Generation:
Output: Create a PDF file named <original_filename>_Translated.pdf in the same directory
macOS Vision Framework (macOS only):
import Vision
from Foundation import NSURL
EasyOCR (cross-platform):
pip install easyocr
Tesseract OCR (if available):
brew install tesseract tesseract-lang
pip install pytesseract
pip install pillow reportlab
For macOS Vision framework:
pip install pyobjc-framework-Vision pyobjc-framework-Quartz
/visa-doc-translate RetirementCertificate.PNG
/visa-doc-translate BankStatement.HEIC
/visa-doc-translate EmploymentLetter.jpg
The skill will:
<filename>_Translated.pdf with:
Perfect for visa applications to Australia, USA, Canada, UK, and other countries requiring translated documents.