Placeholder image

Autonomous Agents with Copilot Studio

| Robin Rosengrün |

Copilot Studio Agents


Episode #252

Introduction

In episode 252 of our SAP on Azure video podcast we talk about Autonmous Agents.

A few weeks back we had several hands-on sessions during the DSAG TechXChange event. One of the most popular sessions were the Copilot Studio & SAP sessions. I was lucky to work with Robin Rosengrün on those and although we had a recap session, Robin wasn’t able to join our podcast at this time.

Now I am happy to have him with us to talk about Copilot Studio, Autonomous agents, when to use them and also look at the new Agent feed.

Links:

Find all the links mentioned here: https://www.saponazurepodcast.de/episode252

Reach out to us for any feedback / questions:

#Microsoft #SAP #Azure #SAPonAzure #CopilotStudio #Agents #PowerPlatform

Summary created by AI

  • Overview and Use Cases for Copilot Studio Autonomous Agents:
  • Holger, Goran, and Robin discussed the evolution and practical use cases of Copilot Studio autonomous agents, emphasizing their application in business processes, particularly in customer service scenarios, and the distinction between autonomous and deterministic automation.
    • Introduction to Copilot Studio Agents: Robin explained the difference between conversational agents and autonomous agents in Copilot Studio, highlighting that most business scenarios benefit from autonomous agents that operate in the background, only involving humans when necessary.
    • Deterministic vs. Generative Automation: The team discussed when to use deterministic tools like Power Automate for predefined, step-by-step processes, and when to leverage generative AI for more complex, less predictable scenarios, such as customer service queries that require dynamic orchestration of multiple tools.
    • Customer Service Scenario Example: Robin presented a customer service use case with four core actions—FAQ lookup, order lookup, answering questions, and escalation to humans—demonstrating how even a small set of actions can create complex decision trees that are better managed by generative AI orchestration.
    • Combining Automation Approaches: The discussion included the value of combining autonomous agents with deterministic workflows, allowing agents to trigger structured processes when appropriate, and using generative AI for orchestration when the path is not clear-cut.
  • Technical Implementation of Autonomous Agents with SAP Integration:
  • Robin provided a detailed walkthrough of building an autonomous agent in Copilot Studio, including integration with SAP via Power Automate, configuration of tools and triggers, and handling of data and responses.
    • Agent and Tool Configuration: Robin demonstrated how to set up a new agent in Copilot Studio, add knowledge sources (such as a PDF FAQ), and configure tools for order lookup, answering questions, and escalation, including the use of system prompts and tool references for improved orchestration.
    • Power Automate Flow for SAP Order Lookup: The process of connecting Copilot Studio to SAP was shown using a Power Automate flow with an OData connector, where the agent passes an order ID to retrieve order details, and the flow returns structured data for the agent to use in its response.
    • Error Handling and Debugging: During the demo, a connection issue with the SAP system was encountered and resolved, illustrating the importance of monitoring flow status, reviewing run histories, and debugging integration points between Copilot Studio and external systems.
    • Data Structuring and Prompt Engineering: Robin emphasized the need to pass only relevant, well-structured data (e.g., using XML tags) to the agent to improve LLM processing, and described how prompt engineering—such as specifying HTML formatting and field descriptions—affects the quality and format of agent responses.
    • Triggering Agents from Business Events: The team discussed various ways to trigger autonomous agents, including database changes, SAP events via Event Mesh, and other business system events, allowing agents to respond automatically to real-time business activities.
  • Agent Feed and Human-AI Collaboration in Business Processes:
  • Robin introduced the agent feed feature in model-driven apps, explaining how it supports collaboration between multiple autonomous agents and human team members by tracking agent activities, surfacing to-do items, and enabling human intervention when needed.
    • Agent Feed Functionality: The agent feed provides a social-media-like activity stream where users can see what actions agents have taken, review completed tasks, and identify where agents require human assistance, supporting transparency and accountability in automated processes.
    • Human-in-the-Loop Scenarios: The discussion covered scenarios where agents escalate tasks to humans for review or approval, such as confirming an answer before sending an email, and how Power Automate can be used to integrate approval steps into the agentic workflow.
    • Collaboration and Task Management: Robin described how the agent feed allows teams to coordinate responses, avoid duplicate work, and ensure that human intervention is tracked and visible to all team members, enhancing the overall efficiency and reliability of business process automation.
  • Best Practices and Lessons Learned in Deploying Autonomous Agents:
  • The participants shared practical advice on deploying autonomous agents, including the importance of choosing the right automation approach, minimizing unnecessary data sent to LLMs, and iteratively refining prompts and workflows to address new challenges.
    • Choosing Automation Approaches: Robin and Holger advised using deterministic automation for straightforward, rule-based processes, and reserving generative orchestration for complex scenarios where multiple tools and knowledge sources must be combined dynamically.
    • Optimizing Data for LLMs: The team highlighted the need to streamline data passed to LLMs, removing irrelevant fields and using clear, structured formats to improve processing efficiency and answer quality.
    • Prompt Engineering and Response Formatting: Robin shared experiences with prompt engineering, such as specifying HTML formatting and providing detailed field descriptions, to ensure that agent responses meet business requirements and are presented in the desired format.