{"owner":"microsoft","repo":"autogen","hasSkills":true,"hasMcp":false,"mcpConfig":null,"found":[".github/copilot-instructions.md"],"files":{".github/copilot-instructions.md":"# AutoGen Multi-Agent AI Framework\n\nAutoGen is a multi-language framework for creating AI agents that can act autonomously or work alongside humans. The project has separate Python and .NET implementations with their own development workflows.\n\nAlways reference these instructions first and fallback to search or bash commands only when you encounter unexpected information that does not match the info here.\n\n## Working Effectively\n\n### Prerequisites and Environment Setup\n\n**CRITICAL**: Install both .NET 8.0 and 9.0 for full compatibility:\n- Install uv package manager: `python3 -m pip install uv` \n- Install .NET 9.0 SDK: `wget https://dot.net/v1/dotnet-install.sh && chmod +x dotnet-install.sh && ./dotnet-install.sh --channel 9.0`\n- Install .NET 8.0 runtime: `./dotnet-install.sh --channel 8.0 --runtime dotnet && ./dotnet-install.sh --channel 8.0 --runtime aspnetcore`\n- Update PATH: `export PATH=\"$HOME/.dotnet:$PATH\"`\n\n### Python Development Workflow\n\n**Bootstrap and build Python environment:**\n```bash\ncd /home/runner/work/autogen/autogen/python\nuv sync --all-extras  # NEVER CANCEL: Takes 2 minutes. Set timeout to 300+ seconds.\nsource .venv/bin/activate\n```\n\n**Validate Python development:**\n```bash\n# Quick validation (under 1 second each)\npoe format  # Code formatting\npoe lint    # Linting with ruff\n\n# Type checking - NEVER CANCEL these commands\npoe mypy     # Takes 6 minutes. Set timeout to 600+ seconds.\npoe pyright  # Takes 41 seconds. Set timeout to 120+ seconds.\n\n# Individual package testing (core package example)\npoe --directory ./packages/autogen-core test  # Takes 10 seconds. Set timeout to 60+ seconds.\n\n# Documentation - NEVER CANCEL\npoe docs-build  # Takes 1 minute 16 seconds. Set timeout to 300+ seconds.\n```\n\n**CRITICAL TIMING EXPECTATIONS:**\n- **NEVER CANCEL**: Python environment setup takes 2 minutes minimum\n- **NEVER CANCEL**: mypy type checking takes 6 minutes \n- **NEVER CANCEL**: Documentation build takes 1+ minutes\n- Format/lint tasks complete in under 1 second\n- Individual package tests typically complete in 10-60 seconds\n\n### .NET Development Workflow\n\n**Bootstrap and build .NET environment:**\n```bash\ncd /home/runner/work/autogen/autogen/dotnet\nexport PATH=\"$HOME/.dotnet:$PATH\"\ndotnet restore  # NEVER CANCEL: Takes 53 seconds. Set timeout to 300+ seconds.\ndotnet build --configuration Release  # NEVER CANCEL: Takes 53 seconds. Set timeout to 300+ seconds.\n```\n\n**Validate .NET development:**\n```bash\n# Unit tests - NEVER CANCEL\ndotnet test --configuration Release --filter \"Category=UnitV2\" --no-build  # Takes 25 seconds. Set timeout to 120+ seconds.\n\n# Format check (if build fails) \ndotnet format --verify-no-changes\n\n# Run samples\ncd samples/Hello\ndotnet run\n```\n\n**CRITICAL TIMING EXPECTATIONS:**\n- **NEVER CANCEL**: .NET restore takes 53 seconds minimum\n- **NEVER CANCEL**: .NET build takes 53 seconds minimum  \n- **NEVER CANCEL**: .NET unit tests take 25 seconds minimum\n- All build and test commands require appropriate timeouts\n\n### Complete Validation Workflow\n\n**Run full check suite (Python):**\n```bash\ncd /home/runner/work/autogen/autogen/python\nsource .venv/bin/activate\npoe check  # NEVER CANCEL: Runs all checks. Takes 7+ minutes total. Set timeout to 900+ seconds.\n```\n\n## Validation Scenarios\n\n### Manual Validation Requirements\nAlways manually validate changes by running complete user scenarios after making modifications:\n\n**Python validation scenarios:**\n1. **Import test**: Verify core imports work:\n   ```python\n   from autogen_agentchat.agents import AssistantAgent\n   from autogen_core import AgentRuntime\n   from autogen_ext.models.openai import OpenAIChatCompletionClient\n   ```\n\n2. **AutoGen Studio test**: Verify web interface can start:\n   ```bash\n   autogenstudio ui --help  # Should show help without errors\n   ```\n\n3. **Documentation test**: Build and verify docs generate without errors:\n   ```bash\n   poe docs-build && ls docs/build/index.html\n   ```\n\n**.NET validation scenarios:**\n1. **Sample execution**: Run Hello sample to verify runtime works:\n   ```bash\n   cd dotnet/samples/Hello && dotnet run --help\n   ```\n\n2. **Build validation**: Ensure all projects compile:\n   ```bash\n   dotnet build --configuration Release --no-restore\n   ```\n\n3. **Test execution**: Run unit tests to verify functionality:\n   ```bash\n   dotnet test --filter \"Category=UnitV2\" --configuration Release --no-build\n   ```\n\n## Common Issues and Workarounds\n\n### Network-Related Issues\n- **Python tests may fail** with network errors (tiktoken downloads, Playwright browser downloads) in sandboxed environments - this is expected\n- **Documentation intersphinx warnings** due to inability to reach external documentation sites - this is expected\n- **Individual package tests work better** than full test suite in network-restricted environments\n\n### .NET Runtime Issues  \n- **Requires both .NET 8.0 and 9.0**: Build uses 9.0 SDK but tests need 8.0 runtime\n- **Global.json specifies 9.0.100**: Must install exact .NET 9.0 version or later\n- **Path configuration critical**: Ensure `$HOME/.dotnet` is in PATH before system .NET\n\n### Python Package Issues\n- **Use uv exclusively**: Do not use pip/conda for dependency management\n- **Virtual environment required**: Always activate `.venv` before running commands\n- **Package workspace structure**: Project uses uv workspace with multiple packages\n\n## Timing Reference\n\n### Python Commands\n| Command | Expected Time | Timeout | Notes |\n|---------|---------------|---------|-------|\n| `uv sync --all-extras` | 2 minutes | 300+ seconds | NEVER CANCEL |\n| `poe mypy` | 6 minutes | 600+ seconds | NEVER CANCEL |\n| `poe pyright` | 41 seconds | 120+ seconds | NEVER CANCEL |\n| `poe docs-build` | 1 min 16 sec | 300+ seconds | NEVER CANCEL |\n| `poe format` | <1 second | 30 seconds | Quick |\n| `poe lint` | <1 second | 30 seconds | Quick |\n| Individual package test | 10 seconds | 60+ seconds | May have network failures |\n\n### .NET Commands  \n| Command | Expected Time | Timeout | Notes |\n|---------|---------------|---------|-------|\n| `dotnet restore` | 53 seconds | 300+ seconds | NEVER CANCEL |\n| `dotnet build --configuration Release` | 53 seconds | 300+ seconds | NEVER CANCEL |\n| `dotnet test --filter \"Category=UnitV2\"` | 25 seconds | 120+ seconds | NEVER CANCEL |\n| `dotnet format --verify-no-changes` | 5-10 seconds | 60 seconds | Quick validation |\n\n## Repository Structure\n\n### Python Packages (`python/packages/`)\n- `autogen-core`: Core agent runtime, model interfaces, and base components\n- `autogen-agentchat`: High-level multi-agent conversation APIs  \n- `autogen-ext`: Extensions for specific model providers and tools\n- `autogen-studio`: Web-based IDE for agent workflows\n- `agbench`: Benchmarking suite for agent performance\n- `magentic-one-cli`: Multi-agent team CLI application\n\n### .NET Projects (`dotnet/src/`)\n- `AutoGen`: Legacy 0.2-style .NET packages (being deprecated)\n- `Microsoft.AutoGen.*`: New event-driven .NET packages\n- `AutoGen.Core`: Core .NET agent functionality\n- Multiple provider packages: OpenAI, Anthropic, Ollama, etc.\n\n### Key Configuration Files\n- `python/pyproject.toml`: Python workspace and tool configuration\n- `dotnet/global.json`: .NET SDK version requirements  \n- `dotnet/AutoGen.sln`: .NET solution file\n- `python/uv.lock`: Locked Python dependencies\n\n## Development Best Practices\n\n### Before Committing Changes\n**ALWAYS run these validation steps:**\n\n**Python:**\n```bash\ncd python && source .venv/bin/activate\npoe format    # Fix formatting\npoe lint      # Check code quality  \npoe mypy      # Type checking (6 minutes)\npoe docs-build # Verify docs build (1+ minutes)\n```\n\n**.NET:**\n```bash  \ncd dotnet && export PATH=\"$HOME/.dotnet:$PATH\"\ndotnet format --verify-no-changes  # Check formatting\ndotnet build --configuration Release --no-restore  # Build (53 seconds)\ndotnet test --configuration Release --filter \"Category=UnitV2\" --no-build  # Test (25 seconds)\n```\n\n### Key Directories Reference\n```\nautogen/\n├── python/                    # Python implementation\n│   ├── packages/             # Individual Python packages\n│   ├── docs/                 # Sphinx documentation\n│   ├── samples/              # Example code\n│   └── pyproject.toml        # Workspace configuration\n├── dotnet/                   # .NET implementation  \n│   ├── src/                  # Source projects\n│   ├── test/                 # Test projects\n│   ├── samples/              # Sample applications\n│   └── AutoGen.sln          # Solution file\n├── .github/workflows/        # CI/CD pipelines\n└── docs/                     # Additional documentation\n```\n\nThis framework supports creating both simple single-agent applications and complex multi-agent workflows with support for various LLM providers, tools, and deployment patterns."}}