chip-diagram-generator

chip-diagram-generator is a skill for Claude Code from zhaixin244-wq/fnw. It costs 88 tokens per session (1,438 once invoked), scanned A, original, MIT.

A diagram-making guide for chip designs, covering module block diagrams, timing diagrams, and state-machine diagrams. It uses D2, Wavedrom, and, when needed, Mermaid to produce PNG images.

In plain words
What is it for?
Use it to document RTL modules, data paths, finite-state machines, interface handshakes, protocol transactions, and NoC topologies.
Why use it?
It gives chip-design work a defined way to turn architecture and signal behavior into rendered diagrams.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

Good fit Use it to document RTL modules, data paths, finite-state machines, interface handshakes, protocol transactions, and NoC topologies.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/zhaixin244-wq/fnw/chip-diagram-generator
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.

Any agent
npx skills add zhaixin244-wq/fnw --skill chip-diagram-generator
Clone the repo
git clone --depth 1 https://github.com/zhaixin244-wq/fnw

Made for: Claude Code.

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 chip-diagram-generator

README.md
[![agentmods](https://agentmods.dev/badge/skills/zhaixin244-wq/fnw/chip-diagram-generator/github.svg)](https://agentmods.dev/skills/zhaixin244-wq/fnw/chip-diagram-generator)
Your own site
<a href="https://agentmods.dev/skills/zhaixin244-wq/fnw/chip-diagram-generator"><img src="https://agentmods.dev/badge/skills/zhaixin244-wq/fnw/chip-diagram-generator/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for chip-diagram-generator

Your own site · 80×15
<a href="https://agentmods.dev/skills/zhaixin244-wq/fnw/chip-diagram-generator"><img src="https://agentmods.dev/badge/skills/zhaixin244-wq/fnw/chip-diagram-generator.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 88 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,438 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.00088 $0.01438
Opus 5 $0.00044 $0.00719
Sonnet 5 $0.00018 $0.00288
Haiku 4.5 $0.00009 $0.00144

Measured 12d ago against content hash 033337829e04, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

chip-diagram-generator 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 12d 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.

.claude/skills/chip-diagram-generator/SKILL.md · 111 lines

How it starts

The opening of the file, as written. The whole thing — 111 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Chip Diagram Generator

任务

为芯片模块架构生成专业、可渲染的图表。

支持的图表类型(按优先级排序)

优先级 图表类型 工具 输出格式 适用场景
1(首选) 框图/架构图/FSM D2 → PNG .d2d2 --layout dagre 模块框图、数据通路、状态机、NoC 拓扑
2 时序图 Wavedrom → PNG .jsonwavedrom-cli 接口握手、协议事务、关键路径
3(降级) 通用图表 Mermaid .mmdmermaid-cli 仅当 D2 无法表达时使用

项目规范:微架构模板 §5.3 明确要求使用 D2 生成 FSM 图。框图和状态机图必须优先使用 D2,Mermaid 仅作为降级方案。

执行步骤

  1. 确认图表类型与用户所需展示的核心信息。
  2. 根据图表类型选择工具
    • 框图/FSM → 生成 D2 源码(.d2 文件),使用 d2 --layout dagre {file}.d2 {file}.png 编译
    • 时序图 → 生成 Wavedrom JSON(.json 文件),使用 wavedrom-cli -i {file}.json -p {file}.png 编译
    • 降级 → 仅当 D2/Wavedrom 均无法表达时,使用 Mermaid
  3. 芯片领域模板
    • RR 仲裁器 FSM:S_IDLE → S_CH0/S_CH1/... → S_IDLE,使用独热码编码
    • Valid-Ready 握手:valid 不依赖 ready,ready 优先依赖下游
    • 子模块框图:左侧 input(箭头→指向模块),右侧 output(箭头→指向外部)
  4. 编译并验证 PNG 输出成功。为复杂框图添加图例与信号流向说明(箭头旁标注数据宽度)。

输出格式

每个图表输出:

  1. 源码(D2/Wavedrom JSON)
  2. 编译命令
  3. PNG 文件路径
  4. 简短文字说明图表内容

使用示例

示例 1:生成模块框图(D2)

用户:帮我画 data_adpt 的模块框图,包含 buf、crc、align 三个子模块

预期行为:生成 wd_data_adpt_arch.d2,使用 D2 语法定义子模块节点和信号连线,d2 --layout dagre 编译为 PNG

示例 2:生成握手时序图(Wavedrom)

用户:画一个 valid-ready 握手时序图

预期行为:生成 wd_valid_ready.json,使用 Wavedrom JSON 定义信号时序,wavedrom-cli 编译为 PNG

示例 3:生成 FSM 状态机图(D2)

用户:画一个 4 通道 RR 仲裁器的状态机图

预期行为:生成 wd_rr_arbiter_fsm.d2,使用 D2 语法定义 S_IDLE/S_CH0~S_CH3 状态和转移条件,独热码编码,编译为 PNG

使用示例

示例 1:生成模块框图

用户:帮我画 data_adpt 的模块框图,包含 buf、crc、align 三个子模块

预期行为:生成 Mermaid graph TB 源码,标注信号流向和数据宽度

示例 2:生成握手时序图

用户:画一个 valid-ready 握手时序图

预期行为:生成 Wavedrom JSON 源码,展示 valid/ready/data 信号的时序关系

异常处理

场景 触发条件 处理动作
图表语法错误 Mermaid/Wavedrom 解析失败 标注错误位置,给出修正建议
图表过于复杂 节点数 > 20 建议拆分为多个子图
渲染工具不可用 mermaid-cli 未安装 输出源码,建议用户使用在线编辑器验证
信号名不规范 使用了非法字符 自动替换为合法标识符,提示用户确认

检查点

检查前

  • 确认图表类型(框图/时序图/FSM)已明确
  • 确认核心信息和数据流向已了解

Read the full file on GitHub · 111 lines

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. 12d ago First seen · 111 lines · 88 tokens per session scan A 033337829e04

Subscribe to this mod's changes

chip-diagram-generator is a skill published in the GitHub repository zhaixin244-wq/fnw (29 stars, last pushed 3mo ago), licensed MIT. It adds 88 tokens to every session and 1,438 once invoked, about $0.0004 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

gke-compute-classes

Configures, optimizes, and troubleshoots GKE ComputeClasses. Use when configuring Spot VMs with on-demand fallback, targeting specific accelerators (GPUs/TPUs) or machine families, restricting ComputeClass access, or debugging pending pods related to node pool auto-creation. Do not use for cluster-level Node Auto…

google/skills · 83 tokens

jetson-diagnostic

Read-only Jetson health snapshot for identity, memory, GPU, thermal, power, storage, services, and top processes.

NVIDIA/skills · 30 tokens

doca-socket-relay

Use this skill when the operator is driving the DOCA Socket Relay to bridge a socket-oriented host application onto a BlueField DPU peer without rewriting it — picking the deployment shape (in-process, sidecar, or BlueField service container), configuring the host-side socket and the DPU-side forwarding endpoint…

NVIDIA/skills · 236 tokens

offensive-z-wave

Z-Wave attack methodology — sniffing with Z-Force / EZ-Wave / RTL-SDR + ZniffMobile, S0 (legacy) network-key derivation flaw and key reuse, S2 (modern) ECDH commissioning analysis, replay/injection on unauthenticated nodes, default-key brute-force on test deployments, and home-automation hub pivots. Use when targeting…

SnailSploit/Claude-Red · 113 tokens

hsb-flash

Flash the FPGA on an HSB board connected to an NVIDIA devkit. Supports HSB Lattice boards (FPGA versions 2407, 2412, 2507, 2510) and Leopard Imaging VB1940 "all-in-one" cameras (FPGA versions 2507, 2510). Uses release-specific YAML manifests and board-type-specific program commands. Lattice and VB1940 commands must…

NVIDIA/skills · 94 tokens

jetson-validate-image

Use after jetson-flash-image to run static BSP checks, on-target smoke/regression tests on a flashed DUT, or both. Not for build or flash steps. Triggers: validate bsp, on-target validation.

NVIDIA/skills · 50 tokens