LexiAlign: a diffusion model for text alignment and font restoration based on local regeneration
摘要
Despite the recent advances of diffusion models in high-quality image synthesis, generating visually accurate textual content remains a persistent bottleneck, which commonly manifesting as misspellings, glyph distortions, and semantic drift. We introduce LexiAlign, a language-guided local diffusion refinement framework that directly targets these issues to restore high-fidelity font design and semantic correctness. The system integrates three tightly coupled components: robust optical character recognition (OCR)-based text extraction, language model-driven semantic correction, and high-fidelity local inpainting via masked diffusion. Unlike prior approaches that retrained large diffusion backbones or overwrite entire regions, LexiAlign performs character-level targeted repair while preserving surrounding visual context, font style, and layout integrity. To support systematic training and evaluation, we construct SynOCRText, a 120k-sample benchmark covering 8 languages, over 20 fonts, diverse layouts, and fine-grained error masks. On SynOCRText, LexiAlign achieves 88.4% OCR accuracy (+6.3% over the best baseline), Contrastive Language-Image Pretraining (CLIP) Score of 0.852 (+0.023), a peak signal-to-noise ratio (PSNR) of 30.92 dB (+2.51 dB), and a structural similarity index measure (SSIM) of 0.893 (+0.020). These results establish LexiAlign as a plug-and-play, domain-agnostic solution for reliable visual–text alignment, offering both quantitative superiority and practical deployability for font design, creative work, advertising, and multimodal content generation.