hf-architecture-tikz — Claude Code skill: what it does, how to install
hf-architecture-tikz draws Sebastian-Raschka-style TikZ architecture diagrams for HuggingFace decoder-only LLMs with formulas and layer parameter counts.
no license ★ 158 updated 2026-07-09
npx skills add yzlnew/infra-skills --skill hf-architecture-tikz -a claude-codeWhat hf-architecture-tikz does
This skill generates publication-ready vertical diagrams of transformer models modeled after Sebastian Raschka's LLM Architecture Gallery. It inspects a HuggingFace repository identifier or a local config.json, determines the model family automatically, and evaluates closed-form parameter counts for each sub-block.
Supported designs include MHA, GQA, MLA, and DeepSeek-V4-Flash with Hyper-Connections and sparse attention. It handles both standard and MoE feed-forward networks, hash-based routing, and multi-token prediction heads. Jinja2 templates generate the raw TikZ LaTeX document, which compiles to a PNG image using XeLaTeX and pdftocairo.
Local rendering depends on an installed TeX distribution with xelatex or pdflatex alongside pdftocairo for final image output.
What it helps with
- render a publication-grade LaTeX diagram of a HuggingFace transformer model
- evaluate closed-form parameter totals for individual attention and FFN blocks
- illustrate architectures such as DeepSeek-V4-Flash featuring MLA and MoE
Example prompts for the agent
- Draw the architecture of deepseek-ai/DeepSeek-V4-Flash in TikZ format
- Generate a Raschka-style diagram for a local config.json file
- Create a TikZ figure with parameter formulas for Qwen3
How to install hf-architecture-tikz
1Skills CLI (Vercel)
npx skills add yzlnew/infra-skills --skill hf-architecture-tikz -a claude-code2Manually: put the files in place
~/.claude/skills/hf-architecture-tikz/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/hf-architecture-tikz/
1Skills CLI (Vercel)
npx skills add yzlnew/infra-skills --skill hf-architecture-tikz -a codex2Manually: put the files in place
.agents/skills/hf-architecture-tikz/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add yzlnew/infra-skills --skill hf-architecture-tikz -a cursor2Manually: put the files in place
.cursor/skills/hf-architecture-tikz/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install yzlnew/infra-skills hf-architecture-tikz2Manually: put the files in place
.github/skills/hf-architecture-tikz/SKILL.md1Skills CLI (Vercel)
npx skills add yzlnew/infra-skills --skill hf-architecture-tikz -a gemini-cli2Platform CLI
gemini skills install https://github.com/yzlnew/infra-skills --path hf-architecture-tikzManually: put the files in place
.devin/skills/hf-architecture-tikz/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about hf-architecture-tikz
How to install hf-architecture-tikz in Claude Code?
Run npx skills add yzlnew/infra-skills --skill hf-architecture-tikz -a claude-code in your terminal.
What does hf-architecture-tikz do?
It parses decoder-only model configs from HuggingFace, calculates parameter tallies per component, and renders vertical TikZ architecture graphics.
What external software is required to compile images?
You need Python with uv, a TeX distribution providing xelatex or pdflatex, and pdftocairo for conversion into PNG.