cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
y51
Frequent Visitor

Extract Invoice Data with AI Builder and upload the File on Sharepoint

Hello,

I get my PDF Invoiceses via Mail.

y51_0-1633527116792.png

But what I really want is to get when my AI Builder find the contact of my Organisation in the Invoice , that he get an E-Mail so he can enable the payment.

Ansprechpartner.PNG

 Moreover I want that my invoice date can allways displayed on my Sharepoint list. I live in Germany so I have to do this: Convert Europe date notation in Power Automate to US date notation in Power Automate - YouTube

Rechnungsdatum2.PNG

What did I do when the MM is not a number, and is named "January", "Febuary" etc.?

For example

y51_1-1633527677825.png

How can I do a switch-case? Or is there any other possibilities which are useful in my requirement?

 

Besides that I want extract the  invoice amount. The Problem is it allways look diffrent.

for example:

y51_2-1633528086400.pngy51_3-1633528117207.png

I tried something but it not work often (maybe my AI Builder needs more Data)

I split the "," and "." and connect it together.

y51_4-1633528485198.png

Rechnungsbetrag2.PNG

Can someone help me?

 

Best regards

y51

2 ACCEPTED SOLUTIONS

Accepted Solutions
Antrod
Microsoft
Microsoft

Hi @y51,

 

Thanks for reaching out. AI Builder models render the fields as they "see" them in the document, so indeed post-processing needs to be done in some cases, for example when date formats vary between documents. It seems you are on the right approach trying to retructure your strings to comply with the ISO format and then apply Power Automate conversion functions (formatDateTime for example).

 

Try to use either the isMatch function to detect you format (using regular expressions) or Find function, to determine the original format of your string and apply the Switch control if you need to apply different logic branches in your flow.

 

Providing more examples to your AI Builder model is also a great idea if you see that some fields are not correctly extracted (for example if it sometimes confuses "," and "." within numbers).

 

Thanks.

View solution in original post

kv
Helper II
Helper II

Got it. The confidence tells me how certain the chunk of text represents e.g. an invoice date, but nothing about the content.

View solution in original post

7 REPLIES 7
Antrod
Microsoft
Microsoft

Hi @y51,

 

Thanks for reaching out. AI Builder models render the fields as they "see" them in the document, so indeed post-processing needs to be done in some cases, for example when date formats vary between documents. It seems you are on the right approach trying to retructure your strings to comply with the ISO format and then apply Power Automate conversion functions (formatDateTime for example).

 

Try to use either the isMatch function to detect you format (using regular expressions) or Find function, to determine the original format of your string and apply the Switch control if you need to apply different logic branches in your flow.

 

Providing more examples to your AI Builder model is also a great idea if you see that some fields are not correctly extracted (for example if it sometimes confuses "," and "." within numbers).

 

Thanks.

y51
Frequent Visitor

When I use a switch-case for the Month (January, February) e.g. I can test it then the values disappear. Iam so frustrated now I use a When function. It don't look nice but it works 🙂

Hi @Antrod ,

Thank you! What do you mean by:

 

> Providing more examples to your AI Builder model is also a great idea if you see that some fields are not correctly extracted (for example if it sometimes confuses "," and "." within numbers).

 

How do I train the model e.g. to use the comma (",") as decimal separator instead of a dot (".")?

Antrod
Microsoft
Microsoft

Hi @kv ,

 

There's no option to use comma instead of dot but providing more examples can help recognize fields better. Anyway, quality of the predicted document is also very important: for example, if the dots and commas look very similar, even to a human eye, the model can also confuse both.

 

Thanks.

kv
Helper II
Helper II

Thank you, @Antrod .

 

Even if the document has the best possible quality, if the date "15.11.2021" cannot be recognized because there is no 15th month then it's hard to use. Can I teach the model somehow to recognize those dates (dd.MM.yyyy)?

Antrod
Microsoft
Microsoft

The model doesn't extract "dates" per say but only "text". If you want to turn this text into a date, you have to do it in as a post processing step in your flow with the formatDateTime function.

kv
Helper II
Helper II

Got it. The confidence tells me how certain the chunk of text represents e.g. an invoice date, but nothing about the content.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Top Solution Authors
Top Kudoed Authors
Users online (4,146)