HOTSPOT - You are building a chatbot by using the Microsoft Bot Framework SDK. You use an object named UserProfile to store user profile information and an obje...


Microsoft AI-102 Exam

Questions Number: 189 out of 241 Questions
78.42%

Question 189
HOTSPOT -
You are building a chatbot by using the Microsoft Bot Framework SDK.
You use an object named UserProfile to store user profile information and an object named ConversationData to store information related to a conversation.
You create the following state accessors to store both objects in state. var userStateAccessors = _userState.CreateProperty<UserProfile>(nameof(UserProfile)); var conversationStateAccessors = _conversationState.CreateProperty<ConversationData>(nameof(ConversationData));
The state storage mechanism is set to Memory Storage.
For each of the following statements, select Yes if the statement is true. Otherwise, select No.
NOTE: Each correct selection is worth one point.
Hot Area:
AI-102_189Q.png related to the Microsoft AI-102 Exam



Box 1: Yes -
You create property accessors using the CreateProperty method that provides a handle to the BotState object. Each state property accessor allows you to get or set the value of the associated state property.
Box 2: Yes -
Box 3: No -
Before you exit the turn handler, you use the state management objects' SaveChangesAsync() method to write all state changes back to storage.
Reference:
https://docs.microsoft.com/en-us/azure/bot-service/bot-builder-howto-v4-state





Previous Questions Next Questions