In this Learn With The Nerds session, Jonathon Silva from Pragmatic Works walks viewers through the process of building autonomous agents using Copilot Studio. The tutorial focuses on creating a personalized AI assistant capable of dynamically handling tasks, integrating with Microsoft tools, and orchestrating workflows across multiple agents.
Understanding Agent Types in Copilot Studio
- Retrieval Agents: Basic chatbot-style agents that answer questions using data from sources like SharePoint, Excel, or SQL.
- Task-Oriented Agents: Agents that perform specific tasks using Power Automate workflows, such as device refresh requests or expense reporting.
- Autonomous Agents: Fully independent agents that dynamically decide how to complete tasks, escalate issues, and learn from past interactions.
Scenario: Landscaping Request Assignment
Jonathon demonstrates building an autonomous agent for a fictional landscaping company. The agent processes form submissions from customers and assigns requests to employees based on zip code coverage.
Step-by-Step Agent Creation
- Form Setup: A Microsoft Form collects customer details including name, email, zip code, and service type.
- Data Preparation: An Excel file contains employee information, including zip code territories.
- Trigger Configuration: The agent is triggered when a new form response is submitted.
- Tool Integration:
- Get response details from Microsoft Forms.
- List rows in Excel to match zip codes.
- Draft and send email notifications via Outlook.
- Add a row to a log table for record-keeping.
- Instruction Setup: Clear, step-by-step instructions guide the agent on how to use each tool and complete the task.
Agent-to-Agent Handoff
Jonathon introduces a child agent that sends a Teams message to a supervisor once a request is assigned. This showcases how agents can collaborate and escalate tasks autonomously.
Testing and Validation
- Form submissions trigger the agent successfully.
- Emails and Teams messages are sent dynamically.
- Logs are updated with correct customer and employee data.
Best Practices for Autonomous Agents
- Use numbered steps and clear syntax in instructions.
- Provide examples and guardrails to guide agent behavior.
- Leverage Power Platform connectors for seamless integration.
- Publish agents to enable agent-to-agent communication.
Conclusion
This session provides a comprehensive guide to building autonomous agents in Copilot Studio. By combining triggers, tools, and clear instructions, users can create powerful AI assistants that streamline business processes and enhance productivity. Pragmatic Works continues to lead in training and innovation around Microsoft technologies.
Don't forget to check out the Pragmatic Works' on-demand learning platform for more insightful content and training sessions on Copilot Studio and other Microsoft applications. Be sure to subscribe to the Pragmatic Works YouTube channel to stay up-to-date on the latest tips and tricks.