- Enable PP-StructureV3's use_doc_orientation_classify feature - Detect rotation angle from doc_preprocessor_res.angle - Swap page dimensions (width <-> height) for 90°/270° rotations - Output PDF now correctly displays landscape-scanned content Also includes: - Archive completed openspec proposals - Add simplify-frontend-ocr-config proposal (pending) - Code cleanup and frontend simplification 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1.5 KiB
1.5 KiB
Change: 簡化前端 OCR 配置選項
Why
OCR track 已改為使用 simple OCR 模式,不再需要前端的複雜配置選項(如表格偵測模式、OCR 預設、進階參數等)。這些配置增加了使用者的認知負擔,且不再影響實際處理結果。
What Changes
- BREAKING 移除前端的 OCR 處理預設選擇器 (
OCRPresetSelector) - BREAKING 移除前端的表格偵測配置選擇器 (
TableDetectionSelector) - BREAKING 移除前端相關的 TypeScript 類型定義 (
OCRPreset,OCRConfig,TableDetectionConfig,TableParsingMode等) - 保留版面模型選擇功能 (
LayoutModelSelector):chinese | default | cdla - 保留影像前處理配置功能 (
PreprocessingSettings): auto/manual/disabled 模式及相關參數 - 簡化後端 API 的
ProcessingOptions,移除不再使用的參數
Impact
- Affected specs:
ocr-processing - Affected code:
- 前端需刪除的檔案:
frontend/src/components/OCRPresetSelector.tsxfrontend/src/components/TableDetectionSelector.tsx
- 前端需修改的檔案:
frontend/src/types/apiV2.ts- 移除未使用的類型定義frontend/src/pages/ProcessingPage.tsx- 移除已註解的相關 import 和邏輯
- 後端需修改的檔案:
backend/app/schemas/task.py- 移除ProcessingOptions中的ocr_preset,ocr_config,table_detection欄位backend/app/routers/tasks.py- 清理對應的參數處理邏輯
- 前端需刪除的檔案: