From cacff6f63a9687eefe8ced51f98ec7c65a252f63 Mon Sep 17 00:00:00 2001 From: panda <1415243231@qq.com> Date: Mon, 25 May 2026 22:25:23 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20ExtractionResult.to=5Fdict()=20=E5=BA=8F?= =?UTF-8?q?=E5=88=97=E5=8C=96=20all=5Felements=20=E5=AE=8C=E6=95=B4?= =?UTF-8?q?=E6=96=87=E6=9C=AC=E5=85=83=E7=B4=A0=E5=B1=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/ocr_extractor.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/backend/ocr_extractor.py b/backend/ocr_extractor.py index 5105e9c..4922434 100644 --- a/backend/ocr_extractor.py +++ b/backend/ocr_extractor.py @@ -98,6 +98,14 @@ class ExtractionResult: } for f in self.fields ], + "all_elements": [ + { + "text": e.text, + "bbox": e.bbox, + "confidence": e.confidence, + } + for e in self.all_elements + ], "total_elements": len(self.all_elements), "errors": self.errors, }