diff --git a/docs/extras/code_samples/bank_account_details_v1.txt b/docs/extras/code_samples/bank_account_details_v1.txt index d319f78d..ff5643f1 100644 --- a/docs/extras/code_samples/bank_account_details_v1.txt +++ b/docs/extras/code_samples/bank_account_details_v1.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.fr.BankAccountDetailsV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.fr.BankAccountDetailsV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/bank_account_details_v2.txt b/docs/extras/code_samples/bank_account_details_v2.txt index 8200d0c3..d60f2806 100644 --- a/docs/extras/code_samples/bank_account_details_v2.txt +++ b/docs/extras/code_samples/bank_account_details_v2.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.fr.BankAccountDetailsV2, input_doc) +result: PredictResponse = mindee_client.parse( + product.fr.BankAccountDetailsV2, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/bank_check_v1.txt b/docs/extras/code_samples/bank_check_v1.txt index a19ddcc5..28c77fa9 100644 --- a/docs/extras/code_samples/bank_check_v1.txt +++ b/docs/extras/code_samples/bank_check_v1.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.us.BankCheckV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.us.BankCheckV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/barcode_reader_v1.txt b/docs/extras/code_samples/barcode_reader_v1.txt index c6eedfbc..06bfaa2d 100644 --- a/docs/extras/code_samples/barcode_reader_v1.txt +++ b/docs/extras/code_samples/barcode_reader_v1.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.BarcodeReaderV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.BarcodeReaderV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/bill_of_lading_v1_async.txt b/docs/extras/code_samples/bill_of_lading_v1_async.txt index 9d5ec6b6..a6569e39 100644 --- a/docs/extras/code_samples/bill_of_lading_v1_async.txt +++ b/docs/extras/code_samples/bill_of_lading_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/business_card_v1_async.txt b/docs/extras/code_samples/business_card_v1_async.txt index 43882dc6..745ebbe6 100644 --- a/docs/extras/code_samples/business_card_v1_async.txt +++ b/docs/extras/code_samples/business_card_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/carte_grise_v1.txt b/docs/extras/code_samples/carte_grise_v1.txt index 202962a3..ff44e59d 100644 --- a/docs/extras/code_samples/carte_grise_v1.txt +++ b/docs/extras/code_samples/carte_grise_v1.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.fr.CarteGriseV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.fr.CarteGriseV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/cropper_v1.txt b/docs/extras/code_samples/cropper_v1.txt index 3c164249..5c0633cc 100644 --- a/docs/extras/code_samples/cropper_v1.txt +++ b/docs/extras/code_samples/cropper_v1.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.CropperV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.CropperV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/default.txt b/docs/extras/code_samples/default.txt index b8eabb73..83fa2d2c 100644 --- a/docs/extras/code_samples/default.txt +++ b/docs/extras/code_samples/default.txt @@ -1,9 +1,15 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client mindee_client = Client(api_key="my-api-key") -# Add the corresponding endpoint (document). Set the account_name to "mindee" if you are using OTS. +# Add the corresponding endpoint (document). +# Set the account_name to "mindee" if you are using OTS. my_endpoint = mindee_client.create_endpoint( account_name="my-account", endpoint_name="my-endpoint", diff --git a/docs/extras/code_samples/default_async.txt b/docs/extras/code_samples/default_async.txt index 70faa140..b701a196 100644 --- a/docs/extras/code_samples/default_async.txt +++ b/docs/extras/code_samples/default_async.txt @@ -1,9 +1,15 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, AsyncPredictResponse, product # Init a new client mindee_client = Client(api_key="my-api-key") -# Add the corresponding endpoint (document). Set the account_name to "mindee" if you are using OTS. +# Add the corresponding endpoint (document). +# Set the account_name to "mindee" if you are using OTS. my_endpoint = mindee_client.create_endpoint( account_name="my-account", endpoint_name="my-endpoint", diff --git a/docs/extras/code_samples/delivery_notes_v1_async.txt b/docs/extras/code_samples/delivery_notes_v1_async.txt index def25556..4ca941a4 100644 --- a/docs/extras/code_samples/delivery_notes_v1_async.txt +++ b/docs/extras/code_samples/delivery_notes_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/driver_license_v1_async.txt b/docs/extras/code_samples/driver_license_v1_async.txt index 5a34e4af..cf3abfce 100644 --- a/docs/extras/code_samples/driver_license_v1_async.txt +++ b/docs/extras/code_samples/driver_license_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/energy_bill_fra_v1_async.txt b/docs/extras/code_samples/energy_bill_fra_v1_async.txt index b5454a74..a953dcb1 100644 --- a/docs/extras/code_samples/energy_bill_fra_v1_async.txt +++ b/docs/extras/code_samples/energy_bill_fra_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/expense_receipts_v5.txt b/docs/extras/code_samples/expense_receipts_v5.txt index f68db5ff..2243cc61 100644 --- a/docs/extras/code_samples/expense_receipts_v5.txt +++ b/docs/extras/code_samples/expense_receipts_v5.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.ReceiptV5, input_doc) +result: PredictResponse = mindee_client.parse( + product.ReceiptV5, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/expense_receipts_v5_async.txt b/docs/extras/code_samples/expense_receipts_v5_async.txt index 2853c469..bf174184 100644 --- a/docs/extras/code_samples/expense_receipts_v5_async.txt +++ b/docs/extras/code_samples/expense_receipts_v5_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/financial_document_v1.txt b/docs/extras/code_samples/financial_document_v1.txt index 2f11ebfa..67a1f00d 100644 --- a/docs/extras/code_samples/financial_document_v1.txt +++ b/docs/extras/code_samples/financial_document_v1.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.FinancialDocumentV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.FinancialDocumentV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/financial_document_v1_async.txt b/docs/extras/code_samples/financial_document_v1_async.txt index 7fbaeff0..9fb1c123 100644 --- a/docs/extras/code_samples/financial_document_v1_async.txt +++ b/docs/extras/code_samples/financial_document_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/french_healthcard_v1_async.txt b/docs/extras/code_samples/french_healthcard_v1_async.txt index 12ff2b1f..4200e4f1 100644 --- a/docs/extras/code_samples/french_healthcard_v1_async.txt +++ b/docs/extras/code_samples/french_healthcard_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/idcard_fr_v1.txt b/docs/extras/code_samples/idcard_fr_v1.txt index 249bd915..b0087d83 100644 --- a/docs/extras/code_samples/idcard_fr_v1.txt +++ b/docs/extras/code_samples/idcard_fr_v1.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.fr.IdCardV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.fr.IdCardV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/idcard_fr_v2.txt b/docs/extras/code_samples/idcard_fr_v2.txt index 5494d4e4..47bcb6b1 100644 --- a/docs/extras/code_samples/idcard_fr_v2.txt +++ b/docs/extras/code_samples/idcard_fr_v2.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.fr.IdCardV2, input_doc) +result: PredictResponse = mindee_client.parse( + product.fr.IdCardV2, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/ind_passport_v1_async.txt b/docs/extras/code_samples/ind_passport_v1_async.txt index c7ce4e15..dd163da4 100644 --- a/docs/extras/code_samples/ind_passport_v1_async.txt +++ b/docs/extras/code_samples/ind_passport_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/international_id_v2_async.txt b/docs/extras/code_samples/international_id_v2_async.txt index ea8e12e8..36a3fa97 100644 --- a/docs/extras/code_samples/international_id_v2_async.txt +++ b/docs/extras/code_samples/international_id_v2_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/invoice_splitter_v1_async.txt b/docs/extras/code_samples/invoice_splitter_v1_async.txt index 20a96b6d..c98da273 100644 --- a/docs/extras/code_samples/invoice_splitter_v1_async.txt +++ b/docs/extras/code_samples/invoice_splitter_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/invoices_v4.txt b/docs/extras/code_samples/invoices_v4.txt index 740cb37b..848441ed 100644 --- a/docs/extras/code_samples/invoices_v4.txt +++ b/docs/extras/code_samples/invoices_v4.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.InvoiceV4, input_doc) +result: PredictResponse = mindee_client.parse( + product.InvoiceV4, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/invoices_v4_async.txt b/docs/extras/code_samples/invoices_v4_async.txt index f775e65b..a4cbf802 100644 --- a/docs/extras/code_samples/invoices_v4_async.txt +++ b/docs/extras/code_samples/invoices_v4_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/material_certificate_v1_async.txt b/docs/extras/code_samples/material_certificate_v1_async.txt index 28b8e2fd..a0997d88 100644 --- a/docs/extras/code_samples/material_certificate_v1_async.txt +++ b/docs/extras/code_samples/material_certificate_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/multi_receipts_detector_v1.txt b/docs/extras/code_samples/multi_receipts_detector_v1.txt index e11656c9..9c50ce44 100644 --- a/docs/extras/code_samples/multi_receipts_detector_v1.txt +++ b/docs/extras/code_samples/multi_receipts_detector_v1.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.MultiReceiptsDetectorV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.MultiReceiptsDetectorV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/nutrition_facts_v1_async.txt b/docs/extras/code_samples/nutrition_facts_v1_async.txt index de0f1285..65c6e670 100644 --- a/docs/extras/code_samples/nutrition_facts_v1_async.txt +++ b/docs/extras/code_samples/nutrition_facts_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/passport_v1.txt b/docs/extras/code_samples/passport_v1.txt index def7cd0d..e0eae0d0 100644 --- a/docs/extras/code_samples/passport_v1.txt +++ b/docs/extras/code_samples/passport_v1.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -7,8 +12,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.PassportV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.PassportV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/code_samples/payslip_fra_v2_async.txt b/docs/extras/code_samples/payslip_fra_v2_async.txt index 1e622121..5bf9366d 100644 --- a/docs/extras/code_samples/payslip_fra_v2_async.txt +++ b/docs/extras/code_samples/payslip_fra_v2_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/payslip_fra_v3_async.txt b/docs/extras/code_samples/payslip_fra_v3_async.txt index b226f5e3..21f66657 100644 --- a/docs/extras/code_samples/payslip_fra_v3_async.txt +++ b/docs/extras/code_samples/payslip_fra_v3_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/resume_v1_async.txt b/docs/extras/code_samples/resume_v1_async.txt index 17d5a1e7..4e6c4a40 100644 --- a/docs/extras/code_samples/resume_v1_async.txt +++ b/docs/extras/code_samples/resume_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/us_healthcare_cards_v1_async.txt b/docs/extras/code_samples/us_healthcare_cards_v1_async.txt index 3f9c6ffa..77da99b0 100644 --- a/docs/extras/code_samples/us_healthcare_cards_v1_async.txt +++ b/docs/extras/code_samples/us_healthcare_cards_v1_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/us_mail_v2_async.txt b/docs/extras/code_samples/us_mail_v2_async.txt index 52e12f67..1735ab37 100644 --- a/docs/extras/code_samples/us_mail_v2_async.txt +++ b/docs/extras/code_samples/us_mail_v2_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/us_mail_v3_async.txt b/docs/extras/code_samples/us_mail_v3_async.txt index 38f5ed7f..797f34a5 100644 --- a/docs/extras/code_samples/us_mail_v3_async.txt +++ b/docs/extras/code_samples/us_mail_v3_async.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/code_samples/workflow_execution.txt b/docs/extras/code_samples/workflow_execution.txt index f21f45f8..a825a8bf 100644 --- a/docs/extras/code_samples/workflow_execution.txt +++ b/docs/extras/code_samples/workflow_execution.txt @@ -1,3 +1,8 @@ +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, WorkflowResponse from mindee.parsing.common import ExecutionPriority @@ -13,9 +18,10 @@ input_doc = mindee_client.source_from_path("/path/to/the/file.ext") result: WorkflowResponse = mindee_client.execute_workflow( input_doc, workflow_id, - # Optionally, add an alias and a priority to the workflow. + # Optional parameters: # alias="my-alias", - # priority=ExecutionPriority.LOW + # priority=ExecutionPriority.LOW, + # rag=True, ) # Print the ID of the execution to make sure it worked. diff --git a/docs/extras/guide/bank_account_details_v2.md b/docs/extras/guide/bank_account_details_v2.md index ae2a7b76..419fca28 100644 --- a/docs/extras/guide/bank_account_details_v2.md +++ b/docs/extras/guide/bank_account_details_v2.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.fr.BankAccountDetailsV2, input_doc) +result: PredictResponse = mindee_client.parse( + product.fr.BankAccountDetailsV2, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/guide/bank_check_v1.md b/docs/extras/guide/bank_check_v1.md index 3cab859c..c1df5d12 100644 --- a/docs/extras/guide/bank_check_v1.md +++ b/docs/extras/guide/bank_check_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.us.BankCheckV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.us.BankCheckV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/guide/barcode_reader_v1.md b/docs/extras/guide/barcode_reader_v1.md index d69db17d..f007220e 100644 --- a/docs/extras/guide/barcode_reader_v1.md +++ b/docs/extras/guide/barcode_reader_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.BarcodeReaderV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.BarcodeReaderV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/guide/bill_of_lading_v1.md b/docs/extras/guide/bill_of_lading_v1.md index 36248682..6ced8301 100644 --- a/docs/extras/guide/bill_of_lading_v1.md +++ b/docs/extras/guide/bill_of_lading_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/business_card_v1.md b/docs/extras/guide/business_card_v1.md index 0c7d1e5a..c88f24b2 100644 --- a/docs/extras/guide/business_card_v1.md +++ b/docs/extras/guide/business_card_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/carte_grise_v1.md b/docs/extras/guide/carte_grise_v1.md index c9480b6e..e21db7f3 100644 --- a/docs/extras/guide/carte_grise_v1.md +++ b/docs/extras/guide/carte_grise_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.fr.CarteGriseV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.fr.CarteGriseV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/guide/cropper_v1.md b/docs/extras/guide/cropper_v1.md index c10b6a32..32674167 100644 --- a/docs/extras/guide/cropper_v1.md +++ b/docs/extras/guide/cropper_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.CropperV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.CropperV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/guide/delivery_notes_v1.md b/docs/extras/guide/delivery_notes_v1.md index db65e431..0bf18f20 100644 --- a/docs/extras/guide/delivery_notes_v1.md +++ b/docs/extras/guide/delivery_notes_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/driver_license_v1.md b/docs/extras/guide/driver_license_v1.md index 321e776b..059b7795 100644 --- a/docs/extras/guide/driver_license_v1.md +++ b/docs/extras/guide/driver_license_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/energy_bill_fra_v1.md b/docs/extras/guide/energy_bill_fra_v1.md index e4535683..7f3ad92b 100644 --- a/docs/extras/guide/energy_bill_fra_v1.md +++ b/docs/extras/guide/energy_bill_fra_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client @@ -35,18 +40,18 @@ print(result.document) ######## Document ######## -:Mindee ID: 17f0ccef-e3fe-4a28-838d-d704489d6ce7 +:Mindee ID: ff1f2ca8-4d29-44d8-a564-599a982a4ef7 :Filename: default_sample.pdf Inference ######### -:Product: mindee/energy_bill_fra v1.0 -:Rotation applied: No +:Product: mindee/energy_bill_fra v1.2 +:Rotation applied: Yes Prediction ========== -:Invoice Number: 10123590373 -:Contract ID: 1234567890 +:Invoice Number: 1234567890 +:Contract ID: 9876543210 :Delivery Point: 98765432109876 :Invoice Date: 2021-01-29 :Due Date: 2021-02-15 @@ -54,11 +59,11 @@ Prediction :Total Taxes: 238.82 :Total Amount: 1479.85 :Energy Supplier: - :Address: TSA 12345, 12345 DEMOCITY CEDEX, 75001 PARIS + :Address: TSA 12345, 12345 DEMOCITY CEDEX :Name: EDF :Energy Consumer: - :Address: 12 AVENUE DES RÊVES, RDC A 123 COUR FAUSSE A, 75000 PARIS - :Name: John Doe + :Address: 123 RUE DE L'IMAGINAIRE, 75001 PARIS + :Name: JOHN DOE :Subscription: +--------------------------------------+------------+------------+----------+-----------+------------+ | Description | End Date | Start Date | Tax Rate | Total | Unit Price | @@ -66,27 +71,27 @@ Prediction | Abonnement électricité | 2021-02-28 | 2021-01-01 | 5.50 | 59.00 | 29.50 | +--------------------------------------+------------+------------+----------+-----------+------------+ :Energy Usage: - +--------------------------------------+------------+------------+----------+-----------+------------+ - | Description | End Date | Start Date | Tax Rate | Total | Unit Price | - +======================================+============+============+==========+===========+============+ - | Consommation (HT) | 2021-01-27 | 2020-11-28 | 20.00 | 898.43 | 10.47 | - +--------------------------------------+------------+------------+----------+-----------+------------+ + +-------------+--------------------------------------+------------+------------+----------+-----------+-----------------+------------+ + | Consumption | Description | End Date | Start Date | Tax Rate | Total | Unit of Measure | Unit Price | + +=============+======================================+============+============+==========+===========+=================+============+ + | 8581.00 | Consommation électricité | 2021-01-27 | 2020-11-28 | 20.00 | 898.43 | kWh | 0.1047 | + +-------------+--------------------------------------+------------+------------+----------+-----------+-----------------+------------+ :Taxes and Contributions: +--------------------------------------+------------+------------+----------+-----------+------------+ | Description | End Date | Start Date | Tax Rate | Total | Unit Price | +======================================+============+============+==========+===========+============+ - | Contribution au Service Public de... | 2021-01-27 | 2020-11-28 | 20.00 | 193.07 | 2.25 | + | Contribution au Service Public de... | 2021-01-27 | 2020-11-28 | 20.00 | 193.07 | 0.0225 | +--------------------------------------+------------+------------+----------+-----------+------------+ - | Départementale sur la Conso Final... | 2020-12-31 | 2020-11-28 | 20.00 | 13.98 | 0.3315 | + | Taxe Départementale sur la Conso ... | 2021-01-27 | 2020-11-28 | 20.00 | 13.98 | 0.003315 | +--------------------------------------+------------+------------+----------+-----------+------------+ - | Communale sur la Conso Finale Ele... | 2021-01-27 | 2021-01-01 | 20.00 | 28.56 | 0.6545 | + | Taxe Communale sur la Conso Final... | 2021-01-27 | 2020-11-28 | 20.00 | 28.56 | 0.006545 | +--------------------------------------+------------+------------+----------+-----------+------------+ - | Contribution Tarifaire d'Achemine... | 2020-12-31 | 2020-11-28 | 20.00 | 27.96 | 0.663 | + | Taxe Communale sur la Conso Final... | 2021-01-27 | 2020-11-28 | 20.00 | 27.96 | 0.00663 | +--------------------------------------+------------+------------+----------+-----------+------------+ :Meter Details: :Meter Number: 620 :Meter Type: electricity - :Unit of Measure: kWh + :Unit of Power: 36kVA ``` # Field Types diff --git a/docs/extras/guide/expense_receipts_v5.md b/docs/extras/guide/expense_receipts_v5.md index fedf7175..352d06d2 100644 --- a/docs/extras/guide/expense_receipts_v5.md +++ b/docs/extras/guide/expense_receipts_v5.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.ReceiptV5, input_doc) +result: PredictResponse = mindee_client.parse( + product.ReceiptV5, + input_doc, +) # Print a summary of the API result print(result.document) @@ -34,6 +41,11 @@ print(result.document) You can also call this product asynchronously: ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/financial_document_v1.md b/docs/extras/guide/financial_document_v1.md index 76689f1d..1b17667d 100644 --- a/docs/extras/guide/financial_document_v1.md +++ b/docs/extras/guide/financial_document_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.FinancialDocumentV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.FinancialDocumentV1, + input_doc, +) # Print a summary of the API result print(result.document) @@ -34,6 +41,11 @@ print(result.document) You can also call this product asynchronously: ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client @@ -58,12 +70,12 @@ print(result.document) ######## Document ######## -:Mindee ID: a80ac0ee-26f6-4e2e-988a-960b240d5ba7 +:Mindee ID: f52333ab-811e-4647-993e-ad79e072afa3 :Filename: default_sample.jpg Inference ######### -:Product: mindee/financial_document v1.11 +:Product: mindee/financial_document v1.12 :Rotation applied: Yes Prediction @@ -99,6 +111,7 @@ Prediction :Shipping Address: 2019 Redbud Drive New York, NY 10011 :Billing Address: 4312 Wood Road New York, NY 10031 :Document Type: INVOICE +:Document Type Extended: INVOICE :Purchase Subcategory: :Purchase Category: miscellaneous :Total Tax: 9.75 @@ -151,6 +164,7 @@ Page 0 :Shipping Address: 2019 Redbud Drive New York, NY 10011 :Billing Address: 4312 Wood Road New York, NY 10031 :Document Type: INVOICE +:Document Type Extended: INVOICE :Purchase Subcategory: :Purchase Category: miscellaneous :Total Tax: 9.75 diff --git a/docs/extras/guide/french_healthcard_v1.md b/docs/extras/guide/french_healthcard_v1.md index 62725e69..58109873 100644 --- a/docs/extras/guide/french_healthcard_v1.md +++ b/docs/extras/guide/french_healthcard_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/idcard_fr_v2.md b/docs/extras/guide/idcard_fr_v2.md index 4b38b671..e8bb49ff 100644 --- a/docs/extras/guide/idcard_fr_v2.md +++ b/docs/extras/guide/idcard_fr_v2.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.fr.IdCardV2, input_doc) +result: PredictResponse = mindee_client.parse( + product.fr.IdCardV2, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/guide/ind_passport_v1.md b/docs/extras/guide/ind_passport_v1.md index 927d2e69..3e6c613d 100644 --- a/docs/extras/guide/ind_passport_v1.md +++ b/docs/extras/guide/ind_passport_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/international_id_v2.md b/docs/extras/guide/international_id_v2.md index d4e2bb62..443ef460 100644 --- a/docs/extras/guide/international_id_v2.md +++ b/docs/extras/guide/international_id_v2.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/invoice_splitter_v1.md b/docs/extras/guide/invoice_splitter_v1.md index 6fb548d9..e9d9d7dd 100644 --- a/docs/extras/guide/invoice_splitter_v1.md +++ b/docs/extras/guide/invoice_splitter_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/invoices_v4.md b/docs/extras/guide/invoices_v4.md index 721d2579..35011ecb 100644 --- a/docs/extras/guide/invoices_v4.md +++ b/docs/extras/guide/invoices_v4.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.InvoiceV4, input_doc) +result: PredictResponse = mindee_client.parse( + product.InvoiceV4, + input_doc, +) # Print a summary of the API result print(result.document) @@ -34,6 +41,11 @@ print(result.document) You can also call this product asynchronously: ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client @@ -58,12 +70,12 @@ print(result.document) ######## Document ######## -:Mindee ID: b55db8f9-ae3b-4f05-b2f1-ec0ced5e5b70 +:Mindee ID: 3e524d26-f7dc-4852-9bbf-833a127a9570 :Filename: default_sample.jpg Inference ######### -:Product: mindee/invoices v4.9 +:Product: mindee/invoices v4.10 :Rotation applied: Yes Prediction @@ -98,6 +110,7 @@ Prediction :Shipping Address: :Billing Address: 1954 Bloor Street West Toronto, ON, M6P 3K9 Canada :Document Type: INVOICE +:Document Type Extended: INVOICE :Line Items: +--------------------------------------+--------------+----------+------------+--------------+--------------+-----------------+------------+ | Description | Product code | Quantity | Tax Amount | Tax Rate (%) | Total Amount | Unit of measure | Unit Price | @@ -144,6 +157,7 @@ Page 0 :Shipping Address: :Billing Address: 1954 Bloor Street West Toronto, ON, M6P 3K9 Canada :Document Type: INVOICE +:Document Type Extended: INVOICE :Line Items: +--------------------------------------+--------------+----------+------------+--------------+--------------+-----------------+------------+ | Description | Product code | Quantity | Tax Amount | Tax Rate (%) | Total Amount | Unit of measure | Unit Price | diff --git a/docs/extras/guide/material_certificate_v1.md b/docs/extras/guide/material_certificate_v1.md index 98cf1d5f..c26c2d25 100644 --- a/docs/extras/guide/material_certificate_v1.md +++ b/docs/extras/guide/material_certificate_v1.md @@ -11,6 +11,11 @@ The [sample below](https://github.com/mindee/client-lib-test-data/blob/main/prod # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/multi_receipts_detector_v1.md b/docs/extras/guide/multi_receipts_detector_v1.md index 647f9126..dbd1c993 100644 --- a/docs/extras/guide/multi_receipts_detector_v1.md +++ b/docs/extras/guide/multi_receipts_detector_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.MultiReceiptsDetectorV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.MultiReceiptsDetectorV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/guide/nutrition_facts_v1.md b/docs/extras/guide/nutrition_facts_v1.md index ac628ae0..a09eed95 100644 --- a/docs/extras/guide/nutrition_facts_v1.md +++ b/docs/extras/guide/nutrition_facts_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/passport_v1.md b/docs/extras/guide/passport_v1.md index 320378cb..6f8dfc5e 100644 --- a/docs/extras/guide/passport_v1.md +++ b/docs/extras/guide/passport_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, PredictResponse, product # Init a new client @@ -20,8 +25,10 @@ mindee_client = Client(api_key="my-api-key") input_doc = mindee_client.source_from_path("/path/to/the/file.ext") # Load a file from disk and parse it. -# The endpoint name must be specified since it cannot be determined from the class. -result: PredictResponse = mindee_client.parse(product.PassportV1, input_doc) +result: PredictResponse = mindee_client.parse( + product.PassportV1, + input_doc, +) # Print a summary of the API result print(result.document) diff --git a/docs/extras/guide/payslip_fra_v3.md b/docs/extras/guide/payslip_fra_v3.md index b1c59ad5..4b8da321 100644 --- a/docs/extras/guide/payslip_fra_v3.md +++ b/docs/extras/guide/payslip_fra_v3.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/resume_v1.md b/docs/extras/guide/resume_v1.md index 61bdb414..1c629a0f 100644 --- a/docs/extras/guide/resume_v1.md +++ b/docs/extras/guide/resume_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/docs/extras/guide/us_healthcare_cards_v1.md b/docs/extras/guide/us_healthcare_cards_v1.md index 6194fc5f..7afee818 100644 --- a/docs/extras/guide/us_healthcare_cards_v1.md +++ b/docs/extras/guide/us_healthcare_cards_v1.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client @@ -35,13 +40,13 @@ print(result.document) ######## Document ######## -:Mindee ID: 0ced9f49-00c0-4a1d-8221-4a1538813a95 +:Mindee ID: 1e71d5f0-dedb-4070-9d94-9207cd9570b5 :Filename: default_sample.jpg Inference ######### -:Product: mindee/us_healthcare_cards v1.0 -:Rotation applied: No +:Product: mindee/us_healthcare_cards v1.2 +:Rotation applied: Yes Prediction ========== @@ -56,21 +61,22 @@ Prediction :Group Number: 98765 :Payer ID: 87726 :RX BIN: 610279 +:RX ID: :RX GRP: UHEALTH :RX PCN: 9999 :copays: - +--------------+--------------+ - | Service Fees | Service Name | - +==============+==============+ - | 20.00 | office visit | - +--------------+--------------+ - | 300.00 | emergency | - +--------------+--------------+ - | 75.00 | urgent care | - +--------------+--------------+ - | 30.00 | specialist | - +--------------+--------------+ -:Enrollment Date: 2023-09-13 + +--------------+----------------------+ + | Service Fees | Service Name | + +==============+======================+ + | 300.00 | emergency_room | + +--------------+----------------------+ + | 20.00 | office_visit | + +--------------+----------------------+ + | 75.00 | urgent_care | + +--------------+----------------------+ + | 30.00 | specialist | + +--------------+----------------------+ +:Enrollment Date: ``` # Field Types diff --git a/docs/extras/guide/us_mail_v3.md b/docs/extras/guide/us_mail_v3.md index 241611fa..b77b4d6c 100644 --- a/docs/extras/guide/us_mail_v3.md +++ b/docs/extras/guide/us_mail_v3.md @@ -11,6 +11,11 @@ Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/mai # Quick-Start ```py +# +# Install the Python client library by running: +# pip install mindee +# + from mindee import Client, product, AsyncPredictResponse # Init a new client diff --git a/mindee/client.py b/mindee/client.py index 11c61af0..07a70219 100644 --- a/mindee/client.py +++ b/mindee/client.py @@ -561,8 +561,9 @@ def create_endpoint( version = "1" return self._build_endpoint(endpoint_name, account_name, version) + @staticmethod def source_from_path( - self, input_path: Union[Path, str], fix_pdf: bool = False + input_path: Union[Path, str], fix_pdf: bool = False ) -> PathInput: """ Load a document from an absolute path, as a string. @@ -576,9 +577,8 @@ def source_from_path( input_doc.fix_pdf() return input_doc - def source_from_file( - self, input_file: BinaryIO, fix_pdf: bool = False - ) -> FileInput: + @staticmethod + def source_from_file(input_file: BinaryIO, fix_pdf: bool = False) -> FileInput: """ Load a document from a normal Python file object/handle. @@ -591,8 +591,9 @@ def source_from_file( input_doc.fix_pdf() return input_doc + @staticmethod def source_from_b64string( - self, input_string: str, filename: str, fix_pdf: bool = False + input_string: str, filename: str, fix_pdf: bool = False ) -> Base64Input: """ Load a document from a base64 encoded string. @@ -607,8 +608,9 @@ def source_from_b64string( input_doc.fix_pdf() return input_doc + @staticmethod def source_from_bytes( - self, input_bytes: bytes, filename: str, fix_pdf: bool = False + input_bytes: bytes, filename: str, fix_pdf: bool = False ) -> BytesInput: """ Load a document from raw bytes. @@ -623,8 +625,8 @@ def source_from_bytes( input_doc.fix_pdf() return input_doc + @staticmethod def source_from_url( - self, url: str, ) -> UrlInputSource: """ diff --git a/mindee/parsing/common/execution.py b/mindee/parsing/common/execution.py index 6e3d7da5..f218656e 100644 --- a/mindee/parsing/common/execution.py +++ b/mindee/parsing/common/execution.py @@ -80,4 +80,5 @@ def parse_date(date_string: Optional[str]) -> Optional[datetime]: """Shorthand to parse the date, if present.""" if not date_string: return None + date_string = date_string.replace("Z", "+00:00") return datetime.fromisoformat(date_string) diff --git a/mindee/product/ind/indian_passport/indian_passport_v1_document.py b/mindee/product/ind/indian_passport/indian_passport_v1_document.py index 2dccd7cc..0576129f 100644 --- a/mindee/product/ind/indian_passport/indian_passport_v1_document.py +++ b/mindee/product/ind/indian_passport/indian_passport_v1_document.py @@ -182,9 +182,9 @@ def __str__(self) -> str: out_str += f":Name of Mother: {self.name_of_mother}\n" out_str += f":Old Passport Date of Issue: {self.old_passport_date_of_issue}\n" out_str += f":Old Passport Number: {self.old_passport_number}\n" + out_str += f":Old Passport Place of Issue: {self.old_passport_place_of_issue}\n" out_str += f":Address Line 1: {self.address1}\n" out_str += f":Address Line 2: {self.address2}\n" out_str += f":Address Line 3: {self.address3}\n" - out_str += f":Old Passport Place of Issue: {self.old_passport_place_of_issue}\n" out_str += f":File Number: {self.file_number}\n" return clean_out_string(out_str) diff --git a/mindee/product/international_id/international_id_v2_document.py b/mindee/product/international_id/international_id_v2_document.py index 071b0638..76e9aa2f 100644 --- a/mindee/product/international_id/international_id_v2_document.py +++ b/mindee/product/international_id/international_id_v2_document.py @@ -9,7 +9,7 @@ class InternationalIdV2Document(Prediction): - """International ID API version 2.1 document data.""" + """International ID API version 2.2 document data.""" address: StringField """The physical address of the document holder.""" diff --git a/mindee/product/invoice_splitter/invoice_splitter_v1_document.py b/mindee/product/invoice_splitter/invoice_splitter_v1_document.py index a3bbdc3e..a0e6c071 100644 --- a/mindee/product/invoice_splitter/invoice_splitter_v1_document.py +++ b/mindee/product/invoice_splitter/invoice_splitter_v1_document.py @@ -9,7 +9,7 @@ class InvoiceSplitterV1Document(Prediction): - """Invoice Splitter API version 1.2 document data.""" + """Invoice Splitter API version 1.4 document data.""" invoice_page_groups: List[InvoiceSplitterV1InvoicePageGroup] """List of page groups. Each group represents a single invoice within a multi-invoice document.""" diff --git a/tests/data b/tests/data index 0c9cfe34..2b3a6893 160000 --- a/tests/data +++ b/tests/data @@ -1 +1 @@ -Subproject commit 0c9cfe3416babad79b0689b40eb71917ab996beb +Subproject commit 2b3a68935e89d1033ae6d7e499361ae6f55cf2ab diff --git a/tests/product/ind/indian_passport/test_indian_passport_v1.py b/tests/product/ind/indian_passport/test_indian_passport_v1.py index bcdefd4b..c87fc176 100644 --- a/tests/product/ind/indian_passport/test_indian_passport_v1.py +++ b/tests/product/ind/indian_passport/test_indian_passport_v1.py @@ -59,8 +59,8 @@ def test_empty_doc(empty_doc: IndianPassportV1DocumentType): assert prediction.name_of_mother.value is None assert prediction.old_passport_date_of_issue.value is None assert prediction.old_passport_number.value is None + assert prediction.old_passport_place_of_issue.value is None assert prediction.address1.value is None assert prediction.address2.value is None assert prediction.address3.value is None - assert prediction.old_passport_place_of_issue.value is None assert prediction.file_number.value is None