mindee 3.19.1 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.rubocop.yml +2 -1
- data/CHANGELOG.md +28 -0
- data/README.md +42 -52
- data/Steepfile +31 -0
- data/bin/mindee.rb +30 -62
- data/docs/advanced_file_operations.md +111 -0
- data/docs/code_samples/bank_account_details_v1.txt +5 -0
- data/docs/code_samples/bank_account_details_v2.txt +5 -0
- data/docs/code_samples/bank_check_v1.txt +5 -0
- data/docs/code_samples/{us_driver_license_v1.txt → bank_statement_fr_v2_async.txt} +6 -1
- data/docs/code_samples/barcode_reader_v1.txt +5 -0
- data/docs/code_samples/bill_of_lading_v1_async.txt +6 -1
- data/docs/code_samples/business_card_v1_async.txt +6 -1
- data/docs/code_samples/carte_grise_v1.txt +5 -0
- data/docs/code_samples/cropper_v1.txt +5 -0
- data/docs/code_samples/default.txt +8 -2
- data/docs/code_samples/default_async.txt +7 -2
- data/docs/code_samples/delivery_notes_v1_async.txt +6 -1
- data/docs/code_samples/driver_license_v1_async.txt +6 -1
- data/docs/code_samples/energy_bill_fra_v1_async.txt +6 -1
- data/docs/code_samples/expense_receipts_v5.txt +7 -1
- data/docs/code_samples/expense_receipts_v5_async.txt +6 -1
- data/docs/code_samples/financial_document_v1.txt +7 -1
- data/docs/code_samples/financial_document_v1_async.txt +6 -1
- data/docs/code_samples/french_healthcard_v1_async.txt +6 -1
- data/docs/code_samples/idcard_fr_v1.txt +5 -0
- data/docs/code_samples/idcard_fr_v2.txt +5 -0
- data/docs/code_samples/ind_passport_v1_async.txt +6 -1
- data/docs/code_samples/international_id_v2_async.txt +6 -1
- data/docs/code_samples/invoice_splitter_v1_async.txt +6 -1
- data/docs/code_samples/invoices_v4.txt +7 -1
- data/docs/code_samples/invoices_v4_async.txt +6 -1
- data/docs/code_samples/license_plates_v1.txt +5 -0
- data/docs/code_samples/multi_receipts_detector_v1.txt +5 -0
- data/docs/code_samples/nutrition_facts_v1_async.txt +6 -1
- data/docs/code_samples/passport_v1.txt +5 -0
- data/docs/code_samples/payslip_fra_v2_async.txt +6 -1
- data/docs/code_samples/payslip_fra_v3_async.txt +6 -1
- data/docs/code_samples/resume_v1_async.txt +6 -1
- data/docs/code_samples/us_healthcare_cards_v1_async.txt +6 -1
- data/docs/code_samples/us_mail_v3_async.txt +6 -1
- data/docs/code_samples/us_w9_v1.txt +5 -0
- data/docs/getting_started.md +50 -118
- data/docs/{barcode_reader_v1.md → global_products/barcode_reader_v1.md} +26 -9
- data/docs/{bill_of_lading_v1.md → global_products/bill_of_lading_v1.md} +62 -37
- data/docs/{business_card_v1.md → global_products/business_card_v1.md} +35 -10
- data/docs/{cropper_v1.md → global_products/cropper_v1.md} +32 -13
- data/docs/{delivery_notes_v1.md → global_products/delivery_notes_v1.md} +35 -10
- data/docs/{driver_license_v1.md → global_products/driver_license_v1.md} +65 -9
- data/docs/{expense_receipts_v5.md → global_products/expense_receipts_v5.md} +57 -21
- data/docs/{financial_document_v1.md → global_products/financial_document_v1.md} +70 -33
- data/docs/{international_id_v2.md → global_products/international_id_v2.md} +39 -13
- data/docs/{invoice_splitter_v1.md → global_products/invoice_splitter_v1.md} +25 -6
- data/docs/{invoices_v4.md → global_products/invoices_v4.md} +70 -33
- data/docs/{multi_receipts_detector_v1.md → global_products/multi_receipts_detector_v1.md} +32 -13
- data/docs/{nutrition_facts_v1.md → global_products/nutrition_facts_v1.md} +103 -78
- data/docs/{passport_v1.md → global_products/passport_v1.md} +26 -9
- data/docs/{resume_v1.md → global_products/resume_v1.md} +72 -46
- data/docs/{generated_v1.md → global_products/universal.md} +39 -19
- data/docs/global_products.md +6 -0
- data/docs/loading_a_document.md +316 -0
- data/docs/{bank_account_details_v2.md → localized_products/bank_account_details_v2.md} +24 -7
- data/docs/{bank_check_v1.md → localized_products/bank_check_v1.md} +37 -18
- data/docs/localized_products/bank_statement_fr_v2.md +269 -0
- data/docs/{carte_grise_v1.md → localized_products/carte_grise_v1.md} +25 -8
- data/docs/{energy_bill_fra_v1.md → localized_products/energy_bill_fra_v1.md} +70 -45
- data/docs/{french_healthcard_v1.md → localized_products/french_healthcard_v1.md} +36 -11
- data/docs/{idcard_fr_v2.md → localized_products/idcard_fr_v2.md} +34 -16
- data/docs/{ind_passport_v1.md → localized_products/ind_passport_v1.md} +37 -11
- data/docs/{license_plates_v1.md → localized_products/license_plates_v1.md} +25 -8
- data/docs/{payslip_fra_v3.md → localized_products/payslip_fra_v3.md} +80 -55
- data/docs/{us_healthcare_cards_v1.md → localized_products/us_healthcare_cards_v1.md} +37 -12
- data/docs/{us_mail_v3.md → localized_products/us_mail_v3.md} +49 -24
- data/docs/{us_w9_v1.md → localized_products/us_w9_v1.md} +64 -45
- data/docs/localized_products.md +6 -0
- data/examples/auto_invoice_splitter_extraction.rb +5 -5
- data/examples/auto_multi_receipts_detector_extraction.rb +4 -5
- data/lib/mindee/client.rb +354 -209
- data/lib/mindee/errors/mindee_error.rb +17 -0
- data/lib/mindee/errors/mindee_http_error.rb +36 -0
- data/lib/mindee/errors/mindee_input_error.rb +30 -0
- data/lib/mindee/errors.rb +5 -0
- data/lib/mindee/extraction/multi_receipts_extractor.rb +28 -1
- data/lib/mindee/extraction.rb +0 -3
- data/lib/mindee/geometry/polygon.rb +1 -1
- data/lib/mindee/geometry/utils.rb +1 -1
- data/lib/mindee/http/endpoint.rb +48 -40
- data/lib/mindee/http/{error.rb → http_error_handler.rb} +5 -35
- data/lib/mindee/http/response_validation.rb +2 -2
- data/lib/mindee/http/workflow_endpoint.rb +12 -12
- data/lib/mindee/http.rb +1 -1
- data/lib/mindee/{extraction/common → image}/extracted_image.rb +22 -18
- data/lib/mindee/{extraction/common → image}/image_extractor.rb +20 -78
- data/lib/mindee/image/image_utils.rb +68 -7
- data/lib/mindee/image.rb +2 -0
- data/lib/mindee/input/local_response.rb +8 -8
- data/lib/mindee/input/sources/base64_input_source.rb +6 -6
- data/lib/mindee/input/sources/bytes_input_source.rb +3 -3
- data/lib/mindee/input/sources/file_input_source.rb +3 -3
- data/lib/mindee/input/sources/local_input_source.rb +43 -41
- data/lib/mindee/input/sources/path_input_source.rb +3 -3
- data/lib/mindee/input/sources/url_input_source.rb +11 -8
- data/lib/mindee/logging/logger.rb +16 -0
- data/lib/mindee/logging.rb +3 -0
- data/lib/mindee/parsing/common/api_request.rb +36 -0
- data/lib/mindee/parsing/common/api_response.rb +6 -96
- data/lib/mindee/parsing/common/document.rb +12 -8
- data/lib/mindee/parsing/common/execution.rb +4 -2
- data/lib/mindee/parsing/common/execution_priority.rb +6 -0
- data/lib/mindee/parsing/common/extras/cropper_extra.rb +2 -1
- data/lib/mindee/parsing/common/extras/extras.rb +9 -4
- data/lib/mindee/parsing/common/extras/full_text_ocr_extra.rb +1 -0
- data/lib/mindee/parsing/common/inference.rb +23 -4
- data/lib/mindee/parsing/common/job.rb +46 -0
- data/lib/mindee/parsing/common/ocr/mvision_v1.rb +6 -6
- data/lib/mindee/parsing/common/ocr/ocr.rb +29 -29
- data/lib/mindee/parsing/common/page.rb +5 -3
- data/lib/mindee/parsing/common/prediction.rb +2 -0
- data/lib/mindee/parsing/common/workflow_response.rb +28 -0
- data/lib/mindee/parsing/common.rb +3 -0
- data/lib/mindee/parsing/standard/abstract_field.rb +72 -0
- data/lib/mindee/parsing/standard/amount_field.rb +2 -2
- data/lib/mindee/parsing/standard/base_field.rb +5 -84
- data/lib/mindee/parsing/standard/boolean_field.rb +4 -3
- data/lib/mindee/parsing/standard/classification_field.rb +1 -1
- data/lib/mindee/parsing/standard/company_registration_field.rb +7 -2
- data/lib/mindee/parsing/standard/date_field.rb +2 -2
- data/lib/mindee/parsing/standard/feature_field.rb +24 -0
- data/lib/mindee/parsing/standard/payment_details_field.rb +2 -2
- data/lib/mindee/parsing/standard/position_field.rb +3 -1
- data/lib/mindee/parsing/standard/string_field.rb +1 -1
- data/lib/mindee/parsing/standard/tax_field.rb +1 -1
- data/lib/mindee/parsing/standard.rb +1 -0
- data/lib/mindee/parsing/{generated/generated_list_field.rb → universal/universal_list_field.rb} +12 -12
- data/lib/mindee/parsing/{generated/generated_object_field.rb → universal/universal_object_field.rb} +23 -14
- data/lib/mindee/parsing/universal.rb +4 -0
- data/lib/mindee/parsing.rb +1 -2
- data/lib/mindee/{extraction/pdf_extractor → pdf}/extracted_pdf.rb +15 -12
- data/lib/mindee/pdf/pdf_compressor.rb +12 -10
- data/lib/mindee/{extraction/pdf_extractor → pdf}/pdf_extractor.rb +20 -17
- data/lib/mindee/pdf/pdf_processor.rb +12 -22
- data/lib/mindee/pdf/pdf_tools.rb +52 -6
- data/lib/mindee/pdf.rb +2 -0
- data/lib/mindee/product/.rubocop.yml +3 -0
- data/lib/mindee/product/barcode_reader/barcode_reader_v1.rb +9 -3
- data/lib/mindee/product/barcode_reader/barcode_reader_v1_document.rb +5 -5
- data/lib/mindee/product/barcode_reader/barcode_reader_v1_page.rb +9 -5
- data/lib/mindee/product/bill_of_lading/bill_of_lading_v1.rb +9 -3
- data/lib/mindee/product/bill_of_lading/bill_of_lading_v1_carrier.rb +1 -1
- data/lib/mindee/product/bill_of_lading/bill_of_lading_v1_carrier_item.rb +13 -7
- data/lib/mindee/product/bill_of_lading/bill_of_lading_v1_carrier_items.rb +62 -0
- data/lib/mindee/product/bill_of_lading/bill_of_lading_v1_consignee.rb +1 -1
- data/lib/mindee/product/bill_of_lading/bill_of_lading_v1_document.rb +44 -17
- data/lib/mindee/product/bill_of_lading/bill_of_lading_v1_notify_party.rb +1 -1
- data/lib/mindee/product/bill_of_lading/bill_of_lading_v1_page.rb +9 -5
- data/lib/mindee/product/bill_of_lading/bill_of_lading_v1_shipper.rb +1 -1
- data/lib/mindee/product/business_card/business_card_v1.rb +9 -3
- data/lib/mindee/product/business_card/business_card_v1_document.rb +40 -13
- data/lib/mindee/product/business_card/business_card_v1_page.rb +9 -5
- data/lib/mindee/product/cropper/cropper_v1.rb +10 -4
- data/lib/mindee/product/cropper/cropper_v1_page.rb +11 -7
- data/lib/mindee/product/delivery_note/delivery_note_v1.rb +9 -3
- data/lib/mindee/product/delivery_note/delivery_note_v1_document.rb +29 -8
- data/lib/mindee/product/delivery_note/delivery_note_v1_page.rb +9 -5
- data/lib/mindee/product/driver_license/driver_license_v1.rb +9 -3
- data/lib/mindee/product/driver_license/driver_license_v1_document.rb +44 -14
- data/lib/mindee/product/driver_license/driver_license_v1_page.rb +9 -5
- data/lib/mindee/product/eu/license_plate/license_plate_v1.rb +9 -3
- data/lib/mindee/product/eu/license_plate/license_plate_v1_document.rb +3 -3
- data/lib/mindee/product/eu/license_plate/license_plate_v1_page.rb +9 -5
- data/lib/mindee/product/financial_document/financial_document_v1.rb +9 -3
- data/lib/mindee/product/financial_document/financial_document_v1_document.rb +110 -42
- data/lib/mindee/product/financial_document/financial_document_v1_line_item.rb +21 -11
- data/lib/mindee/product/financial_document/financial_document_v1_line_items.rb +62 -0
- data/lib/mindee/product/financial_document/financial_document_v1_page.rb +9 -5
- data/lib/mindee/product/fr/bank_account_details/bank_account_details_v1.rb +9 -3
- data/lib/mindee/product/fr/bank_account_details/bank_account_details_v1_document.rb +7 -4
- data/lib/mindee/product/fr/bank_account_details/bank_account_details_v1_page.rb +9 -5
- data/lib/mindee/product/fr/bank_account_details/bank_account_details_v2.rb +9 -3
- data/lib/mindee/product/fr/bank_account_details/bank_account_details_v2_bban.rb +1 -1
- data/lib/mindee/product/fr/bank_account_details/bank_account_details_v2_document.rb +11 -5
- data/lib/mindee/product/fr/bank_account_details/bank_account_details_v2_page.rb +9 -5
- data/lib/mindee/product/fr/bank_statement/bank_statement_v2.rb +47 -0
- data/lib/mindee/product/fr/bank_statement/{bank_statement_v1_document.rb → bank_statement_v2_document.rb} +62 -26
- data/lib/mindee/product/fr/bank_statement/bank_statement_v2_page.rb +38 -0
- data/lib/mindee/product/fr/bank_statement/{bank_statement_v1_transaction.rb → bank_statement_v2_transaction.rb} +17 -6
- data/lib/mindee/product/fr/bank_statement/bank_statement_v2_transactions.rb +54 -0
- data/lib/mindee/product/fr/carte_grise/carte_grise_v1.rb +9 -3
- data/lib/mindee/product/fr/carte_grise/carte_grise_v1_document.rb +51 -42
- data/lib/mindee/product/fr/carte_grise/carte_grise_v1_page.rb +9 -5
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1.rb +9 -3
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_document.rb +56 -30
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_energy_consumer.rb +1 -1
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_energy_supplier.rb +1 -1
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_energy_usage.rb +13 -7
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_energy_usages.rb +65 -0
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_meter_detail.rb +1 -1
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_page.rb +9 -5
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_subscription.rb +13 -7
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_subscriptions.rb +65 -0
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_taxes_and_contribution.rb +13 -7
- data/lib/mindee/product/fr/energy_bill/energy_bill_v1_taxes_and_contributions.rb +65 -0
- data/lib/mindee/product/fr/health_card/health_card_v1.rb +9 -3
- data/lib/mindee/product/fr/health_card/health_card_v1_document.rb +15 -6
- data/lib/mindee/product/fr/health_card/health_card_v1_page.rb +9 -5
- data/lib/mindee/product/fr/id_card/id_card_v1.rb +9 -3
- data/lib/mindee/product/fr/id_card/id_card_v1_document.rb +33 -12
- data/lib/mindee/product/fr/id_card/id_card_v1_page.rb +14 -7
- data/lib/mindee/product/fr/id_card/id_card_v2.rb +9 -3
- data/lib/mindee/product/fr/id_card/id_card_v2_document.rb +50 -17
- data/lib/mindee/product/fr/id_card/id_card_v2_page.rb +18 -8
- data/lib/mindee/product/fr/payslip/payslip_v2.rb +9 -3
- data/lib/mindee/product/fr/payslip/payslip_v2_bank_account_detail.rb +1 -1
- data/lib/mindee/product/fr/payslip/payslip_v2_document.rb +29 -14
- data/lib/mindee/product/fr/payslip/payslip_v2_employee.rb +1 -1
- data/lib/mindee/product/fr/payslip/payslip_v2_employer.rb +1 -1
- data/lib/mindee/product/fr/payslip/payslip_v2_employment.rb +3 -2
- data/lib/mindee/product/fr/payslip/payslip_v2_page.rb +9 -5
- data/lib/mindee/product/fr/payslip/payslip_v2_pay_detail.rb +33 -11
- data/lib/mindee/product/fr/payslip/payslip_v2_pay_period.rb +1 -1
- data/lib/mindee/product/fr/payslip/payslip_v2_pto.rb +13 -4
- data/lib/mindee/product/fr/payslip/payslip_v2_salary_detail.rb +13 -7
- data/lib/mindee/product/fr/payslip/payslip_v2_salary_details.rb +63 -0
- data/lib/mindee/product/fr/payslip/payslip_v3.rb +9 -3
- data/lib/mindee/product/fr/payslip/payslip_v3_bank_account_detail.rb +1 -1
- data/lib/mindee/product/fr/payslip/payslip_v3_document.rb +31 -19
- data/lib/mindee/product/fr/payslip/payslip_v3_employee.rb +1 -1
- data/lib/mindee/product/fr/payslip/payslip_v3_employer.rb +1 -1
- data/lib/mindee/product/fr/payslip/payslip_v3_employment.rb +1 -1
- data/lib/mindee/product/fr/payslip/payslip_v3_page.rb +9 -5
- data/lib/mindee/product/fr/payslip/payslip_v3_paid_time_off.rb +13 -7
- data/lib/mindee/product/fr/payslip/payslip_v3_paid_time_offs.rb +65 -0
- data/lib/mindee/product/fr/payslip/payslip_v3_pay_detail.rb +33 -11
- data/lib/mindee/product/fr/payslip/payslip_v3_pay_period.rb +1 -1
- data/lib/mindee/product/fr/payslip/payslip_v3_salary_detail.rb +17 -9
- data/lib/mindee/product/fr/payslip/payslip_v3_salary_details.rb +65 -0
- data/lib/mindee/product/ind/indian_passport/indian_passport_v1.rb +9 -3
- data/lib/mindee/product/ind/indian_passport/indian_passport_v1_document.rb +87 -24
- data/lib/mindee/product/ind/indian_passport/indian_passport_v1_page.rb +9 -5
- data/lib/mindee/product/international_id/international_id_v2.rb +9 -3
- data/lib/mindee/product/international_id/international_id_v2_document.rb +62 -20
- data/lib/mindee/product/international_id/international_id_v2_page.rb +9 -5
- data/lib/mindee/product/invoice/invoice_v4.rb +9 -3
- data/lib/mindee/product/invoice/invoice_v4_document.rb +90 -36
- data/lib/mindee/product/invoice/invoice_v4_line_item.rb +21 -11
- data/lib/mindee/product/invoice/invoice_v4_line_items.rb +62 -0
- data/lib/mindee/product/invoice/invoice_v4_page.rb +9 -5
- data/lib/mindee/product/invoice_splitter/invoice_splitter_v1.rb +8 -0
- data/lib/mindee/product/invoice_splitter/invoice_splitter_v1_document.rb +2 -2
- data/lib/mindee/product/invoice_splitter/invoice_splitter_v1_page.rb +1 -1
- data/lib/mindee/product/multi_receipts_detector/multi_receipts_detector_v1.rb +9 -3
- data/lib/mindee/product/multi_receipts_detector/multi_receipts_detector_v1_document.rb +3 -3
- data/lib/mindee/product/multi_receipts_detector/multi_receipts_detector_v1_page.rb +9 -5
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1.rb +9 -3
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_added_sugar.rb +7 -4
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_calorie.rb +7 -4
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_cholesterol.rb +7 -4
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_dietary_fiber.rb +7 -4
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_document.rb +58 -20
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_nutrient.rb +13 -7
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_nutrients.rb +68 -0
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_page.rb +9 -5
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_protein.rb +7 -4
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_saturated_fat.rb +7 -4
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_serving_size.rb +3 -2
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_sodium.rb +7 -4
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_total_carbohydrate.rb +7 -4
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_total_fat.rb +7 -4
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_total_sugar.rb +7 -4
- data/lib/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_trans_fat.rb +7 -4
- data/lib/mindee/product/passport/passport_v1.rb +9 -3
- data/lib/mindee/product/passport/passport_v1_document.rb +37 -13
- data/lib/mindee/product/passport/passport_v1_page.rb +9 -5
- data/lib/mindee/product/receipt/receipt_v5.rb +9 -3
- data/lib/mindee/product/receipt/receipt_v5_document.rb +54 -24
- data/lib/mindee/product/receipt/receipt_v5_line_item.rb +13 -7
- data/lib/mindee/product/receipt/receipt_v5_line_items.rb +54 -0
- data/lib/mindee/product/receipt/receipt_v5_page.rb +9 -5
- data/lib/mindee/product/resume/resume_v1.rb +9 -3
- data/lib/mindee/product/resume/resume_v1_certificate.rb +1 -1
- data/lib/mindee/product/resume/resume_v1_certificates.rb +58 -0
- data/lib/mindee/product/resume/resume_v1_document.rb +60 -47
- data/lib/mindee/product/resume/resume_v1_education.rb +1 -1
- data/lib/mindee/product/resume/resume_v1_educations.rb +64 -0
- data/lib/mindee/product/resume/resume_v1_language.rb +1 -1
- data/lib/mindee/product/resume/resume_v1_languages.rb +54 -0
- data/lib/mindee/product/resume/resume_v1_page.rb +9 -5
- data/lib/mindee/product/resume/resume_v1_professional_experience.rb +1 -1
- data/lib/mindee/product/resume/resume_v1_professional_experiences.rb +68 -0
- data/lib/mindee/product/resume/resume_v1_social_networks_url.rb +1 -1
- data/lib/mindee/product/resume/resume_v1_social_networks_urls.rb +54 -0
- data/lib/mindee/product/universal/universal.rb +46 -0
- data/lib/mindee/product/universal/universal_document.rb +32 -0
- data/lib/mindee/product/{generated/generated_v1_page.rb → universal/universal_page.rb} +14 -14
- data/lib/mindee/product/{generated/generated_v1_prediction.rb → universal/universal_prediction.rb} +32 -24
- data/lib/mindee/product/us/bank_check/bank_check_v1.rb +9 -3
- data/lib/mindee/product/us/bank_check/bank_check_v1_document.rb +20 -8
- data/lib/mindee/product/us/bank_check/bank_check_v1_page.rb +15 -8
- data/lib/mindee/product/us/healthcare_card/healthcare_card_v1.rb +9 -3
- data/lib/mindee/product/us/healthcare_card/healthcare_card_v1_copay.rb +5 -3
- data/lib/mindee/product/us/healthcare_card/healthcare_card_v1_copays.rb +52 -0
- data/lib/mindee/product/us/healthcare_card/healthcare_card_v1_document.rb +46 -19
- data/lib/mindee/product/us/healthcare_card/healthcare_card_v1_page.rb +9 -5
- data/lib/mindee/product/us/us_mail/us_mail_v3.rb +9 -3
- data/lib/mindee/product/us/us_mail/us_mail_v3_document.rb +20 -12
- data/lib/mindee/product/us/us_mail/us_mail_v3_page.rb +9 -5
- data/lib/mindee/product/us/us_mail/us_mail_v3_recipient_address.rb +2 -2
- data/lib/mindee/product/us/us_mail/us_mail_v3_recipient_addresses.rb +65 -0
- data/lib/mindee/product/us/us_mail/us_mail_v3_sender_address.rb +1 -1
- data/lib/mindee/product/us/w9/w9_v1.rb +10 -4
- data/lib/mindee/product/us/w9/w9_v1_page.rb +49 -18
- data/lib/mindee/product.rb +2 -8
- data/lib/mindee/version.rb +2 -2
- data/lib/mindee.rb +22 -9
- data/mindee.gemspec +19 -17
- data/sig/custom/marcel.rbs +3 -0
- data/sig/custom/mini_magick.rbs +24 -0
- data/sig/custom/net_http.rbs +34 -0
- data/sig/custom/origami.rbs +54 -0
- data/sig/mindee/client.rbs +63 -0
- data/sig/mindee/errors/mindee_error.rbs +13 -0
- data/sig/mindee/errors/mindee_http_error.rbs +16 -0
- data/sig/mindee/errors/mindee_input_error.rbs +17 -0
- data/sig/mindee/extraction/multi_receipts_extractor.rbs +6 -0
- data/sig/mindee/geometry/min_max.rbs +10 -0
- data/sig/mindee/geometry/point.rbs +13 -0
- data/sig/mindee/geometry/polygon.rbs +9 -0
- data/sig/mindee/geometry/quadrilateral.rbs +18 -0
- data/sig/mindee/geometry/utils.rbs +13 -0
- data/sig/mindee/http/endpoint.rbs +26 -0
- data/sig/mindee/http/http_error_handler.rbs +10 -0
- data/sig/mindee/http/response_validation.rbs +10 -0
- data/sig/mindee/http/workflow_endpoint.rbs +14 -0
- data/sig/mindee/image/extracted_image.rbs +15 -0
- data/sig/mindee/image/image_compressor.rbs +8 -0
- data/sig/mindee/image/image_extractor.rbs +13 -0
- data/sig/mindee/image/image_utils.rbs +19 -0
- data/sig/mindee/input/local_response.rbs +13 -0
- data/sig/mindee/input/sources/base64_input_source.rbs +11 -0
- data/sig/mindee/input/sources/bytes_input_source.rbs +10 -0
- data/sig/mindee/input/sources/file_input_source.rbs +10 -0
- data/sig/mindee/input/sources/local_input_source.rbs +24 -0
- data/sig/mindee/input/sources/path_input_source.rbs +10 -0
- data/sig/mindee/input/sources/url_input_source.rbs +20 -0
- data/sig/mindee/logging/logger.rbs +9 -0
- data/sig/mindee/parsing/common/api_request.rbs +15 -0
- data/sig/mindee/parsing/common/api_response.rbs +27 -0
- data/sig/mindee/parsing/common/document.rbs +20 -0
- data/sig/mindee/parsing/common/execution.rbs +23 -0
- data/sig/mindee/parsing/common/execution_file.rbs +12 -0
- data/sig/mindee/parsing/common/execution_priority.rbs +13 -0
- data/sig/mindee/parsing/common/extras/cropper_extra.rbs +14 -0
- data/sig/mindee/parsing/common/extras/extras.rbs +18 -0
- data/sig/mindee/parsing/common/extras/full_text_ocr_extra.rbs +15 -0
- data/sig/mindee/parsing/common/inference.rbs +19 -0
- data/sig/mindee/parsing/common/job.rbs +16 -0
- data/sig/mindee/parsing/common/ocr/mvision_v1.rbs +15 -0
- data/sig/mindee/parsing/common/ocr/ocr.rbs +39 -0
- data/sig/mindee/parsing/common/orientation.rbs +12 -0
- data/sig/mindee/parsing/common/page.rbs +15 -0
- data/sig/mindee/parsing/common/prediction.rbs +11 -0
- data/sig/mindee/parsing/common/product.rbs +13 -0
- data/sig/mindee/parsing/common/workflow_response.rbs +13 -0
- data/sig/mindee/parsing/standard/abstract_field.rbs +19 -0
- data/sig/mindee/parsing/standard/amount_field.rbs +12 -0
- data/sig/mindee/parsing/standard/base_field.rbs +12 -0
- data/sig/mindee/parsing/standard/boolean_field.rbs +12 -0
- data/sig/mindee/parsing/standard/classification_field.rbs +10 -0
- data/sig/mindee/parsing/standard/company_registration_field.rbs +14 -0
- data/sig/mindee/parsing/standard/date_field.rbs +14 -0
- data/sig/mindee/parsing/standard/feature_field.rbs +10 -0
- data/sig/mindee/parsing/standard/locale_field.rbs +16 -0
- data/sig/mindee/parsing/standard/payment_details_field.rbs +15 -0
- data/sig/mindee/parsing/standard/position_field.rbs +17 -0
- data/sig/mindee/parsing/standard/string_field.rbs +12 -0
- data/sig/mindee/parsing/standard/tax_field.rbs +23 -0
- data/sig/mindee/parsing/universal/universal_list_field.rbs +17 -0
- data/sig/mindee/parsing/universal/universal_object_field.rbs +23 -0
- data/sig/mindee/pdf/extracted_pdf.rbs +15 -0
- data/sig/mindee/pdf/pdf_compressor.rbs +15 -0
- data/sig/mindee/pdf/pdf_extractor.rbs +16 -0
- data/sig/mindee/pdf/pdf_processor.rbs +12 -0
- data/sig/mindee/pdf/pdf_tools.rbs +23 -0
- data/sig/mindee/product/barcode_reader/barcode_reader_v1.rbs +11 -0
- data/sig/mindee/product/barcode_reader/barcode_reader_v1_document.rbs +14 -0
- data/sig/mindee/product/barcode_reader/barcode_reader_v1_page.rbs +15 -0
- data/sig/mindee/product/bill_of_lading/bill_of_lading_v1.rbs +11 -0
- data/sig/mindee/product/bill_of_lading/bill_of_lading_v1_carrier.rbs +14 -0
- data/sig/mindee/product/bill_of_lading/bill_of_lading_v1_carrier_item.rbs +19 -0
- data/sig/mindee/product/bill_of_lading/bill_of_lading_v1_carrier_items.rbs +13 -0
- data/sig/mindee/product/bill_of_lading/bill_of_lading_v1_consignee.rbs +15 -0
- data/sig/mindee/product/bill_of_lading/bill_of_lading_v1_document.rbs +25 -0
- data/sig/mindee/product/bill_of_lading/bill_of_lading_v1_notify_party.rbs +15 -0
- data/sig/mindee/product/bill_of_lading/bill_of_lading_v1_page.rbs +15 -0
- data/sig/mindee/product/bill_of_lading/bill_of_lading_v1_shipper.rbs +15 -0
- data/sig/mindee/product/business_card/business_card_v1.rbs +11 -0
- data/sig/mindee/product/business_card/business_card_v1_document.rbs +23 -0
- data/sig/mindee/product/business_card/business_card_v1_page.rbs +15 -0
- data/sig/mindee/product/cropper/cropper_v1.rbs +11 -0
- data/sig/mindee/product/cropper/cropper_v1_document.rbs +12 -0
- data/sig/mindee/product/cropper/cropper_v1_page.rbs +16 -0
- data/sig/mindee/product/delivery_note/delivery_note_v1.rbs +11 -0
- data/sig/mindee/product/delivery_note/delivery_note_v1_document.rbs +19 -0
- data/sig/mindee/product/delivery_note/delivery_note_v1_page.rbs +15 -0
- data/sig/mindee/product/driver_license/driver_license_v1.rbs +11 -0
- data/sig/mindee/product/driver_license/driver_license_v1_document.rbs +25 -0
- data/sig/mindee/product/driver_license/driver_license_v1_page.rbs +15 -0
- data/sig/mindee/product/eu/license_plate/license_plate_v1.rbs +13 -0
- data/sig/mindee/product/eu/license_plate/license_plate_v1_document.rbs +15 -0
- data/sig/mindee/product/eu/license_plate/license_plate_v1_page.rbs +17 -0
- data/sig/mindee/product/financial_document/financial_document_v1.rbs +11 -0
- data/sig/mindee/product/financial_document/financial_document_v1_document.rbs +46 -0
- data/sig/mindee/product/financial_document/financial_document_v1_line_item.rbs +21 -0
- data/sig/mindee/product/financial_document/financial_document_v1_line_items.rbs +13 -0
- data/sig/mindee/product/financial_document/financial_document_v1_page.rbs +15 -0
- data/sig/mindee/product/fr/bank_account_details/bank_account_details_v1.rbs +13 -0
- data/sig/mindee/product/fr/bank_account_details/bank_account_details_v1_document.rbs +17 -0
- data/sig/mindee/product/fr/bank_account_details/bank_account_details_v1_page.rbs +17 -0
- data/sig/mindee/product/fr/bank_account_details/bank_account_details_v2.rbs +13 -0
- data/sig/mindee/product/fr/bank_account_details/bank_account_details_v2_bban.rbs +17 -0
- data/sig/mindee/product/fr/bank_account_details/bank_account_details_v2_document.rbs +18 -0
- data/sig/mindee/product/fr/bank_account_details/bank_account_details_v2_page.rbs +17 -0
- data/sig/mindee/product/fr/bank_statement/bank_statement_v2.rbs +13 -0
- data/sig/mindee/product/fr/bank_statement/bank_statement_v2_document.rbs +29 -0
- data/sig/mindee/product/fr/bank_statement/bank_statement_v2_page.rbs +17 -0
- data/sig/mindee/product/fr/bank_statement/bank_statement_v2_transaction.rbs +18 -0
- data/sig/mindee/product/fr/bank_statement/bank_statement_v2_transactions.rbs +15 -0
- data/sig/mindee/product/fr/carte_grise/carte_grise_v1.rbs +13 -0
- data/sig/mindee/product/fr/carte_grise/carte_grise_v1_document.rbs +55 -0
- data/sig/mindee/product/fr/carte_grise/carte_grise_v1_page.rbs +17 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1.rbs +13 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_document.rbs +34 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_energy_consumer.rbs +15 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_energy_supplier.rbs +15 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_energy_usage.rbs +21 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_energy_usages.rbs +15 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_meter_detail.rbs +16 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_page.rbs +17 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_subscription.rbs +21 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_subscriptions.rbs +15 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_taxes_and_contribution.rbs +21 -0
- data/sig/mindee/product/fr/energy_bill/energy_bill_v1_taxes_and_contributions.rbs +15 -0
- data/sig/mindee/product/fr/health_card/health_card_v1.rbs +13 -0
- data/sig/mindee/product/fr/health_card/health_card_v1_document.rbs +18 -0
- data/sig/mindee/product/fr/health_card/health_card_v1_page.rbs +17 -0
- data/sig/mindee/product/fr/id_card/id_card_v1.rbs +13 -0
- data/sig/mindee/product/fr/id_card/id_card_v1_document.rbs +24 -0
- data/sig/mindee/product/fr/id_card/id_card_v1_page.rbs +18 -0
- data/sig/mindee/product/fr/id_card/id_card_v2.rbs +13 -0
- data/sig/mindee/product/fr/id_card/id_card_v2_document.rbs +29 -0
- data/sig/mindee/product/fr/id_card/id_card_v2_page.rbs +19 -0
- data/sig/mindee/product/fr/payslip/payslip_v2.rbs +13 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_bank_account_detail.rbs +16 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_document.rbs +24 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_employee.rbs +20 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_employer.rbs +20 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_employment.rbs +19 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_page.rbs +17 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_pay_detail.rbs +23 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_pay_period.rbs +18 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_pto.rbs +16 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_salary_detail.rbs +19 -0
- data/sig/mindee/product/fr/payslip/payslip_v2_salary_details.rbs +15 -0
- data/sig/mindee/product/fr/payslip/payslip_v3.rbs +13 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_bank_account_detail.rbs +16 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_document.rbs +26 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_employee.rbs +20 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_employer.rbs +20 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_employment.rbs +20 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_page.rbs +17 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_paid_time_off.rbs +20 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_paid_time_offs.rbs +15 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_pay_detail.rbs +23 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_pay_period.rbs +18 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_salary_detail.rbs +20 -0
- data/sig/mindee/product/fr/payslip/payslip_v3_salary_details.rbs +15 -0
- data/sig/mindee/product/ind/indian_passport/indian_passport_v1.rbs +13 -0
- data/sig/mindee/product/ind/indian_passport/indian_passport_v1_document.rbs +37 -0
- data/sig/mindee/product/ind/indian_passport/indian_passport_v1_page.rbs +17 -0
- data/sig/mindee/product/international_id/international_id_v2.rbs +11 -0
- data/sig/mindee/product/international_id/international_id_v2_document.rbs +29 -0
- data/sig/mindee/product/international_id/international_id_v2_page.rbs +15 -0
- data/sig/mindee/product/invoice/invoice_v4.rbs +11 -0
- data/sig/mindee/product/invoice/invoice_v4_document.rbs +40 -0
- data/sig/mindee/product/invoice/invoice_v4_line_item.rbs +21 -0
- data/sig/mindee/product/invoice/invoice_v4_line_items.rbs +13 -0
- data/sig/mindee/product/invoice/invoice_v4_page.rbs +15 -0
- data/sig/mindee/product/invoice_splitter/invoice_splitter_v1.rbs +14 -0
- data/sig/mindee/product/invoice_splitter/invoice_splitter_v1_document.rbs +19 -0
- data/sig/mindee/product/invoice_splitter/invoice_splitter_v1_page.rbs +13 -0
- data/sig/mindee/product/multi_receipts_detector/multi_receipts_detector_v1.rbs +11 -0
- data/sig/mindee/product/multi_receipts_detector/multi_receipts_detector_v1_document.rbs +13 -0
- data/sig/mindee/product/multi_receipts_detector/multi_receipts_detector_v1_page.rbs +15 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1.rbs +11 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_added_sugar.rbs +14 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_calorie.rbs +14 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_cholesterol.rbs +14 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_dietary_fiber.rbs +14 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_document.rbs +28 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_nutrient.rbs +18 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_nutrients.rbs +13 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_page.rbs +15 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_protein.rbs +14 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_saturated_fat.rbs +14 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_serving_size.rbs +13 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_sodium.rbs +15 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_total_carbohydrate.rbs +14 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_total_fat.rbs +14 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_total_sugar.rbs +14 -0
- data/sig/mindee/product/nutrition_facts_label/nutrition_facts_label_v1_trans_fat.rbs +14 -0
- data/sig/mindee/product/passport/passport_v1.rbs +11 -0
- data/sig/mindee/product/passport/passport_v1_document.rbs +23 -0
- data/sig/mindee/product/passport/passport_v1_page.rbs +15 -0
- data/sig/mindee/product/receipt/receipt_v5.rbs +11 -0
- data/sig/mindee/product/receipt/receipt_v5_document.rbs +31 -0
- data/sig/mindee/product/receipt/receipt_v5_line_item.rbs +17 -0
- data/sig/mindee/product/receipt/receipt_v5_line_items.rbs +13 -0
- data/sig/mindee/product/receipt/receipt_v5_page.rbs +15 -0
- data/sig/mindee/product/resume/resume_v1.rbs +11 -0
- data/sig/mindee/product/resume/resume_v1_certificate.rbs +17 -0
- data/sig/mindee/product/resume/resume_v1_certificates.rbs +13 -0
- data/sig/mindee/product/resume/resume_v1_document.rbs +39 -0
- data/sig/mindee/product/resume/resume_v1_education.rbs +20 -0
- data/sig/mindee/product/resume/resume_v1_educations.rbs +13 -0
- data/sig/mindee/product/resume/resume_v1_language.rbs +15 -0
- data/sig/mindee/product/resume/resume_v1_languages.rbs +13 -0
- data/sig/mindee/product/resume/resume_v1_page.rbs +15 -0
- data/sig/mindee/product/resume/resume_v1_professional_experience.rbs +22 -0
- data/sig/mindee/product/resume/resume_v1_professional_experiences.rbs +13 -0
- data/sig/mindee/product/resume/resume_v1_social_networks_url.rbs +15 -0
- data/sig/mindee/product/resume/resume_v1_social_networks_urls.rbs +13 -0
- data/sig/mindee/product/universal/universal.rbs +14 -0
- data/sig/mindee/product/universal/universal_document.rbs +10 -0
- data/sig/mindee/product/universal/universal_page.rbs +14 -0
- data/sig/mindee/product/universal/universal_prediction.rbs +19 -0
- data/sig/mindee/product/us/bank_check/bank_check_v1.rbs +13 -0
- data/sig/mindee/product/us/bank_check/bank_check_v1_document.rbs +20 -0
- data/sig/mindee/product/us/bank_check/bank_check_v1_page.rbs +19 -0
- data/sig/mindee/product/us/healthcare_card/healthcare_card_v1.rbs +13 -0
- data/sig/mindee/product/us/healthcare_card/healthcare_card_v1_copay.rbs +17 -0
- data/sig/mindee/product/us/healthcare_card/healthcare_card_v1_copays.rbs +15 -0
- data/sig/mindee/product/us/healthcare_card/healthcare_card_v1_document.rbs +28 -0
- data/sig/mindee/product/us/healthcare_card/healthcare_card_v1_page.rbs +17 -0
- data/sig/mindee/product/us/us_mail/us_mail_v3.rbs +13 -0
- data/sig/mindee/product/us/us_mail/us_mail_v3_document.rbs +21 -0
- data/sig/mindee/product/us/us_mail/us_mail_v3_page.rbs +17 -0
- data/sig/mindee/product/us/us_mail/us_mail_v3_recipient_address.rbs +23 -0
- data/sig/mindee/product/us/us_mail/us_mail_v3_recipient_addresses.rbs +15 -0
- data/sig/mindee/product/us/us_mail/us_mail_v3_sender_address.rbs +18 -0
- data/sig/mindee/product/us/w9/w9_v1.rbs +13 -0
- data/sig/mindee/product/us/w9/w9_v1_document.rbs +14 -0
- data/sig/mindee/product/us/w9/w9_v1_page.rbs +29 -0
- data/sig/mindee/version.rbs +6 -0
- data/sig/mindee.rbs +59 -0
- metadata +395 -103
- data/docs/bank_statement_fr_v1.md +0 -178
- data/docs/code_samples/bank_statement_fr_v1_async.txt +0 -19
- data/docs/code_samples/custom_v1.txt +0 -33
- data/docs/code_samples/eu_driver_license_v1.txt +0 -19
- data/docs/code_samples/expense_receipts_v4.txt +0 -19
- data/docs/code_samples/proof_of_address_v1.txt +0 -19
- data/docs/code_samples/us_mail_v2_async.txt +0 -19
- data/docs/code_samples/workflow_execution.txt +0 -29
- data/docs/custom_v1.md +0 -111
- data/docs/payslip_fra_v2.md +0 -294
- data/lib/mindee/extraction/common.rb +0 -4
- data/lib/mindee/extraction/multi_receipts_extractor/multi_receipts_extractor.rb +0 -32
- data/lib/mindee/extraction/pdf_extractor.rb +0 -4
- data/lib/mindee/extraction/tax_extractor/ocr_extractor.rb +0 -110
- data/lib/mindee/extraction/tax_extractor/tax_extractor.rb +0 -338
- data/lib/mindee/extraction/tax_extractor.rb +0 -3
- data/lib/mindee/parsing/custom/classification_field.rb +0 -28
- data/lib/mindee/parsing/custom/list_field.rb +0 -78
- data/lib/mindee/parsing/custom.rb +0 -4
- data/lib/mindee/parsing/generated.rb +0 -4
- data/lib/mindee/product/custom/custom_v1.rb +0 -36
- data/lib/mindee/product/custom/custom_v1_document.rb +0 -60
- data/lib/mindee/product/custom/custom_v1_page.rb +0 -32
- data/lib/mindee/product/eu/driver_license/driver_license_v1.rb +0 -41
- data/lib/mindee/product/eu/driver_license/driver_license_v1_document.rb +0 -88
- data/lib/mindee/product/eu/driver_license/driver_license_v1_page.rb +0 -53
- data/lib/mindee/product/fr/bank_statement/bank_statement_v1.rb +0 -41
- data/lib/mindee/product/fr/bank_statement/bank_statement_v1_page.rb +0 -34
- data/lib/mindee/product/generated/generated_v1.rb +0 -38
- data/lib/mindee/product/generated/generated_v1_document.rb +0 -35
- data/lib/mindee/product/proof_of_address/proof_of_address_v1.rb +0 -39
- data/lib/mindee/product/proof_of_address/proof_of_address_v1_document.rb +0 -83
- data/lib/mindee/product/proof_of_address/proof_of_address_v1_page.rb +0 -32
- data/lib/mindee/product/receipt/receipt_v4.rb +0 -36
- data/lib/mindee/product/receipt/receipt_v4_document.rb +0 -86
- data/lib/mindee/product/receipt/receipt_v4_page.rb +0 -32
- data/lib/mindee/product/us/driver_license/driver_license_v1.rb +0 -41
- data/lib/mindee/product/us/driver_license/driver_license_v1_document.rb +0 -113
- data/lib/mindee/product/us/driver_license/driver_license_v1_page.rb +0 -53
- data/lib/mindee/product/us/us_mail/us_mail_v2.rb +0 -41
- data/lib/mindee/product/us/us_mail/us_mail_v2_document.rb +0 -100
- data/lib/mindee/product/us/us_mail/us_mail_v2_page.rb +0 -34
- data/lib/mindee/product/us/us_mail/us_mail_v2_recipient_address.rb +0 -105
- data/lib/mindee/product/us/us_mail/us_mail_v2_sender_address.rb +0 -66
@@ -0,0 +1,269 @@
|
|
1
|
+
---
|
2
|
+
title: Ruby Client Library - FR Bank Statement
|
3
|
+
category: 622b805aaec68102ea7fcbc2
|
4
|
+
slug: ruby-fr-bank-statement-ocr
|
5
|
+
parentDoc: 67b49e29a2cd6f08d69a40d8
|
6
|
+
---
|
7
|
+
The Ruby Client Library supports the [Bank Statement API](https://platform.mindee.com/mindee/bank_statement_fr).
|
8
|
+
|
9
|
+
|
10
|
+
> 📝 Product Specs
|
11
|
+
>
|
12
|
+
> | Specification | Details |
|
13
|
+
> | ------------------------------ | -------------------------------------------------- |
|
14
|
+
> | Endpoint Name | `bank_statement_fr` |
|
15
|
+
> | Recommended Version | `v2.0` |
|
16
|
+
> | Supports Polling/Webhooks | ✔️ Yes |
|
17
|
+
> | Support Synchronous HTTP Calls | ❌ No |
|
18
|
+
> | Geography | 🇫🇷 France |
|
19
|
+
|
20
|
+
> 🔐 Polling Limitations
|
21
|
+
>
|
22
|
+
> | Setting | Parameter name | Default Value |
|
23
|
+
> | ------------------------------- | ----------------------- | ------------- |
|
24
|
+
> | Initial Delay Before Polling | `initial_delay_seconds` | 2 seconds |
|
25
|
+
> | Default Delay Between Calls | `delay_sec` | 1.5 seconds |
|
26
|
+
> | Polling Attempts Before Timeout | `max_retries` | 80 retries |
|
27
|
+
|
28
|
+
|
29
|
+
Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/main/products/bank_statement_fr/default_sample.jpg),
|
30
|
+
we are going to illustrate how to extract the data that we want using the Ruby Client Library.
|
31
|
+

|
32
|
+
|
33
|
+
# Quick-Start
|
34
|
+
```rb
|
35
|
+
#
|
36
|
+
# Install the Ruby client library by running:
|
37
|
+
# gem install mindee
|
38
|
+
#
|
39
|
+
|
40
|
+
require 'mindee'
|
41
|
+
|
42
|
+
# Init a new client
|
43
|
+
mindee_client = Mindee::Client.new(api_key: 'my-api-key')
|
44
|
+
|
45
|
+
# Load a file from disk
|
46
|
+
input_source = mindee_client.source_from_path('/path/to/the/file.ext')
|
47
|
+
|
48
|
+
# Parse the file
|
49
|
+
result = mindee_client.parse(
|
50
|
+
input_source,
|
51
|
+
Mindee::Product::FR::BankStatement::BankStatementV2
|
52
|
+
)
|
53
|
+
|
54
|
+
# Print a full summary of the parsed data in RST format
|
55
|
+
puts result.document
|
56
|
+
|
57
|
+
# Print the document-level parsed data
|
58
|
+
# puts result.document.inference.prediction
|
59
|
+
```
|
60
|
+
|
61
|
+
**Output (RST):**
|
62
|
+
```rst
|
63
|
+
########
|
64
|
+
Document
|
65
|
+
########
|
66
|
+
:Mindee ID: 3c1811c0-9876-45ae-91ad-c2e9cd75dd83
|
67
|
+
:Filename: default_sample.jpg
|
68
|
+
|
69
|
+
Inference
|
70
|
+
#########
|
71
|
+
:Product: mindee/bank_statement_fr v2.0
|
72
|
+
:Rotation applied: Yes
|
73
|
+
|
74
|
+
Prediction
|
75
|
+
==========
|
76
|
+
:Account Number: XXXXXXXXXXXXXX
|
77
|
+
:Bank Name: Banque lafinancepourtous
|
78
|
+
:Bank Address: 1 rue de la Banque, 100210 Cassette
|
79
|
+
:Client Names: Karine Plume
|
80
|
+
:Client Address: 1 rue des Cigales, 100210 Cassette
|
81
|
+
:Statement Date: 2002-02-28
|
82
|
+
:Statement Start Date: 2002-02-01
|
83
|
+
:Statement End Date: 2002-02-28
|
84
|
+
:Opening Balance: 22.15
|
85
|
+
:Closing Balance: -278.96
|
86
|
+
:Transactions:
|
87
|
+
+------------+------------+--------------------------------------+
|
88
|
+
| Amount | Date | Description |
|
89
|
+
+============+============+======================================+
|
90
|
+
| 1240.00 | 2002-02-01 | Virement salaire |
|
91
|
+
+------------+------------+--------------------------------------+
|
92
|
+
| -520.00 | 2002-02-02 | Virement loyer |
|
93
|
+
+------------+------------+--------------------------------------+
|
94
|
+
| -312.00 | 2002-02-03 | Débit Carte nºxxxx |
|
95
|
+
+------------+------------+--------------------------------------+
|
96
|
+
| 12.47 | 2002-02-04 | Virement CPAM |
|
97
|
+
+------------+------------+--------------------------------------+
|
98
|
+
| 65.00 | 2002-02-05 | Virement APL |
|
99
|
+
+------------+------------+--------------------------------------+
|
100
|
+
| -110.00 | 2002-02-07 | Débit Carte nxxxxxxxxxxxxxxxx |
|
101
|
+
+------------+------------+--------------------------------------+
|
102
|
+
| -3.30 | 2002-02-08 | Cotisation mensuelle carte bancaire |
|
103
|
+
+------------+------------+--------------------------------------+
|
104
|
+
| -120.00 | 2002-02-09 | Chèque n° xxxxxx98 |
|
105
|
+
+------------+------------+--------------------------------------+
|
106
|
+
| -60.00 | 2002-02-09 | Retrait espèces DAB |
|
107
|
+
+------------+------------+--------------------------------------+
|
108
|
+
| -55.00 | 2002-02-15 | Chèque n° xxxxxx99 |
|
109
|
+
+------------+------------+--------------------------------------+
|
110
|
+
| -80.00 | 2002-02-16 | Prélèvement supercrédit |
|
111
|
+
+------------+------------+--------------------------------------+
|
112
|
+
| -120.00 | 2002-02-17 | Chèque n° xxxxx 100 |
|
113
|
+
+------------+------------+--------------------------------------+
|
114
|
+
| -163.25 | 2002-02-20 | Débit Carte nºxxxxxxxxxxxxx |
|
115
|
+
+------------+------------+--------------------------------------+
|
116
|
+
| -25.50 | 2002-02-21 | Débit Carte n°xxxxxxxxxxxxxxxxxx |
|
117
|
+
+------------+------------+--------------------------------------+
|
118
|
+
| -30.00 | 2002-02-24 | Prélèvement Opérateur téléphonique |
|
119
|
+
+------------+------------+--------------------------------------+
|
120
|
+
| -6.53 | 2002-02-25 | Agios |
|
121
|
+
+------------+------------+--------------------------------------+
|
122
|
+
| -13.00 | 2002-02-28 | Frais irrégularités et incidents ... |
|
123
|
+
+------------+------------+--------------------------------------+
|
124
|
+
:Total Debits: 1618.58
|
125
|
+
:Total Credits: 1339.62
|
126
|
+
```
|
127
|
+
|
128
|
+
# Field Types
|
129
|
+
## Standard Fields
|
130
|
+
These fields are generic and used in several products.
|
131
|
+
|
132
|
+
### Basic Field
|
133
|
+
Each prediction object contains a set of fields that inherit from the generic `Field` class.
|
134
|
+
A typical `Field` object will have the following attributes:
|
135
|
+
|
136
|
+
* **value** (`String`, `Float`, `Integer`, `bool`): corresponds to the field value. Can be `nil` if no value was extracted.
|
137
|
+
* **confidence** (Float, nil): the confidence score of the field prediction.
|
138
|
+
* **bounding_box** (`Mindee::Geometry::Quadrilateral`, `nil`): contains exactly 4 relative vertices (points) coordinates of a right rectangle containing the field in the document.
|
139
|
+
* **polygon** (`Mindee::Geometry::Polygon`, `nil`): contains the relative vertices coordinates (`Point`) of a polygon containing the field in the image.
|
140
|
+
* **page_id** (`Integer`, `nil`): the ID of the page, always `nil` when at document-level.
|
141
|
+
* **reconstructed** (`bool`): indicates whether an object was reconstructed (not extracted as the API gave it).
|
142
|
+
|
143
|
+
|
144
|
+
Aside from the previous attributes, all basic fields have access to a `to_s` method that can be used to print their value as a string.
|
145
|
+
|
146
|
+
|
147
|
+
### Amount Field
|
148
|
+
The amount field `AmountField` only has one constraint: its **value** is a `Float` (or `nil`).
|
149
|
+
|
150
|
+
### Date Field
|
151
|
+
Aside from the basic `Field` attributes, the date field `DateField` also implements the following:
|
152
|
+
|
153
|
+
* **date_object** (`Date`): an accessible representation of the value as a JavaScript object.
|
154
|
+
|
155
|
+
### String Field
|
156
|
+
The text field `StringField` only has one constraint: it's **value** is a `String` (or `nil`).
|
157
|
+
|
158
|
+
## Specific Fields
|
159
|
+
Fields which are specific to this product; they are not used in any other product.
|
160
|
+
|
161
|
+
### Transactions Field
|
162
|
+
The list of values that represent the financial transactions recorded in a bank statement.
|
163
|
+
|
164
|
+
A `BankStatementV2Transaction` implements the following attributes:
|
165
|
+
|
166
|
+
* `amount` (Float): The monetary amount of the transaction.
|
167
|
+
* `date` (String): The date on which the transaction occurred.
|
168
|
+
* `description` (String): The additional information about the transaction.
|
169
|
+
|
170
|
+
# Attributes
|
171
|
+
The following fields are extracted for Bank Statement V2:
|
172
|
+
|
173
|
+
## Account Number
|
174
|
+
**account_number** ([StringField](#string-field)): The unique identifier for a customer's account in the bank's system.
|
175
|
+
|
176
|
+
```rb
|
177
|
+
puts result.document.inference.prediction.account_number.value
|
178
|
+
```
|
179
|
+
|
180
|
+
## Bank Address
|
181
|
+
**bank_address** ([StringField](#string-field)): The physical location of the bank where the statement was issued.
|
182
|
+
|
183
|
+
```rb
|
184
|
+
puts result.document.inference.prediction.bank_address.value
|
185
|
+
```
|
186
|
+
|
187
|
+
## Bank Name
|
188
|
+
**bank_name** ([StringField](#string-field)): The name of the bank that issued the statement.
|
189
|
+
|
190
|
+
```rb
|
191
|
+
puts result.document.inference.prediction.bank_name.value
|
192
|
+
```
|
193
|
+
|
194
|
+
## Client Address
|
195
|
+
**client_address** ([StringField](#string-field)): The address of the client associated with the bank statement.
|
196
|
+
|
197
|
+
```rb
|
198
|
+
puts result.document.inference.prediction.client_address.value
|
199
|
+
```
|
200
|
+
|
201
|
+
## Client Names
|
202
|
+
**client_names** (Array<[StringField](#string-field)>): The name of the clients who own the bank statement.
|
203
|
+
|
204
|
+
```rb
|
205
|
+
result.document.inference.prediction.client_names do |client_names_elem|
|
206
|
+
puts client_names_elem.value
|
207
|
+
end
|
208
|
+
```
|
209
|
+
|
210
|
+
## Closing Balance
|
211
|
+
**closing_balance** ([AmountField](#amount-field)): The final amount of money in the account at the end of the statement period.
|
212
|
+
|
213
|
+
```rb
|
214
|
+
puts result.document.inference.prediction.closing_balance.value
|
215
|
+
```
|
216
|
+
|
217
|
+
## Opening Balance
|
218
|
+
**opening_balance** ([AmountField](#amount-field)): The initial amount of money in an account at the start of the period.
|
219
|
+
|
220
|
+
```rb
|
221
|
+
puts result.document.inference.prediction.opening_balance.value
|
222
|
+
```
|
223
|
+
|
224
|
+
## Statement Date
|
225
|
+
**statement_date** ([DateField](#date-field)): The date on which the bank statement was generated.
|
226
|
+
|
227
|
+
```rb
|
228
|
+
puts result.document.inference.prediction.statement_date.value
|
229
|
+
```
|
230
|
+
|
231
|
+
## Statement End Date
|
232
|
+
**statement_end_date** ([DateField](#date-field)): The date when the statement period ends.
|
233
|
+
|
234
|
+
```rb
|
235
|
+
puts result.document.inference.prediction.statement_end_date.value
|
236
|
+
```
|
237
|
+
|
238
|
+
## Statement Start Date
|
239
|
+
**statement_start_date** ([DateField](#date-field)): The date when the bank statement period begins.
|
240
|
+
|
241
|
+
```rb
|
242
|
+
puts result.document.inference.prediction.statement_start_date.value
|
243
|
+
```
|
244
|
+
|
245
|
+
## Total Credits
|
246
|
+
**total_credits** ([AmountField](#amount-field)): The total amount of money deposited into the account.
|
247
|
+
|
248
|
+
```rb
|
249
|
+
puts result.document.inference.prediction.total_credits.value
|
250
|
+
```
|
251
|
+
|
252
|
+
## Total Debits
|
253
|
+
**total_debits** ([AmountField](#amount-field)): The total amount of money debited from the account.
|
254
|
+
|
255
|
+
```rb
|
256
|
+
puts result.document.inference.prediction.total_debits.value
|
257
|
+
```
|
258
|
+
|
259
|
+
## Transactions
|
260
|
+
**transactions** (Array<[BankStatementV2Transaction](#transactions-field)>): The list of values that represent the financial transactions recorded in a bank statement.
|
261
|
+
|
262
|
+
```rb
|
263
|
+
result.document.inference.prediction.transactions do |transactions_elem|
|
264
|
+
puts transactions_elem.value
|
265
|
+
end
|
266
|
+
```
|
267
|
+
|
268
|
+
# Questions?
|
269
|
+
[Join our Slack](https://join.slack.com/t/mindee-community/shared_invite/zt-2d0ds7dtz-DPAF81ZqTy20chsYpQBW5g)
|
@@ -1,16 +1,34 @@
|
|
1
1
|
---
|
2
|
-
title: FR Carte Grise
|
2
|
+
title: Ruby Client Library - FR Carte Grise
|
3
3
|
category: 622b805aaec68102ea7fcbc2
|
4
4
|
slug: ruby-fr-carte-grise-ocr
|
5
|
-
parentDoc:
|
5
|
+
parentDoc: 67b49e29a2cd6f08d69a40d8
|
6
6
|
---
|
7
|
-
The Ruby
|
7
|
+
The Ruby Client Library supports the [Carte Grise API](https://platform.mindee.com/mindee/carte_grise).
|
8
8
|
|
9
|
-
|
9
|
+
|
10
|
+
> 📝 Product Specs
|
11
|
+
>
|
12
|
+
> | Specification | Details |
|
13
|
+
> | ------------------------------ | -------------------------------------------------- |
|
14
|
+
> | Endpoint Name | `carte_grise` |
|
15
|
+
> | Recommended Version | `v1.1` |
|
16
|
+
> | Supports Polling/Webhooks | ❌ No |
|
17
|
+
> | Support Synchronous HTTP Calls | ✔️ Yes |
|
18
|
+
> | Geography | 🇫🇷 France |
|
19
|
+
|
20
|
+
|
21
|
+
Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/main/products/carte_grise/default_sample.jpg),
|
22
|
+
we are going to illustrate how to extract the data that we want using the Ruby Client Library.
|
10
23
|

|
11
24
|
|
12
25
|
# Quick-Start
|
13
26
|
```rb
|
27
|
+
#
|
28
|
+
# Install the Ruby client library by running:
|
29
|
+
# gem install mindee
|
30
|
+
#
|
31
|
+
|
14
32
|
require 'mindee'
|
15
33
|
|
16
34
|
# Init a new client
|
@@ -30,7 +48,6 @@ puts result.document
|
|
30
48
|
|
31
49
|
# Print the document-level parsed data
|
32
50
|
# puts result.document.inference.prediction
|
33
|
-
|
34
51
|
```
|
35
52
|
|
36
53
|
**Output (RST):**
|
@@ -146,18 +163,18 @@ These fields are generic and used in several products.
|
|
146
163
|
Each prediction object contains a set of fields that inherit from the generic `Field` class.
|
147
164
|
A typical `Field` object will have the following attributes:
|
148
165
|
|
149
|
-
* **value** (`String`, `Float`, `Integer`, `
|
166
|
+
* **value** (`String`, `Float`, `Integer`, `bool`): corresponds to the field value. Can be `nil` if no value was extracted.
|
150
167
|
* **confidence** (Float, nil): the confidence score of the field prediction.
|
151
168
|
* **bounding_box** (`Mindee::Geometry::Quadrilateral`, `nil`): contains exactly 4 relative vertices (points) coordinates of a right rectangle containing the field in the document.
|
152
169
|
* **polygon** (`Mindee::Geometry::Polygon`, `nil`): contains the relative vertices coordinates (`Point`) of a polygon containing the field in the image.
|
153
170
|
* **page_id** (`Integer`, `nil`): the ID of the page, always `nil` when at document-level.
|
154
|
-
* **reconstructed** (`
|
171
|
+
* **reconstructed** (`bool`): indicates whether an object was reconstructed (not extracted as the API gave it).
|
155
172
|
|
156
173
|
|
157
174
|
Aside from the previous attributes, all basic fields have access to a `to_s` method that can be used to print their value as a string.
|
158
175
|
|
159
176
|
### Date Field
|
160
|
-
Aside from the basic `Field` attributes, the date field `DateField` also implements the following:
|
177
|
+
Aside from the basic `Field` attributes, the date field `DateField` also implements the following:
|
161
178
|
|
162
179
|
* **date_object** (`Date`): an accessible representation of the value as a JavaScript object.
|
163
180
|
|
@@ -1,16 +1,42 @@
|
|
1
1
|
---
|
2
|
-
title: FR Energy Bill
|
2
|
+
title: Ruby Client Library - FR Energy Bill
|
3
3
|
category: 622b805aaec68102ea7fcbc2
|
4
4
|
slug: ruby-fr-energy-bill-ocr
|
5
|
-
parentDoc:
|
5
|
+
parentDoc: 67b49e29a2cd6f08d69a40d8
|
6
6
|
---
|
7
|
-
The Ruby
|
8
|
-
|
9
|
-
|
7
|
+
The Ruby Client Library supports the [Energy Bill API](https://platform.mindee.com/mindee/energy_bill_fra).
|
8
|
+
|
9
|
+
|
10
|
+
> 📝 Product Specs
|
11
|
+
>
|
12
|
+
> | Specification | Details |
|
13
|
+
> | ------------------------------ | -------------------------------------------------- |
|
14
|
+
> | Endpoint Name | `energy_bill_fra` |
|
15
|
+
> | Recommended Version | `v1.0` |
|
16
|
+
> | Supports Polling/Webhooks | ✔️ Yes |
|
17
|
+
> | Support Synchronous HTTP Calls | ❌ No |
|
18
|
+
> | Geography | 🇫🇷 France |
|
19
|
+
|
20
|
+
> 🔐 Polling Limitations
|
21
|
+
>
|
22
|
+
> | Setting | Parameter name | Default Value |
|
23
|
+
> | ------------------------------- | ----------------------- | ------------- |
|
24
|
+
> | Initial Delay Before Polling | `initial_delay_seconds` | 2 seconds |
|
25
|
+
> | Default Delay Between Calls | `delay_sec` | 1.5 seconds |
|
26
|
+
> | Polling Attempts Before Timeout | `max_retries` | 80 retries |
|
27
|
+
|
28
|
+
|
29
|
+
Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/main/products/energy_bill_fra/default_sample.pdf),
|
30
|
+
we are going to illustrate how to extract the data that we want using the Ruby Client Library.
|
10
31
|

|
11
32
|
|
12
33
|
# Quick-Start
|
13
34
|
```rb
|
35
|
+
#
|
36
|
+
# Install the Ruby client library by running:
|
37
|
+
# gem install mindee
|
38
|
+
#
|
39
|
+
|
14
40
|
require 'mindee'
|
15
41
|
|
16
42
|
# Init a new client
|
@@ -20,7 +46,7 @@ mindee_client = Mindee::Client.new(api_key: 'my-api-key')
|
|
20
46
|
input_source = mindee_client.source_from_path('/path/to/the/file.ext')
|
21
47
|
|
22
48
|
# Parse the file
|
23
|
-
result = mindee_client.
|
49
|
+
result = mindee_client.parse(
|
24
50
|
input_source,
|
25
51
|
Mindee::Product::FR::EnergyBill::EnergyBillV1
|
26
52
|
)
|
@@ -30,7 +56,6 @@ puts result.document
|
|
30
56
|
|
31
57
|
# Print the document-level parsed data
|
32
58
|
# puts result.document.inference.prediction
|
33
|
-
|
34
59
|
```
|
35
60
|
|
36
61
|
**Output (RST):**
|
@@ -100,12 +125,12 @@ These fields are generic and used in several products.
|
|
100
125
|
Each prediction object contains a set of fields that inherit from the generic `Field` class.
|
101
126
|
A typical `Field` object will have the following attributes:
|
102
127
|
|
103
|
-
* **value** (`String`, `Float`, `Integer`, `
|
128
|
+
* **value** (`String`, `Float`, `Integer`, `bool`): corresponds to the field value. Can be `nil` if no value was extracted.
|
104
129
|
* **confidence** (Float, nil): the confidence score of the field prediction.
|
105
130
|
* **bounding_box** (`Mindee::Geometry::Quadrilateral`, `nil`): contains exactly 4 relative vertices (points) coordinates of a right rectangle containing the field in the document.
|
106
131
|
* **polygon** (`Mindee::Geometry::Polygon`, `nil`): contains the relative vertices coordinates (`Point`) of a polygon containing the field in the image.
|
107
132
|
* **page_id** (`Integer`, `nil`): the ID of the page, always `nil` when at document-level.
|
108
|
-
* **reconstructed** (`
|
133
|
+
* **reconstructed** (`bool`): indicates whether an object was reconstructed (not extracted as the API gave it).
|
109
134
|
|
110
135
|
|
111
136
|
Aside from the previous attributes, all basic fields have access to a `to_s` method that can be used to print their value as a string.
|
@@ -115,7 +140,7 @@ Aside from the previous attributes, all basic fields have access to a `to_s` met
|
|
115
140
|
The amount field `AmountField` only has one constraint: its **value** is a `Float` (or `nil`).
|
116
141
|
|
117
142
|
### Date Field
|
118
|
-
Aside from the basic `Field` attributes, the date field `DateField` also implements the following:
|
143
|
+
Aside from the basic `Field` attributes, the date field `DateField` also implements the following:
|
119
144
|
|
120
145
|
* **date_object** (`Date`): an accessible representation of the value as a JavaScript object.
|
121
146
|
|
@@ -125,6 +150,15 @@ The text field `StringField` only has one constraint: it's **value** is a `Strin
|
|
125
150
|
## Specific Fields
|
126
151
|
Fields which are specific to this product; they are not used in any other product.
|
127
152
|
|
153
|
+
### Energy Supplier Field
|
154
|
+
The company that supplies the energy.
|
155
|
+
|
156
|
+
A `EnergyBillV1EnergySupplier` implements the following attributes:
|
157
|
+
|
158
|
+
* `address` (String): The address of the energy supplier.
|
159
|
+
* `name` (String): The name of the energy supplier.
|
160
|
+
Fields which are specific to this product; they are not used in any other product.
|
161
|
+
|
128
162
|
### Energy Consumer Field
|
129
163
|
The entity that consumes the energy.
|
130
164
|
|
@@ -134,13 +168,17 @@ A `EnergyBillV1EnergyConsumer` implements the following attributes:
|
|
134
168
|
* `name` (String): The name of the energy consumer.
|
135
169
|
Fields which are specific to this product; they are not used in any other product.
|
136
170
|
|
137
|
-
###
|
138
|
-
The
|
171
|
+
### Subscription Field
|
172
|
+
The subscription details fee for the energy service.
|
139
173
|
|
140
|
-
A `
|
174
|
+
A `EnergyBillV1Subscription` implements the following attributes:
|
141
175
|
|
142
|
-
* `
|
143
|
-
* `
|
176
|
+
* `description` (String): Description or details of the subscription.
|
177
|
+
* `end_date` (String): The end date of the subscription.
|
178
|
+
* `start_date` (String): The start date of the subscription.
|
179
|
+
* `tax_rate` (Float): The rate of tax applied to the total cost.
|
180
|
+
* `total` (Float): The total cost of subscription.
|
181
|
+
* `unit_price` (Float): The price per unit of subscription.
|
144
182
|
Fields which are specific to this product; they are not used in any other product.
|
145
183
|
|
146
184
|
### Energy Usage Field
|
@@ -156,6 +194,19 @@ A `EnergyBillV1EnergyUsage` implements the following attributes:
|
|
156
194
|
* `unit_price` (Float): The price per unit of energy consumed.
|
157
195
|
Fields which are specific to this product; they are not used in any other product.
|
158
196
|
|
197
|
+
### Taxes and Contributions Field
|
198
|
+
Details of Taxes and Contributions.
|
199
|
+
|
200
|
+
A `EnergyBillV1TaxesAndContribution` implements the following attributes:
|
201
|
+
|
202
|
+
* `description` (String): Description or details of the Taxes and Contributions.
|
203
|
+
* `end_date` (String): The end date of the Taxes and Contributions.
|
204
|
+
* `start_date` (String): The start date of the Taxes and Contributions.
|
205
|
+
* `tax_rate` (Float): The rate of tax applied to the total cost.
|
206
|
+
* `total` (Float): The total cost of Taxes and Contributions.
|
207
|
+
* `unit_price` (Float): The price per unit of Taxes and Contributions.
|
208
|
+
Fields which are specific to this product; they are not used in any other product.
|
209
|
+
|
159
210
|
### Meter Details Field
|
160
211
|
Information about the energy meter.
|
161
212
|
|
@@ -169,34 +220,8 @@ A `EnergyBillV1MeterDetail` implements the following attributes:
|
|
169
220
|
- gas
|
170
221
|
- water
|
171
222
|
- None
|
172
|
-
|
223
|
+
|
173
224
|
* `unit` (String): The unit of measurement for energy consumption, which can be kW, m³, or L.
|
174
|
-
Fields which are specific to this product; they are not used in any other product.
|
175
|
-
|
176
|
-
### Subscription Field
|
177
|
-
The subscription details fee for the energy service.
|
178
|
-
|
179
|
-
A `EnergyBillV1Subscription` implements the following attributes:
|
180
|
-
|
181
|
-
* `description` (String): Description or details of the subscription.
|
182
|
-
* `end_date` (String): The end date of the subscription.
|
183
|
-
* `start_date` (String): The start date of the subscription.
|
184
|
-
* `tax_rate` (Float): The rate of tax applied to the total cost.
|
185
|
-
* `total` (Float): The total cost of subscription.
|
186
|
-
* `unit_price` (Float): The price per unit of subscription.
|
187
|
-
Fields which are specific to this product; they are not used in any other product.
|
188
|
-
|
189
|
-
### Taxes and Contributions Field
|
190
|
-
Details of Taxes and Contributions.
|
191
|
-
|
192
|
-
A `EnergyBillV1TaxesAndContribution` implements the following attributes:
|
193
|
-
|
194
|
-
* `description` (String): Description or details of the Taxes and Contributions.
|
195
|
-
* `end_date` (String): The end date of the Taxes and Contributions.
|
196
|
-
* `start_date` (String): The start date of the Taxes and Contributions.
|
197
|
-
* `tax_rate` (Float): The rate of tax applied to the total cost.
|
198
|
-
* `total` (Float): The total cost of Taxes and Contributions.
|
199
|
-
* `unit_price` (Float): The price per unit of Taxes and Contributions.
|
200
225
|
|
201
226
|
# Attributes
|
202
227
|
The following fields are extracted for Energy Bill V1:
|
@@ -240,7 +265,7 @@ puts result.document.inference.prediction.energy_supplier.value
|
|
240
265
|
**energy_usage** (Array<[EnergyBillV1EnergyUsage](#energy-usage-field)>): Details of energy consumption.
|
241
266
|
|
242
267
|
```rb
|
243
|
-
|
268
|
+
result.document.inference.prediction.energy_usage do |energy_usage_elem|
|
244
269
|
puts energy_usage_elem.value
|
245
270
|
end
|
246
271
|
```
|
@@ -270,7 +295,7 @@ puts result.document.inference.prediction.meter_details.value
|
|
270
295
|
**subscription** (Array<[EnergyBillV1Subscription](#subscription-field)>): The subscription details fee for the energy service.
|
271
296
|
|
272
297
|
```rb
|
273
|
-
|
298
|
+
result.document.inference.prediction.subscription do |subscription_elem|
|
274
299
|
puts subscription_elem.value
|
275
300
|
end
|
276
301
|
```
|
@@ -279,7 +304,7 @@ end
|
|
279
304
|
**taxes_and_contributions** (Array<[EnergyBillV1TaxesAndContribution](#taxes-and-contributions-field)>): Details of Taxes and Contributions.
|
280
305
|
|
281
306
|
```rb
|
282
|
-
|
307
|
+
result.document.inference.prediction.taxes_and_contributions do |taxes_and_contributions_elem|
|
283
308
|
puts taxes_and_contributions_elem.value
|
284
309
|
end
|
285
310
|
```
|
@@ -1,16 +1,42 @@
|
|
1
1
|
---
|
2
|
-
title: FR Health Card
|
2
|
+
title: Ruby Client Library - FR Health Card
|
3
3
|
category: 622b805aaec68102ea7fcbc2
|
4
4
|
slug: ruby-fr-health-card-ocr
|
5
|
-
parentDoc:
|
5
|
+
parentDoc: 67b49e29a2cd6f08d69a40d8
|
6
6
|
---
|
7
|
-
The Ruby
|
8
|
-
|
9
|
-
|
7
|
+
The Ruby Client Library supports the [Health Card API](https://platform.mindee.com/mindee/french_healthcard).
|
8
|
+
|
9
|
+
|
10
|
+
> 📝 Product Specs
|
11
|
+
>
|
12
|
+
> | Specification | Details |
|
13
|
+
> | ------------------------------ | -------------------------------------------------- |
|
14
|
+
> | Endpoint Name | `french_healthcard` |
|
15
|
+
> | Recommended Version | `v1.0` |
|
16
|
+
> | Supports Polling/Webhooks | ✔️ Yes |
|
17
|
+
> | Support Synchronous HTTP Calls | ❌ No |
|
18
|
+
> | Geography | 🇫🇷 France |
|
19
|
+
|
20
|
+
> 🔐 Polling Limitations
|
21
|
+
>
|
22
|
+
> | Setting | Parameter name | Default Value |
|
23
|
+
> | ------------------------------- | ----------------------- | ------------- |
|
24
|
+
> | Initial Delay Before Polling | `initial_delay_seconds` | 2 seconds |
|
25
|
+
> | Default Delay Between Calls | `delay_sec` | 1.5 seconds |
|
26
|
+
> | Polling Attempts Before Timeout | `max_retries` | 80 retries |
|
27
|
+
|
28
|
+
|
29
|
+
Using the [sample below](https://github.com/mindee/client-lib-test-data/blob/main/products/french_healthcard/default_sample.jpg),
|
30
|
+
we are going to illustrate how to extract the data that we want using the Ruby Client Library.
|
10
31
|

|
11
32
|
|
12
33
|
# Quick-Start
|
13
34
|
```rb
|
35
|
+
#
|
36
|
+
# Install the Ruby client library by running:
|
37
|
+
# gem install mindee
|
38
|
+
#
|
39
|
+
|
14
40
|
require 'mindee'
|
15
41
|
|
16
42
|
# Init a new client
|
@@ -20,7 +46,7 @@ mindee_client = Mindee::Client.new(api_key: 'my-api-key')
|
|
20
46
|
input_source = mindee_client.source_from_path('/path/to/the/file.ext')
|
21
47
|
|
22
48
|
# Parse the file
|
23
|
-
result = mindee_client.
|
49
|
+
result = mindee_client.parse(
|
24
50
|
input_source,
|
25
51
|
Mindee::Product::FR::HealthCard::HealthCardV1
|
26
52
|
)
|
@@ -30,7 +56,6 @@ puts result.document
|
|
30
56
|
|
31
57
|
# Print the document-level parsed data
|
32
58
|
# puts result.document.inference.prediction
|
33
|
-
|
34
59
|
```
|
35
60
|
|
36
61
|
**Output (RST):**
|
@@ -62,18 +87,18 @@ These fields are generic and used in several products.
|
|
62
87
|
Each prediction object contains a set of fields that inherit from the generic `Field` class.
|
63
88
|
A typical `Field` object will have the following attributes:
|
64
89
|
|
65
|
-
* **value** (`String`, `Float`, `Integer`, `
|
90
|
+
* **value** (`String`, `Float`, `Integer`, `bool`): corresponds to the field value. Can be `nil` if no value was extracted.
|
66
91
|
* **confidence** (Float, nil): the confidence score of the field prediction.
|
67
92
|
* **bounding_box** (`Mindee::Geometry::Quadrilateral`, `nil`): contains exactly 4 relative vertices (points) coordinates of a right rectangle containing the field in the document.
|
68
93
|
* **polygon** (`Mindee::Geometry::Polygon`, `nil`): contains the relative vertices coordinates (`Point`) of a polygon containing the field in the image.
|
69
94
|
* **page_id** (`Integer`, `nil`): the ID of the page, always `nil` when at document-level.
|
70
|
-
* **reconstructed** (`
|
95
|
+
* **reconstructed** (`bool`): indicates whether an object was reconstructed (not extracted as the API gave it).
|
71
96
|
|
72
97
|
|
73
98
|
Aside from the previous attributes, all basic fields have access to a `to_s` method that can be used to print their value as a string.
|
74
99
|
|
75
100
|
### Date Field
|
76
|
-
Aside from the basic `Field` attributes, the date field `DateField` also implements the following:
|
101
|
+
Aside from the basic `Field` attributes, the date field `DateField` also implements the following:
|
77
102
|
|
78
103
|
* **date_object** (`Date`): an accessible representation of the value as a JavaScript object.
|
79
104
|
|
@@ -87,7 +112,7 @@ The following fields are extracted for Health Card V1:
|
|
87
112
|
**given_names** (Array<[StringField](#string-field)>): The given names of the card holder.
|
88
113
|
|
89
114
|
```rb
|
90
|
-
|
115
|
+
result.document.inference.prediction.given_names do |given_names_elem|
|
91
116
|
puts given_names_elem.value
|
92
117
|
end
|
93
118
|
```
|