Claude Official Skill: algorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithm...
What it is
The algorithmic-art skill is an official Claude skill that teaches Claude Code how to create algorithmic art using p5.js. It provides rules for seeded randomness, interactive parameter exploration, and code-driven visual generation. When installed, Claude Code produces self-contained p5.js sketches that create generative visuals with reproducible outputs.
Creative coders, generative art enthusiasts, and developers who want to produce visual art through code use this skill to guide Claude Code in producing well-structured p5.js sketches with proper randomness seeding and parameter controls.
How it saves time or tokens
Writing generative art code from scratch requires understanding p5.js APIs, implementing proper random seeding for reproducibility, and building parameter controls for interactive exploration. This skill pre-loads these patterns into Claude Code, so the agent produces correct generative art code without you needing to specify seeding strategies, canvas setup, or interaction patterns in every prompt.
How to use
- Install the skill:
claude skill install anthropics/skills/algorithmic-art
- Or manually copy the SKILL.md content to
.claude/skills/algorithmic-art/SKILL.md - Ask Claude Code to create algorithmic art:
> Create a generative art piece with flowing particle systems
> Make a recursive fractal tree with randomized branching
> Generate a tiling pattern with interactive color controls
Example
// Seeded generative art sketch (produced by Claude with this skill)
let seed;
function setup() {
createCanvas(800, 800);
seed = floor(random(99999));
noLoop();
}
function draw() {
randomSeed(seed);
background(20);
noFill();
for (let i = 0; i < 200; i++) {
let x = random(width);
let y = random(height);
let r = random(20, 100);
let hue = map(y, 0, height, 0, 360);
stroke(hue, 80, 90, 30);
strokeWeight(random(0.5, 2));
ellipse(x, y, r, r * random(0.5, 1.5));
}
}
function mousePressed() {
seed = floor(random(99999));
redraw();
}
Related on TokRepo
- AI Tools for Coding -- explore coding skills and tools for AI-assisted development
- Prompt Library -- discover prompts and skills for creative and technical tasks
Common pitfalls
- Always use randomSeed() for reproducible outputs. Without seeding, each run produces different results, making it impossible to reproduce a specific artwork.
- p5.js sketches run in the browser. Keep computational complexity reasonable to avoid freezing the browser tab with large particle counts or deep recursion.
- Color mode matters. Switch to colorMode(HSB, 360, 100, 100) early in setup for more intuitive color control in generative art.
Frequently Asked Questions
It is an official Claude skill that provides rules and patterns for creating generative art using p5.js. When installed, Claude Code produces well-structured p5.js sketches with proper seeded randomness, interactive controls, and creative visual patterns.
Run claude skill install anthropics/skills/algorithmic-art or manually create .claude/skills/algorithmic-art/SKILL.md in your project with the skill content. Claude Code automatically loads it when creative coding tasks are detected.
Seeded randomness uses a fixed seed value with randomSeed() so that random() calls produce the same sequence every run. This makes your artwork reproducible -- the same seed always generates the same visual. Click to get a new seed and explore different variations.
The skill is specifically designed for p5.js. However, the principles of seeded randomness, parameter exploration, and compositional structure apply to other creative coding frameworks. Claude Code can adapt the patterns to canvas API, SVG, or other rendering targets.
The skill supports both. Static pieces use noLoop() and redraw() for on-demand regeneration. Animated pieces use the standard draw() loop with frameCount-based progression. The skill guides Claude Code to choose the appropriate approach based on your description.
Citations (3)
- Anthropic Claude Code Skills— Official Claude skill for algorithmic art creation
- p5.js— p5.js creative coding library
- p5.js Random Reference— Generative art with seeded randomness
Related on TokRepo
Source & Thanks
Created by Anthropic. Licensed under MIT. anthropics/skills
Discussion
Related Assets
Claude-Flow — Multi-Agent Orchestration for Claude Code
Layers swarm and hive-mind multi-agent orchestration on top of Claude Code with 64 specialized agents, SQLite memory, and parallel execution.
ccusage — Real-Time Token Cost Tracker for Claude Code
CLI that reads ~/.claude logs and breaks down Claude Code token spend by day, session, and project — pluggable into your statusline.
SuperClaude — Workflow Framework for Claude Code
Adds 16+ slash commands, 9 cognitive personas, and a smart flag system to Claude Code in one pipx install.