官术网_书友最值得收藏!

Testing context and no context scenarios

Let's test the context using Google Assistant simulator from the Dialogflow console. In the Try it now textbox, enter my name is Henry and you will see the response, Henry you can ask me anything about the president of America. Notice that, in the Contexts section, it shows that the GET_NAME context is set and also has the username parameter value of Henry.

The following screenshot shows us testing the get_name context:

Testing the get_name context

If you enter the next question, I want to know John Adams' birthday, you will see that the response contains the username when responding about the president's birthday.

The following screenshot shows the debugger showing the Get President Birthday intent with the get_name context:

Testing the Get President Birthday intent with the get_name context

Test out the no context scenario by typing in, What is his birthday?. The intent will trigger the prompt, asking Which president's birthday would you like to know? When you respond with George Washington, the response returns George Washington's birthday.

The following screenshot shows the intent triggering the prompt, asking the user which president's birthday they would like to know about:

  
Testing no context

The following screenshot shows the chatbot providing the president's name as a response to Get President Birthday:

Providing the president's name as a response

In the following section, you will learn how to actually test FaqChatBot using your iPhone or Android mobile device.

主站蜘蛛池模板: 密山市| 枣强县| 墨竹工卡县| 儋州市| 定西市| 寻乌县| 长阳| 宝清县| 弥渡县| 蒲城县| 个旧市| 临沧市| 望奎县| 沧源| 咸丰县| 东光县| 竹溪县| 凌云县| 东至县| 宜宾市| 永和县| 逊克县| 宜春市| 揭东县| 夹江县| 郸城县| 贵港市| 读书| 北票市| 安图县| 游戏| 玛纳斯县| 浮山县| 甘洛县| 广东省| 太仆寺旗| 康乐县| 南溪县| 方山县| 宝兴县| 阿克|