oneshotlm
Compare all models on this prompt →

Boids flocking · minimax-m2.5

Create a full-screen flocking simulation of boids using separation, alignment, and cohesion, drawn as oriented triangles that steer smoothly and flee from the mouse cursor.

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

Create a full-screen flocking simulation of boids using separation, alignment, and cohesion, drawn as oriented triangles that steer smoothly and flee from the mouse cursor.

assistant
thinking
The user wants a flocking simulation (boids) with:
1. Separation, alignment, and cohesion behaviors
2. Drawn as oriented triangles
3. Smooth steering
4. Mouse fleeing behavior
5. Full-screen
6. All in one self-contained HTML file

Let me create this simulation. I'll need to implement:
- Boid class with position, velocity, acceleration
- Separation - avoid crowding neighbors
- Alignment - steer towards average heading of neighbors
- Cohesion - steer towards average position of neighbors
- Mouse flee behavior
- Smooth steering using acceleration limiting
- Render as oriented triangles (using canvas)
- Full-screen canvas that resizes with window

Let me write this out.
write /tmp/ws/index.html (13910 bytes)
toolResult

Successfully wrote 13910 bytes to /tmp/ws/index.html

assistant
thinking
The file has been created. Let me verify it exists and summarize what I built.
bash {"command":"ls -la /tmp/ws/index.html"}
toolResult

-rw-r--r--. 1 node node 13910 Aug 1 17:40 /tmp/ws/index.html

assistant
thinking
The file is created successfully. Let me summarize what I've built.

Created `/tmp/ws/index.html` - a full-screen boids flocking simulation with: **Boid Behaviors:** - **Separation** - boids steer away from nearby neighbors to avoid crowding - **Alignment** - boids steer towards the average heading of nearby boids - **Cohesion** - boids steer towards the average position of nearby boids - **Mouse Fear** - boids flee from the mouse cursor with a radial fear zone - **Edge Handling** - soft boundary steering plus wraparound at screen edges **Visuals:** - Oriented triangles that rotate to match velocity direction - Gradient coloring with hue variations (cyan/blue tones) - Speed-based intensity - faster boids are brighter - Subtle glow effect on each boid - Faint background grid for atmosphere - Red radial gradient shows mouse influence area **Controls:** - Move your mouse to scare the boids - they'll flee and reform their flock - Full responsive canvas that resizes with the window The simulation runs at 120 boids with smooth steering using acceleration limiting (maxForce), creating organic, lifelike flocking behavior.

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

modelminimax-m2.5
vendorMiniMax
harnesspi-agent
generated2026-08-01

EVALUATION

4/5 working

Boids flock as oriented triangles with smooth flocking behavior; mouse fear glow visible but flocks continue independent of keyboard input.

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 motion8.5%
on click10.5%
on drag11.7%
on wheel10.9%
on enter + space10.6%
on arrow keys9.3%
on w/a/s/d10.3%
frame spread14.7 / 255
console errors0
js errors none

METRICS

runtime106.4s
tokens in11k
tokens out3.6k
cached11k
cost / run$0.0038