Exercise - Create a topic with Copilot

Completed

Here, you create a conversational flow for your copilot.

Create a topic using Copilot

  1. Sign into Microsoft Copilot Studio.

  2. On the left-hand side of the screen, select Copilots and then select the copilot that you created in the previous exercise.

    Screenshot of selecting a copilot.

  3. When the copilot opens up, select the Topics tab.

    Topics are discrete conversation paths that, when used together, allow for users to have a conversation that feels natural and flows appropriately. They can be created manually or generated using natural language.

  4. Select + Add a topic > Create from description with Copilot.

    Screenshot of creating a topic from description with Copilot.

  5. A new window appears asking you to Name your topic and provide a description in the Create a topic to... space.

  6. In the Name your topic field, enter:

    Book a Real Estate Showing.

  7. In the Create a topic to... field, enter:

    Let someone book a real estate showing providing their full name, email, address of the property, and date and time of the showing.

    Then select Create.

    Screenshot of the topic creation window.

  8. You should see a new topic with the generated trigger phrases:

    Screenshot of the generated topic trigger phrases.

    Along with multiple question nodes, entity selection, and variable naming:

    Screenshot of the generated topic nodes.

    In summary, you should see:

    • A trigger node with the trigger phrases
    • A question node asking for the user's name
    • A question node asking for the user's email address
    • A question node asking for the property address
    • A question node asking for the date and time of the showing

    Delete any nodes that you don't need.

    Note

    Remember, your generated content may be different than what's shown here.

Edit a topic using Copilot

  1. Look for the What is your email address? question node and select it.

  2. Then select the Copilot icon in the upper part of the authoring canvas. This opens the Edit with Copilot panel on the right-hand side of the screen.

    Selecting the Copilot icon after selecting a node ensures that any changes you make with Copilot will be applied to that node.

  3. Within the Edit with Copilot panel, in the field What do you want to do?, enter:

    Update the Question node to say thank you to the FullName variable from the previous node and then proceed to ask the question

    Then select Update.

    Screenshot of updating a question node with Copilot.

  4. Copilot updates the What is your email address? question node to the following, which now includes the FullName variable from the message node before it:

    Screenshot of the updated question node.

    So with Copilot, in addition to adding new nodes, you can also update existing ones.

  5. Make sure no node is selected by clicking in the empty space around the nodes and then within the Edit with Copilot panel, in the field What do you want to do?, enter:

    Summarize the information collected in an adaptive card

    Then select Update.

  6. You'll then see that a message node with an Adaptive Card has been added to the end of the topic. Select the Adaptive Card.

  7. The Adaptive Card properties should appear on the right of the screen. Select the arrow icon to Expand the Adaptive Card formula.

    Screenshot of the Adaptive Card properties.

    Your Adaptive Card formula should look similar to the one above. If it doesn't, then you can copy and paste the following formula:

    {
    type: "AdaptiveCard", 
        body: 
        [
            {
                type: "TextBlock",
                size: "Medium",
                weight: "Bolder",
                text: "Summary"    
            },
            {
                type: "FactSet",
                facts: 
                [
                    {
                        title: "Full Name",
                        value: Text(Topic.FullName)
                    },
                    {
                        title: "Email Address",
                        value: Text(Topic.EmailAddress)
                    },
                    {
                        title: "Property Address",
                        value: Text(Topic.PropertyAddress)
                    },
                    {
                        title: "Date and Time",
                        value: Text(Topic.ShowingDateAndTime)
                    }
                ]
            },
            {
                type: "TextBlock",
                text: "Thank you for providing the information."
            }
        ]
    }
    
  8. Opening the Adaptive Card properties closes the Edit with Copilot panel; therefore, you need to select the icon to reopen it.

  9. Make sure that no node is selected by clicking in the empty space around the nodes. In the What do you want to do? field, enter the following text:

    Add a new multiple choice question to prompt the user if the details are correct with two options Yes or No

    Then select Update.

  10. A new question node is added to the end of the topic with options for the user to select.

    Screenshot of the multiple choice question node.

  11. In the top-right of the screen, select Save to save your Topic changes.

  12. Once saved, select Test in the top-right of the screen to open the Test your copilot pane.

  13. The Conversation Start message will appear, and your copilot will start a conversation. In response, enter a trigger phrase for the topic that you've created:

    I want to book a real estate showing

    And then you'll see it respond with the "What is your full name" question:

    Screenshot of the "What is your full name" question.

  14. Enter the rest of the information as prompted.

    "What is your full name?"

    <Your name>
    

    "Thank you, <Your name>! What is your email address?"

    <Your email address>
    

    "What is the address of the property?"

    555 Oak Lane, Denver, CO 80203
    

    "What date and time would you like to schedule the showing?"

    10/10/2023 10:00 AM
    
  15. Once all the information has been entered, you'll see the Adaptive Card with the information you entered and a question asking if the information is correct with the options to select either "Yes" or "No":

    Screenshot of the Adaptive Card with the information entered.

    After selecting one of the options, you can further develop the topic to either save the data in Dataverse via a Power Automate flow or send an email to the user with the information they entered. However this is outside the scope of this module.