Create an OCR engine abstraction layer in ocr/app/engines/ to decouple extractors from Tesseract. Implement PaddleOCR as the primary engine using PP-OCRv4 models.
Changes
Create ocr/app/engines/base_engine.py - OcrEngine ABC with recognize(image_bytes, config) method
Create ocr/app/engines/paddle_engine.py - PaddleOCR wrapper with PP-OCRv4, angle classification, CPU-only
Create ocr/app/engines/engine_factory.py - Factory to instantiate configured engine
Update ocr/app/config.py - Add OCR_PRIMARY_ENGINE, OCR_CONFIDENCE_THRESHOLD env vars
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Relates to #115
Create an OCR engine abstraction layer in
ocr/app/engines/to decouple extractors from Tesseract. Implement PaddleOCR as the primary engine using PP-OCRv4 models.Changes
ocr/app/engines/base_engine.py-OcrEngineABC withrecognize(image_bytes, config)methodocr/app/engines/paddle_engine.py- PaddleOCR wrapper with PP-OCRv4, angle classification, CPU-onlyocr/app/engines/engine_factory.py- Factory to instantiate configured engineocr/app/config.py- AddOCR_PRIMARY_ENGINE,OCR_CONFIDENCE_THRESHOLDenv varsocr/requirements.txt- Addpaddlepaddle,paddleocrdependenciesAcceptance Criteria
recognize()returning structured OcrEngineResult (text, confidence, word boxes)