Last Updated: November 8, 2025
Version: 0.4.1
Status: Ready for publication
Agent Designer is a VS Code extension that provides a visual canvas for designing multi-agent workflows. Users can create, connect, and export GitHub Copilot agents using an intuitive drag-and-drop interface.
- Backend: TypeScript + VS Code Extension API (1.105.0+)
- Frontend: React 19.2.0 + React Flow (@xyflow/react 12.9.2)
- Layout: ELK.js 0.11.0 (currently using simple grid layout)
- Build: esbuild for webview bundling, TypeScript compiler for extension
-
Visual Canvas
- Interactive drag-and-drop interface
- React Flow-based node system
- Smoothstep edge routing with enhanced visibility
- Zoom and pan controls
- Background grid with dots pattern
-
Agent Management
- Create/edit/delete agents
- Configure: name, description, instructions, tools, model
- Mark entry points
- Click-to-edit nodes
- Agent nodes with visual styling
-
Handoff System
- Visual connections between agents
- Click edges to edit handoff properties
- Configure: label, prompt, auto-send
- Smoothstep routing (3px stroke, hover effects)
-
File Operations
- Import individual
.agent.mdfiles - Import from directory (scans all
.agent.mdfiles) - Export to
.github/agents/or.github/chatmodes/ - Drag-and-drop
.agent.mdfiles onto canvas - Custom editor for
.agentdesign.mdfiles (single tab, no double-opening) - "Open as Text" command for viewing raw markdown
- State persistence in
.agentdesign.mdwith JSON in YAML frontmatter
- Import individual
-
Validation
- Real-time validation before export
- Checks: circular dependencies, required fields, entry points
- Validation panel with error/warning display
-
UI/UX
- Flat modern toolbar design (matching VS Code aesthetic)
- Removed minimap component
- Clean button styling with hover effects
- No double-tab opening (custom editor with default priority)
-
File Format
- Changed from
.chat.md/.chatmode.mdto.agent.md - YAML frontmatter with agent metadata
- Markdown body with name (H1) and instructions (H2)
- Changed from
-
Auto-Layout Not Working
- Current implementation: Simple grid layout (3 columns, 400px spacing)
- Issue: Nodes still appear grouped in center despite positioning
- Attempted fixes:
- Removed all
fitViewcalls - Set explicit viewport
- Created new node objects
- Increased spacing dramatically
- Simplified to basic grid layout
- Removed all
- Root cause: Unknown (possibly React Flow internal behavior)
- Status: Deferred for later investigation
- Workaround: Users can manually arrange nodes
-
TypeScript Errors (Pre-existing)
- Some type assertion issues in modal components
- Does not affect compilation or runtime
- Compiles successfully with
npm run compile
copilot-agentdesigner/
├── src/
│ ├── extension.ts # Extension entry point, commands
│ ├── AgentDesignerPanel.ts # Webview panel controller, state management
│ ├── AgentDesignEditorProvider.ts # Custom editor for .agentdesign.md
│ ├── models/
│ │ └── agent.ts # TypeScript interfaces, DEFAULT_PREFERENCES
│ └── generators/
│ ├── agentFileGenerator.ts # Generates .agent.md files
│ └── agentFileParser.ts # Parses .agent.md, scans directories
├── webview-ui/src/
│ ├── App.tsx # Main canvas, React Flow setup
│ ├── App.css # Canvas styling, edge animations
│ ├── AgentNode.tsx # Agent node component
│ ├── AgentEditModal.tsx # Agent property editor
│ ├── HandoffModal.tsx # Handoff editor
│ ├── ValidationPanel.tsx # Validation UI
│ ├── SettingsPanel.tsx # Settings UI
│ └── layout.ts # Layout algorithms (simple grid)
├── out/ # Compiled output
├── package.json # Extension manifest, v0.4.1
├── README.md # Comprehensive documentation
├── CHANGELOG.md # Version history
├── LICENSE # MIT License
├── PUBLISHING.md # Publication guide
└── .vscodeignore # Files excluded from package
- State stored in
.agentdesign.mdfiles - Format: YAML frontmatter with JSON content
- Contains: agents array, preferences, theme, workflowDescription
- Auto-saves on changes
---
description: Agent description
tools:
- tool1
- tool2
model: Claude Sonnet 4
handoffs:
- agent: TargetAgent
label: Handoff Label
prompt: Optional prompt
send: false
---
# Agent Name
## Instructions
Detailed instructions here...- Registered for
*.agentdesign.mdfiles - Priority:
default(opens as canvas by default) - Context menu: "Open as Text" command
- Single tab opening (no duplicate tabs)
- Type:
smoothstep - Stroke width: 3px
- Color: #9e9e9e (default), #1e88e5 (hover/selected)
- Z-index layering for visibility
- Hover effects with glow
- Selected animation (pulse)
- Flat buttons with transparent background
- Border: 1px solid rgba(255, 255, 255, 0.15)
- Hover: subtle background + border highlight
- Primary actions (Add Agent, Add from File): VS Code button background
- Changed file extension from
.chat.md/.chatmode.mdto.agent.md - Updated all file parsing and generation logic
- Attempted multiple fixes for auto-layout (not successful)
- Simplified layout to basic grid (3 columns)
- Prepared repository for publication:
- Updated package.json with metadata
- Created comprehensive README.md
- Added MIT LICENSE
- Created PUBLISHING.md guide
- Updated .vscodeignore
Agent Designer: Open Canvas- Open new canvasAgent Designer: Open Design File- Open .agentdesign.mdAgent Designer: Export Agents- Export to filesAgent Designer: Import Agents- Import filesAgent Designer: Open as Text- View design file as text
Agent Designer: New From Template- Shows "coming soon" message (templates exist in code but no UI)Agent Designer: Run Simulation- Shows "coming soon" messageAgent Designer: Toggle Entry Point- Shows "coming soon" message (feature works via UI button)Agent Designer: Customize Theme- Shows "coming soon" message
npm run compile # Compile extension
npm run compile:webview # Compile webview
npm run vscode:prepublish # Full build for publishingnpm run watch # Watch extension
npm run watch:webview # Watch webview (separate terminal)Press F5 in VS Code to launch Extension Development Host
- Run extension (F5)
- Open Command Palette (Ctrl+Shift+P)
- Run "Agent Designer: Open Canvas"
- Test features
- ✅ Package.json updated with metadata
- ✅ README.md comprehensive
- ✅ MIT License added
- ✅ CHANGELOG.md exists
- ✅ .vscodeignore configured
- ✅ Code compiles successfully
- ✅ PUBLISHING.md guide created
- Update publisher name in package.json (currently:
TODO-publisher-name) - Update author name in package.json (currently:
TODO-author-name) - Add repository URLs if desired (currently removed to avoid placeholders)
- Create icon.png (128x128) if desired (icon field removed from package.json)
- Create publisher account on marketplace
- Get Personal Access Token from Azure DevOps
- Add screenshots/GIFs to README
- Test .vsix package locally
- Remove or implement stub commands (template, simulation, theme) before v1.0.0
-
Fix Auto-Layout
- Investigate React Flow positioning behavior
- Consider using React Flow's built-in layout utilities
- Test with explicit position updates and viewport control
-
Implement Stub Commands
- Template gallery UI (templates exist in
src/templates/workflowTemplates.ts) - Workflow simulation functionality
- Theme customization UI
- Wire up Toggle Entry Point command (UI button already works)
- Template gallery UI (templates exist in
-
Enhanced Features
- Undo/redo functionality
- Export to different formats
- Import from other sources
-
UI Improvements
- Minimap toggle option
- Customizable themes
- Node color customization
- Grid snapping
-
Quality
- Fix TypeScript type assertions
- Add unit tests
- Add integration tests
- Performance optimization for large graphs
- Extension requires VS Code 1.105.0+
- Uses Node.js 22.x for development
- React Flow version: @xyflow/react 12.9.2
- File format changed to .agent.md (breaking change from earlier versions)
- Auto-layout feature needs rework (currently non-functional)
- Enable Developer Tools: Help > Toggle Developer Tools
- Check Console for layout debug logs (look for [Layout] and [App] prefixes)
- State logs show agent count and handoff details
- Webview reloads require reopening canvas
- VS Code Extension API: https://code.visualstudio.com/api
- React Flow docs: https://reactflow.dev/
- Publishing guide: ./PUBLISHING.md
- Repository: (update with your GitHub URL)
How to Resume:
- Read this context file
- Review CHANGELOG.md for version history
- Check package.json for current dependencies
- Run
npm installif dependencies changed - Run
npm run vscode:prepublishto build - Press F5 to test extension
- Continue from "Next Steps" section above