Now that you have covered the basics (if not, refer to https://contractfit.atlassian.net/wiki/spaces/DA/pages/1059913749/Getting%2Bstarted%2Bwith%2Bour%2BAPI%2Bdocument%2Bupload), it is time to look at some of the more advanced features.
Uploading documents with our admin API (https://<organisation_name>.contract-<environment>.fit/admin/documents/<inbox_id>/ ) gives the option to add supply a “hints” field.
These hints are indications of what a field in the document may look like (whitelist) or what the field cannot look like (blacklist). Under the hood, the blacklist will prevent the algorithm from predicting a specific value (for example a VAT number of your company), while the whitelist will tell the algorithm to favour a prediction over others (and can therefore be used as training, as well).
Concretely, uploading some (positive) hints to tell the algorithms what to look for for some common invoice fields, could look like this:
"{ 'tax_amount': {'whitelist': ['2.23', '3.54']}, 'gross_amount': {'whitelist': ['183.4']}, 'invoice_number': {'whitelist': ['8568586']}, 'invoice_date': {'whitelist': ['2020-01-23']}, 'country': {'whitelist': ['FR']}, 'sender_vat': {'whitelist': ['FR41448268276']}, 'company_number': {'whitelist': ['FR41448268276']} }"
Note that this hints dictionary needs to be supplied as a string (“{}”).