This repository contains multiple basketball coaching AI agent implementations demonstrating different Azure AI technologies and frameworks.
Technology: Azure AI Foundry
Framework: Azure AI Agent Service
Description: Demo code for Azure AI Agent Service intro post. Basic agent implementation using Azure AI Foundry's native agent capabilities.
Blog Post: https://beyondelastic.github.io/posts/agent/
Technology: Azure AI Foundry
Framework: Semantic Kernel
Description: Multi-agent basketball coaching system using Semantic Kernel's agent orchestration capabilities.
Blog Post: https://beyondelastic.github.io/posts/multi-agent/
Technology: Azure AI Foundry
Framework: Semantic Kernel
Description: Refactored version of App2 with improved modularity and separation of concerns using Semantic Kernel agents.
Technology: Azure OpenAI
Framework: Semantic Kernel
Description: Demonstrates Semantic Kernel function calling and plugins for basketball coaching scenarios.
Blog Post: https://beyondelastic.github.io/posts/skfc/
Technology: Azure AI Foundry
Framework: Azure AI Agent Service
Description: Advanced implementation showcasing Azure AI Foundry features like Bing Grounding Tool, Connected Agent Tool, and File Search capabilities.
Technology: Azure AI Foundry
Framework: Microsoft Agent Framework
Description: Clean, modular multi-agent basketball coaching system using the new Microsoft Agent Framework with proper resource management and workflow orchestration.
Technology: Azure AI Foundry
Framework: Azure AI Projects SDK
Description: Utility script for cleaning up Azure AI Foundry resources (agents, threads, files, vector stores) to manage costs and maintain clean environments.
-
Clone the repository:
git clone https://github.com/yourusername/basketball-ai-agent.git cd basketball-ai-agent -
Create and activate a virtual environment (optional but recommended):
python3 -m venv .venv source .venv/bin/activate -
Install dependencies:
- Each app has its own
requirements.txtfile. Install dependencies for the app you want to run:- For App 1:
pip install -r src/app1/requirements.txt
- For App 2:
pip install -r src/app2/requirements.txt
- For App 2-Modular:
pip install -r src/app2-modular/requirements.txt
- For App 3:
pip install -r src/app3/requirements.txt
- For App 4:
pip install -r src/app4/requirements.txt
- For App 5:
pip install -r src/app5/requirements.txt
- For Clean-up:
pip install -r src/clean-up/requirements.txt
- For App 1:
- (If a
requirements.txtis missing, install dependencies as needed for that app, e.g.semantic-kernel,openai, etc.)
- Each app has its own
-
Set up environment variables:
- Set the following variables in your shell or
.envfile as needed for each app:- App 1 (Azure AI Foundry):
AZURE_AI_AGENT_PROJECT_CONNECTION_STRING=""AZURE_AI_AGENT_MODEL_DEPLOYMENT_NAME=""NBA_CSV_FILE_PATH="../data/nba3p.csv"
- App 2 (Azure AI Foundry + Semantic Kernel):
AZURE_AI_AGENT_PROJECT_CONNECTION_STRING=""AZURE_AI_AGENT_MODEL_DEPLOYMENT_NAME=""
- App 2-Modular (Azure AI Foundry + Semantic Kernel):
AZURE_AI_AGENT_PROJECT_CONNECTION_STRING=""AZURE_AI_AGENT_MODEL_DEPLOYMENT_NAME=""
- App 3 (Azure OpenAI + Semantic Kernel):
AZURE_OPENAI_ENDPOINT=""AZURE_OPENAI_API_KEY=""AZURE_OPENAI_DEPLOYMENT=""
- App 4 (Azure AI Foundry):
AZURE_AI_AGENT_PROJECT_CONNECTION_STRING=""AZURE_AI_AGENT_MODEL_DEPLOYMENT_NAME=""
- App 5 (Azure AI Foundry + Agent Framework):
AZURE_AI_AGENT_PROJECT_CONNECTION_STRING=""AZURE_AI_AGENT_MODEL_DEPLOYMENT_NAME=""
- Clean-up (Azure AI Foundry):
AZURE_AI_AGENT_PROJECT_CONNECTION_STRING=""
- App 1 (Azure AI Foundry):
- Set the following variables in your shell or
-
App 1 (Azure AI Foundry Agent Service):
- Navigate to
src/app1/and run the main script:cd src/app1 python app1.py
- Navigate to
-
App 2 (Semantic Kernel Multi-Agent):
- Navigate to
src/app2/and run the app:cd src/app2 python app2.py
- Navigate to
-
App 2-Modular (Modular Semantic Kernel):
- Navigate to
src/app2-modular/and run the main app:cd src/app2-modular python main.py
- Navigate to
-
App 3 (Semantic Kernel Function Calling):
- Navigate to
src/app3/and run the app:cd src/app3 python app3.py
- Navigate to
-
App 4 (Advanced Azure AI Foundry):
- Navigate to
src/app4/and run the app:cd src/app4 python app4.py
- Navigate to
-
App 5 (Microsoft Agent Framework):
- Navigate to
src/app5/and run the app:cd src/app5 python app5.py - Or with custom task:
cd src/app5 python app5.py "We need help with our defense against pick and roll plays"
- Navigate to
-
Clean-up (Resource Management):
- Navigate to
src/clean-up/and run the cleanup script:cd src/clean-up python clean_up.py - Use dry-run mode to preview deletions:
python clean_up.py --dry-run
- Navigate to
- The
data/folder contains basketball datasets (e.g.,nba3p.csv) used by app1.
| App | Technology | Framework | Use Case |
|---|---|---|---|
| App1 | Azure AI Foundry | Azure AI Agent Service | Basic agent implementation |
| App2 | Azure AI Foundry | Semantic Kernel | Multi-agent orchestration |
| App2-Modular | Azure AI Foundry | Semantic Kernel | Modular multi-agent system |
| App3 | Azure OpenAI | Semantic Kernel | Function calling & plugins |
| App4 | Azure AI Foundry | Azure AI Agent Service | Advanced features (Bing, File Search) |
| App5 | Azure AI Foundry | Microsoft Agent Framework | Clean workflow orchestration |
| Clean-up | Azure AI Foundry | Azure AI Projects SDK | Resource management utility |
- Make sure you have the necessary Azure AI Foundry or Azure OpenAI access and correct API keys/connection strings.
- For Azure AI Foundry apps, you'll need a project connection string.
- For Azure OpenAI apps (App3), you'll need direct Azure OpenAI service credentials.
- Each app demonstrates different approaches to building basketball coaching AI agents.
- For more details, refer to the code comments and the referenced blog posts above.