返回 Skill 列表
extension
分类: 开发与工程无需 API Key

uml

使用drawio XML格式创建UML(统一建模语言)图。最适合软件建模,包括类图、序列图、活动图、状态机图、组件图、用例图和部署图。基于drawio构建,并带有UML特定的形状和符号。不适用于简单的流程图(请使用mermaid)、分层系统架构(请使用architecture)或数据图表(请使用vega)。

person作者: jakexiaohubgithub

UML Diagram Generator

Quick Start: Choose diagram type → Define classes/objects/actors → Add relationships/edges → Use appropriate shapes and arrow styles → Wrap in ```drawio fence.

⚠️ IMPORTANT: Always use ```drawio code fence. NEVER use ```xml — it will NOT render as a diagram.

Critical Rules

🔗 This is a drawio-derived skill. All structure, layout, and edge routing rules inherit from drawio SKILL.md. Read the base rules first.

UML-specific additions:

  • Use standard UML shapes: shape=umlLifeline, shape=umlActor, shape=component, swimlane;childLayout=stackLayout
  • Use fillColor=none; for package/component containers to avoid covering child elements

UML Diagram Types

| Type | Purpose | Key Shape | Example | |------|---------|-----------|---------| | Class | Class structure and relationships | swimlane;childLayout=stackLayout | class-diagram.md | | Sequence | Message interactions over time | shape=umlLifeline | sequence-diagram.md | | Activity | Workflow and process flow | rounded=1;arcSize=50 | activity-diagram.md | | State Machine | Object lifecycle states | rounded=1 with colors | state-machine-diagram.md | | Component | System component organization | shape=component | component-diagram.md | | Use Case | User-system interactions | shape=umlActor, ellipse | use-case-diagram.md | | Deployment | Physical deployment architecture | shape=cube;direction=south | deployment-diagram.md | | Object | Runtime object snapshot | swimlane;fontStyle=4 | object-diagram.md | | Package | Module organization | shape=folder | package-diagram.md | | Communication | Object collaboration | whiteSpace=wrap with numbered messages | communication-diagram.md | | Composite Structure | Internal class structure | shape=ellipse;container=1;dashed=1 | composite-structure-diagram.md | | Interaction Overview | Activity + sequence combination | shape=umlFrame | interaction-overview-diagram.md | | Timing | State changes over time | shape=waypoint | timing-diagram.md | | Profile | UML extension mechanisms | <<stereotype>> labels | profile-diagram.md |