OCR

OCR Page

class OCRPage(raw_response)

OCR result for a single page.

Parameters:

raw_response (dict[str, Any])

content: str

Full text content extracted from the document page.

words: list[OCRWord]

List of words extracted from the document page.

OCR Word

class OCRWord(raw_response)

OCR result for a single word extracted from the document page.

Parameters:

raw_response (dict)

content: str

Text content of the word.

polygon: Polygon

Position information as a list of points in clockwise order.

Ocr Inference

class OCRInference(raw_response)

OCR inference result.

Parameters:

raw_response (dict[str, Any])

file: InferenceFile

File info for the inference.

id: str

ID of the inference.

job: InferenceJob

Job the inference belongs to.

model: InferenceModel

Model info for the inference.

result: OCRResult

Result of a ocr inference.

OCR Response

class OCRResponse(raw_response)

Represent an OCR inference response from Mindee V2 API.

Parameters:

raw_response (dict[str, Any])

classmethod get_result_slug()

Getter for the inference slug.

Return type:

str

inference: OCRInference

Inference object for ocr inference.

property raw_http: str

Displays the result of the raw response as json string.

OCR Result

class OCRResult(raw_response)

OCR result info.

Parameters:

raw_response (dict[str, Any])

pages: list[OCRPage]

List of OCR results for each page in the document.