Forum Discussion

arie_schwartzman's avatar
Dec 26, 2022

Using Azure's Face API to detect faces from a locally uploaded image

Health bot supports uploading of files from local file systems. The files are temporarily stored on the Bot framework's infrastructure and access to them is only available to the holder of an exceedingly long URL.

 

This can open various use cases, for example, having the patient upload some image of a medical condition via the bot, the bot can then use some cognitive service to detect the condition and answer the patient based on the uploaded image. 

 

In this example, we will use the Face API to detect faces in an image uploaded from the local file system. 

 

On the left you can see the scenario flow in which we first prompt for file upload, the canvas in response displays the prompt text and the "paper clip" icon is ready to be clicked and image can be selected from the file system (or Camera Roll on a mobile device). 

 

 

Prompt the user for an Image.

 

 

 

Once the image is selected, we then proceed to call the Face API using the "Data Connection" step. 

 

 

We pass the URL of the uploaded image and calling the REST API for API Detection and use the subscription key I have copied from the Azure Cognitive Services resource I have created. 

 

 

 

No RepliesBe the first to reply

Resources