Skip to Content
Solution PlaysPlay 40: Play 40 β€” Copilot Studio Advanced

Play 40 β€” Copilot Studio Advanced

Production-grade Microsoft Copilot Studio solution with declarative agents, TypeSpec API plugins, Graph API data grounding, SSO/OAuth2, adaptive card responses, Power Automate integration, and enterprise admin controls.

Architecture

ComponentServicePurpose
Bot PlatformMicrosoft Copilot Studio (Premium)Declarative agent runtime, topic routing, conversation management
API PluginsTypeSpec β†’ OpenAPI 3.0Custom backend operations (incidents, projects, tasks)
Data GroundingMicrosoft Graph ConnectorsSharePoint, Outlook, Teams, Planner data access
AuthenticationEntra ID SSO/OAuth2Single sign-on, token exchange, permission scoping
OrchestrationAzure OpenAI (GPT-4o)Intent classification, response generation, plugin routing
WorkflowsPower AutomateEscalation flows, approval chains, notifications
ResponsesAdaptive Cards v1.5Rich interactive cards in Teams with actions/deep links
SecretsAzure Key VaultGraph credentials, OpenAI key, plugin auth

πŸ“ Full architecture details

How It Differs from Play 08 (Copilot Studio Bot)

AspectPlay 08 (Basic)Play 40 (Advanced)
Agent typeStandard topicsDeclarative agents with $[file]() instructions
PluginsBasic connectorsTypeSpec API plugins with OAuth2
GroundingFAQ knowledge baseGraph Connectors (SharePoint, Outlook, Teams)
AuthBasic authSSO with token exchange, permission scoping
ResponsesText + basic cardsAdaptive Cards v1.5 with actions
WorkflowsSimple flowsPower Automate with multi-stage approvals
AdminBasic settingsEnterprise admin controls, audit logging, data retention
Multi-turnLimited context10-turn context with summarization

DevKit Structure

40-copilot-studio-advanced/ β”œβ”€β”€ agent.md # Root orchestrator with handoffs β”œβ”€β”€ .github/ β”‚ β”œβ”€β”€ copilot-instructions.md # Domain knowledge (<150 lines) β”‚ β”œβ”€β”€ agents/ β”‚ β”‚ β”œβ”€β”€ builder.agent.md # Declarative agents + plugins + Graph β”‚ β”‚ β”œβ”€β”€ reviewer.agent.md # SSO/OAuth2, permissions, safety β”‚ β”‚ └── tuner.agent.md # Plugin latency, context, cost β”‚ β”œβ”€β”€ prompts/ β”‚ β”‚ β”œβ”€β”€ deploy.prompt.md # Deploy bot + plugins + connectors β”‚ β”‚ β”œβ”€β”€ test.prompt.md # Test plugin routing + context β”‚ β”‚ β”œβ”€β”€ review.prompt.md # Audit SSO + permissions β”‚ β”‚ └── evaluate.prompt.md # Measure routing accuracy + grounding β”‚ β”œβ”€β”€ skills/ β”‚ β”‚ β”œβ”€β”€ deploy-copilot-studio-advanced/ # Full deployment with TypeSpec + Graph β”‚ β”‚ β”œβ”€β”€ evaluate-copilot-studio-advanced/ # Plugin accuracy, grounding, conversation β”‚ β”‚ └── tune-copilot-studio-advanced/ # Instructions, plugin, Graph, cost tuning β”‚ └── instructions/ β”‚ └── copilot-studio-advanced-patterns.instructions.md β”œβ”€β”€ config/ # TuneKit β”‚ β”œβ”€β”€ openai.json # Model + conversation context settings β”‚ β”œβ”€β”€ guardrails.json # Safety, admin controls, performance β”‚ └── agents.json # Plugin config, routing thresholds β”œβ”€β”€ infra/ # Bicep IaC β”‚ β”œβ”€β”€ main.bicep β”‚ └── parameters.json └── spec/ # SpecKit └── fai-manifest.json

Quick Start

# 1. Deploy backend + register bot + configure Graph connectors /deploy # 2. Test plugin routing and conversation context /test # 3. Review SSO scoping and permission boundaries /review # 4. Evaluate plugin accuracy and grounding quality /evaluate

Cost

ServiceDevProdEnterprise
Copilot Studio$0 (Trial)$200 (Per-session)$600 (Capacity Pack)
Azure OpenAI$40 (PAYG)$300 (PAYG)$1,000 (PTU)
Dataverse$0 (Included)$40 (Included+Capacity)$120 (Capacity Pack)
Microsoft Graph API$0 (Included)$0 (Included)$0 (Included)
Azure AI Search$0 (Free)$75 (Basic)$250 (Standard S1)
Azure Functions$0 (Consumption)$15 (Consumption)$120 (Premium EP1)
Key Vault$1 (Standard)$3 (Standard)$10 (Premium HSM)
Application Insights$0 (Free)$20 (Pay-per-GB)$80 (Pay-per-GB)
Total$41/mo$653/mo$2,180/mo

πŸ’° Full cost breakdown

Key Metrics

MetricTargetDescription
Plugin Routing Accuracy> 92%Correct function called for user intent
Groundedness> 0.85Response grounded in Graph data
Context Retention> 90%Remembers 5+ turns of context
SSO Success Rate> 95%Silent token acquisition
Adaptive Card Rendering> 99%Cards display without errors
Cost per Conversation< $0.255-15 turns average

WAF Alignment

PillarImplementation
ReliabilityPlugin retry with exponential backoff, Graph connector health checks
SecuritySSO/OAuth2 with least-privilege scoping, PII blocking, audit logging
Cost Optimizationgpt-4o-mini for routing, Graph result caching, conversation summarization
Operational ExcellencePower Automate for escalation, admin portal, data retention policies
Performance EfficiencyPlugin response caching, batched Graph calls, adaptive card pre-rendering
Responsible AIContent safety filters, groundedness enforcement, source attribution

FAI Manifest

FieldValue
Play40-copilot-studio-advanced
Version1.0.0
KnowledgeF4-GitHub-Agentic-OS, O6-Copilot-Extend, O3-MCP-Tools-Functions
WAF Pillarssecurity, reliability, operational-excellence, responsible-ai
Groundednessβ‰₯ 85%
Safety0 violations max
Last updated on