viz

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Viz Pack — Multi-Mode Visual Dispatcher

Viz Pack — 多模式可视化调度工具

Transform any content into a professional visualization via one of four output modes. This skill is a dispatcher: it resolves the active mode, loads the mode-specific workflow from
references/
, and executes it.
可通过四种输出模式将任意内容转换为专业可视化内容。该技能作为调度工具:它会解析激活模式,从
references/
加载对应模式的工作流并执行。

Step 1: Resolve the active mode

步骤1:解析激活模式

Inspect the invocation in this priority order:
  1. Positional argument. The first positional argument is
    $0
    . If
    $0
    matches
    diagram
    ,
    infographic
    ,
    visualize
    , or
    publish
    , use it as the mode. Remaining arguments (
    $ARGUMENTS
    after the mode token) are the optional content reference (URL, file path, or inline text).
  2. Keyword trigger. If
    $0
    is empty or not a valid mode, scan the most recent user message for a trigger keyword and map it to a mode:
    Trigger keyword(s)Mode
    "diagram it", "excalidraw this", "draw a diagram of this"
    diagram
    "nano this"
    infographic
    "vis it"
    visualize
    "ver it", "hey it", "heygenverse this", "put this on heygenverse as a visual"
    publish
  3. Ask the user. If neither signal yields a mode, stop and ask which output to produce —
    diagram
    (Excalidraw),
    infographic
    (Swiss Pulse PNG via Gemini),
    visualize
    (inline Visualizer widget), or
    publish
    (interactive Swiss Pulse app on HeyGenverse). Do not guess.
Invocation context injected at render time: mode token is
$0
, content reference is
$ARGUMENTS
.
按以下优先级检查调用指令:
  1. 位置参数。第一个位置参数为
    $0
    。若
    $0
    匹配
    diagram
    infographic
    visualize
    publish
    ,则将其作为模式。剩余参数(模式标识后的
    $ARGUMENTS
    )为可选的内容引用(网址、文件路径或内嵌文本)。
  2. 关键词触发。若
    $0
    为空或不是有效模式,则扫描用户最新消息中的触发关键词并映射到对应模式:
    触发关键词模式
    "diagram it"、"excalidraw this"、"draw a diagram of this"
    diagram
    "nano this"
    infographic
    "vis it"
    visualize
    "ver it"、"hey it"、"heygenverse this"、"put this on heygenverse as a visual"
    publish
  3. 询问用户。若以上两种方式均无法确定模式,则停止操作并询问用户需要生成哪种输出——
    diagram
    (Excalidraw图表)、
    infographic
    (通过Gemini生成Swiss Pulse PNG图片)、
    visualize
    (内嵌式Visualizer组件)或
    publish
    (在HeyGenverse上发布交互式Swiss Pulse应用)。请勿自行猜测。
渲染时注入的调用上下文:模式标识为
$0
,内容引用为
$ARGUMENTS

Step 2: Load the mode workflow

步骤2:加载模式工作流

Read the reference file for the resolved mode and follow its workflow end-to-end:
ModeWorkflow file
diagram
references/mode-diagram.md
infographic
references/mode-infographic.md
visualize
references/mode-visualize.md
publish
references/mode-publish.md
Read the file on every invocation — do not execute from memory — so any updates to the workflow are applied.
读取对应模式的参考文件并完整执行其工作流:
模式工作流文件
diagram
references/mode-diagram.md
infographic
references/mode-infographic.md
visualize
references/mode-visualize.md
publish
references/mode-publish.md
每次调用时都需读取文件——请勿依赖内存执行——确保工作流的任何更新都能生效。

Step 3: Acquire the content (shared across modes)

步骤3:获取内容(所有模式通用)

All four modes accept content from the same sources. Resolve the content target in this priority order:
  1. If
    $ARGUMENTS
    contains a URL → retrieve via
    web_fetch
    . If blocked (429/403), fall back to
    web_search
    with key phrases to get the content from search snippets.
  2. If
    $ARGUMENTS
    points to an uploaded file → read from
    /mnt/user-data/uploads/
    using
    pdfplumber
    for PDF,
    python-docx
    for DOCX,
    pandas
    for CSV/TSV, direct read for TXT/MD/HTML.
  3. If
    $ARGUMENTS
    is inline text → use it directly.
  4. Else scan the current conversation for a referenced source (uploaded file, URL previously shared, meeting transcript at
    /mnt/transcripts/
    , pasted text) and use that.
Summarize to core structure if the content exceeds 3,000 words for modes that pipe text into an LLM (
infographic
) or 5,000 words for modes that assemble visuals client-side (
diagram
,
visualize
,
publish
).
四种模式均支持从以下来源获取内容。按以下优先级解析内容目标:
  1. $ARGUMENTS
    包含网址 → 通过
    web_fetch
    获取。若请求被拦截(429/403状态码),则回退至
    web_search
    ,通过关键短语从搜索片段中获取内容。
  2. $ARGUMENTS
    指向已上传文件 → 使用对应工具读取
    /mnt/user-data/uploads/
    路径下的文件:PDF用
    pdfplumber
    ,DOCX用
    python-docx
    ,CSV/TSV用
    pandas
    ,TXT/MD/HTML直接读取。
  3. $ARGUMENTS
    是内嵌文本 → 直接使用该文本。
  4. 否则,扫描当前对话中的引用来源(已上传文件、之前分享的网址、
    /mnt/transcripts/
    下的会议记录、粘贴的文本)并使用该来源。
若内容超过指定字数,需提炼核心结构:对于将文本输入LLM的模式(
infographic
),字数上限为3000字;对于客户端侧生成可视化的模式(
diagram
visualize
publish
),字数上限为5000字。

Step 4: Execute the loaded workflow

步骤4:执行加载的工作流

Follow the steps in the loaded workflow file exactly. Do not substitute tools, colors, typography, or output formats across modes.
严格按照加载的工作流文件中的步骤执行。请勿跨模式替换工具、颜色、排版或输出格式。

Non-Negotiable Rules

不可违反的规则

  • Never respond with a plain-text summary instead of the requested visual output.
  • Never swap output format across modes (e.g., do not emit Excalidraw when
    mode=publish
    was requested).
  • Never skip reading the mode-specific workflow file — every mode has non-obvious tool contracts and design constraints.
  • Never use colors outside each mode's palette (Excalidraw: 2–3 neutrals; Swiss Pulse modes: black/white + #0066FF only).
  • 切勿以纯文本摘要替代请求的可视化输出。
  • 切勿跨模式调换输出格式(例如,当请求
    mode=publish
    时,请勿生成Excalidraw内容)。
  • 切勿跳过读取模式专属工作流文件——每个模式都有非显性的工具约定和设计约束。
  • 切勿使用超出各模式调色板的颜色(Excalidraw:2-3种中性色;Swiss Pulse模式:仅黑白+#0066FF)。

Error Handling

错误处理

  • Mode unresolved → execute Step 1.3 and ask the user.
  • Missing workflow file → stop and report the missing path (
    references/mode-<mode>.md
    ).
  • Missing tool integration (
    Excalidraw:*
    ,
    visualize:*
    ,
    HeyGenverse:*
    ) → report the specific missing integration and ask whether to proceed with an alternative mode.
  • Missing
    GEMINI_API_KEY
    (mode
    infographic
    only) → stop and ask for the key before continuing.
  • Content acquisition fails (empty, unreadable, blocked URL) → report the specific failure and request a different source.
  • 模式未解析 → 执行步骤1.3,询问用户。
  • 工作流文件缺失 → 停止操作并报告缺失的文件路径(
    references/mode-<mode>.md
    )。
  • 工具集成缺失
    Excalidraw:*
    visualize:*
    HeyGenverse:*
    )→ 报告具体缺失的集成,并询问是否改用其他模式继续。
  • GEMINI_API_KEY
    缺失
    (仅
    infographic
    模式)→ 停止操作并请求提供密钥后再继续。
  • 内容获取失败(内容为空、无法读取、网址被拦截)→ 报告具体失败原因,并请求提供其他来源。