> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abbyy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Improve capture quality

> Improve invoice capture quality in FlexiCapture for Invoices Cloud by training the model: get the layout, mark correct field locations, and call Training.Train.

The quality of data capture can be improved by training ABBYY FlexiCapture for Invoices Cloud.

In a stream of documents of the same type, some unusual documents may have field locations that differ from those on a standard document. If the application cannot reliably detect fields on such documents, you can indicate the correct field locations, and the application "learns" to detect these fields.

If a dataset of business units and vendors is connected to your application, ABBYY FlexiCapture for Invoices Cloud trains the capture model by default after the data has been verified.

To train the capture model manually:

<Steps>
  <Step title="Run a processing task and verify the results">
    Run a document processing task and verify the results. For details, see [Extraction of main invoice fields](/flexi-capture/cloud/cloud-f-cfor-invoices-extraction) and [Verification of extracted data](/flexi-capture/cloud/cloud-f-cfor-invoices-verification).
  </Step>

  <Step title="Get the data layout">
    After the task status changes to `Done`, get the data layout using the Training.Layout method.

    ```bash theme={null}
    curl -X GET \
      --header "Accept: application/json" \
      --header "Authorization: Basic QWxhZGRpbjpPcGVuU2VzYW1l" \
      "https://api-eu.flexicapture.com/v2/training/layout/5eeb7bf728613d1e04a70782/5eeb762149c6470fdc65a84c"
    ```

    The response contains the data layout, including each detected field and its coordinates:

    <Accordion title="Response example">
      ```json theme={null}
      {
        "task_id": "5eeb7bf728613d1e04a70782",
        "file_id": "5eeb762149c6470fdc65a84c",
        "pages": [
          {
            "id": 2,
            "number": 1,
            "resolution": 300,
            "height": 3283,
            "width": 2529
          }
        ],
        "fields": [
          {
            "name": "Root/Invoice Layout",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/BU",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/BU/BUId",
            "value": "1",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/BU/Street",
            "value": "18 Prince George Drive",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 275,
                "y1": 763,
                "x2": 705,
                "y2": 801
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/BU/PostalCode",
            "value": "23875",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 628,
                "y1": 823,
                "x2": 741,
                "y2": 853
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/BU/City",
            "value": "Prince George",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 332,
                "y1": 763,
                "x2": 596,
                "y2": 801
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/BU/Country",
            "value": "US",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/BU/Name",
            "value": "US NORTHLAND",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 276,
                "y1": 645,
                "x2": 599,
                "y2": 675
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/BU/State",
            "value": "VA",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/Vendor",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/Vendor/VendorId",
            "value": "1",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/Vendor/Street",
            "value": "1 Memphis Dr.",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 238,
                "y1": 271,
                "x2": 499,
                "y2": 309
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/Vendor/ZIP",
            "value": "38118",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 512,
                "y1": 331,
                "x2": 621,
                "y2": 361
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/Vendor/City",
            "value": "Memphis",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 272,
                "y1": 271,
                "x2": 436,
                "y2": 309
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/Vendor/Country",
            "value": "US",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/Vendor/Name",
            "value": "AA APPAREL",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 240,
                "y1": 213,
                "x2": 492,
                "y2": 243
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/Vendor/State",
            "value": "TN",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/InvoiceNumber",
            "value": "99044",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 2266,
                "y1": 374,
                "x2": 2362,
                "y2": 409
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/InvoiceDate",
            "value": "06/09/2004",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 1958,
                "y1": 374,
                "x2": 2099,
                "y2": 412
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/Total",
            "value": "20,208",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 2204,
                "y1": 2947,
                "x2": 2384,
                "y2": 2985
              }
            ]
          },
          {
            "name": "Root/Invoice Layout/Currency",
            "value": "USD",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/Amounts",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/Amounts/Summary",
            "value": "",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/Amounts/TotalTaxAmount",
            "value": "",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/Amounts/TotalNetAmount",
            "value": "",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/InvoiceType",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/InvoiceType/Invoice",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/InvoiceType/Credit Note",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/PurchaseOrder",
            "rectangles": []
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/OrderNumber",
            "value": "1505",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 191,
                "y1": 1198,
                "x2": 279,
                "y2": 1232
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "OrderNumber"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/OrderDate",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "OrderDate"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/Position",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "Position"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/ArticleNumber",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "ArticleNumber"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/ArticleNumberBU",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "ArticleNumberBU"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/MaterialNumber",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "MaterialNumber"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/MaterialNumberBU",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "MaterialNumberBU"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/Description",
            "value": "49910 - Gloves or mittens, NOI, in boxes",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 747,
                "y1": 1419,
                "x2": 1500,
                "y2": 1462
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "Description"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/Quantity",
            "value": "7",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 208,
                "y1": 1420,
                "x2": 231,
                "y2": 1456
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "Quantity"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/QuantityUndelivered",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "QuantityUndelivered"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/QuantityOrdered",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "QuantityOrdered"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/UnitOfMeasurement",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "UnitOfMeasurement"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/UnitPrice",
            "value": "150",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 1842,
                "y1": 1420,
                "x2": 1968,
                "y2": 1456
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "UnitPrice"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/UnitPriceDenominator",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "UnitPriceDenominator"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/DiscountPercentage",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "DiscountPercentage"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/DiscountValue",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "DiscountValue"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/TotalPriceNetto",
            "value": "1,050",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 2213,
                "y1": 1419,
                "x2": 2360,
                "y2": 1455
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "TotalPriceNetto"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/VATPercentage",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "VATPercentage"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/VATValue",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "VATValue"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/VATCode",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "VATCode"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/Currency",
            "value": "USD",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "Currency"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/DeliveryDate",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "DeliveryDate"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/IsValid",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "IsValid"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[0]/OrderItemId",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 0,
              "column_name": "OrderItemId"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/OrderNumber",
            "value": "1505",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 191,
                "y1": 1198,
                "x2": 279,
                "y2": 1232
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "OrderNumber"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/OrderDate",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "OrderDate"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/Position",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "Position"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/ArticleNumber",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "ArticleNumber"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/ArticleNumberBU",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "ArticleNumberBU"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/MaterialNumber",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "MaterialNumber"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/MaterialNumberBU",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "MaterialNumberBU"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/Description",
            "value": "15560 - Bulk, NOI, inflated",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 745,
                "y1": 1530,
                "x2": 1230,
                "y2": 1573
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "Description"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/Quantity",
            "value": "42",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 200,
                "y1": 1532,
                "x2": 248,
                "y2": 1568
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "Quantity"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/QuantityUndelivered",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "QuantityUndelivered"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/QuantityOrdered",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "QuantityOrdered"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/UnitOfMeasurement",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "UnitOfMeasurement"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/UnitPrice",
            "value": "275",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 1841,
                "y1": 1528,
                "x2": 1970,
                "y2": 1564
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "UnitPrice"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/UnitPriceDenominator",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "UnitPriceDenominator"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/DiscountPercentage",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "DiscountPercentage"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/DiscountValue",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "DiscountValue"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/TotalPriceNetto",
            "value": "11,550",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 2193,
                "y1": 1531,
                "x2": 2361,
                "y2": 1567
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "TotalPriceNetto"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/VATPercentage",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "VATPercentage"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/VATValue",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "VATValue"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/VATCode",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "VATCode"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/Currency",
            "value": "USD",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "Currency"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/DeliveryDate",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "DeliveryDate"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/IsValid",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "IsValid"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[1]/OrderItemId",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 1,
              "column_name": "OrderItemId"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/OrderNumber",
            "value": "1505",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 191,
                "y1": 1198,
                "x2": 279,
                "y2": 1232
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "OrderNumber"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/OrderDate",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "OrderDate"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/Position",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "Position"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/ArticleNumber",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "ArticleNumber"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/ArticleNumberBU",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "ArticleNumberBU"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/MaterialNumber",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "MaterialNumber"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/MaterialNumberBU",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "MaterialNumberBU"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/Description",
            "value": "15520 - Athletic or Sporting Goods, NOI",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 745,
                "y1": 1651,
                "x2": 1478,
                "y2": 1696
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "Description"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/Quantity",
            "value": "24",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 200,
                "y1": 1657,
                "x2": 248,
                "y2": 1693
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "Quantity"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/QuantityUndelivered",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "QuantityUndelivered"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/QuantityOrdered",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "QuantityOrdered"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/UnitOfMeasurement",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "UnitOfMeasurement"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/UnitPrice",
            "value": "317",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 1843,
                "y1": 1644,
                "x2": 1971,
                "y2": 1680
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "UnitPrice"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/UnitPriceDenominator",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "UnitPriceDenominator"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/DiscountPercentage",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "DiscountPercentage"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/DiscountValue",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "DiscountValue"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/TotalPriceNetto",
            "value": "7,608",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 2211,
                "y1": 1641,
                "x2": 2366,
                "y2": 1677
              }
            ],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "TotalPriceNetto"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/VATPercentage",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "VATPercentage"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/VATValue",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "VATValue"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/VATCode",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "VATCode"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/Currency",
            "value": "USD",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "Currency"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/DeliveryDate",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "DeliveryDate"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/IsValid",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "IsValid"
            }
          },
          {
            "name": "Root/Invoice Layout/LineItems[2]/OrderItemId",
            "value": "",
            "rectangles": [],
            "cell": {
              "table_name": "Root/Invoice Layout/LineItems",
              "row_number": 2,
              "column_name": "OrderItemId"
            }
          }
        ],
        "tables": [
          {
            "name": "Root/Invoice Layout/LineItems",
            "regions": [
              {
                "rectangles": [
                  {
                    "page_id": 2,
                    "x1": 200,
                    "y1": 1419,
                    "x2": 2366,
                    "y2": 1696
                  }
                ],
                "columns": [
                  {
                    "left": 200,
                    "right": 248
                  },
                  {
                    "left": 248,
                    "right": 745
                  },
                  {
                    "left": 745,
                    "right": 1500
                  },
                  {
                    "left": 1500,
                    "right": 1841
                  },
                  {
                    "left": 1841,
                    "right": 1971
                  },
                  {
                    "left": 1971,
                    "right": 2193
                  },
                  {
                    "left": 2193,
                    "right": 2366
                  }
                ],
                "horizontal_separators": [
                  1495,
                  1607
                ]
              }
            ]
          }
        ]
      }
      ```
    </Accordion>
  </Step>

  <Step title="Train the data capture model">
    Provide the corrected field coordinates using the Training.Train method.

    ```bash theme={null}
    curl -X POST \
      --header "Content-Type: application/json" \
      --header "Accept: application/json" \
      --header "Authorization: Basic QWxhZGRpbjpPcGVuU2VzYW1l" \
      -d '{
        "task_id": "5eeb7bf728613d1e04a70782",
        "file_id": "5eeb762149c6470fdc65a84c",
        "fields": [
          {
            "name": "Root/Invoice Layout/BU/Street",
            "rectangles": [
              {
                "page_id": 2,
                "x1": 275,
                "y1": 763,
                "x2": 705,
                "y2": 801
              }
            ]
          }
        ]
      }' \
      "https://api-eu.flexicapture.com/v2/training"
    ```

    If the training completes successfully, the server returns a `204 No Content` HTTP status.
  </Step>
</Steps>
