Use when generating SVG graphics from written descriptions including icons, data visualizations, illustrations, technical diagrams, or any visual content. Emphasizes visual accuracy through planning-first workflows, proper coordinate systems, and verification steps to ensure generated SVGs match the described appearance.
/plugin marketplace add mthalman/superpowers/plugin install superpowers@claude-marketplaceThis skill inherits all available tools. When active, it can use any tool Claude has access to.
references/svg-reference.mdThis skill provides systematic workflows for generating accurate SVG graphics from textual descriptions. The primary focus is ensuring visual accuracy - that generated SVGs actually look like what was described. This is achieved through planning-first workflows, proper use of coordinate systems, and verification steps.
Use this skill when:
CRITICAL: Never generate SVG code directly from a description. Always plan first.
The planning phase ensures:
This prevents misaligned, disproportionate, or inaccurate graphics.
User requests SVG generation?
│
├─ Simple icon or symbol (< 10 elements)
│ └─ Use "Quick Icon Generation" workflow
│
├─ Data visualization (chart, graph)
│ └─ Use "Data Visualization" workflow
│
├─ Technical diagram (flowchart, architecture)
│ └─ Use "Technical Diagram" workflow
│
├─ Complex illustration or scene
│ └─ Use "Complex Illustration" workflow
│
└─ Unknown or complex requirements
└─ Start with "Complex Illustration" workflow
For simple icons and symbols (< 10 basic shapes).
Read references/svg-reference.md (Common ViewBox Patterns)
Select appropriate viewBox:
List the visual elements needed:
Example: "Blue checkmark icon"
Create SVG with planned elements:
<svg> tag including viewBox and dimensionsCheck the generated SVG:
If inaccurate, identify the issue and regenerate with corrections.
For charts, graphs, and data-driven graphics.
Parse the data or data description:
Read references/svg-reference.md (Data Visualizations)
Select appropriate visualization:
Choose viewBox dimensions (e.g., 400×300 for charts with axes).
For bar charts:
chartWidth / numberOfBars(value / maxValue) * chartHeightFor pie charts:
(percentage / 100) * 360For line/scatter plots:
x = (index / maxIndex) * chartWidth, y = chartHeight - (value / maxValue) * chartHeightCreate SVG in layers:
Check that:
For flowcharts, architecture diagrams, process flows.
Identify diagram components:
Read references/svg-reference.md (Technical Diagrams)
Calculate positions:
Example: 3-step vertical flowchart
Create SVG structure:
<defs>
<marker id="arrowhead" ...>
</defs>
<g> for logical groupingCheck that:
For scenes, landscapes, artistic compositions, or multi-element graphics.
Break down the description into:
Example: "Mountain landscape with sun and trees"
Read references/svg-reference.md (Coordinate System and ViewBox)
Select viewBox based on aspect ratio:
Consider using centered origin for symmetrical compositions.
Establish spatial layout:
Plan colors:
Read references/svg-reference.md (Color Harmony, Visual Accuracy Techniques)
Calculate key coordinates:
Create SVG structure from back to front:
<svg viewBox="..." width="..." height="...">
<!-- 1. Background layer -->
<g id="background">
<!-- Sky, backdrop, gradients -->
</g>
<!-- 2. Midground layer -->
<g id="midground">
<!-- Main subjects, focal elements -->
</g>
<!-- 3. Foreground layer -->
<g id="foreground">
<!-- Details, overlaying objects -->
</g>
</svg>
For each layer:
Read references/svg-reference.md (Content-Specific Patterns)
Use grouping and reuse:
<g><defs> and use <use>Enhance visual richness:
Read references/svg-reference.md (Depth and Dimension)
Verify the illustration matches the description:
Compositional accuracy:
Visual accuracy:
Technical quality:
If any verification fails, identify the specific issue and regenerate the affected elements or sections.
The SVG reference document contains comprehensive technical information:
Read references/svg-reference.md
When to consult specific sections:
Search the reference for:
1. Recognize as icon generation task
2. Plan: Circle with arc path, blue stroke, centered in 24×24 viewBox
3. Consult references/svg-reference.md (Paths - Arc Examples)
4. Generate SVG with animated arc or segmented circle
5. Verify: circular shape, blue color, appropriate for loading indication
1. Recognize as data visualization task
2. Parse data values and labels
3. Consult references/svg-reference.md (Bar Chart Pattern)
4. Calculate bar widths and heights based on data
5. Generate SVG with axes, bars, and labels
6. Verify: bars accurately represent data values, labels are correct
1. Recognize as technical diagram task
2. Map structure: identify 5 process boxes, 2 diamond decisions
3. Consult references/svg-reference.md (Flowchart Box, Diamond)
4. Calculate layout: vertical flow with appropriate spacing
5. Generate SVG with arrow markers, nodes, connectors
6. Verify: 7 total nodes, clear flow direction, decisions properly marked
1. Recognize as complex illustration task
2. Decompose: Background (sky gradient, sun), Midground (palm tree), Foreground (beach, ocean)
3. Choose viewBox="0 0 1600 900" for landscape aspect ratio
4. Consult references/svg-reference.md (Sun, Water, Sky Gradient, Tree pattern)
5. Plan composition: sky top 50%, ocean middle 30%, beach bottom 20%
6. Generate in layers: sky → sun → ocean → beach → palm tree
7. Verify: all elements present, sunset colors appropriate, composition balanced
1. Identify the problem: which elements are misaligned
2. Check coordinate calculations in planning
3. Consult references/svg-reference.md (Coordinate System)
4. Recalculate positions ensuring proper spacing and alignment
5. Regenerate affected elements with corrected coordinates
6. Verify alignment is now correct
<defs> and <use> for repeated elementsInclude accessibility features:
<svg role="img" aria-labelledby="title desc">
<title id="title">Descriptive Title</title>
<desc id="desc">Detailed description of the visual content</desc>
<!-- SVG content -->
</svg>
Issue: Coordinates exceed viewBox bounds
Solution:
Issue: Color selection doesn't align with described appearance
Solution:
Issue: Elements are disproportionate to each other
Solution:
Issue: Visual weight is unevenly distributed
Solution:
Issue: Flow or relationships are unclear
Solution:
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithmic art, flow fields, or particle systems. Create original algorithmic art rather than copying existing artists' work to avoid copyright violations.
Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply.
Create beautiful visual art in .png and .pdf documents using design philosophy. You should use this skill when the user asks to create a poster, piece of art, design, or other static piece. Create original visual designs, never copying existing artists' work to avoid copyright violations.