Skip to content

Latest commit

Β 

History

History
96 lines (71 loc) Β· 3.46 KB

File metadata and controls

96 lines (71 loc) Β· 3.46 KB

Semantic Kernel Course - GitHub Codespaces

This repository is configured to run in GitHub Codespaces with all necessary tools and dependencies pre-installed.

πŸš€ Quick Start

  1. Open in Codespaces: Click the green "Code" button and select "Create codespace on main"
  2. Wait for setup: The environment will automatically install .NET 9.0 and all required packages
  3. Configure API Keys: Set up your OpenAI or Azure OpenAI credentials (see below)
  4. Start coding: All modules are ready to run!

πŸ”‘ API Configuration

You'll need to configure API keys for the AI services. Use .NET user secrets to store them securely:

For Azure OpenAI:

# Replace with your actual values
dotnet user-secrets set "AzureOpenAI:Endpoint" "https://your-resource.openai.azure.com/" --project module2/SK_Console
dotnet user-secrets set "AzureOpenAI:ApiKey" "your-api-key" --project module2/SK_Console
dotnet user-secrets set "AzureOpenAI:DeploymentName" "your-deployment-name" --project module2/SK_Console

For OpenAI:

dotnet user-secrets set "OpenAI:ApiKey" "your-openai-api-key" --project module2/SK_Console

πŸ“ Module Overview

  • Module 2: Foundation - Basic Semantic Kernel concepts
  • Module 3: Model Providers - OpenAI, Azure AI, Ollama, Hugging Face, etc.
  • Module 4: Multimodal AI - Working with images and text
  • Module 5: Web Applications - ASP.NET Core with Semantic Kernel
  • Module 7: Advanced Features - Plugins and complex scenarios
  • Module 8: RAG Applications - Retrieval-Augmented Generation with document processing

πŸƒβ€β™‚οΈ Running the Projects

Console Applications (Module 2, 3, 4):

cd module2/SK_Console
dotnet run

Web Applications with .NET Aspire (Module 5, 7, 8):

cd module5
dotnet run --project SKDevChat.AppHost

# Or for Module 8 (RAG functionality)
cd module8
dotnet run --project SKDevChat.AppHost

The Aspire dashboard will be available at the forwarded port (usually port 15000).

🌐 Forwarded Ports

The Codespace automatically forwards these ports:

  • 5000/5001: Standard .NET development server
  • 7000/7001: Chat application
  • 8080/8081: Customer API
  • 15000/15001: .NET Aspire Dashboard
  • 18888: Aspire OTLP endpoint

πŸ”§ Available Tools

The Codespace includes:

  • βœ… .NET 9.0 SDK (latest version)
  • βœ… .NET Aspire workload (latest - 9.3.x series)
  • βœ… Azure CLI
  • βœ… Node.js (for any frontend dependencies)
  • βœ… Git & GitHub CLI
  • βœ… VS Code extensions for C# and Aspire development

πŸ’‘ Tips

  1. Hot Reload: Use dotnet watch run for automatic reloading during development
  2. Multiple Projects: Each module can be run independently
  3. Secrets Management: Always use dotnet user-secrets for API keys, never commit them to code
  4. Aspire Dashboard: Great for monitoring distributed applications in modules 5, 7, and 8

πŸ› Troubleshooting

  • Build Errors: Run dotnet restore and dotnet build in the specific module directory
  • Missing Packages: The setup script should install everything, but you can manually restore with dotnet restore
  • Port Issues: Check the "Ports" tab in VS Code to see forwarded ports

πŸ“š Course Resources

Happy learning! πŸŽ“