PaddleOCR 3.5 release notes / what's new
PaddleOCR 3.5 release notes / what's new
PaddleOCR 3.5 enables the use of Hugging Face Transformers as an inference backend for supported OCR and document parsing models. This update allows developers to integrate PaddleOCR's capabilities into Hugging Face-centered environments with reduced integration friction, particularly for RAG and Document AI applications.
Inference Backend Flexibility
PaddleOCR 3.5 introduces a flexible inference-engine interface that allows developers to select their backend via the engine parameter. By setting engine="transformers", supported models can run using the Transformers library.
While the Transformers backend is now an option, PaddleOCR continues to manage the pipelines behind these tasks, meaning developers do not need to manually call internal components. Backend-specific options—such as dtype, device placement, and attention implementation—can be configured through the engine_config parameter.
The PaddleOCR 3.5 Architecture Stack
| Layer | Description | Examples |
|---|---|---|
| Application layer | Applications utilizing OCR and document parsing outputs | RAG, agents, Document AI |
| Model layer | OCR and document parsing capabilities | PP-OCRv5, PaddleOCR-VL 1.5 |
| Inference backend layer | Runtime used to run supported models | Paddle static graph, Paddle dynamic graph, Transformers |
Key Capabilities and Supported Models
This release focuses on the inference backend layer rather than new model architectures. PaddleOCR continues to provide high-performance OCR and document parsing model series, including:
- PP-OCRv5: An OCR model series.
- PaddleOCR-VL 1.5: A document parsing model series.
These models can now be run using the Transformers backend to better fit into PyTorch / Transformers infrastructure for model loading, experimentation, and deployment.
Implementation and Quick Start
To use the Transformers backend, developers must install paddleocr==3.5.0, paddlex==3.5.2, and transformers>=5.4.0, along with a compatible PyTorch build.
Command Line Interface (CLI)
paddleocr ocr \
-i https://paddle-model-ecology.bj.bcebos.com/paddlex/imgs/demo_image/general_ocr_002.png \
--device gpu:0 \
--engine transformers
Python API
from paddleocr import PaddleOCR
pipeline = PaddleOCR(
device="gpu:0",
engine="transformers",
use_doc_orientation_classify=False,
use_doc_unwarping=False,
use_textline_orientation=False,
engine_config={
"dtype": "float32",
},
)
results = pipeline.predict(
"https://paddle-model-ecology.bj.bcebos.com/paddlex/imgs/demo_image/general_ocr_002.png"
)
Developers can further tune performance via engine_config using parameters such as dtype (e.g., bfloat16), device_type, device_id, and attn_implementation (e.g., sdpa).
When to Use the Transformers Backend
The Transformers backend is recommended for teams already relying on PyTorch / Transformers infrastructure for model artifact management and deployment. It provides a more familiar development experience and Hub-compatible model discovery.
However, for users prioritizing maximum OCR or document parsing throughput, the default paddle_static backend remains the recommended choice. This release provides flexibility rather than a replacement for existing backends.
Resources
- Live Demo: Hugging Face Spaces
- Model Hub: PaddlePaddle on Hugging Face
- Documentation: PaddleOCR Official Site