prototype-design-xml

prototype-design-xml is a skill for OpenCode from BeWaterMyFriend7/SKILL-PROJECT. It costs 92 tokens per session (1,115 once invoked), scanned A, original, Apache-2.0.

A skill that creates editable Draw.io diagrams.net page prototypes from written requirements, mainly as low-detail layouts for web pages or internal tools. Draw.io is a diagram editor whose files can be reopened and changed.

In plain words
What is it for?
Use it to create editable wireframes for page reviews, admin screens, product structures, and UI requirements; it is not for runnable websites or decorative final designs.
Why use it?
It turns requirements into a structured visual draft, making page layout and component discussions easier before building the real interface.

Skill for OpenCode

Written for OpenCode: installed under .opencode/.

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/bewatermyfriend7/skill-project/prototype-design-xml
Any agent
npx skills add BeWaterMyFriend7/SKILL-PROJECT --skill prototype-design-xml
Clone the repo
git clone --depth 1 https://github.com/BeWaterMyFriend7/SKILL-PROJECT

Made for: OpenCode.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for prototype-design-xml

README.md
[![agentmods](https://agentmods.dev/badge/skills/bewatermyfriend7/skill-project/prototype-design-xml.svg)](https://agentmods.dev/skills/bewatermyfriend7/skill-project/prototype-design-xml)
Your own site
<a href="https://agentmods.dev/skills/bewatermyfriend7/skill-project/prototype-design-xml"><img src="https://agentmods.dev/badge/skills/bewatermyfriend7/skill-project/prototype-design-xml.svg" alt="Measured on agentmods" height="20"></a>
Per session 92 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,115 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00092 $0.01115
Opus 5 $0.00046 $0.00558
Sonnet 5 $0.00018 $0.00223
Haiku 4.5 $0.00009 $0.00112

Measured 6d ago against content hash 5de6061d526b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

prototype-design-xml scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.opencode/skills/prototype-design-xml/SKILL.md · 71 lines

What it actually says

Draw.io XML 原型生成器

生成用于需求沟通和页面评审的可编辑原型。重点表达页面结构、组件和状态,不把原型画成复杂流程图或正式视觉稿。

必读资源

  • 分析页面、组件和布局前读取 references/prototype-dsl.md
  • 生成时以 templates/web-prototype.drawio 为页面骨架参考。
  • 需要完整案例时读取 examples/red-packet-prototype.drawio

强制流程

需求分析 → 页面与任务规划 → 内部自然语言 DSL → 匹配基础模板 → 生成 Draw.io XML → 结构检查 → Draw.io 渲染检查 → 修正并交付

1. 分析需求

明确原型目的、用户角色、核心任务、页面范围、设备类型、保真度、主题和输出路径。用户提供需求文档时读取该文档;未提供时直接分析当前需求,不依赖固定默认文件。

2. 规划页面与任务

列出页面清单、全局导航、每个页面的主要任务及页面关系。一个主要页面优先使用一个 Draw.io diagram page;页面较少时也可以在同一画布使用清晰分离的页面画框。

普通页面原型不使用大量跳转箭头。需要表达页面关系时优先使用编号、文字注释或单独的页面索引;只有用户明确要求页面流程视图时才增加少量连线。

3. 在内部形成详细自然语言 DSL

references/prototype-dsl.md 在当前上下文中描述页面、画框、导航、组件、文案、状态、布局和检查要求。DSL 仅作为内部生成依据,默认不得创建、输出或交付 .dsl、Markdown、JSON、JSON Schema 或 DiagramPlan 等中间文件。

完成条件:只阅读 DSL 即可还原所有页面画框和主要组件,XML 阶段不再猜测布局意图。

4. 匹配基础模板

使用 templates/web-prototype.drawio 的页面画框、设计令牌和基础组件。根据需求增删区域,禁止保留空导航、空卡片或无业务含义的模板占位内容。

5. 生成 Draw.io XML

  • 生成 UTF-8、未压缩、可编辑的 .drawio XML。
  • 保持 mxCell ID 唯一,元素位于对应页面 root 下。
  • 默认 grid=0shadow=0,不使用渐变、纹理或背景网格。
  • 标题使用独立文字元素,不与内容容器共用一个 cell。
  • 使用普通矩形、文字和分割线;圆角控制在 4–6px 的视觉程度。
  • 页面允许纵向延伸,不把全部内容压入固定首屏。
  • 原型页面默认不画连接线;注释线不得穿过页面内容。

6. 结构检查

检查 XML 可解析、ID 唯一、页面名称清楚、元素父级正确、画框范围合理、文字非空以及必要组件完整。检查标题是否独立、同类组件尺寸是否一致、表格列是否对齐、元素是否越界或重叠。

7. Draw.io 渲染检查

在 Draw.io 中打开或导出 PNG 进行视觉检查,覆盖颜色对比、布局均衡、元素重叠、字体清晰、对齐、间距、内容拥挤、大面积空白和连线混乱。发现问题时返回 DSL 或布局阶段修正。

无法真实打开或渲染时必须明确说明“仅完成 XML 结构检查,未完成视觉验收”,不得声称最终视觉质量已通过。

简约视觉基线

  • 默认浅色、系统字体、1px 边框、4–6px 圆角和 4/8px 间距体系。
  • 默认无阴影、渐变、网格、发光和装饰性插画。
  • 页面标题、区域标题和组件标签使用独立文字元素形成三级层级。
  • 主色只用于主要操作和当前状态,状态色不得大面积铺色。
  • 不为每个区域增加容器;只在需要表达分组时使用边框。

输出

输出到用户指定目录;未指定时输出到项目根目录 output/prototype/drawio。只交付最终 .drawio 路径,并说明页面范围、主题及结构和渲染验证结果。默认不创建 README、DSL、Markdown、JSON 或临时图片等中间产物。

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 71 lines · 92 tokens per session scan A 5de6061d526b

Subscribe to this mod's changes

prototype-design-xml is a skill published in the GitHub repository BeWaterMyFriend7/SKILL-PROJECT (51 stars, last pushed 2d ago), licensed Apache-2.0. It adds 92 tokens to every session and 1,115 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

next-cache-components-optimizer

Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…

vercel/next.js · 170 tokens

next-partial-prefetching-adoption

Turn on Partial Prefetching in a Next.js app and work through the insights it surfaces. Use when the user wants to enable or adopt Partial Prefetching, flip the partialPrefetching flag, opt routes in with export const prefetch = 'partial', audit Link prefetch={true} behavior, preserve existing prefetched UI with…

vercel/next.js · 103 tokens

chronicle

Analyze Copilot session history for standup reports, usage tips, session search, and session reindexing. Use when the user asks for a standup, daily summary, usage tips, workflow recommendations, wants to search or find past sessions by keyword/file/PR, wants to reindex their session store, or asks about deleting…

microsoft/vscode · 72 tokens