Add docTR as primary OCR engine with 2-tier sequential processing, OCR metrics tracking, and simplified engine selection. Features: - docTR OCR engine with light+medium preprocessing tiers - doctr_plus mode with early exit optimization (~65% fast path) - OCR metrics dashboard with per-engine statistics - User OCR preference persistence - Parallel worker pool for OCR processing - Cross-validation for extraction quality Engine options: tesseract, doctr, doctr_plus (recommended), paddleocr 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
99 lines
3.9 KiB
Plaintext
99 lines
3.9 KiB
Plaintext
# ============================================================================
|
|
# ROA2WEB Unified Backend - Dependencies
|
|
# ============================================================================
|
|
# Merged from reports-app, data-entry-app, and telegram-bot
|
|
# All three modules now run in a single backend process
|
|
|
|
# ============================================================================
|
|
# FASTAPI CORE (Common to all modules)
|
|
# ============================================================================
|
|
fastapi>=0.109.0
|
|
uvicorn[standard]>=0.27.0
|
|
python-multipart>=0.0.6
|
|
pydantic>=2.5.3
|
|
pydantic-settings>=2.1.0
|
|
email-validator>=2.1.0
|
|
|
|
# ============================================================================
|
|
# AUTHENTICATION (Shared across all modules)
|
|
# ============================================================================
|
|
PyJWT>=2.8.0
|
|
python-jose[cryptography]>=3.3.0
|
|
|
|
# ============================================================================
|
|
# DATABASE - ORACLE (Shared: Reports + Data Entry nomenclatures + Auth)
|
|
# ============================================================================
|
|
oracledb>=2.0.1
|
|
|
|
# ============================================================================
|
|
# DATABASE - SQLITE (Data Entry + Telegram + Reports Cache)
|
|
# ============================================================================
|
|
aiosqlite>=0.19.0
|
|
|
|
# ============================================================================
|
|
# DATABASE - SQLMODEL + ALEMBIC (Data Entry only)
|
|
# ============================================================================
|
|
sqlmodel>=0.0.14
|
|
sqlalchemy[asyncio]>=2.0.25
|
|
alembic>=1.13.1
|
|
|
|
# ============================================================================
|
|
# HTTP CLIENT (Shared)
|
|
# ============================================================================
|
|
httpx>=0.27.0
|
|
|
|
# ============================================================================
|
|
# UTILITIES (Shared)
|
|
# ============================================================================
|
|
python-dotenv>=1.0.0
|
|
python-dateutil>=2.8.2
|
|
|
|
# ============================================================================
|
|
# FILE HANDLING (Data Entry)
|
|
# ============================================================================
|
|
aiofiles>=23.2.1
|
|
Pillow>=10.2.0
|
|
|
|
# ============================================================================
|
|
# REPORTS MODULE - Exports (Excel, PDF)
|
|
# ============================================================================
|
|
openpyxl>=3.1.0
|
|
fpdf2>=2.7.0
|
|
|
|
# ============================================================================
|
|
# DATA ENTRY MODULE - OCR Dependencies
|
|
# ============================================================================
|
|
# docTR - fastest OCR engine with 90/100 accuracy (3.3x faster than PaddleOCR)
|
|
python-doctr[torch]>=0.8.0
|
|
|
|
# PaddleOCR for receipt text extraction (fallback)
|
|
paddleocr>=2.7.0
|
|
paddlepaddle>=2.5.0
|
|
opencv-python>=4.8.0
|
|
pytesseract>=0.3.10
|
|
pdf2image>=1.16.0
|
|
numpy>=1.24.0
|
|
# Process management for OCR worker pool (Windows orphan cleanup)
|
|
psutil>=5.9.0
|
|
|
|
# ============================================================================
|
|
# TELEGRAM MODULE - Bot SDK
|
|
# ============================================================================
|
|
python-telegram-bot>=20.7
|
|
|
|
# ============================================================================
|
|
# TELEGRAM MODULE - Email (SMTP for 2FA)
|
|
# ============================================================================
|
|
aiosmtplib>=3.0.0
|
|
|
|
# ============================================================================
|
|
# MONITORING (Optional - Telegram module)
|
|
# ============================================================================
|
|
# sentry-sdk>=1.40.0 # Uncomment if needed
|
|
|
|
# ============================================================================
|
|
# TESTING
|
|
# ============================================================================
|
|
pytest>=8.0.0
|
|
pytest-asyncio>=0.23.3
|