Skip to content

Commit 5bc119a

Browse files
committed
fix(pdf): make deterministic settings optional, remove sample invoice
1 parent 94f8d02 commit 5bc119a

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed
-1.83 KB
Binary file not shown.

src/flare_ai_kit/ingestion/settings.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,14 +64,15 @@ class PDFFieldExtractionSettings(BaseSettings):
6464
"""Specifies fields to extract from a PDF and their locations."""
6565

6666
field_name: str = Field(description="The name of the field to extract.")
67-
x0: int = Field(description="The starting x-coordinate of the bounding box.")
68-
y0: int = Field(description="The starting y-coordinate of the bounding box.")
69-
x1: int = Field(description="The ending x-coordinate of the bounding box.")
70-
y1: int = Field(description="The ending y-coordinate of the bounding box.")
7167
data_type: str = Field(
7268
"string",
7369
description="The data type of the field (e.g., 'string', 'integer', 'date').",
7470
)
71+
# For deterministic extraction pipeline
72+
x0: int | None = Field(default=None, description="The starting x-coordinate of the bounding box.")
73+
y0: int | None = Field(default=None, description="The starting y-coordinate of the bounding box.")
74+
x1: int | None = Field(default=None, description="The ending x-coordinate of the bounding box.")
75+
y1: int | None = Field(default=None, description="The ending y-coordinate of the bounding box.")
7576

7677

7778
class PDFTemplateSettings(BaseSettings):

0 commit comments

Comments
 (0)