Integrating ChatGPT with Copilot through Power Automate
Alona Soroka
Project manager / Team lead / SCM Functional Analyst Microsoft Dynamics 365 F&O
Continuing my previous Article in which I showed the way to set up ChatGPT connection in Power Automate flow, I would like to show how this connection can be used in Copilot.
In today’s fast-paced digital environment, organizations constantly seek ways to streamline operations and improve decision-making processes. One innovative approach involves integrating cutting-edge AI technologies, such as OpenAI's ChatGPT, with internal business applications like Copilot via Power Automate. This integration allows companies to leverage AI-generated insights directly in their workflows, significantly enhancing response capabilities and accuracy in various applications, from customer service to internal knowledge management.
Introduction to Power Automate
Power Automate, a component of the Microsoft Power Platform, is designed to help businesses create automated workflows between apps and services. These workflows can synchronize files, get notifications, collect data, and more, all without human intervention. The key advantage is the ability to design processes that trigger responses, perform tasks, and manage data across multiple services automatically.
Why Integrate ChatGPT with Copilot?
ChatGPT, developed by OpenAI, is a powerful language model that can understand and generate human-like text based on the input it receives. Integrating ChatGPT with Copilot through Power Automate enables businesses to:
Requirements:
Setting Up the Integration in Power Automate Flow
The integration of ChatGPT with Copilot involves several steps in Power Automate. Here is how to set it up:
Here are the detailed steps for the flow creation:
Step 1: Create a New Flow
Step 2: Configure Flow Trigger
Step 3: Initialize Variable
We need this variable for converting the ChatGPT answer into the string format instead of table, as I want to get my answer in Copilot String.
Step 4: Add Chat Completion Action
Please see detailed instructions of how to perform this action in my previous Article.
Step 5: Set Variable
Step 7: Respond to Copilot
领英推荐
Step 8: Save and Test
?
Creating a Copilot Topic and using the Power Automate Flow with ChatGPT
Overview:
This guide will walk you through the steps to create a topic in Copilot that captures a user's question and uses the GPT model to generate an answer, which is then relayed back to the user. This flow is particularly useful in scenarios like helpdesks, automated Q&A services, or interactive bots.
The integration of ChatGPT with Copilot through the Power Automate flow involves several steps in Copilot topic. Here is how to set it up:
Detailed steps to Create the Topic:
Step 1: Set Up the Trigger:
1.?????? Login into Copilot studio.
2.?????? Select desired Environment.
3.?????? Select already existing Copilot or create the new one.
4.?????? Navigate to Topics and create the new topic From blank.
5.?????? Trigger Type: Choose Dynamic chaining (preview) as the trigger. This allows the flow to start based on dynamic inputs.
6.?????? Description: Optionally, provide a description to explain what the flow does, such as "This flow generates answers to user questions using GPT."
Step 2: Capture User Input:
1.?????? Action Type: Add a Question action.
2.?????? Configure:
·??????? Prompt: Enter the text "What is your question?"
·??????? Identify: Choose how you want to capture the response, usually "User's entire response".
·??????? Save Response As: Name the variable to store the user's question, for example, GPTQuestion.
Step 3: Invoke the GPT Model:
1.?????? Action Type: Add an Action that sends the user's question to a GPT model. This could be labeled something like "GPT Chat Completion", depending on your ChatGPT connection flow name in Power Automate.
2.?????? Input: Pass the GPTQuestion variable as input to this action.
3.?????? Output: Ensure the output variable (e.g., Answer) is configured to capture the model's response. Output is the answer from the ChatGPT Flow in Power Automate.
Step 4: Send the Response Back:
1.?????? Action Type: Add a Message action.
2.?????? Message Content: Configure the message text to be "Here is your answer:" followed by the dynamic content Answer which holds the GPT model's output.
Step 5: Save and Test the Flow:
1.?????? Click on Save to save the configuration.
2.?????? Use the Test feature in Power Automate to ensure the flow works as expected. Enter a sample question and check if the correct response is generated.
You can also use this ChatGPT to create generic answers about your data in documents and external databases.
?
Senior Managing Director
5 个月Alona Soroka Great post! You've raised some interesting points.