AI Debugging
Use GitHub Copilot and other AI assistants to diagnose issues, analyze logs, and understand your services through natural conversation.
How It Works
1. Ask a Question
Describe the issue in natural language
2. MCP Gathers Data
AI uses MCP tools to check services
3. Get Insights
AI explains issues and suggests fixes
Example: Finding a Bug
Debugging Workflows
Diagnose Errors
When a service is failing or returning errors
Steps
- Ask: "Which services are having issues?"
- Get service health status via MCP
- Ask: "Show me errors from [service name]"
- AI analyzes logs and identifies the root cause
- Get suggested fixes
Try these prompts
Monitor Health
Keep track of service status and performance
Steps
- Ask: "What's the health status of all services?"
- MCP checks each service's health endpoint
- AI reports healthy vs unhealthy services
- For unhealthy services, AI explains why
Try these prompts
Analyze Logs
Search and understand log output
Steps
- Ask: "Show me logs from the last 5 minutes"
- MCP streams recent logs
- Ask: "Find any errors or warnings"
- AI highlights important log entries
Try these prompts
Understand Configuration
Get help with project setup and configuration
Steps
- Ask: "What services are configured in this project?"
- MCP reads azure.yaml and project structure
- AI explains the service architecture
- Get help with configuration issues
Try these prompts
Tips for Effective AI Debugging
Be Specific
Instead of "something is broken", say "the API is returning 500 errors when I call /users endpoint".
Name Your Services
Reference specific service names from your azure.yaml like "the web service" or "the api container".
Include Timeframes
"Show me errors from the last 10 minutes" helps narrow down relevant logs.
Follow Up
Ask follow-up questions to dig deeper. "Why did that error happen?" or "Show me more context around that log".
MCP Tools for Debugging
get_services Lists all services with their current status (running, stopped, error)
get_service_logs Retrieves logs from a specific service, optionally filtered by time or level
check_requirements Verifies all prerequisites are met (Node.js, Python, Docker, etc.)
get_project_info Returns project configuration from azure.yaml
get_environment_variables Shows environment variables for services (secrets redacted)