Domain 2 β€” Module 8 of 12 67%
18 of 28 overall
Domain 2: Integrate and Extend Agents in Copilot Studio Free ⏱ ~14 min read

Integrating Foundry Agents

Understand Microsoft Foundry as an AI platform and connect Foundry agents to Copilot Studio for advanced reasoning and custom model capabilities.

What is Microsoft Foundry?

Simple explanation

Think of Copilot Studio as a restaurant kitchen and Foundry as a gourmet chef you can hire.

Your kitchen (Copilot Studio) has everything you need for most meals β€” ovens, stoves, standard recipes. But when a customer orders a complex molecular gastronomy dish, you bring in a specialist chef (Foundry) who has training, custom techniques, and specialised equipment your kitchen does not have.

Foundry is Microsoft’s AI platform where developers build agents using custom models, advanced reasoning, and specialised AI capabilities. When Copilot Studio’s built-in AI is not enough β€” say, you need medical image analysis or complex financial modelling β€” you build that piece in Foundry and connect it back to Copilot Studio as a connected agent.

Copilot Studio vs Foundry β€” when to use which

Both platforms build agents, but they serve different developer profiles and use cases. Understanding the boundary is key for the exam.

Copilot Studio vs Foundry β€” complementary platforms
FeatureBest forDeveloper profileAI modelsDeployment
Copilot StudioConversational agents with topic routing, enterprise channels, M365 integrationLow-code / citizen developers and pro-devs doing integration workBuilt-in GPT models β€” you do not choose or fine-tune themTeams, M365 Copilot, websites, custom channels β€” built-in channel support
Microsoft FoundryCustom AI logic β€” advanced reasoning, domain models, multi-step AI workflowsAI engineers and developers comfortable with Python SDKs, REST APIs, and model selectionFull model catalog β€” GPT-4o, GPT-4o mini, Phi, Llama, Mistral; supports fine-tuningAPI endpoints, Azure-hosted β€” needs Copilot Studio or custom frontend for conversational UX
Best togetherCopilot Studio handles conversation + channels; Foundry handles complex AI reasoning behind the scenesCopilot Studio dev builds the orchestrator; AI engineer builds the Foundry agentCopilot Studio uses default model for routing; Foundry uses specialised model for domain tasksUser talks to Copilot Studio agent in Teams; Copilot Studio calls Foundry agent for heavy AI work

How integration works

Connecting a Foundry agent to Copilot Studio follows the same connected agent pattern you learned in the multi-agent module β€” but the connected agent lives in Foundry instead of Copilot Studio.

Integration steps:

  1. Build the Foundry agent β€” create an agent in Foundry using the Agent SDK, configure its model, tools, and knowledge sources
  2. Deploy the Foundry agent β€” deploy to an Azure endpoint so it has a reachable URL
  3. Register in Copilot Studio β€” in your orchestrator agent, go to Settings then Connected agents then Add then Foundry agent
  4. Configure the connection β€” provide the Foundry agent’s endpoint and authentication details
  5. Set trigger descriptions β€” define when the orchestrator should route to the Foundry agent
  6. Test the handoff β€” verify that context passes correctly and the Foundry agent returns structured results
What gets passed between the agents?

When Copilot Studio routes to a Foundry connected agent, it sends the conversation context (user message, relevant variables, and any context you configure). The Foundry agent processes this with its own model and tools, then returns a response. The orchestrator presents this response to the user.

Key point: the Foundry agent runs in its own security context with its own Azure credentials. It does not inherit the Copilot Studio agent’s DLP policies β€” you must configure security on both sides.

When to use Foundry agents

Not every scenario needs Foundry. Here are the signals the exam uses:

SignalUse FoundryStay in Copilot Studio
Custom model neededMedical diagnosis, legal reasoning, domain-specific fine-tuned modelStandard Q&A, policy lookup, FAQ
Advanced reasoningMulti-step analysis, chain-of-thought, complex calculationsSimple routing, data retrieval, form filling
Model choice mattersNeed Phi for cost efficiency or GPT-4o for accuracy on specific tasksDefault model handles the task well
Evaluation pipelinesNeed systematic model evaluation with test datasetsManual testing in Copilot Studio is sufficient
Python/code-firstTeam prefers Python SDKs, wants full control over agent logicTeam prefers low-code visual authoring
Scenario: Lena builds clinical decision support with Foundry

Lena’s healthcare analytics firm needs an agent that helps doctors interpret lab results. The agent must:

  • Use a fine-tuned medical model that understands clinical terminology (Copilot Studio’s default model is not trained on medical data)
  • Run multi-step reasoning β€” compare results against reference ranges, flag anomalies, suggest follow-up tests
  • Pull from a curated medical knowledge base indexed in Azure AI Search
  • Return structured citations so doctors can verify every recommendation

Lena builds this as a Foundry agent: she selects GPT-4o from the model catalog, connects it to the medical knowledge index, and writes evaluation tests against real clinical scenarios. Then she works with the IT team’s Copilot Studio developer who adds Lena’s Foundry agent as a connected agent in the hospital’s employee assistance bot. Doctors talk to the bot in Teams β€” routine HR and IT questions go to other connected agents, but lab interpretation routes to Lena’s Foundry agent.

Exam tip: Foundry is for what Copilot Studio cannot do alone

If the exam describes a scenario where the built-in model is insufficient β€” custom training, domain-specific reasoning, model selection β€” Foundry is the answer. If the scenario just needs a new knowledge source or connector, stay in Copilot Studio.

Question

What is Microsoft Foundry?

Click or press Enter to reveal answer

Answer

Microsoft's unified AI platform for building code-first agents. It offers a model catalog (GPT-4o, Phi, Llama, etc.), prompt engineering tools, fine-tuning, evaluation pipelines, and an Agent SDK. Formerly called Azure AI Studio.

Click to flip back

Question

How do you connect a Foundry agent to Copilot Studio?

Click or press Enter to reveal answer

Answer

Add it as a connected agent: Settings β†’ Connected agents β†’ Add β†’ Foundry agent. Provide the Foundry agent's endpoint URL and authentication details, then set trigger descriptions for when the orchestrator should route to it.

Click to flip back

Question

When should you use Foundry instead of building everything in Copilot Studio?

Click or press Enter to reveal answer

Answer

When you need custom models, fine-tuning, advanced multi-step reasoning, specific model selection (e.g., Phi for cost, GPT-4o for accuracy), or Python SDK-based agent development that Copilot Studio's low-code canvas cannot support.

Click to flip back

Question

What is the key architectural benefit of combining Copilot Studio with Foundry?

Click or press Enter to reveal answer

Answer

Copilot Studio handles conversational UX (channels, authentication, topic routing) while Foundry handles complex AI reasoning (custom models, RAG pipelines, evaluation). Each platform does what it does best.

Click to flip back

Knowledge Check

Lena needs her healthcare agent to use a fine-tuned medical model for lab result interpretation. Where should she build this capability?

Knowledge Check

What is the primary advantage of the Copilot Studio + Foundry pattern over building entirely in Foundry?