КАРМАЗИН.MEDIA • Скан PDF в Word • Учебный комплект / Scan to Word exercise
Все имена и сведения вымышлены. All names and transaction details are fictional.

scan.pdf — чистое изображение страницы / clean page image.
tilted.pdf — та же страница, уменьшенная и наклонённая / lower-resolution tilted copy of the same sheet.
expected.txt — ключевые поля до распознавания / known reference fields.
raw.docx — абзацы Tesseract для scan.pdf, без исправлений / uncorrected editable OCR text from the clean scan.
checked.docx — отдельно подготовленный и сверенный Word с настоящей таблицей / manually reconstructed and checked native Word table.
outputs/ — четыре необработанных UTF-8 вывода / four raw UTF-8 transcripts.
convert_scan.py — Tesseract → DOCX, Python 3, python-docx, Poppler and Tesseract 5 with rus and eng traineddata.
Example: python3 convert_scan.py scan.pdf my-copy.docx
Windows (with Python launcher): py -3 convert_scan.py scan.pdf my-copy.docx
Use --tessdata-dir PATH if the installed program needs a separate language data directory.
The script expects pdfinfo, pdftoppm and tesseract on PATH, leaves the input alone, and requires a new output filename.
vision.swift — optional independent comparator for supported macOS versions with the Swift command-line tools.
pdftoppm -r 300 -f 1 -l 1 -singlefile -png scan.pdf check-page
swift vision.swift check-page.png > vision-result.txt

Метки KM-0417 и RX состоят из латинских букв. Проверьте алфавит, связь строки с суммой и арифметику.
KM-0417 and both RX codes use Latin capitals. Check the actual characters, row-to-amount associations and arithmetic.
