oneshotlm
Compare all models on this prompt →

Flow-field particles · claude-opus-4.8

Using the pre-provided p5.min.js (global p5, instance or global mode), create a full-screen flow-field particle animation: thousands of particles advected by Perlin-noise vectors, leaving fading trails, with colors shifting over time.

⛨ sandboxed Open in new tab ↗
transcript · 8 messages
user

Using the pre-provided p5.min.js (global p5, instance or global mode), create a full-screen flow-field particle animation: thousands of particles advected by Perlin-noise vectors, leaving fading trails, with colors shifting over time.

assistant
thinking
I'm setting up an HTML file with p5.js to create a flow field visualization.
bash {"command":"ls -la /workspace"}
toolResult

total 1028 drwxrwxrwx 3 node node 96 Jul 8 02:58 . drwxr-xr-x 1 root root 4096 Jul 8 02:58 .. -rw-r--r-- 1 node node 1034532 Jul 8 02:58 p5.min.js

assistant
write /workspace/index.html (3777 bytes)
toolResult

Successfully wrote 3777 bytes to /workspace/index.html

assistant
bash {"command":"cd /workspace && node -e \"const fs=require('fs');const h=fs.readFileSync('index.html','utf8');console.log('bytes',h.length);con
toolResult

bytes 3777 has p5 src true

assistant

Done. `index.html` is a self-contained single-page flow-field particle animation. Key features: - **4000 particles** advected by a Perlin-noise vector field (angle = `noise(x,y,z)` mapped to direction). - **Fading trails** via a translucent black rect drawn each frame instead of clearing. - **Colors shift over time** — `hueBase` drifts continuously, combined with position and speed for HSB coloring. - **Time-evolving field** — the noise `zoff` dimension animates the flow slowly. - **Interactivity** — mouse position pushes nearby particles away; clicking reseeds all particles. - Loads the local `p5.min.js` with a plain `<script src="p5.min.js">`, no external resources, and handles window resize. Open it in a browser to run.

TAKE IT TO CODE

A single self-contained HTML file — copy it and open in any browser, or reuse the prompt with your own pi-agent run.

RUN

modelclaude-opus-4.8
vendorAnthropic · Claude
harnesspi-agent
generated2026-07-08

EVALUATION

4/5 working

Flowing perlin-noise particle trails with color shifts, animates continuously, reacts strongly to click/drag/scroll and mouse move.

Vision grade · anthropic/claude-sonnet-5

MEASUREMENTS

Raw readings from the capture, not a verdict — the grade above is the only judgement. Percentages are how much of the screen changed; the measure under-reports sparse motion on a dark background.

idle motion14.6%
on click43.1%
on drag34.5%
on wheel11.3%
on enter + space8.3%
on arrow keys10.6%
on w/a/s/d3.6%
frame spread29.9 / 255
console errors0
js errors none

METRICS

runtime35.1s
tokens in4.4k
tokens out2.3k
cached8.4k
cost / run$0.0911