Paxa Labs

งานวิจัยOCR

Thai OCR trained without a single real label

A 0.9B document model taught on 45,723 reconstructed pages, and the controlled experiments that say which part of a synthetic document actually transfers.

ผู้เขียน
Kunat PipatanakulWayu Research, Paxa Labs
เผยแพร่
20 หน้า
รายงาน
arXiv:2609.03595v1cs.CL, cs.AI, cs.CV

arXiv(opens in a new tab)PDF(opens in a new tab)

Synthetic training pages give you exact labels at any scale, which is the whole reason to use them for a language whose documents are plentiful and whose labels are not. What nobody had isolated is which part of a synthetic page does the work. Realism is not one property: it bundles the source domain, the page context, the typography, the spatial structure, and the shape of the glyphs. The usual advice is to add more of all of it.

This report separates those factors with a controlled reconstruction pipeline, then uses the answer to build Wayu-Paxa-OCR-Zero, a Thai document model trained without one OCR label from a real Thai page. It reads a typical printed page at 1.24% median character error, down from 6.64% for the checkpoint it was adapted from. At 0.9B parameters it beats a 7B Thai OCR model on all five evaluation sets.

Reconstruct a real page, one property at a time#

Every synthetic page starts as a real one. The pipeline takes a document with annotated text regions, keeps the region geometry and the reading order, and erases the original text pixels. It then fits the label back into the same region and renders it in either a sampled typeface or real handwriting glyphs. The label is exact by construction, because it is the text that was rendered.

One reconstructed page

An annual-report page whose original text has been erased and replaced with Thai, keeping the original charts, rules, and column structure in place.
Out-of-domain synthetic

Rendered by docaug from a public source page, as published with the report.

Because the geometry survives, each property can be varied on its own. Keep the source background or replace it with white. Keep the two-dimensional arrangement or stack the regions vertically. Sample the measured Thai typeface profile or collapse to a single face. Render glyphs from a font or redraw them from a bank of real ink.

Which properties actually transfer#

Source properties, page-level traininglower is better
  • Out-of-domain synthetic43.99%
  • Without non-text page context43.16%
  • Without typeface diversity49.86%
  • Without two-dimensional layout58.4%
Table 2 of the report: median character error rate on the handwriting set, each row removing one more property. Removing the page's backgrounds, figures and rules changes nothing; removing typeface variety and then spatial structure degrades transfer step by step.

Non-text context is the property everyone reaches for first, and it moves the median by at most 1.62 points across three evaluation sets and two training settings. Typeface diversity is the first thing whose removal consistently costs something, and it costs it on handwriting. Removing it takes 6.70 and 9.48 points of median CER under page-level training, against 0.56 and 2.15 on printed pages. Flattening the layout costs more again.

Training granularity changes which dataset wins, and the reversal is sharp. A model that sees whole pages does best on in-domain reconstruction, at 1.82% median CER against 5.07% for out-of-domain. A model that sees individual cropped elements does the opposite, at 15.59% against 5.52%. The report does not explain the reversal, and says so.

How close reconstruction gets to real supervision#

Reconstruction against real supervision, page-level traininglower is better
  • Qwen3-VL-2B-Instruct, unadapted14.47%
  • Out-of-domain synthetic5.07%
  • In-domain synthetic1.82%
  • Real Thai printed pages1.31%
Table 4 of the report: median character error rate on printed Thai. On a typical page, reconstruction lands 0.51 points off real supervision.

The median is the flattering statistic. Under character-weighted mean CER the same comparison reads 16.20% against 9.79%. Real supervision is still removing a tail of severe failures that reconstruction does not reach. On handwriting, reconstructed Thai print and real Thai print land within 0.13 points of each other, and both stay far behind training that includes real handwriting at 26.05%.

The gap was handwriting, and real ink closed it#

A handwriting typeface renders the same character the same way every time. Real handwriting does not, and that difference is visible before any number is quoted. The two plates below carry identical labels, layout, ink height and ink colour, and differ only in where the strokes came from.

The same page, two sources of ink

A Thai page rendered in a handwriting font, where every occurrence of a character has an identical outline.
Handwriting typefaces
The same Thai page redrawn from a bank of real handwritten characters, where each occurrence of a character has a different shape.
Real glyph instances

Table 5 of the report. Labels, layout, ink height and ink colour held fixed; only the source of the strokes differs.

Handwriting typefaces alone take page-level median CER on the handwriting set from 43.99% to 38.65%. Redrawing the same pages from real ink takes it to 37.91%, and the easier handwriting set from 34.84% to 30.66%. Because the two variants differ in nothing else, the remaining gain belongs to stroke variation and not to the choice of font. Real handwriting supervision still wins at 26.05%, and the glyph bank holds only 5,953 instances.

What the model scores#

The recipe that follows from all of this is 45,723 synthetic pages: a base set with both renderings of every handwriting page, a handwriting-focused set, and 2,190 reconstructed forms. Every page is generated from a public source document. No real Thai page is used as a source image and no label from one enters training.

Wayu-Paxa-OCR-Zero against its base checkpoint and open Thai OCR
PaddleOCR-VL-1.6 (0.9B)Heldout ↓6.64%Handwriting ↓74.87%ThaiOCRBench ↓38.0%SEA-DocBench ↓8.87%
Wayu-Paxa-OCR-Zero (0.9B)Heldout ↓1.24%Handwriting ↓20.55%ThaiOCRBench ↓15.3%SEA-DocBench ↓4.86%
Typhoon OCR (7B)Heldout ↓2.54%Handwriting ↓43.60%ThaiOCRBench ↓30.6%SEA-DocBench ↓9.22%
Typhoon OCR 1.5 (2B)Heldout ↓0.21%Handwriting ↓19.36%ThaiOCRBench ↓6.2%SEA-DocBench ↓5.81%
Gemini 3.7 FlashHeldout ↓0.00%Handwriting ↓11.29%ThaiOCRBench ↓0.9%SEA-DocBench ↓5.51%
Table 7 of the report: median page character error rate, lower is better. Heldout and Handwriting are the report's own sets. ThaiOCRBench averages five audited reading tasks, and SEA-DocBench uses its 1,148-page clean Thai subset. Scores include layout-detection and reading-order errors.

Against the checkpoint it was adapted from, with the architecture held fixed, the recipe cuts median CER on every benchmark: 6.64% to 1.24% on printed pages and 74.87% to 20.55% on handwriting. Against independently trained systems the comparison is about competitiveness, and it is mixed on purpose. It beats the 7B Typhoon model everywhere, nearly matches the 2B model on handwriting, and wins SEA-DocBench. It stays behind on printed pages and ThaiOCRBench. Gemini 3.7 Flash is stronger on three of the four.

Where the method stops#

Synthetic supervision still trails real supervision on the severe failures that dominate a character-weighted mean, and it trails it further on handwriting. The value of matching the source domain depends on the training unit, and the reason is unresolved. A model trained only on reconstructions is less robust to document types, typefaces, and handwriting styles it never saw, which is a real limit for anyone pointing it at an unfamiliar form.

If you are working with Thai documents#

The useful conclusion is where to spend effort. More visual realism in the background of a synthetic page buys nothing measurable. More typefaces, real two-dimensional layout, and real handwritten strokes buy a great deal, and the training unit decides which corpus you want in the first place. The reconstruction pipeline and both model weights are open. The experiment can be repeated on another language with abundant documents and few labels.

This is research. It is not a product specification. Paxa Labs serves Thai documents through its own OCR API, which is a different model with its own published limits.

สิ่งที่เผยแพร่