AlexandrAI AGENTS.md
agents-md

Draw.io Lite Skill Agent Guide

Project-specific AGENTS.md guidance for the Draw.io Lite skill, route selection, template-first XML generation, style defaults, validation, and response contract.

AGENTS.md

Guidance for coding agents working on Draw.io Lite, a lightweight skill for creating and editing draw.io diagrams.

Project Overview

Draw.io Lite converts text, notes, Mermaid, CSV, YAML, screenshots, or existing diagrams into draw.io-ready structure. It is template-first and route-based, with explicit workflows for create, edit, replicate, and convert tasks.

Key paths:

  • SKILL.md: route, workflow, XML, style, and response rules.
  • assets/templates/flowchart-standard.drawio: default process template.
  • assets/templates/system-architecture-standard.drawio: default architecture template.
  • assets/templates/incident-analysis-standard.drawio: default incident template.

Route Rules

  • create: build a new diagram from request text.
  • edit: modify an existing .drawio while preserving unaffected cells.
  • replicate: reconstruct a reference visual into structured draw.io form.
  • convert: turn Mermaid, CSV, YAML, or notes into nodes, groups, edges, and layout.

Classify the route before editing files.

Workflow

  1. Summarize the diagram goal in one sentence.
  2. Extract title, nodes, groups, edges, and layout hint.
  3. Draft a short ASCII outline when the structure is dense or ambiguous.
  4. Select the closest template.
  5. Build or edit XML on top of that template.
  6. State assumptions, limits, and exact change scope.

XML And Style Rules

  • Start from a template by default.
  • Keep node labels short and readable.
  • Prefer orthogonal edges for process and system diagrams.
  • Place containers before child nodes and edges.
  • Preserve page IDs and unaffected cells when editing.
  • Use semantic built-in shapes before vendor-specific icons.
  • Keep default font, palette, and edge style consistent with the skill.

Quality Checks

  • Labels are readable.
  • Arrow directions match the explanation.
  • Containers wrap their child nodes.
  • No duplicate IDs or orphan edges exist.
  • The file opens in draw.io without recovery warnings.

Security

  • Do not embed private screenshots, customer names, local paths, or internal URLs in public example diagrams.
  • Treat source diagrams and screenshots as potentially confidential.