Invoice Coding Proposals
Kaunt provides coding proposals for each invoice line through the InvoiceCodingProposals
endpoint. The proposals consist of a list of codings for each dimension as well as a coding for the combination of dimensions.
Kaunt delivers multiple proposals for each invoice line, prioritized by confidence. The proposalPriority
is a number starting from 1 where 1 is the most confident proposal for the invoice line.
The proposal output consists of the invoiceLineCodingDimensionProposals
, invoiceLineCodingDimensionCombinationProposals
and invoiceCodingProposalGroups
properties which are described in the next sections.
Invoice Line Dimension Proposals
The invoiceLineCodingDimensionProposals
property in InvoiceCodingProposal
contains a list of coding proposals for a particular dimension. Kaunt typically delivers multiple proposals in a prioritized order (from most confident HIGH
to LOW
) along with a confidence of either HIGH
, MEDIUM
or LOW
. Common examples of dimensions could be Area Code, VAT code, and Cost center.
Example 1 : invoiceLineCodingDimensionProposals
(simplified visualization of the InvoiceCodingProposals
JSON response)
Invoice Line No | Dimension Name | Dimension Value | Confidence | ProposalPriority |
---|---|---|---|---|
1 | GL Account | 2221 | HIGH | 1 |
1 | GL Account | 2233 | LOW | 2 |
1 | Cost Center | R&D | HIGH | 1 |
1 | Cost Center | Finance | MEDIUM | 2 |
1 | Tax Code | 2235 | MEDIUM | 1 |
1 | Tax Code | 4444 | LOW | 2 |
Invoice Line Dimension Combination Proposals
The invoiceLineCodingDimensionCombinationProposals
property in InvoiceCodingProposal
contains a set of dimension combinations which can be used as an accounting proposal. Kaunt typically delivers multiple proposals in a prioritized order (from most confident HIGH
to LOW
) along with a confidence of either HIGH
, MEDIUM
or LOW
.
Example 2 : invoiceLineCodingDimensionCombinationProposals
(simplified visualization of the InvoiceCodingProposals
JSON response)
Invoice Line No | GL Account Value | Cost Center | Tax Code | Confidence | ProposalPriority |
---|---|---|---|---|---|
1 | 2221 | R&D | 2235 | HIGH | 1 |
1 | 2233 | HR | 2222 | LOW | 2 |
Invoice Coding Group Proposals
The InvoiceCodingProposalGroups
property in the InvoiceCodingProposals
endpoint contains a list of coding proposals for a group of invoice lines. The groups are inferred from the output of InvoiceLineCodingDimensionCombinationProposals
where invoice lines with the same combination of dimension values are grouped. Invoice lines with no InvoiceLineCodingDimensionCombinationProposals
are bundled in a single group.
The Confidence
property in InvoiceCodingProposalGroups
represents the confidence of the proposal for the group of invoice lines. The confidence is represented as either HIGH
, MEDIUM
or LOW
. The Confidence
property is inferred from the confidence of the least confident InvoiceLineCodingDimensionCombinationProposal
within the group.
Posting Texts
The postingTextProposals
property in InvoiceCodingProposalGroups
contains the proposed posting text for the group of invoice lines. The posting text is a human-readable description of the accounting proposal.
By default, the posting text is generated based on the Description
and Name
properties of the invoice line with the highest absolute amount in the group. We also offer the possibility to generate more sophisticated posting texts based on generative AI models. Please contact us if you are interested in this feature.
Should I Use invoiceLineCodingDimensionProposals
, invoiceLineCodingDimensionCombinationProposals
or InvoiceCodingProposalGroups
?
The difference between invoiceLineCodingDimensionProposals
and invoiceLineCodingDimensionCombinationProposals
is that invoiceLineCodingDimensionProposals
provides proposals on the dimension level independent from other dimensions, whereas invoiceLineCodingDimensionCombinationProposals
provides proposals as a combination of dimensions.
Furthermore, the invoiceLineCodingDimensionCombinationProposals
guarantees that the combination of the dimensions has been used historically.
Rapidly changing values such as free text typically does not go well with invoiceLineCodingDimensionCombinationProposals
since the concept of a free text value typically violates the guarantee that the combination of dimensions has been used before. In those cases we recommend to use the invoiceLineCodingDimensionProposals
for proposals.
Both the invoiceLineCodingDimensionProposals
and invoiceLineCodingDimensionCombinationProposals
contain multiple proposals. This could prove useful if you for instance would like to display the list of most likely correct coding values in the frontend of your application.
The InvoiceCodingProposalGroups
is the most suitable option if the desired result is a list of distinct posting groups rather than invoice line level proposals. This is especially useful when you have multiple invoice lines with the same combination of dimensions. The InvoiceCodingProposalGroups
also provides a posting text which is a human-readable description of the accounting proposal.
Understanding the Confidence
Property
The Confidence
property represents the confidence of the proposal. The confidence is represented as either HIGH
, MEDIUM
or LOW
and is calculated based on the historical data provided. Typically, the underlying AI-models will be calibrated towards the following statistics:
HIGH
: The proposal matches the invoice line posting at least 90% of the time.MEDIUM
: The proposal matches the invoice line posting at least 70% of the time.LOW
: The proposal matches the invoice line posting at least 30% of the time.
Please be assured that Kaunt continually monitors the models' performances and retrain them as more data becomes available.
Invoice Split
An invoice is sometimes split into several different codings. Kaunt is capable of handling invoice splits on the invoice line level (one coding per invoice line). Kaunt is not capable of splitting a single invoice line into multiple proposals.
Adjusting Invoice Line Amounts
Sometimes, the invoice total amount does not match the sum of the invoice line totals. There can be several reasons for this. For instance, the invoice total might include VAT, while the invoice lines do not, or the invoice total could contain additional charges or duties not represented at the line level. The latter is particularly important to adjust at the line level in warehouse bookkeeping, as it ensures the correct price per item and, ultimately, the accurate profit margin for each individual item.
When retrieving an invoice previously uploaded to Kaunt, we have the option to adjust the line amounts proportionally to match the invoice total as shown in example 3 and 4 below.
Example 3 : Invoice with VAT in total amount but not in invoice lines
"result": {
"amountExVat": 300,
"vatAmount": 75,
"amountInclVat": 375,
"invoiceLines": [
{
"lineNumber": "1",
"lineAmountExVat": 250,
"lineVatAmount": 0,
"lineAmountInclVat": 250
},
{
"lineNumber": "2",
"lineAmountExVat": 50,
"lineVatAmount": 0,
"lineAmountInclVat": 50
}
]
}
As shown in Example 3, the total amount on the invoice (375) does not match the line total (300) because the VAT is only represented at the invoice header level.
By providing the adjustLineAmounts
query parameter when retrieving an invoice from Kaunt, Kaunt will adjust the line amounts to match the invoice total, as illustrated in Example 4 below.
Example 4 : Adjusted invoice line amounts (based on the original invoice in Example 3)
"result": {
"amountExVat": 300,
"vatAmount": 75,
"amountInclVat": 375,
"invoiceLines": [
{
"lineNumber": "1",
"lineAmountExVat": 250,
"lineVatAmount": 62.5,
"lineAmountInclVat": 312.5
},
{
"lineNumber": "2",
"lineAmountExVat": 50,
"lineVatAmount": 12.5,
"lineAmountInclVat": 62.5
}
]
}