.NET AI Workshop

Get up to speed quickly with AI app building in .NET. This workshop covers two tracks: AI application development (Parts 1-6) and MCP server development (Parts 7-9). The AI track uses Microsoft Foundry (Azure OpenAI) as the cloud provider, with local-model options covered in the provider module.

Prerequisites

AI Web Chat Application Requirements (Parts 1-6)

  • Visual Studio 2026 or VS Code
  • .NET AI Web Chatbot template installed (instructions in Part 1 - Setup)
  • .NET 10.0 SDK or later
  • Docker Desktop or Podman (recommended for the full Qdrant + Aspire path in Part 4)
  • Azure subscription with access to Microsoft Foundry (Azure OpenAI), the primary AI provider

When Docker is required

Docker Desktop or Podman is required when you run the workshop's Qdrant container locally. This is the recommended path in Part 4 because it demonstrates a persistent vector database, Aspire orchestration, the Aspire dashboard, and service telemetry.

Parts Docker requirement
Parts 1-3 Not required. These use console applications and an in-memory vector store.
Part 4 Required for the recommended Qdrant + Aspire path. A supported Docker-free path uses the template's local JSON vector store without Aspire; see the Part 4 instructions.
Part 5 Not required. Provider comparisons can use Microsoft Foundry, Foundry Local, or a native Ollama installation.
Part 6 Required to run the supplied Qdrant + Aspire application locally. The Azure deployment itself runs the containers in Azure.
Parts 7-9 Not required for the MCP exercises. Containerizing an MCP server in Part 9 is optional.

Without Docker, you can still complete Parts 1-5 and Parts 7-9, including the main chat, RAG, template, provider, and MCP concepts. In Part 4 you will miss the hands-on Qdrant, Aspire dashboard, service orchestration, and container persistence experience. Part 6 uses the full Qdrant + Aspire application, so local execution of that snapshot requires Docker or Podman.

Model Context Protocol (Parts 7-9)

  • .NET 10.0 SDK - Required for MCP development
  • Visual Studio Code
  • GitHub Copilot subscription (required for MCP testing)
  • Microsoft.Extensions.AI.Templates package

Optional but Recommended

  • Git for version control
  • Azure subscription for production deployment

Lab Overview 🧪

The workshop is split into two tracks:

  • AI Application Build Path (Parts 1-6): Build a minimal chat app, add retrieval, inspect the generated template architecture, configure provider strategy, and deploy.
  • Model Context Protocol (MCP) Path (Parts 7-9): Build MCP servers and package/publish them.

Detailed architecture and sequence diagrams are documented in the individual module READMEs where each concept is implemented.

Getting Started

Follow the setup instructions to get started with the lab.

Lab Modules 📚

The lab is divided into nine modules.

The primary sequence below reflects the current converged workshop flow and keeps advanced modules explicitly optional for pacing.

AI Application Build Path (Parts 1-6)

This sequence starts with a minimal console chat app, then layers in RAG, template architecture, provider strategy, and deployment.

  1. 🏗️ Setup: Configure prerequisites and development environment for the AI workshop.

  2. 💬 Build Chat App: Build and run a minimal console-based AI chat app.

  3. 🧩 Add RAG: Add retrieval-augmented generation with embeddings and semantic search.

  4. 🔍 AI Web Chat Template: Compare your manual implementation with the generated template architecture.

  5. 🔁 Providers and Fallbacks: Configure provider options and fallback paths (Microsoft Foundry primary).

  6. 🚀 Deployment: Deploy your application to Azure using the Azure Developer CLI.

Model Context Protocol (MCP) Servers (Parts 7-9)

  1. 🔧 MCP Server Basics: Create your first MCP server with weather tools that extend AI agents like GitHub Copilot.

  2. 🏢 Enhanced MCP Server (Optional / bonus): Build sophisticated business tools for order management, inventory, and customer service scenarios.

  3. 📦 MCP Publishing (Optional / bonus): Package, publish, and distribute your MCP servers through NuGet for professional deployment.

Lab Structure 📁

The repository is structured as follows:

  • 📖 Part 1 - Setup through Part 9 - MCP Publishing: Contains all the lab instructions, documentation, and working code snapshots
  • 📄 manuals/: Product documentation PDFs for the AI chatbot exercises
  • 🧪 docs/testing/: Testing procedures and validation reports

Session Resources 📚

Resources Links Description
Microsoft Learn https://aka.ms/build25/plan/ADAI_DevStartPlan AI developer resources
Microsoft Learn https://learn.microsoft.com/en-us/dotnet/machine-learning/ai-overview .NET AI Documentation
Microsoft Learn https://learn.microsoft.com/en-us/dotnet/aspire/get-started/aspire-overview Aspire Documentation
Microsoft Learn https://learn.microsoft.com/en-us/dotnet/machine-learning/extensions-ai/ Extensions for AI Documentation
Microsoft Learn https://learn.microsoft.com/en-us/azure/ai-services/openai/ Azure OpenAI Documentation

Testing the Workshop 🧪

For workshop instructors and contributors who want to validate the workshop content, a comprehensive testing procedure is available:

Automated Credential Setup

Before testing the workshop, run the credential setup script to configure required API keys and endpoints:

# Navigate to the workshop root directory
cd ai-workshop

# Run the credential setup script
.\.github\scripts\setup-workshop-credentials.ps1

This script will prompt you for:

  • Azure OpenAI Endpoint: Your Azure OpenAI service endpoint URL
  • Azure OpenAI Key: Your Azure OpenAI service API key

The credentials are saved as environment variables (WORKSHOP_AZURE_OPENAI_ENDPOINT, WORKSHOP_AZURE_OPENAI_KEY) and will be available for subsequent testing sessions.

Testing Procedure

The complete testing procedure and validation scripts are available in .github/prompts/test-workshop.prompt.md. This includes:

  • Step-by-step testing instructions for all 9 workshop parts
  • Automated build validation commands
  • Common troubleshooting scenarios
  • Documentation improvement tracking

License

This project is licensed under the MIT License - see the LICENSE file for details.