Use Generative AI in Microsoft Copilot Studio

Scenario

In this lab, you will:

  • Create copilot actions

What you will learn

  • How to use the Generative answers feature to improve your copilot’s responses.

High-level lab steps

  • Enable Generative AI
  • Add knowledge

Prerequisites

  • Must have completed Lab: Create copilot actions

Detailed steps

Exercise 1 - Configure Generative AI

Task 1.1 - Enable Generative AI

  1. Navigate to the Microsoft Copilot Studio portal https://copilotstudio.microsoft.com and ensure you are in the appropriate environment.

  2. Select the Test button in the upper-right of the screen to close the testing panel if the panel is open.

  3. Select Copilots from the left navigation pane.

  4. Select the copilot you created in the earlier lab.

  5. Select Settings in the upper-right of the screen.

  6. Select the Generative AI tab.

    Generative AI pane in CoPilot Studio Settings

  7. Select Generative under How should your copilot decide how to respond.

  8. Select Medium for Copilot content moderation.

  9. Select Save.

  10. Close the Settings pane.

Task 1.2 - Use generative answers in the Conversational boosting topic

  1. Select the Topics tab and select System.

  2. Select the Conversational boosting topic.

    Screenshot of the Conversational boosting topic nodes.

  3. Review the Create generative answers node.

Task 1.3 - Enable knowledge

  1. Select the Overview tab.

  2. Verify that general knowledge is enabled.

    Screenshot of the general knowledge enabled.

  3. You should see the public website added as knowledge in Lab 1.

Task 1.4 - Configure Authentication

  1. Select Settings in the upper-right of the screen.

  2. Select the Security tab.

  3. Select the Authentication tile.

  4. Select Microsoft Entra ID authentication in Teams and Power Apps.

  5. Select Save.

  6. Select Save.

  7. Select Close.

  8. Close the security pane.

  9. Select Publish and select Publish again.

Exercise 2 - Add knowledge

Task 2.1 - Add knowledge from Dataverse

  1. Select the Knowledge tab.

  2. Select + Add knowledge.

  3. Select Dataverse.

  4. Select the Real Estate Property table

    Screenshot of adding website knowledge.

  5. Select Next.

  6. Select Next.

  7. Select Add.

Task 2.2 - Add knowledge from files

  1. Download this Microsoft case study or SummitRealtyCaseStudy.docx from GitHub.

  2. Select + Add knowledge.

  3. Select Files.

  4. Browse and select the case study that you downloaded.

    Screenshot of adding file knowledge.

  5. Select Add.

    Screenshot of knowledge.

Exercise 3 - Configure Fallback topic

Task 3.1 - Use generative answers in System fallback topic

  1. Select the Topics tab and select System.

  2. Select the Fallback topic.

    Screenshot of the system fallback topic nodes.

  3. Select the three dots in the message node and select Delete.

  4. Select the the + icon under the Condition node, select Advanced, and select Generative answers.

  5. Select Activity.Text for the Input field.

  6. Select Edit under Data sources.

    Screenshot of the create generative answers node.

  7. Select Search only selected sources.

  8. Select the Real Estate Property Dataverse table.

  9. Deselect Allow the AI to use its own general knowledge.

  10. Select Medium for Content moderation.

    Screenshot of the generative answers configuration.

  11. Select Save.

Exercise 4 - Test Generative AI

Task 4.1 Test the copilot’s knowledge

  1. Select the Test button in the upper-right of the screen to open the testing panel.

  2. Select the Conversation map icon at the top of the testing panel in the upper-right of the screen.

    Screenshot of the Testing panel conversation map.

  3. Select On..

  4. Select the Start a new conversation icon at the top of the testing panel.

  5. Explore the copilot and see how it uses the knowledge sources.