Determine the appropriate UI system for the project and route to the correct specialized skill.
When to Route vs Answer Directly
Route to a specialized skill when:
- User wants to understand, edit, or generate specific UI elements
- User references specific files or UI objects
- User asks for UI changes or creation
Answer directly (without routing) when:
- User asks comparative/educational questions ("What's the difference between UI Toolkit and uGUI?")
- User asks about UI system capabilities or recommendations ("Should I use UITK or uGUI for mobile?")
- User needs conceptual explanation of Unity UI architecture
Routing Logic
Step 1: Check for explicit file references or keywords:
| User mentions |
Route to |
.uxml or .uss files (including in /Editor/) |
ui-uitk |
| "UI Toolkit", "UITK", "UIElements", "CreateGUI" |
ui-uitk |
Canvas prefabs/objects, .prefab with UI |
ui-ugui |
| "uGUI", "Canvas", "RectTransform", "legacy UI" |
ui-ugui |
| "IMGUI", "OnGUI", "OnInspectorGUI", "immediate mode" |
ui-imgui |
Figma URL (figma.com/design/...), "Figma", "import from Figma" |
Not available — see below |
For editor-related requests (EditorWindow, custom inspector, PropertyDrawer):
- If no explicit UI system mentioned → Go to Step 2 to detect project's editor UI system
- If no existing pattern is detected, default to
ui-uitk for new editor UI
- Only use
ui-imgui if project exclusively uses IMGUI or user explicitly requests it
If explicit file or keywords found, activate the corresponding skill immediately.
Step 2: If ambiguous, detect from project:
Search the project to determine which UI system is in use:
| Look for |
Indicates |
.uxml or .uss files (including in /Editor/) |
UI Toolkit (runtime or editor) |
UIDocument components in scenes |
UI Toolkit (runtime) |
Editor scripts with CreateGUI() method |
UI Toolkit (editor) |
Canvas in scenes/prefabs |
uGUI |
RectTransform heavy usage |
uGUI |
Editor scripts with OnGUI() or OnInspectorGUI() |
IMGUI (legacy editor) |
Step 3: If still unclear, ask or default:
- For existing projects: detect and follow whichever framework is already in use (Step 2)
- For new projects with no UI yet: ask the user which framework they prefer (UI Toolkit vs uGUI), briefly explaining that UI Toolkit is modern/CSS-like while uGUI is Canvas-based/mature
- For new runtime/game UI where the user has no preference: default to uGUI (
ui-ugui)
- When the user mentions mobile/performance constraints or older Unity versions (pre-6.0): bias toward uGUI (
ui-ugui)
Request Types
Specialized skills handle three types of requests:
| Type |
Examples |
| Understanding |
"What does this button do?", "How is this laid out?", "Explain this UI" |
| Editing |
"Change this color", "Add a label here", "Fix this layout" |
| Generation |
"Create a menu", "Make an inventory screen", "Build a settings panel" |
Route all types to the appropriate specialized skill based on the UI system.
Available Sub-Skills
UI Toolkit — ui-uitk
- For Unity 6.0+ projects using UI Toolkit (runtime game UI and editor tools)
- Understands, edits, and generates
.uxml and .uss files
- Modern, CSS-like styling approach
- Preferred for new editor windows (CreateGUI) and existing UI Toolkit projects
uGUI — ui-ugui
- For projects using Unity's Canvas-based UI system
- Understands, edits, and generates Canvas hierarchies
- Uses Layout Groups for responsive design
- Default for new runtime/game UI when the user has no framework preference
IMGUI — ui-imgui
- For legacy editor tools using OnGUI/immediate mode
- Only use when project has existing IMGUI editor code or user explicitly requests IMGUI
- Understands, edits, and generates EditorWindow, inspectors, PropertyDrawers built with OnGUI
- Not for runtime game UI — for new editor tools, use UI Toolkit unless the project already uses IMGUI exclusively
Figma design import — not available here
Importing a Figma design requires Unity's Figma integration service, which only exists
inside Unity AI Assistant. There is no client-side equivalent, so do not promise it.
If the user brings a Figma URL, say the automated import is not available here and offer
the alternative: ask them to describe or screenshot the screen, then build it with the
appropriate framework skill above.
Common Guidelines (All UI Systems)
Scope Discipline
Do only what is requested:
- Question → answer without making changes
- Targeted edit → modify only what's specified
- Generation → create only requested files
- Don't proactively add scripts unless explicitly asked
These do NOT imply scripts:
- "proper buttons" → well-styled buttons
- "working UI" → valid UI that renders
- "menu screen" → visual layout only
Conventions
Follow project patterns first. Search existing files before applying defaults.
| Type |
Convention |
| Element names |
Follow project patterns, or camelCase |
| File organization |
Match existing project structure |
Workflow
- Determine UI system — Use routing logic above
- For Figma requests, tell the user the automated import is not available here, then
work from their description or screenshot and continue with framework detection
- Activate specialized skill — Route to
ui-uitk, ui-ugui, or ui-imgui
- Skill handles request — Understanding, editing, or generation as appropriate
Handling Mixed Projects
Many Unity projects use multiple UI systems simultaneously (e.g., UI Toolkit for runtime game UI plus editor tools). When you detect multiple systems:
- For runtime UI requests (menus, HUDs, game screens) → Route to whichever runtime system (UITK or uGUI) is already in use
- For editor tool requests (custom inspectors, editor windows):
- Prefer UI Toolkit (CreateGUI) for new editor UI — it's the modern approach
- Only use IMGUI if the project's existing editor tools use IMGUI exclusively, or user explicitly requests IMGUI
- Check for existing editor
.uxml files to confirm UITK usage
- If creating new runtime UI in a mixed project → Match the pattern used by similar existing UI; if there is no similar existing UI and the user has no preference, use uGUI
1---2name: ui3description: Determine the appropriate UI system for the project and route to the correct specialized skill.4---56Determine the appropriate UI system for the project and route to the correct specialized skill.78## When to Route vs Answer Directly910**Route to a specialized skill when:**11- User wants to understand, edit, or generate specific UI elements12- User references specific files or UI objects13- User asks for UI changes or creation1415**Answer directly (without routing) when:**16- User asks comparative/educational questions ("What's the difference between UI Toolkit and uGUI?")17- User asks about UI system capabilities or recommendations ("Should I use UITK or uGUI for mobile?")18- User needs conceptual explanation of Unity UI architecture1920## Routing Logic2122**Step 1: Check for explicit file references or keywords:**2324| User mentions | Route to |25|---------------|----------|26| `.uxml` or `.uss` files (including in `/Editor/`) | `ui-uitk` |27| "UI Toolkit", "UITK", "UIElements", "CreateGUI" | `ui-uitk` |28| Canvas prefabs/objects, `.prefab` with UI | `ui-ugui` |29| "uGUI", "Canvas", "RectTransform", "legacy UI" | `ui-ugui` |30| "IMGUI", "OnGUI", "OnInspectorGUI", "immediate mode" | `ui-imgui` |31| Figma URL (`figma.com/design/...`), "Figma", "import from Figma" | Not available — see below |3233**For editor-related requests (EditorWindow, custom inspector, PropertyDrawer):**34- If no explicit UI system mentioned → **Go to Step 2** to detect project's editor UI system35- If no existing pattern is detected, default to `ui-uitk` for new editor UI36- Only use `ui-imgui` if project exclusively uses IMGUI or user explicitly requests it3738If explicit file or keywords found, activate the corresponding skill immediately.3940**Step 2: If ambiguous, detect from project:**4142Search the project to determine which UI system is in use:4344| Look for | Indicates |45|----------|-----------|46| `.uxml` or `.uss` files (including in `/Editor/`) | UI Toolkit (runtime or editor) |47| `UIDocument` components in scenes | UI Toolkit (runtime) |48| Editor scripts with `CreateGUI()` method | UI Toolkit (editor) |49| `Canvas` in scenes/prefabs | uGUI |50| `RectTransform` heavy usage | uGUI |51| Editor scripts with `OnGUI()` or `OnInspectorGUI()` | IMGUI (legacy editor) |5253**Step 3: If still unclear, ask or default:**5455- For existing projects: detect and follow whichever framework is already in use (Step 2)56- For new projects with no UI yet: ask the user which framework they prefer (UI Toolkit vs uGUI), briefly explaining that UI Toolkit is modern/CSS-like while uGUI is Canvas-based/mature57- For new runtime/game UI where the user has no preference: default to uGUI (`ui-ugui`)58- When the user mentions mobile/performance constraints or older Unity versions (pre-6.0): bias toward uGUI (`ui-ugui`)5960## Request Types6162Specialized skills handle three types of requests:6364| Type | Examples |65|------|----------|66| **Understanding** | "What does this button do?", "How is this laid out?", "Explain this UI" |67| **Editing** | "Change this color", "Add a label here", "Fix this layout" |68| **Generation** | "Create a menu", "Make an inventory screen", "Build a settings panel" |6970Route all types to the appropriate specialized skill based on the UI system.7172## Available Sub-Skills7374### UI Toolkit — `ui-uitk`75- For Unity 6.0+ projects using UI Toolkit (runtime game UI and editor tools)76- **Understands**, **edits**, and **generates** `.uxml` and `.uss` files77- Modern, CSS-like styling approach78- Preferred for new editor windows (CreateGUI) and existing UI Toolkit projects7980### uGUI — `ui-ugui`81- For projects using Unity's Canvas-based UI system82- **Understands**, **edits**, and **generates** Canvas hierarchies83- Uses Layout Groups for responsive design84- Default for new runtime/game UI when the user has no framework preference8586### IMGUI — `ui-imgui`87- For legacy editor tools using OnGUI/immediate mode88- Only use when project has existing IMGUI editor code or user explicitly requests IMGUI89- **Understands**, **edits**, and **generates** EditorWindow, inspectors, PropertyDrawers built with OnGUI90- Not for runtime game UI — for new editor tools, use UI Toolkit unless the project already uses IMGUI exclusively9192### Figma design import — not available here9394Importing a Figma design requires Unity's Figma integration service, which only exists95inside Unity AI Assistant. There is no client-side equivalent, so do not promise it.9697If the user brings a Figma URL, say the automated import is not available here and offer98the alternative: ask them to describe or screenshot the screen, then build it with the99appropriate framework skill above.100101## Common Guidelines (All UI Systems)102103### Scope Discipline104105**Do only what is requested:**106- Question → answer without making changes107- Targeted edit → modify only what's specified108- Generation → create only requested files109- Don't proactively add scripts unless explicitly asked110111**These do NOT imply scripts:**112- "proper buttons" → well-styled buttons113- "working UI" → valid UI that renders114- "menu screen" → visual layout only115116### Conventions117118**Follow project patterns first.** Search existing files before applying defaults.119120| Type | Convention |121|------|------------|122| Element names | Follow project patterns, or camelCase |123| File organization | Match existing project structure |124125### Workflow1261271. **Determine UI system** — Use routing logic above128 - For Figma requests, tell the user the automated import is not available here, then129 work from their description or screenshot and continue with framework detection1302. **Activate specialized skill** — Route to `ui-uitk`, `ui-ugui`, or `ui-imgui`1313. **Skill handles request** — Understanding, editing, or generation as appropriate132133## Handling Mixed Projects134135Many Unity projects use multiple UI systems simultaneously (e.g., UI Toolkit for runtime game UI plus editor tools). When you detect multiple systems:136137- **For runtime UI requests** (menus, HUDs, game screens) → Route to whichever runtime system (UITK or uGUI) is already in use138- **For editor tool requests** (custom inspectors, editor windows):139 - **Prefer UI Toolkit** (CreateGUI) for new editor UI — it's the modern approach140 - Only use IMGUI if the project's existing editor tools use IMGUI exclusively, or user explicitly requests IMGUI141 - Check for existing editor `.uxml` files to confirm UITK usage142- **If creating new runtime UI in a mixed project** → Match the pattern used by similar existing UI; if there is no similar existing UI and the user has no preference, use uGUI