Weather
The Weather solution contains a weather flow that gets the current weather for a city using the free tier Weather API from Openweather.
Core concepts
- Integration
- External weather service
- Extended Teneo Web Chat functionality
- Slot filling
- Data actions
- Match requirements
- Topic handling
- Follow ups
Example conversation
User: What is the weather like?
Bot: For which city?
User: Amsterdam
Bot: The weather in Amsterdam is 15.40 °C degrees with light cloud.
User: What is the weather like in Stockholm?
Bot: The weather in Stockholm is 10.00 °C degrees with clear sky.
User: What is the forecast?
Bot: For which city?
User: Barcelona
Bot: The weather in Barcelona is 19.95°C degrees with few clouds.
User: What about London?
Bot: The weather in London is 14.6°C degrees with broken clouds.
User: Do I need my umbrella with me?
Bot: For which city?
User: Barcelona
Bot: You will not need your umbrella. The weather in Barcelona is 19.95°C degrees with few clouds.
User: Do I need my umbrella with me to Istanbul?
Bot: You will need your umbrella. The weather in Istanbul is 25.5°C degrees with rain.
Solution components
Name | Type | Description |
---|---|---|
Weather | Folder | The solution folder that holds a flow and other folders. |
Weather flow | Flow | A slot filling flow in which allows the user to get the weather by city. The user can also decide to ask for accesories nessecary such as umbrella and sunglasses. |
Weather integration | Integration | An integration that contains the method to retrieve the weather information from the service. The weather service Openweather is used to get the weather. |
weatherAPI | Global variable | The API key used to communicate with the service. |
weatherTemperatureScale | Global variable | Used for controlling which temperature scale to use. Contains one letter ‘C’ for Celsius. Change the "C" to an "F" to get Fahrenheit. If left empty it will return the temperature scale in Kelvin. |
Weather | Order Group | This is an order group for triggers used by the solution. |
Download
- Download the solution Weather bot.
- Import the solution into Teneo studio. We recommend you to import it into a solution that is based on the Teneo Dialogue Resources English.
- If you are using the solution together with Teneo Dialog Resources, disable the flow 'The user comments on the weather' in the folder 'Dialogue' -> 'Conversational' -> 'Conversation'. Otherwise, this flow will steal inputs from the solution you are about to import.