From d33fed470755340b39bffe7c8a8c6bcc9dcd86ae Mon Sep 17 00:00:00 2001 From: Ralph Soika Date: Tue, 25 Feb 2025 11:39:48 +0100 Subject: [PATCH] model fix posteingang --- workflow/businesspartner-en-1.0.0.bpmn | 14 +- workflow/posteingang-de-2.0.1.bpmn | 1625 +++++++++++++++++++++++ workflow/posteingang-en-2.0.1.bpmn | 1626 ++++++++++++++++++++++++ 3 files changed, 3258 insertions(+), 7 deletions(-) create mode 100644 workflow/posteingang-de-2.0.1.bpmn create mode 100644 workflow/posteingang-en-2.0.1.bpmn diff --git a/workflow/businesspartner-en-1.0.0.bpmn b/workflow/businesspartner-en-1.0.0.bpmn index fb3fc66..0fd6526 100644 --- a/workflow/businesspartner-en-1.0.0.bpmn +++ b/workflow/businesspartner-en-1.0.0.bpmn @@ -10,7 +10,7 @@ true - + @@ -26,12 +26,12 @@ - - - - - - + + + + + + diff --git a/workflow/posteingang-de-2.0.1.bpmn b/workflow/posteingang-de-2.0.1.bpmn new file mode 100644 index 0000000..7931e8e --- /dev/null +++ b/workflow/posteingang-de-2.0.1.bpmn @@ -0,0 +1,1625 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + true + + + + + + + + + + + + + BoundaryEvent_1 + Task_4 + IntermediateCatchEvent_2 + Task_2 + IntermediateCatchEvent_3 + StartEvent_1 + EndEvent_1 + + dataObject_FS1r0Q + task_uB6BGQ + textAnnotation_CtU05A + task_PsBytg + dataObject_CRa7xA + event_Zxhr0w + dataObject_vVKXIg + event_yQLmNA + task_0YaQ2w + dataObject_HHM58Q + event_xOeBKg + event_pDFoXg + dataObject_ZhBiZg + event_4DNGzg + dataObject_KPUiiw + event_wmNwPA + event_tFxV0w + event_88sCAA + event_T901Jg + event_7rbeVA + gateway_qDAhHw + event_9mJrhQ + gateway_gd9zQQ + TextAnnotation_1 + gateway_MgL04w + event_VEvZRQ + event_Xk1mPA + event_a1P5WQ + + + + + + + + + + + + _subject]]> + + + + + + + + + _amount (Brutto € _amount_brutto) +_description]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + home +Empfang +]]> + + + + + + + + + + + + false + + + + sequenceFlow_fRPOrw + sequenceFlow_4gpPgw + + + + sequenceFlow_fRPOrw + + + + + + + + + + + + + + + + + true + + + + + + + + $workflowgroup - $workflowstatus]]> + SequenceFlow_9 + sequenceFlow_4gpPgw + sequenceFlow_CbkmwA + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +X-Tika-OCRLanguage=eng+deu +X-Tika-PDFocrStrategy=OCR_ONLY +(PDF|pdf)$ +10 +Empfang]]> + + + + + + + + + + + + false + + + + SequenceFlow_9 + SequenceFlow_2 + + + DataOutput_1 + + + DataOutput_1 + + + sequenceFlow_VlPVJg + + + + + + + + txtlastcomment]]> + + + + + + + + + + + + + + + + + + + + + + + + cdtr.name (invoice.language)]]> + + + $workflowgroup - $workflowstatus]]> + SequenceFlow_12 + sequenceFlow_gXJm0w + + + SequenceFlow_12 + + + + + + + SequenceFlow_2 + + 1000 + + + + + + + + + + +]]> + + + + + + + + + + + + + + + + + true + + + + + + + + + sequenceFlow_fN22Gg + sequenceFlow_bh4DIw + sequenceFlow_ofQKHg + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + document.type ⇒ document.company (Import: document.import.type - Langauge: document.language) ]]> + + + true + + + + + + + + document.type
+Company: document.company
]]>
+
+
+ + sequenceFlow_JpNUKg + sequenceFlow_8SpIiA + sequenceFlow_I8o4DA + sequenceFlow_KKWo0w +
+ + + + + + + + + + + + +]]> + + + + + + + + sequenceFlow_3YcMGQ + + + + + + + + +]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + https://llama.cpp.imixs.com/ + XML + false + + + cdtr.name,invoice.number,invoice.date,invoice.total,payment.date,cdtr.iban,cdtr.bic,total + ON + +false + +]]> + + + + + + DataOutput_2 + + + DataOutput_2 + + + sequenceFlow_aC0skQ + sequenceFlow_YMtfiw + sequenceFlow_PWXjog + + + + + + + + + + + + + + document.type ⇒ document.company (Import: document.import.type - Langauge: document.language) ]]> + + + true + + + + + + + + + sequenceFlow_JpNUKg + sequenceFlow_lmU9IA + sequenceFlow_aC0skQ + sequenceFlow_A62nqQ + sequenceFlow_DdWK6A + + + + + + + + + + + {"n_predict": 4096, "temperature": 0 } + invoice.summary + +[INST]Transfer the invoice data into an XML object with the following structure: + + + ... + ... + 2024-12-31 + 2024-12-31 + 1234.00 + ... + ... + + +Transfer the individual invoice data to the XML tags, taking into account the following suggestions for mapping: + + - Company name ==> "cdtr.name" (the name of the company that issued the invoice document, not the recipient) + - Invoice number ==> "invoice.number" + - Invoice Date ==> "invoice.date" + - Total ==> "invoice.total" (in EUR or if not available in USD or PLN) + - IBAN ==> "cdtr.iban" + - BIC or SWIFT ==> "cdtr.bic" + - Payment date / Due date ==> "invoice.duedate" + +Note: Output only the XML object! Don't add explanations or comments. Use only the XML structure specified in this example and do not create any other XML tags. If you don't have data for some fields, leave the corresponding XML tags blank. Format date values (invoice.date, invoice.duedate) into the ISO 8601 format (YYYY-MM-DD). Format numbers and amounts (type="double") according to ISO 4217. + +<> + +[/INST] + +]]]]> + + ]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + (^rechnungseingang-[a-z]{2,3}-\d+(?:\.\d+)?$) + 5000 + 990 + +]]> + + + + + + DataOutput_2 + + + DataOutput_2 + + sequenceFlow_gXJm0w + sequenceFlow_gpPDLg + sequenceFlow_eccehA + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + false + + https://llama.cpp.imixs.com/ + XML + +Empfang + + +]]> + + + + + + DataOutput_2 + + + DataOutput_2 + + + sequenceFlow_fN22Gg + sequenceFlow_naZnAA + sequenceFlow_PgyOMw + + + + + {"n_predict": 512, "temperature": 0 } + ^.+\.([pP][dD][fF])$ + +[INST] Assign the invoice to one of the following categories: + +- Cargo-Invoice - in case the invoice is about cargo and logistic services +- Credit - in case of a credit note +- Invoice - in all other cases + +Extract also the company name and the language the invoice is written in. + +Note: The company name is the name of the company that issued the invoice document and not the name of the recipient. As a rule, it is not Alexander Global Logistics either. The company name is often at the beginning or end of the invoice document. + +Output the infromation as one XML object that has the following structure: + + + Type + Kraxi GmbH + German + + +Note: Do not generate any other information instead of the XML object. Do not generate more than one XML Object. + +[/INST] +]]]]> + + ]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + https://llama.cpp.imixs.com/ + invoice.summary + false + +false +]]> + + + + + + DataOutput_2 + + + DataOutput_2 + + + sequenceFlow_8SpIiA + sequenceFlow_A62nqQ + sequenceFlow_Di4BQA + + + + + + + + + + + {"n_predict": 4096, "temperature": 0} + ^.+\.([pP][dD][fF])$ + +[INST] + +Summarize the data from this invoice document: + + - Vendor information + - General Billing data + - Invoice total information + - Payment summary (including bank data) + - Invoice items + +Note: The vendor information refers to the sender of the invoice. The company name is the name of the company that issued the invoice document and not the name of the recipient. As a rule, it is not Alexander Global Logistics either. The company name is often at the beginning or end of the invoice document. + +Use only the default values and do not perform any calculations, summing or changes to these values yourself. Format numbers and amounts according to ISO 4217. + +If possible summarize the invoice lines in a table. + +[/INST] +]]]]> + + ]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + + + + + + + + + + + + + + + + + + + sequenceFlow_3YcMGQ + sequenceFlow_p0asUQ + + + + + + sequenceFlow_DdWK6A + + + + + + + + sequenceFlow_PgyOMw + + + + + sequenceFlow_Di4BQA + + + + + + + + + + + sequenceFlow_PWXjog + + + + + + + sequenceFlow_naZnAA + sequenceFlow_tcjWAA + sequenceFlow_I8o4DA + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + adapter.error_code: adapter.error_message]]> + + + false + + + + + + DataOutput_2 + + + DataOutput_2 + + sequenceFlow_tcjWAA + sequenceFlow_gpPDLg + sequenceFlow_d0zSHA + + + + + + + + + + + + + + + sequenceFlow_I8o4DA + sequenceFlow_VlPVJg + sequenceFlow_bh4DIw + sequenceFlow_d0zSHA + + + + + + + + + + + + + For the OCR Adapter the following minimal options should be set: + + * X-Tika-PDFocrStrategy=OCR_AND_TEXT_EXTRACTION + * X-Tika-OCRLanguage=eng+deu + +These options allow OCR and text extraction suporting English and German language. + +Additional Tika Options can be set but are NOT needed in most cases: + + * X-Tika-PDFOcrImageType=RGB (setting the RGB color mode) + * X-Tika-PDFOcrDPI=400 (setting DPI) + +Setting the OcrDPI is only recommended if the DPI is know! + +Possible ImageTypes are: + + * ARGB Alpha, Red, Green, Blue + * BINARY Black or white. + * GRAY Shades of gray + * RGB Red, Green, Blue + + + + + + sequenceFlow_YMtfiw + sequenceFlow_eccehA + sequenceFlow_p0asUQ + + + + + + + + + + + + + + + + + sequenceFlow_KKWo0w + + + + + + + + sequenceFlow_ofQKHg + + + + + + + + sequenceFlow_CbkmwA + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
diff --git a/workflow/posteingang-en-2.0.1.bpmn b/workflow/posteingang-en-2.0.1.bpmn new file mode 100644 index 0000000..f7f51fc --- /dev/null +++ b/workflow/posteingang-en-2.0.1.bpmn @@ -0,0 +1,1626 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + true + + + + + + + + + + + + + BoundaryEvent_1 + Task_4 + IntermediateCatchEvent_2 + Task_2 + IntermediateCatchEvent_3 + StartEvent_1 + EndEvent_1 + + dataObject_FS1r0Q + task_uB6BGQ + textAnnotation_CtU05A + task_PsBytg + dataObject_CRa7xA + event_Zxhr0w + dataObject_vVKXIg + event_yQLmNA + task_0YaQ2w + dataObject_HHM58Q + event_xOeBKg + event_pDFoXg + dataObject_ZhBiZg + event_4DNGzg + dataObject_KPUiiw + event_wmNwPA + event_tFxV0w + event_88sCAA + event_T901Jg + event_7rbeVA + gateway_qDAhHw + event_9mJrhQ + gateway_gd9zQQ + TextAnnotation_1 + gateway_1py0TA + event_kjzDVg + event_VQZVwg + event_OKWZDg + + + + + + + + + + + + _subject]]> + + + + + + + + + _amount (Brutto € _amount_brutto) +_description]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + home +Front Desk +]]> + + + + + + + + + + + + false + + + + sequenceFlow_fRPOrw + sequenceFlow_4gpPgw + + + + sequenceFlow_fRPOrw + + + + + + + + + + + + + + + + + true + + + + + + + + $workflowgroup - $workflowstatus]]> + SequenceFlow_9 + sequenceFlow_4gpPgw + sequenceFlow_B0T5KA + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +X-Tika-OCRLanguage=eng+deu +X-Tika-PDFocrStrategy=OCR_ONLY +(PDF|pdf)$ +10 +Front Desk]]> + + + + + + + + + + + + false + + + + SequenceFlow_9 + SequenceFlow_2 + + + DataOutput_1 + + + DataOutput_1 + + + sequenceFlow_VlPVJg + + + + + + + + txtlastcomment]]> + + + + + + + + + + + + + + + + + + + + + + + + cdtr.name (invoice.language)]]> + + + $workflowgroup - $workflowstatus]]> + SequenceFlow_12 + sequenceFlow_gXJm0w + + + SequenceFlow_12 + + + + + + + SequenceFlow_2 + + 1000 + + + + + + + + + + +]]> + + + + + + + + + + + + + + + + + true + + + + + + + + + sequenceFlow_fN22Gg + sequenceFlow_bh4DIw + sequenceFlow_WBx7JQ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + document.type ⇒ document.company (Import: document.import.type - Langauge: document.language) ]]> + + + true + + + + + + + + document.type
+Company: document.company
]]>
+
+
+ + sequenceFlow_JpNUKg + sequenceFlow_8SpIiA + sequenceFlow_I8o4DA + sequenceFlow_n3o55Q +
+ + + + + + + + + + + + +]]> + + + + + + + + sequenceFlow_Z8050g + + + + + + + + +]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + https://llama.cpp.imixs.com/ + XML + true + + + cdtr.name,invoice.number,invoice.date,invoice.total,payment.date,cdtr.iban,cdtr.bic,total + ON + +false + +]]> + + + + + + DataOutput_2 + + + DataOutput_2 + + + sequenceFlow_aC0skQ + sequenceFlow_YMtfiw + sequenceFlow_PWXjog + + + + + + + + + + + + + + document.type ⇒ document.company (Import: document.import.type - Langauge: document.language) ]]> + + + true + + + + + + + + + sequenceFlow_JpNUKg + sequenceFlow_lmU9IA + sequenceFlow_aC0skQ + sequenceFlow_A62nqQ + sequenceFlow_WIiVnQ + + + + + + + + + + + {"n_predict": 4096, "temperature": 0 } + invoice.summary + +[INST]Transfer the invoice data into an XML object with the following structure: + + + ... + ... + 2024-12-31 + 2024-12-31 + 1234.00 + ... + ... + + +Transfer the individual invoice data to the XML tags, taking into account the following suggestions for mapping: + + - Company name ==> "cdtr.name" (the name of the company that issued the invoice document, not the recipient) + - Invoice number ==> "invoice.number" + - Invoice Date ==> "invoice.date" + - Total ==> "invoice.total" (in EUR or if not available in USD or PLN) + - IBAN ==> "cdtr.iban" + - BIC or SWIFT ==> "cdtr.bic" + - Payment date / Due date ==> "invoice.duedate" + +Note: Output only the XML object! Don't add explanations or comments. Use only the XML structure specified in this example and do not create any other XML tags. If you don't have data for some fields, leave the corresponding XML tags blank. Format date values (invoice.date, invoice.duedate) into the ISO 8601 format (YYYY-MM-DD). Format numbers and amounts (type="double") according to ISO 4217. + +<> + +[/INST] + +]]]]> + + ]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + (^rechnungseingang-[a-z]{2,3}-\d+(?:\.\d+)?$) + 5000 + 990 + +]]> + + + + + + DataOutput_2 + + + DataOutput_2 + + sequenceFlow_gXJm0w + sequenceFlow_gpPDLg + sequenceFlow_I8Pggg + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + false + + https://llama.cpp.imixs.com/ + XML + + + +]]> + + + + + + DataOutput_2 + + + DataOutput_2 + + + sequenceFlow_fN22Gg + sequenceFlow_naZnAA + sequenceFlow_PgyOMw + + + + + {"n_predict": 512, "temperature": 0 } + ^.+\.([pP][dD][fF])$ + +[INST] Assign the invoice to one of the following categories: + +- Cargo-Invoice - in case the invoice is about cargo and logistic services +- Credit - in case of a credit note +- Invoice - in all other cases + +Extract also the company name and the language the invoice is written in. + +Note: The company name is the name of the company that issued the invoice document and not the name of the recipient. As a rule, it is not Alexander Global Logistics either. The company name is often at the beginning or end of the invoice document. + +Output the infromation as one XML object that has the following structure: + + + Type + Kraxi GmbH + German + + +Note: Do not generate any other information instead of the XML object. Do not generate more than one XML Object. + +[/INST] +]]]]> + + ]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + https://llama.cpp.imixs.com/ + invoice.summary + true + +false + +]]> + + + + + + DataOutput_2 + + + DataOutput_2 + + + sequenceFlow_8SpIiA + sequenceFlow_A62nqQ + sequenceFlow_Di4BQA + + + + + + + + + + + {"n_predict": 4096, "temperature": 0} + ^.+\.([pP][dD][fF])$ + +[INST] + +Summarize the data from this invoice document: + + - Vendor information + - General Billing data + - Invoice total information + - Payment summary (including bank data) + - Invoice items + +Note: The vendor information refers to the sender of the invoice. The company name is the name of the company that issued the invoice document and not the name of the recipient. As a rule, it is not Alexander Global Logistics either. The company name is often at the beginning or end of the invoice document. + +Use only the default values and do not perform any calculations, summing or changes to these values yourself. Format numbers and amounts according to ISO 4217. + +If possible summarize the invoice lines in a table. + +[/INST] +]]]]> + + ]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + + + + + + + + + + + + + + + + + + + sequenceFlow_Z8050g + sequenceFlow_0XHjPA + + + + + + sequenceFlow_WIiVnQ + + + + + + + + sequenceFlow_PgyOMw + + + + + sequenceFlow_Di4BQA + + + + + + + + + + + sequenceFlow_PWXjog + + + + + + + sequenceFlow_naZnAA + sequenceFlow_tcjWAA + sequenceFlow_I8o4DA + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + adapter.error_code: adapter.error_message]]> + + + false + + + + + + DataOutput_2 + + + DataOutput_2 + + sequenceFlow_tcjWAA + sequenceFlow_gpPDLg + sequenceFlow_d0zSHA + + + + + + + + + + + + + + + sequenceFlow_I8o4DA + sequenceFlow_VlPVJg + sequenceFlow_bh4DIw + sequenceFlow_d0zSHA + + + + + + + + + + + + + For the OCR Adapter the following minimal options should be set: + + * X-Tika-PDFocrStrategy=OCR_AND_TEXT_EXTRACTION + * X-Tika-OCRLanguage=eng+deu + +These options allow OCR and text extraction suporting English and German language. + +Additional Tika Options can be set but are NOT needed in most cases: + + * X-Tika-PDFOcrImageType=RGB (setting the RGB color mode) + * X-Tika-PDFOcrDPI=400 (setting DPI) + +Setting the OcrDPI is only recommended if the DPI is know! + +Possible ImageTypes are: + + * ARGB Alpha, Red, Green, Blue + * BINARY Black or white. + * GRAY Shades of gray + * RGB Red, Green, Blue + + + + + + sequenceFlow_YMtfiw + sequenceFlow_I8Pggg + sequenceFlow_0XHjPA + + + + + + + + + + + + + + + + + sequenceFlow_n3o55Q + + + + + + + + sequenceFlow_WBx7JQ + + + + + + + + sequenceFlow_B0T5KA + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +