All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- Smart OCR Resume & Retry Logic: Enhanced the processing queue to automatically filter out successful files. When rate limits (HTTP 429) or errors occur, the UI transforms into a "Retry OCR on X remaining files" button, allowing users to seamlessly resume failed tasks without removing completed ones.
- Configurable Max Upload Limit: Added
TYPHOON_MAX_FILESconfiguration (default: 10) dynamically linked between the backend (.env) and frontend, adjustable via the in-app Settings UI.
- Port Conflict Mitigation: Updated process management and documentation to handle scenarios where the default port might get stuck in use.
- ReferenceError on Settings Modal: Fixed a missing
FileTexticon import causing UI crashes when viewing configuration.
- Automatic GitHub Update Checker: Integrated
UpdateBadgecomponent in Navbar to check for new releases/commits on GitHub via lightweight API (/api/update/check), prompting users when an update is available without consuming extra CPU/memory. - One-Click Git Pull Update: Added safe in-app update trigger (
/api/update/pull) executinggit pull origin mainwith automated working directory status verification (git status --porcelain) to prevent merge conflicts.
- Strict Git Branch Sanitization: Applied strict regex validation (
/^[a-zA-Z0-9_\-\.\/]+$/) on branch names in/api/update/pullto eliminate shell command injection risks.
- Keyboard Accessibility & Popover Polish: Enhanced
UpdateBadgewithEscapekey handlers, outside-click closing, and full ARIA attributes (aria-expanded,role="dialog"). - Design System Alignment: Created
PRODUCT.mdestablishing core product facts and visual standards usingimpeccableandui-ux-pro-maxguidelines.
- Viewport-Based PDF Lazy Loading: Implemented
<LazyPdfPage>withIntersectionObserverinPdfPreview.tsxto render PDF page canvases on-demand when scrolled into view, eliminating memory spikes and browser freezes on large multi-page documents. - Robust PDF Single-File Detection: Enhanced
isSinglePdfcheck inConfigPanel.tsxwith a filename extension fallback (.endsWith(".pdf")), ensuring page selection tools (range, checkboxes, odd/even) remain visible even when OS/URL imports omit the MIME type. - Progressive Markdown Page Rendering: Added
visiblePageCountstate and progressive pagination toResponsePanel.tsxto prevent UI lag when rendering complex multi-page Markdown outputs with syntax highlighting.
- Multi-File Batch OCR: Support uploading up to 10 documents/images simultaneously with queue management, file removal, and clear-all actions.
- Sliding Window Concurrent Queue: Implemented a dynamic worker queue (
processBatch.ts) with concurrency cap of 3 to maximize throughput without stalling the browser main thread. - Tabbed Results Panel: Added per-file tab strip with live status badges (pending, processing, success, error) and "+X more" overflow dropdown.
- Flexible Copy & Export Engine: Extended copy and download capabilities to support per-file Markdown/Text, merged multi-file Markdown/Text, and ZIP archives (
.zip) with automatic filename deduplication. - Keyboard Accessibility: Added
focus-withinkeyboard navigation support to the overflow tabs dropdown inResponsePanel.tsx.
- Server-Level 404 Redirect: Added
redirects()configuration innext.config.tsmapping/to/ocrat the server level, preventing 404 warnings during initial startup. - React Re-render Freeze: Wrapped
MarkdownContentwithReact.memoto eliminate main thread UI freezes during SSE progress stream updates. - Download Race Condition: Delayed
URL.revokeObjectURLinexport.tsviasetTimeoutto prevent premature URL revocation during browser downloads. - Security Vulnerabilities: Resolved high-severity package vulnerabilities (
pdfjs-distCVE GHSA-hq66-cqwq-w95j) vianpm audit fix.
- Asynchronous Processing: Refactored the entire backend OCR service to use
AsyncOpenAIandasyncio, drastically improving performance and resource utilization. - Parallel Page Execution: Multi-page PDF documents are now processed concurrently using
asyncio.Semaphore, vastly reducing total processing time. - Smart Startup Validation:
start_app.batnow verifies.envconfiguration and detects Windows "Excluded Port Ranges" (Hyper-V) before launching.
- Port Migration (8345): Moved backend default port to 8345 to avoid frequent conflicts with Windows/Hyper-V reserved ranges (8123 was often blocked).
- Frontend Refactoring: Improved React component structure, removing unused code and optimizing state management functional updates in the configuration panel.
- Stream API Optimization: The SSE
/api/ocr/streamendpoint now natively yields events from fully asynchronous background tasks. - Enhanced Security: Optimized
.gitignorefor public repository safety, ensuring secrets and large binaries are properly excluded.
- WinError 10013: Resolved "Access Forbidden" errors by migrating to a port outside of system-reserved ranges.
- Startup Script Crashes: Fixed a parser bug in the
.batfile caused by unescaped parentheses in output messages.
- Professional Startup Script: Completely redesigned
start_app.batwith modern UI featuring Unicode box-drawing characters. - Enhanced Dependency Checks: Added version display for Python, Node.js, npm, and optional pdfinfo (Poppler) detection.
- Auto-Install Dependencies: Script now automatically installs missing pip packages before starting the backend.
- API Documentation Link: Added quick access to Swagger docs at
http://localhost:8000/docs. - Tips Section: Helpful tips for users on how to manage servers.
- UTF-8 Encoding: Startup script now uses
chcp 65001for proper Unicode/emoji support. - Improved Virtual Environment Detection: Enhanced auto-detection logic for
venv,.venv,env, and any custom-named virtual environments. - Better Error Handling: Centralized error handling with styled error messages and download links.
- Visual Design: Progress indicators (
[1/3],[2/3],[3/3]) and Unicode separators for better readability.
- Dependency Conflicts: Resolved Gradio compatibility issues by pinning
pillow<12.0andpydantic<2.12.
- One-Click Startup: Introduced
start_app.batfor seamless launching of both backend and frontend services. - Robustness: Enhanced startup script with automatic environment detection (
venv,.venv,env) and dependency checks. - Documentation: Updated READMEs (English & Thai) with simplified startup instructions.
- Real-time Progress Tracking: Implemented Server-Sent Events (SSE) to stream OCR progress updates to the frontend.
- Processing Timer: Added a dedicated timer component to track elapsed time accurately.
- Page Counter: Added "Processing page X of Y" indicator for multi-page documents.
- Backend Performance: Refactored OCR service to use
run_in_threadpoolfor non-blocking execution. - UI Improvements: Fixed layout scrolling issues in PDF preview and results panel.
- Code Refactoring: Cleaned up
ResponsePaneland improved state management.
- Modern Frontend: Initial release of the Next.js web application with a modern, dark-themed UI.
- FastAPI Integration: Added Python FastAPI backend to bridge the frontend with Typhoon OCR.
- Improved OCR Capabilities: Added support for OCR v1.5 with enhanced prompts and runtime checks.
- Multi-page Support: Implemented document layout analysis for handling multiple pages.
- Project Structure: Organized codebase into clear
frontendandbackenddirectories. - Configuration: Added
.envsupport for easy API key and model management.