From 43916da6eb464fc3afd15ac7506ef0ae888ef65d Mon Sep 17 00:00:00 2001 From: perf3ct Date: Tue, 24 Jun 2025 01:28:12 +0000 Subject: [PATCH] fix(ocr): set preprocessing to false by default --- frontend/src/pages/SettingsPage.tsx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/frontend/src/pages/SettingsPage.tsx b/frontend/src/pages/SettingsPage.tsx index 7b43842..b3be669 100644 --- a/frontend/src/pages/SettingsPage.tsx +++ b/frontend/src/pages/SettingsPage.tsx @@ -175,7 +175,7 @@ const SettingsPage: React.FC = () => { maxFileSizeMb: 50, allowedFileTypes: ['pdf', 'png', 'jpg', 'jpeg', 'tiff', 'bmp', 'txt'], autoRotateImages: true, - enableImagePreprocessing: true, + enableImagePreprocessing: false, searchResultsPerPage: 25, searchSnippetLength: 200, fuzzySearchThreshold: 0.8, @@ -267,7 +267,7 @@ const SettingsPage: React.FC = () => { maxFileSizeMb: response.data.max_file_size_mb || 50, allowedFileTypes: response.data.allowed_file_types || ['pdf', 'png', 'jpg', 'jpeg', 'tiff', 'bmp', 'txt'], autoRotateImages: response.data.auto_rotate_images !== undefined ? response.data.auto_rotate_images : true, - enableImagePreprocessing: response.data.enable_image_preprocessing !== undefined ? response.data.enable_image_preprocessing : true, + enableImagePreprocessing: response.data.enable_image_preprocessing !== undefined ? response.data.enable_image_preprocessing : false, searchResultsPerPage: response.data.search_results_per_page || 25, searchSnippetLength: response.data.search_snippet_length || 200, fuzzySearchThreshold: response.data.fuzzy_search_threshold || 0.8, @@ -686,6 +686,9 @@ const SettingsPage: React.FC = () => { Enhance images for better OCR accuracy (deskew, denoise, contrast) + + ⚠️ Warning: Enabling preprocessing can significantly alter OCR text results and may reduce accuracy for some documents +