A Cursor plugin that provides AI-powered coding guidance, skills, and agents for building multi-agent applications with the AG2 framework.
Coding standards that guide Cursor's AI when writing AG2 code:
| Rule | Description |
|---|---|
| agent-patterns | Agent creation, configuration, and chat patterns |
| tool-registration | Tool/function registration with decorators, @tool, Tool class, and Toolkit |
| llm-config | LLMConfig creation, provider configs, structured outputs, and common mistakes |
| group-chat | run_group_chat API, patterns (Auto/RoundRobin/Default/Manual), handoffs, guardrails |
| sequential-chats | Pipeline workflows with a_sequential_run, carryover, and summary methods |
| code-execution | LocalCommandLineCodeExecutor, Docker, PythonCodeExecutionTool, safety practices |
| imports | Correct import paths (autogen not ag2), all experimental tools/agents, extras installation |
| hooks-and-replies | Hook system, custom reply functions, and nested chats |
Complex code generation workflows:
| Skill | Description |
|---|---|
| create-agent-team | Scaffold a complete multi-agent team using run_group_chat with patterns |
| add-tool | Generate a properly typed tool with correct registration |
| add-mcp-integration | Wire an MCP server into AG2 agents |
| debug-conversation | Diagnose agent conversation issues |
| build-research-agent | Build a web research agent with search tools and structured output |
| build-rag-agent | Build a RAG agent with RetrieveUserProxyAgent and vector database |
| build-group-chat | Build a handoff-driven workflow with DefaultPattern, routing, and context variables |
| add-code-execution | Add code execution with Local/Docker executors and safety config |
| add-guardrails | Add LLMGuardrail and RegexGuardrail for safety constraints |
| build-reasoning-agent | Build a ReasoningAgent with beam search, MCTS, or LATS strategies |
Specialized AI personas:
| Agent | Description |
|---|---|
| ag2-architect | Design multi-agent systems, pick patterns (group chat, sequential, reasoning), avoid pitfalls |
| ag2-migrator | Migrate from old AutoGen 0.2 to current AG2 API |
Quick-reference prompts:
| Command | Description |
|---|---|
| explain-flow | Trace message flow in an AG2 application |
| review-agent-config | Check agent config for common mistakes |
This plugin helps you build:
- Customer service bots — DefaultPattern routing with triage, billing, and support agents
- Research pipelines — Sequential chats (
a_sequential_run) or group chat teams with search tools - Code generation workflows — Coder + executor agents with sandboxed execution
- Document Q&A systems — RAG agents with ChromaDB or Qdrant vector databases
- Complex reasoning — ReasoningAgent with tree-of-thought for math, analysis, planning
- Tool-augmented assistants — Agents with web search, browser, MCP, and custom tools
- Safety-critical systems — Guardrails for PII filtering, content moderation, relevance checks
- Legacy migration — Automated migration from AutoGen 0.2 / pyautogen to AG2
Install from the Cursor Marketplace, or clone this repo and add it as a local plugin.
- Cursor IDE
- AG2 framework:
pip install ag2 - Optional extras for specific features (see the imports rule for the full list)