跳到正文
Skillpedia
图片与图标260k · #598

p5js

它能做什么

这项技能引导你的 AI 使用 p5.js 完成创意编程项目。适合希望为网络制作交互式或生成式视觉效果的艺术家、设计师和开发者。

适用场景

  • ✓你想要一个在浏览器中运行的生成艺术草图或交互式视觉效果的时候。
  • ✓你想要数据可视化,或粒子、流场、噪声动画的时候。
  • ✓你想把草图导出为 HTML、PNG、GIF、MP4 或 SVG 的时候。

技能链接

https://github.com/NousResearch/hermes-agent/blob/main/skills/creative/p5js/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/NousResearch/hermes-agent/blob/main/skills/creative/p5js/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

📦 包含此技能的技能包

可以这样问 AI

“请用 p5.js 制作一幅生成艺术作品,让流动的粒子随我的鼠标变化,并导出为 PNG。”

每周 5 个新技能,1 分钟读完。

工作原理

这项技能让你的 AI 先规划创意构思,然后为草图编写 p5.js 代码。它可以加入着色器、声音响应或三维场景,并能以多种格式导出结果。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

p5.js Production Pipeline

When to use

Use when users request: p5.js sketches, creative coding, generative art, interactive visualizations, canvas animations, browser-based visual art, data viz, shader effects, or any p5.js project.

What's inside

Production pipeline for interactive and generative visual art using p5.js. Creates browser-based sketches, generative art, data visualizations, interactive experiences, 3D scenes, audio-reactive visuals, and motion graphics — exported as HTML, PNG, GIF, MP4, or SVG. Covers: 2D/3D rendering, noise and particle systems, flow fields, shaders (GLSL), pixel manipulation, kinetic typography, WebGL scenes, audio analysis, mouse/keyboard interaction, and headless high-res export.

Creative Standard

This is visual art rendered in the browser. The canvas is the medium; the algorithm is the brush.

Before writing a single line of code, articulate the creative concept. What does this piece communicate? What makes the viewer stop scrolling? What separates this from a code tutorial example? The user's prompt is a starting point — interpret it with creative ambition.

First-render excellence is non-negotiable. The output must be visually striking on first load. If it looks like a p5.js tutorial exercise, a default configuration, or "AI-generated creative coding," it is wrong. Rethink before shipping.

Go beyond the reference vocabulary. The noise functions, particle systems, color palettes, and shader effects in the references are a starting vocabulary. For every project, combine, layer, and invent. The catalog is a palette of paints — you write the painting.

Be proactively creative. If the user asks for "a particle system," deliver a particle system with emergent flocking behavior, trailing ghost echoes, palette-shifted depth fog, and a background noise field that breathes. Include at least one visual detail the user didn't ask for but will appreciate.

Dense, layered, considered. Every frame should reward viewing. Never flat white backgrounds. Always compositional hierarchy. Always intentional color. Always micro-detail that only appears on close inspection.

Cohesive aesthetic over feature count. All elements must serve a unified visual language — shared color temperature, consistent stroke weight vocabulary, harmonious motion speeds. A sketch with ten unrelated effects is worse than one with three that belong together.

Modes

Mode Input Output Reference
Generative art Seed / parameters Procedural visual composition (still or animated) references/visual-effects.md
Data visualization Dataset / API Interactive charts, graphs, custom data displays references/interaction.md
Interactive experience None (user drives) Mouse/keyboard/touch-driven sketch references/interaction.md
Animation / motion graphics Timeline / storyboard Timed sequences, kinetic typography, transitions references/animation.md
3D scene Concept description WebGL geometry, lighting, camera, materials references/webgl-and-3d.md
Image processing Image file(s) Pixel manipulation, filters, mosaic, pointillism references/visual-effects.md § Pixel Manipulation
Audio-reactive Audio file / mic Sound-driven generative visuals references/interaction.md § Audio Input

Stack

Single self-contained HTML file per project. No build step required.

Layer Tool Purpose
Core p5.js 1.11.3 (CDN) Canvas rendering, math, transforms, event handling
3D p5.js WebGL mode 3D geometry, camera, lighting, GLSL shaders
Audio p5.sound.js (CDN) FFT analysis, amplitude, mic input, oscillators
Export Built-in saveCanvas() / saveGif() / saveFrames() PNG, GIF, frame sequence output
Capture CCapture.js (optional) Deterministic framerate video capture (WebM, GIF)
Headless Puppeteer + Node.js (optional) Automated high-res rendering, MP4 via ffmpeg
SVG p5.js-svg 1.6.0 (optional) Vector output for print — requires p5.js 1.x
Natural media p5.brush (optional) Watercolor, charcoal, pen — requires p5.js 2.x + WEBGL
Texture p5.grain (optional) Film grain, texture overlays
Fonts Google Fonts / loadFont() Custom typography via OTF/TTF/WOFF2

Version Note

p5.js 1.x (1.11.3) is the default — stable, well-documented, broadest library compatibi

常见问题

我需要懂 JavaScript 吗?

具备一些基础知识会有帮助,但技能会引导 AI 编写代码并进行解释。

它能制作三维场景吗?

可以。技能涵盖使用 p5.js 的 WebGL 场景和三维渲染。

有哪些输出格式?

技能列出了 HTML、PNG、GIF、MP4 和 SVG。

详情

作者的原始描述

p5.js sketches: gen art, shaders, interactive, 3D.

repo: NousResearch/hermes-agent

热度

GitHub 星标
260k
排名
#598
许可证
MIT
更新时间
2026/11/2

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能