worker-visualizer
What it does
Creates a visual animation that runs smoothly (60 frames per second) in your browser. It performs heavy calculations in the background without freezing the main page and displays the result on a canvas.
When to use it
- βWhen you want to see real-time particle or physics simulations.
- βTo create complex visual effects like moving fractals.
- βWhen developing something that needs heavy computation without slowing down the interface.
Skill link
https://github.com/nexu-io/open-design/blob/main/design-templates/worker-visualizer/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agentβs skills folder.
Example of what to ask your AI
βCreate a simulation of 1000 particles attracting each other and display it on a canvas.β
5 new skills a week. 1 minute to read.
How it works
The code splits the work: one part handles heavy calculations in a separate area (Web Worker), and the other part simply draws the result on the screen. This ensures the page remains responsive.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
Worker Visualizer Skill
Produce a single self-contained index.html that moves heavy per-frame compute into a Web Worker and renders the result to a canvas, keeping the main thread at a smooth 60fps.
Why this is a powered artifact
OpenDesign detects new Worker( / SharedArrayBuffer / OffscreenCanvas and renders this file in powered preview β a cross-origin-isolated iframe with allow-same-origin. That means external and blob Web Workers construct successfully, SharedArrayBuffer is defined (crossOriginIsolated === true), and importScripts works. In the old opaque sandbox all three failed; here they just work.
Resource map
worker-visualizer/
βββ SKILL.md β you're reading this
βββ example.html β a working 12k-particle SharedArrayBuffer sim (READ FIRST)
Workflow
Step 0 β Read the reference
Read example.html. Note the split: the worker integrates positions each tick; the main thread only reads + draws. It feature-detects crossOriginIsolated and uses a SharedArrayBuffer for zero-copy when available, falling back to a transferable postMessage copy otherwise. Always ship that fallback so the artifact still animates if isolation is off.
Step 1 β Choose the workload
Pick ONE compute-bound job worth offloading:
- Particle / N-body field (default): thousands of bodies with a cheap force law.
- Fractal: Mandelbrot/Julia escape-time into an
ImageDatabuffer. - Cellular automata / reaction-diffusion: grid updated in the worker.
- Data/audio visualizer: transform a stream into bars/rings each frame.
Step 2 β Build index.html
- One file, zero external requests. Build the worker from a
Blob+URL.createObjectURL(inline its source), or embed it as adata:URL. - Prefer SharedArrayBuffer for large per-frame state: allocate on the main thread, pass the
SharedArrayBufferto the worker, and read the sameFloat32Array/Uint8ClampedArrayview while drawing. Guard ontypeof SharedArrayBuffer !== 'undefined' && crossOriginIsolated. - Fallback path: if not isolated,
postMessagea transferableArrayBuffereach frame. - Consider
OffscreenCanvas+canvas.transferControlToOffscreen()to render inside the worker for the heaviest scenes.
Step 3 β Overlay + brand
- HUD with the title and 2β3 live stat tiles (particle count, transport mode, fps). Map accent color to the active DESIGN.md when present; otherwise a dark ground with one vivid accent.
Step 4 β Self-review (P0)
- Worker constructs with no SecurityError; sim runs.
- Main-thread render holds ~60fps under the full workload.
-
SharedArrayBufferpath engages whencrossOriginIsolatedis true;postMessagefallback engages otherwise β verify BOTH branches degrade cleanly. - No unbounded growth: velocities/positions stay stable over minutes.
- The "Transport" stat truthfully reports which path is live.
FAQ
What is a 'Web Worker'?
It's like having a secret helper in the browser that performs heavy tasks without interfering with what you see on the main screen.
What is 'SharedArrayBuffer'?
It's an advanced way to share very large data between the main part and the helper (Web Worker) without needing to copy everything, making it faster.
Why does the animation run at 60fps?
The tool is designed to optimize calculations and drawing, ensuring the animation is smooth and pleasant to watch, like in a game.
Details
Original description by the author
A real-time data/particle/simulation visualizer whose heavy compute runs in a Web Worker (off the main thread), optionally sharing memory with the UI via SharedArrayBuffer, and renders to a canvas at 60fps. Produced as a single self-contained `index.html`. Use when the brief asks for a "web worker", "simulation", "particle system", "physics", "off-main-thread", "fractal", "real-time compute", or "
repo: nexu-io/open-design
Popularity
- GitHub stars
- 101k
- Ranking position
- #976
- License
- Apache-2.0
- Updated
- 10/15/2026
Comments
- β¦
More skills from this repository
sample-plugin
101kMakes your agent create a metadata file for tests. It helps ensure code works correctly in different situations.
aster-atelier
101kHelps your agent create an artistic website with a classic look. It uses elegant imagery, blue skies, and serif fonts for a cinematic feel.
audio-jingle
101kMakes your agent generate audio like jingles and sound effects. It can create music and voices, saving the result as an audio file.
blog-post
101kHelps your agent write long articles or blog posts. It includes space for images, quotes, and author information.
Similar skills
add-model-provider
394kLets your agent connect a new AI model provider to OpenClaw using safe setup commands, keep API keys out of plain text, and run a live test.
acp-router
394kHelps your agent send a task to a coding assistant such as Claude Code or Cursor through OpenClaw, so the work runs in that tool.
browser-automation
394kTeaches your agent to control web pages step by step, including logins, tabs, and recovery when a page stops responding.