/diagram-studio:hierarchy-lensfrom diagram-studio
Builds offline interactive hierarchies with decision-driven pixel composition, compact organic cells, radial heatmaps, or labeled charts. Use for organizational maps, portfolios, or taxonomies needing explicit placement priorities, proximity rules, step-by-step growth, switchable color lenses, and exact record lookup.
Ships in diagram-studio. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Read palette-policy.md before authoring or composing visuals. Apply one exact colorset to authored content and report preserved source media separately. Read solid-surfaces.md for solid-first category fills, black/white text on the actual fill, and palette exhaustion before border variants.
Create one explorable hierarchy image inside a self-contained HTML file. Put the root in the center and organize generations outward. Keep geometry independent of the selected color dimension.
For a composition engine that decides which record enters next and which vacancy it occupies, use --view decision. Read decision-growth.md. Define placement priority separately from spatial affinity and color. Expose editable rules, weighted explanations, and replay of actual placements. Recompose when the policy changes; switching color lenses preserves the current composition.
For a compact organic or slime-like body, a tiny center, equal small cells, or requests to eliminate thick bands and needle-like regions, use --view organic. Read organic-pixels.md. Each record occupies one square of --cell-pixels 2 by default; generations consume successive positions on a connected growth front. Keep the image compact instead of stretching it to fill the screen. Explain that growth order represents depth, while physical adjacency is packing rather than a reporting edge.
For pixel art, a radial heatmap, a text-free procedural data image, or an image whose color patterns reveal attributes, use --view pixel. Read radial-pixels.md. Build square pixels directly from the hierarchy, keep every record represented, and place controls and the visual key outside the image. Use the hide-controls mode for an image-only view. Do not add names, legends, connectors, decorative noise, or glow inside this image.
For a conventional labeled radial chart, use --view analytical (the builder default). Read radial-lenses.md for labels, ring limits, and rebased branch focus. All views share the same input contract; honor an explicit choice of style.
Read data-contract.md to normalize the source into a flat JSON tree and explicit dimension descriptors. Preserve source IDs, missing values, units, and reporting periods. Use a single declared primary parent; a matrix organization needs an agreed primary reporting line rather than duplicated people.
If no source data was supplied, clearly identify any demonstration as synthetic outside the image. Never infer leadership level from reporting depth unless that is the supplied definition. Keep individual metrics distinct from observed subtree sums.
The bundled builder uses Python through uv; decision mode also uses Node.js to execute the same engine embedded in the offline HTML. Replace <skill-root> with this bundle's location. Write task outputs outside the read-only bundle and honor exact requested paths.
uv run --script <skill-root>/scripts/build_explorer.py --input hierarchy.json --view pixel --output explorer.html --report build-report.json
For a fictional organization of N people, use --demo --demo-size N unless the user specifies a custom reporting structure. This route already supplies leadership, contract, role, monthly tokens, zero values, and missing observations with an exact record count; do not recalculate synthetic team sizes by hand. Customize the exported JSON only when the request needs different attributes. For example:
uv run --script <skill-root>/scripts/build_explorer.py --demo --demo-size 1200 --view pixel --output explorer.html --data-output hierarchy.json --report build-report.json
--demo-size controls the number of synthetic records (default 1200, range 2–20000). Normal authoring reads the compact contract and runs the builder; it does not need template source or acceptance examples. Customize title, description, entity label, dimensions, and source notes through the input. The output embeds data, styles, and runtime without CDNs, telemetry, or external requests.
Run the browser audit after the last build. It requires the Python playwright package (declared by the script) and an installed Chromium browser. If Chromium is missing, install it with uv run --with playwright python -m playwright install chromium when local dependency installation is authorized, or report the browser gate as incomplete.
uv run --script <skill-root>/scripts/audit_pixels.py explorer.html --report audit.json --screenshot overview.png
Use audit_decisions.py for decision mode, audit_pixels.py for organic mode, and audit_explorer.py for the analytical view. For decisions, verify priority eligibility, parent precedence, editable weights, exact playback prefixes, exported traces, and deterministic restore. Parent-ready mode intentionally relaxes generation order. Inspect the screenshot and interact with a meaningful branch and a numeric lens. For organic cells, verify equal small squares, a small root, one connected body, connected generation prefixes, and the native-size export. For all pixels, verify hard edges, a text-free image, stable regions across lenses, and recognizable color patterns. Check mobile controls, missing-value treatment, global scales, period/unit wording in the external key, and whether the map answers the actual question. Read validation.md when adapting the interaction or evaluating a large or unusual input.
Deliver the HTML and its normalized input, including its explicit composition policy when used. Pixel SVG/PNG downloads capture active colors and highlighting without visible text; decision mode captures the current replay prefix. Organic exports retain the native small grid. Decision SVG additionally keeps the policy, complete trace, and visible record count. SVG keeps the source and metric context in hidden metadata. Analytical downloads include the current chart and legend. HTML retains interaction. Report tested size and any incomplete gate without implying unlimited-scale performance. Do not publish private source data without authorization.
agents/openai.yaml (opens in a new tab)assets/examples/hierarchy-lens/analytical.html (opens in a new tab)assets/examples/hierarchy-lens/composition.json (opens in a new tab)assets/examples/hierarchy-lens/organic.html (opens in a new tab)assets/examples/hierarchy-lens/organization.json (opens in a new tab)assets/examples/hierarchy-lens/radial.html (opens in a new tab)assets/palettes/colorsets.json (opens in a new tab)assets/templates/decision-engine.js (opens in a new tab)assets/templates/decision-ui.js (opens in a new tab)assets/templates/explorer.html (opens in a new tab)assets/templates/pixels.html (opens in a new tab)references/data-contract.md (opens in a new tab)references/decision-growth.md (opens in a new tab)references/organic-pixels.md (opens in a new tab)references/palette-policy.md (opens in a new tab)references/radial-lenses.md (opens in a new tab)references/radial-pixels.md (opens in a new tab)references/solid-surfaces.md (opens in a new tab)references/validation.md (opens in a new tab)scripts/audit_decisions.py (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
11 skills in this plugin
/compose-synchronized-svgDesigns, builds, synchronizes, and validates giant standalone SVG compositions made from many related diagrams, charts, maps, schematics, illustrations, and explanatory assets. Use when Codex must turn one idea into a coherent 6–16-module megacanvas or a 12–48-module navigable world such as a Path of Exile-style skill tree, giant genealogy, causal atlas, or linked-diagram map; keep recurring concepts visually consistent; propagate canonical values through every relevant view; coordinate focus, time, world-to-district-to-module semantic zoom, or a deterministic camera route for video; and deliver one self-contained interactive SVG with meaningful static and reduced-motion fallbacks./d3Creates, animates, inspects, recomposes, and validates D3-powered HTML and SVG visuals. Use for custom charts, simulations, linked views, visual audits, parametric logos, textures, and portable SVG that need data-driven geometry, joins, layouts, or transitions./diagram-compositionDecomposes a complex idea into related subdiagrams, chooses suitable visual forms, and composes a compact page with explicit grid spans, consistent semantic colors, readable text, shared SVG icons, and meaningful cross-panel connections. Use for dense explanatory figures, architecture plates, visual comparisons, and multi-panel diagrams that need semantic planning before layout; coordinate available diagram and icon skills without requiring them./echarts-animated-svgAnimates already-rendered Apache ECharts SVG output and builds replayable SVG galleries. Use when Codex needs to render ECharts charts with SVGRenderer or SSR, post-process the resulting SVG instead of rebuilding chart geometry, choose chart-type-specific SVG animation profiles for ECharts chart types, or create an HTML index with controls to replay or restore chart animations./lucidchart-svgExports Lucidchart diagrams to SVG, inserts SVG artwork into Lucidchart, and reconstructs SVG diagrams as editable Lucid shapes and connectors. Use for Lucidchart SVG downloads, uploads, conversions, and fidelity checks./mermaidCreates, selects, styles, renders, validates, and animates Mermaid diagrams from prose or structured data, including verified accessible title and description metadata for newly authored work. Use when Codex must honor or infer an appropriate Mermaid family; preserve workflows, schedules, schemas, hierarchies, interactions, behavioral contracts, tabular data, or quantitative facts; simplify or audience-adapt an existing diagram with an explicit fidelity ledger; apply colorset1 as the standard palette or colorset2 only when extended/full-color styling is explicitly requested; restyle Mermaid files or Markdown fences; render static SVG; or produce faithful animated SVG.npx claudepluginhub gvillarroel/plugins --plugin diagram-studio