visual-explainer
Render interactive visual explanations, architecture simulators, option tradeoff matrices, permission or blast-radius maps, and phased rollout cards on the host's native visual surface. Use when answering a question that compares three or more options across multiple dimensions, traces a multi-gate request or state flow, maps permissions or blast radius, lays out a multi-phase architecture plan, or when the user asks to visualize or sends `viz`.
- License 许可
- MIT
- 所属仓库
- dwin/skills
- 最近更新
- 2026-11-14
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- visual-explainer
- description
- Render interactive visual explanations, architecture simulators, option tradeoff matrices, permission or blast-radius maps, and phased rollout cards on the host's native visual surface. Use when answering a question that compares three or more options across multiple dimensions, traces a multi-gate request or state flow, maps permissions or blast radius, lays out a multi-phase architecture plan, or when the user asks to visualize or sends `viz`.
02 资源文件 2
- 参考文档agents/openai.yaml234 B
- 参考文档references/surfaces.md5.1 KB
03 SKILL.md 正文
Visual Explainer
Compress dense engineering answers into an interactive visual card so the user can click scenarios, toggle options, and act in seconds rather than reading walls of prose.
When to render vs stay in plain text
Render an interactive visual when the answer:
- Compares three or more options across multiple evaluation dimensions.
- Traces a request, authentication, permission, or state flow across three or more gates or components.
- Maps blast radius, tenant or role permissions, or Today vs Target state.
- Lays out a multi-phase rollout or architecture plan alongside its tradeoffs.
- Responds to an explicit visualization request or the standalone
vizalias.
Stay in plain text (a short paragraph, a small Markdown table, or a fenced Mermaid block) for simple factual lookups, single-file bug reports, routine git or CI checks, and one-decision answers.
1. Pick the host surface
Check what rendering or file-writing tools this session actually exposes before
choosing a surface. In a read-only session with neither a host visual tool nor
file-write access, deliver a compact Markdown comparison matrix and a fenced
mermaid diagram inline without attempting unavailable writes.
Otherwise, identify the host this session runs in and read the matching section in references/surfaces.md:
| Host | Surface to render on |
|---|---|
T3 Code (html_preview and html_render available) |
Inline HTML card via html_preview (width: 728 and 390) then html_render |
| Cursor IDE / Cloud (outside T3 Code) | In-transcript HTML fragment (<cursor-content kind="visualization" ...>) for immutable answers, or .canvas.tsx (cursor/canvas) for durable workspace dashboards |
| Claude Code (CLI / IDE outside T3 Code) | Artifact tool publishing a self-contained .html page (or /tmp/<slug>.html + inline Mermaid/table when signed out) |
Claude Chat / Cowork (claude.ai or Desktop) |
Self-contained HTML or React Artifact beside the conversation |
| ChatGPT | GPT-6 Intelligent UI inline interactive cards/charts, or a downloadable self-contained .html simulator when custom stateful logic is needed |
| Codex CLI / App (outside T3 Code) | Compact Mermaid + Markdown table inline, plus /tmp/<slug>.html linked by path when stateful interaction helps |
Notion (create_attachment available) |
Uploaded .html <embed source="file-upload://..." /> followed by a collapsed <toggle> table fallback |
2. Choose the smallest interactive pattern
Pick one primary interaction, or combine at most two panels when the question has both a flow and a comparison:
- Path / Gate Simulator: Persona or input chips at top -> 3 to 5 stage cards showing what each gate checks -> verdict bar with outcome badge and audit trail.
- Architecture / Option Switcher: Segmented tabs (
Option A,Option B, orProposed targetvsToday's state) switching an inline SVG topology diagram and 3 to 4 key constraint boxes underneath. - Blast-Radius / Access Matrix: Scannable grid of principals or services
by targets with semantic status pills (
Allow,JIT,Read-Only,Blocked,Gap) and keyboard-accessible hover/focus detail tooltips. - Phased Rollout Card: Compact
P1toPNlist pairing each phase's action with its concrete target or gate.
Every visual must make its first paint useful before any click or hover.
3. Authoring invariants
- Zero external dependencies. Inline
<style>, vanilla<script>IIFE, and inline<svg>or semantic HTML (cursor/canvasimports only on Cursor Canvases). Never load external CDNs, fonts, images, orfetch()calls. - Theme-native colors. Use host CSS tokens where provided (T3
:rootvariables or CursoruseHostTheme()), and support both light and dark modes via@media (prefers-color-scheme: dark)and[data-theme="dark"]on standalone HTML files. Keep surfaces flat: no gradients, decorative shadows, or rainbow borders. - Responsive and keyboard-accessible. Compose for ~728px desktop width
down to 360px mobile width so grids stack cleanly (
2or1columns on narrow screens) and code badges wrap instead of clipping. Use<button>witharia-pressedfor toggles, orrole="tab"witharia-selected(and arrow-key navigation) inside arole="tablist", and pair hover handlers withtabindex="0"andfocus/blur. - Truthful data only. Every role, file, metric, limit, and status comes from verified session evidence. Mark unverified items explicitly as open questions rather than inventing values.
4. Let the visual do the explaining
Do not narrate, announce, or restate what the visual already shows. Keep the text reply underneath to a few lines covering only:
- The direct answer or recommendation in the opening sentence (when the host places text below an inline frame, skip repeating the card's tables).
- Links to created files, pages, or pull requests.
- Numbered or coded open decisions (
Q1,Q2) waiting on the user.
04 同仓库更多 Skills
writing-for-agents
Writing documents for agents. Use when creating or editing skills, or modifying AGENTS.md or CLAUDE.md.
wizard
Generate an interactive bash wizard that walks a human through steps only they can perform. Use when provisioning infrastructure, setting up credentials or CI secrets, walking an unfamiliar third-party dashboard, or running a one-off migration or cutover. Don't invoke this for steps the agent can perform itself.
why
Find out why code is the way it is from its history, reviews, tickets, docs, and other records, and say how sure each answer is. Use when the user asks why something is built, written, or behaves a certain way, why a choice was made, or where a number or limit came from.
whats-next
Match a task to the skill, flow, or playbook that fits it. Use when the user asks what to do next or which workflow applies, when a task fits no other skill, and for these kinds of work, which have playbooks here - proving a property of concurrent or stateful code with a model checker or verifier, matching a UI pixel for pixel, and diagnosing a live process or a captured profile, trace, or heap snapshot.
wayfinder
Plan a huge chunk of work — more than one agent session can hold — as a shared map of decision tickets on your issue tracker, and resolve them one at a time until the way to the destination is clear.
wait-what
Stop. That last message did not land — re-pitch it.