After following the article, we created a smart weather forecast bot app successfully. Now in this article, we will see how to improve this weather forecast bot app features by editing Language Generation content (Bot Response) and bot design canvas.
This code means we will use prebuilt function convertFromUTC to calculate the target city time based on some time zone information, such as IANA time zone id, county info, day light saving info, etc. And wrap this logic in a template TimeZoneInfo. Then we can reuse it in other bot responses. For more information about LG (Language Generation) file format, check:
And set turn.timezone in the Result.Property field, the URL get request will save returned json result to this property:
This step means we will use coordinates information saved in this dialog, to get time zone information from Azure Maps service.
Click Start Bot, and input “how is the weather in Tokyo”, we can get improved answers from this Weather bot now.
9. In Composer, click Publish, select the publish profile we configured before, and click Publish selected bots, in put your Azure subscription account info, and click Okay to submit the bot to Azure. This may take 2 minutes.
Now you can follow this link and change one or more channels for this forecast bot app, so that other online users can access it: