# hareeshpalagiri/mslearn-ai-agents architecture

> Architecture diagram of the GitHub repository hareeshpalagiri/mslearn-ai-agents, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-14). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/hareeshpalagiri/mslearn-ai-agents
- Repository: https://github.com/hareeshpalagiri/mslearn-ai-agents

## Overview

This repository is a collection of hands-on Python labs for developing AI agents on Azure, rather than one deployable application. The learning path moves from agent tools and integrations to knowledge access, workflows, multi-agent collaboration, and agent evaluation and security. The A2A sample shows a concrete runtime flow: a user message reaches the routing server, which invokes a routing agent that can delegate work to specialized remote agents. Most other connections are documented only as exercise topics; their runtime wiring is not established by the sampled source.

Main entry points: [`Labfiles/09-build-remote-agents-with-a2a/python/routing_agent/agent.py`](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/routing_agent/agent.py) (Routing agent), [`Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/agent_executor.py`](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/agent_executor.py) (Outline executor), [`Labfiles/09-build-remote-agents-with-a2a/python/title_agent/agent_executor.py`](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/title_agent/agent_executor.py) (Title executor), [`Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/server.py`](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/server.py) (Outline server)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_fundamentals["Agent fundamentals"]
  node_custom_tools["Custom tools<br/>[functions.py]"]
  node_portal_agent["Portal agent"]
  node_mcp_agent["MCP agent<br/>[agent.py]"]
  node_mcp_client["MCP client<br/>[client.py]"]
  node_mcp_server["MCP server<br/>[server.py]"]
end

subgraph group_knowledge["Knowledge and apps"]
  node_foundry_iq["Foundry IQ agent<br/>[agent_client.py]"]
  node_teams_integration["Teams integration<br/>[m365_teams_lab.py]"]
  node_search_setup["Search setup<br/>[setup_search.py]"]
  node_work_iq["Work IQ lab<br/>[workiq_lab.py]"]
  node_enterprise_agent["Knowledge agent<br/>[knowledge_agent.py]"]
  node_knowledge_chat["Knowledge chat"]
end

subgraph group_orchestration["Workflow and orchestration"]
  node_foundry_workflow["Foundry workflow<br/>[workflow.py]"]
  node_agent_framework["Agent framework<br/>[agent-framework.py]"]
  node_multi_agent["Agent orchestration<br/>[agents.py]"]
  node_a2a_client["A2A client<br/>[client.py]"]
  node_routing_server["Routing server<br/>[server.py]"]
  node_routing_agent["Routing agent<br/>[agent.py]"]
  node_outline_agent["Outline agent<br/>[agent.py]"]
  node_outline_executor["Outline executor<br/>[agent_executor.py]"]
  node_title_agent["Title agent<br/>[agent.py]"]
  node_title_executor["Title executor<br/>[agent_executor.py]"]
  node_outline_server["Outline server<br/>[server.py]"]
  node_title_server["Title server<br/>[server.py]"]
end

subgraph group_operations["Agent operations"]
  node_evaluation["Agent evaluation<br/>[evaluate_agent.py]"]
  node_red_team["Red-team agent<br/>[red_team_agent.py]"]
  node_traced_agent["Traced agent<br/>[traced_agent.py]"]
end

node_learner(("Developer"))
node_exercises["Learning exercises"]

node_learner -->|"explores"| node_exercises
node_routing_server -->|"calls"| node_routing_agent
node_routing_agent -.->|"delegates remotely"| node_outline_server
node_routing_agent -.->|"delegates remotely"| node_title_server
node_outline_server -->|"registers"| node_outline_executor
node_outline_executor -->|"runs"| node_outline_agent
node_title_server -->|"registers"| node_title_executor
node_title_executor -->|"creates"| node_title_agent

click node_custom_tools "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/02-agent-custom-tools/Python/functions.py"
click node_portal_agent "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/01-build-agent-portal-and-vscode/Python/agent_with_functions.py"
click node_mcp_agent "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/03-mcp-integration/Python/agent.py"
click node_mcp_client "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/03-mcp-integration/Python/client.py"
click node_mcp_server "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/03-mcp-integration/Python/server.py"
click node_foundry_iq "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/04-integrate-agent-with-foundry-iq/Python/agent_client.py"
click node_teams_integration "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/05a-m365-teams-integration/Python/m365_teams_lab.py"
click node_search_setup "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/05a-m365-teams-integration/Python/setup_search.py"
click node_work_iq "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/05b-work-iq-integration/Python/workiq_lab.py"
click node_enterprise_agent "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/B-integrate-agents-with-enterprise-knowledge-and-m365/Python/knowledge_agent.py"
click node_knowledge_chat "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/B-integrate-agents-with-enterprise-knowledge-and-m365/Python/knowledge_chat_app.py"
click node_foundry_workflow "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/06-build-workflow-ms-foundry/Python/workflow.py"
click node_agent_framework "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/07-agent-framework/python/agent-framework.py"
click node_multi_agent "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/08-agent-orchestration/Python/agents.py"
click node_a2a_client "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/client.py"
click node_routing_server "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/routing_agent/server.py"
click node_routing_agent "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/routing_agent/agent.py"
click node_outline_agent "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/agent.py"
click node_outline_executor "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/agent_executor.py"
click node_title_agent "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/title_agent/agent.py"
click node_title_executor "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/title_agent/agent_executor.py"
click node_outline_server "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/server.py"
click node_title_server "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/title_agent/server.py"
click node_evaluation "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/D-observe-evaluate-and-secure-agents/Python/evaluate_agent.py"
click node_red_team "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/D-observe-evaluate-and-secure-agents/Python/red_team_agent.py"
click node_traced_agent "https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/D-observe-evaluate-and-secure-agents/Python/traced_agent.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_custom_tools,node_portal_agent,node_mcp_agent,node_mcp_client,node_mcp_server toneBlue
class node_foundry_iq,node_teams_integration,node_search_setup,node_work_iq,node_enterprise_agent,node_knowledge_chat toneAmber
class node_foundry_workflow,node_agent_framework,node_multi_agent,node_a2a_client,node_routing_server,node_routing_agent,node_outline_agent,node_outline_executor,node_title_agent,node_title_executor,node_outline_server,node_title_server toneMint
class node_evaluation,node_red_team,node_traced_agent toneRose
class node_learner,node_exercises toneIndigo
```

## Components

### Agent fundamentals

- [Custom tools](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/02-agent-custom-tools/Python/functions.py): `Labfiles/02-agent-custom-tools/Python/functions.py`
- [Portal agent](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/01-build-agent-portal-and-vscode/Python/agent_with_functions.py): `Labfiles/01-build-agent-portal-and-vscode/Python/agent_with_functions.py`
- [MCP agent](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/03-mcp-integration/Python/agent.py): `Labfiles/03-mcp-integration/Python/agent.py`
- [MCP client](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/03-mcp-integration/Python/client.py): `Labfiles/03-mcp-integration/Python/client.py`
- [MCP server](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/03-mcp-integration/Python/server.py): `Labfiles/03-mcp-integration/Python/server.py`

### Knowledge and apps

- [Foundry IQ agent](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/04-integrate-agent-with-foundry-iq/Python/agent_client.py): `Labfiles/04-integrate-agent-with-foundry-iq/Python/agent_client.py`
- [Teams integration](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/05a-m365-teams-integration/Python/m365_teams_lab.py): `Labfiles/05a-m365-teams-integration/Python/m365_teams_lab.py`
- [Search setup](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/05a-m365-teams-integration/Python/setup_search.py): `Labfiles/05a-m365-teams-integration/Python/setup_search.py`
- [Work IQ lab](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/05b-work-iq-integration/Python/workiq_lab.py): `Labfiles/05b-work-iq-integration/Python/workiq_lab.py`
- [Knowledge agent](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/B-integrate-agents-with-enterprise-knowledge-and-m365/Python/knowledge_agent.py): `Labfiles/B-integrate-agents-with-enterprise-knowledge-and-m365/Python/knowledge_agent.py`
- [Knowledge chat](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/B-integrate-agents-with-enterprise-knowledge-and-m365/Python/knowledge_chat_app.py): `Labfiles/B-integrate-agents-with-enterprise-knowledge-and-m365/Python/knowledge_chat_app.py`

### Workflow and orchestration

- [Foundry workflow](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/06-build-workflow-ms-foundry/Python/workflow.py): `Labfiles/06-build-workflow-ms-foundry/Python/workflow.py`
- [Agent framework](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/07-agent-framework/python/agent-framework.py): `Labfiles/07-agent-framework/python/agent-framework.py`
- [Agent orchestration](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/08-agent-orchestration/Python/agents.py): `Labfiles/08-agent-orchestration/Python/agents.py`
- [A2A client](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/client.py): `Labfiles/09-build-remote-agents-with-a2a/python/client.py`
- [Routing server](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/routing_agent/server.py): `Labfiles/09-build-remote-agents-with-a2a/python/routing_agent/server.py`
- [Routing agent](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/routing_agent/agent.py): `Labfiles/09-build-remote-agents-with-a2a/python/routing_agent/agent.py`
- [Outline agent](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/agent.py): `Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/agent.py`
- [Outline executor](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/agent_executor.py): `Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/agent_executor.py`
- [Title agent](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/title_agent/agent.py): `Labfiles/09-build-remote-agents-with-a2a/python/title_agent/agent.py`
- [Title executor](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/title_agent/agent_executor.py): `Labfiles/09-build-remote-agents-with-a2a/python/title_agent/agent_executor.py`
- [Outline server](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/server.py): `Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/server.py`
- [Title server](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/09-build-remote-agents-with-a2a/python/title_agent/server.py): `Labfiles/09-build-remote-agents-with-a2a/python/title_agent/server.py`

### Agent operations

- [Agent evaluation](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/D-observe-evaluate-and-secure-agents/Python/evaluate_agent.py): `Labfiles/D-observe-evaluate-and-secure-agents/Python/evaluate_agent.py`
- [Red-team agent](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/D-observe-evaluate-and-secure-agents/Python/red_team_agent.py): `Labfiles/D-observe-evaluate-and-secure-agents/Python/red_team_agent.py`
- [Traced agent](https://github.com/hareeshpalagiri/mslearn-ai-agents/blob/main/Labfiles/D-observe-evaluate-and-secure-agents/Python/traced_agent.py): `Labfiles/D-observe-evaluate-and-secure-agents/Python/traced_agent.py`

### Other components

- **Developer**
- **Learning exercises**

## Connections

- Developer → Learning exercises: explores
- Routing server → Routing agent: calls (evidence: `Labfiles/09-build-remote-agents-with-a2a/python/routing_agent/server.py`)
- Routing agent → Outline server: delegates remotely
- Routing agent → Title server: delegates remotely
- Outline server → Outline executor: registers (evidence: `Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/server.py`)
- Outline executor → Outline agent: runs (evidence: `Labfiles/09-build-remote-agents-with-a2a/python/outline_agent/agent_executor.py`)
- Title server → Title executor: registers (evidence: `Labfiles/09-build-remote-agents-with-a2a/python/title_agent/server.py`)
- Title executor → Title agent: creates (evidence: `Labfiles/09-build-remote-agents-with-a2a/python/title_agent/agent_executor.py`)
