Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 18 additions & 18 deletions docs/energy_bill_fra_v1.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,58 +39,58 @@ apiResponse.then((resp) => {
########
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
:Total Before Taxes: 1241.03
: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 |
+======================================+============+============+==========+===========+============+
| 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
Expand Down
12 changes: 12 additions & 0 deletions docs/expense_receipts_v5.md
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,9 @@ The following fields are extracted for Receipt V5:
- 'gasoline'
- 'telecom'
- 'miscellaneous'
- 'software'
- 'shopping'
- 'energy'

```js
console.log(result.document.inference.prediction.category.value);
Expand Down Expand Up @@ -287,6 +290,15 @@ console.log(result.document.inference.prediction.receiptNumber.value);
- 'train'
- 'restaurant'
- 'shopping'
- 'other'
- 'groceries'
- 'cultural'
- 'electronics'
- 'office_supplies'
- 'micromobility'
- 'car_rental'
- 'public'
- 'delivery'
- null

```js
Expand Down
45 changes: 37 additions & 8 deletions docs/financial_document_v1.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,12 @@ apiResponse.then((resp) => {
########
Document
########
:Mindee ID: a80ac0ee-26f6-4e2e-988a-960b240d5ba7
:Mindee ID: 6dd26385-719b-4527-bf6f-87d9da619de5
:Filename: default_sample.jpg

Inference
#########
:Product: mindee/financial_document v1.11
:Product: mindee/financial_document v1.14
:Rotation applied: Yes

Prediction
Expand Down Expand Up @@ -106,6 +106,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
Expand Down Expand Up @@ -158,6 +159,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
Expand Down Expand Up @@ -196,6 +198,21 @@ A typical `Field` object will have the following attributes:
Aside from the previous attributes, all basic fields have access to a `toString()` method that can be used to print their value as a string.


### AddressField
Aside from the basic `BaseField` attributes, the address field `AddressField` also implements the following:

* **streetNumber** (`string`): String representation of the street number. Can be `null`.
* **streetName** (`string`): Name of the street. Can be `null`.
* **poBox** (`string`): String representation of the PO Box number. Can be `null`.
* **addressComplement** (`string`): Address complement. Can be `null`.
* **city** (`string`): City name. Can be `null`.
* **postalCode** (`string`): String representation of the postal code. Can be `null`.
* **state** (`string`): State name. Can be `null`.
* **country** (`string`): Country name. Can be `null`.

Note: The `value` field of an AddressField should be a concatenation of the rest of the values.


### Amount Field
The amount field `AmountField` only has one constraint: its **value** is a `number` (or `undefined`).

Expand Down Expand Up @@ -269,14 +286,14 @@ A `FinancialDocumentV1LineItem` implements the following attributes:
The following fields are extracted for Financial Document V1:

## Billing Address
**billingAddress** ([StringField](#string-field)): The customer's address used for billing.
**billingAddress** : The customer's address used for billing.

```js
console.log(result.document.inference.prediction.billingAddress.value);
```

## Purchase Category
**category** ([ClassificationField](#classification-field)): The purchase category, only for receipts.
**category** ([ClassificationField](#classification-field)): The purchase category.

#### Possible values include:
- 'toll'
Expand All @@ -287,13 +304,16 @@ console.log(result.document.inference.prediction.billingAddress.value);
- 'gasoline'
- 'telecom'
- 'miscellaneous'
- 'software'
- 'shopping'
- 'energy'

```js
console.log(result.document.inference.prediction.category.value);
```

## Customer Address
**customerAddress** ([StringField](#string-field)): The address of the customer.
**customerAddress** : The address of the customer.

```js
console.log(result.document.inference.prediction.customerAddress.value);
Expand Down Expand Up @@ -428,29 +448,38 @@ for (const referenceNumbersElem of result.document.inference.prediction.referenc
```

## Shipping Address
**shippingAddress** ([StringField](#string-field)): The customer's address used for shipping.
**shippingAddress** : The customer's address used for shipping.

```js
console.log(result.document.inference.prediction.shippingAddress.value);
```

## Purchase Subcategory
**subcategory** ([ClassificationField](#classification-field)): The purchase subcategory for transport and food, only for receipts.
**subcategory** ([ClassificationField](#classification-field)): The purchase subcategory for transport, food and shooping.

#### Possible values include:
- 'plane'
- 'taxi'
- 'train'
- 'restaurant'
- 'shopping'
- 'other'
- 'groceries'
- 'cultural'
- 'electronics'
- 'office_supplies'
- 'micromobility'
- 'car_rental'
- 'public'
- 'delivery'
- null

```js
console.log(result.document.inference.prediction.subcategory.value);
```

## Supplier Address
**supplierAddress** ([StringField](#string-field)): The address of the supplier or merchant.
**supplierAddress** : The address of the supplier or merchant.

```js
console.log(result.document.inference.prediction.supplierAddress.value);
Expand Down
4 changes: 2 additions & 2 deletions docs/ind_passport_v1.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ Document

Inference
#########
:Product: mindee/ind_passport v1.0
:Product: mindee/ind_passport v1.2
:Rotation applied: Yes

Prediction
Expand All @@ -67,10 +67,10 @@ Prediction
:Name of Mother:
:Old Passport Date of Issue:
:Old Passport Number:
:Old Passport Place of Issue:
:Address Line 1:
:Address Line 2:
:Address Line 3:
:Old Passport Place of Issue:
:File Number:
```

Expand Down
76 changes: 70 additions & 6 deletions docs/invoices_v4.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,12 @@ apiResponse.then((resp) => {
########
Document
########
:Mindee ID: b55db8f9-ae3b-4f05-b2f1-ec0ced5e5b70
:Mindee ID: 744748d5-9051-461c-b70c-bbf81f5ff943
:Filename: default_sample.jpg

Inference
#########
:Product: mindee/invoices v4.9
:Product: mindee/invoices v4.11
:Rotation applied: Yes

Prediction
Expand Down Expand Up @@ -105,6 +105,9 @@ Prediction
:Shipping Address:
:Billing Address: 1954 Bloor Street West Toronto, ON, M6P 3K9 Canada
:Document Type: INVOICE
:Document Type Extended: INVOICE
:Purchase Subcategory:
:Purchase Category: miscellaneous
:Line Items:
+--------------------------------------+--------------+----------+------------+--------------+--------------+-----------------+------------+
| Description | Product code | Quantity | Tax Amount | Tax Rate (%) | Total Amount | Unit of measure | Unit Price |
Expand Down Expand Up @@ -151,6 +154,9 @@ Page 0
:Shipping Address:
:Billing Address: 1954 Bloor Street West Toronto, ON, M6P 3K9 Canada
:Document Type: INVOICE
:Document Type Extended: INVOICE
:Purchase Subcategory:
:Purchase Category: miscellaneous
:Line Items:
+--------------------------------------+--------------+----------+------------+--------------+--------------+-----------------+------------+
| Description | Product code | Quantity | Tax Amount | Tax Rate (%) | Total Amount | Unit of measure | Unit Price |
Expand Down Expand Up @@ -184,6 +190,21 @@ A typical `Field` object will have the following attributes:
Aside from the previous attributes, all basic fields have access to a `toString()` method that can be used to print their value as a string.


### AddressField
Aside from the basic `BaseField` attributes, the address field `AddressField` also implements the following:

* **streetNumber** (`string`): String representation of the street number. Can be `null`.
* **streetName** (`string`): Name of the street. Can be `null`.
* **poBox** (`string`): String representation of the PO Box number. Can be `null`.
* **addressComplement** (`string`): Address complement. Can be `null`.
* **city** (`string`): City name. Can be `null`.
* **postalCode** (`string`): String representation of the postal code. Can be `null`.
* **state** (`string`): State name. Can be `null`.
* **country** (`string`): Country name. Can be `null`.

Note: The `value` field of an AddressField should be a concatenation of the rest of the values.


### Amount Field
The amount field `AmountField` only has one constraint: its **value** is a `number` (or `undefined`).

Expand Down Expand Up @@ -257,14 +278,33 @@ A `InvoiceV4LineItem` implements the following attributes:
The following fields are extracted for Invoice V4:

## Billing Address
**billingAddress** ([StringField](#string-field)): The customer billing address.
**billingAddress** : The customer billing address.

```js
console.log(result.document.inference.prediction.billingAddress.value);
```

## Purchase Category
**category** ([ClassificationField](#classification-field)): The purchase category.

#### Possible values include:
- 'toll'
- 'food'
- 'parking'
- 'transport'
- 'accommodation'
- 'telecom'
- 'miscellaneous'
- 'software'
- 'shopping'
- 'energy'

```js
console.log(result.document.inference.prediction.category.value);
```

## Customer Address
**customerAddress** ([StringField](#string-field)): The address of the customer.
**customerAddress** : The address of the customer.

```js
console.log(result.document.inference.prediction.customerAddress.value);
Expand Down Expand Up @@ -383,14 +423,38 @@ for (const referenceNumbersElem of result.document.inference.prediction.referenc
```

## Shipping Address
**shippingAddress** ([StringField](#string-field)): Customer's delivery address.
**shippingAddress** : Customer's delivery address.

```js
console.log(result.document.inference.prediction.shippingAddress.value);
```

## Purchase Subcategory
**subcategory** ([ClassificationField](#classification-field)): The purchase subcategory for transport, food and shopping.

#### Possible values include:
- 'plane'
- 'taxi'
- 'train'
- 'restaurant'
- 'shopping'
- 'other'
- 'groceries'
- 'cultural'
- 'electronics'
- 'office_supplies'
- 'micromobility'
- 'car_rental'
- 'public'
- 'delivery'
- null

```js
console.log(result.document.inference.prediction.subcategory.value);
```

## Supplier Address
**supplierAddress** ([StringField](#string-field)): The address of the supplier or merchant.
**supplierAddress** : The address of the supplier or merchant.

```js
console.log(result.document.inference.prediction.supplierAddress.value);
Expand Down
Loading