oneshotlm
Compare all models on this prompt →

Fluid simulation · seed-2.0-code

Create a real-time fluid simulation on a full-screen canvas where dragging the mouse pushes swirling colored dye through the fluid.

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

Create a real-time fluid simulation on a full-screen canvas where dragging the mouse pushes swirling colored dye through the fluid.

assistant

I'll create a real-time fluid simulation with swirling colored dye using a full-screen canvas.

write /tmp/ws/index.html (26892 bytes)
toolResult

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

assistant
thinking
Perfect, the file has been created successfully. Let me verify the file exists and then provide a summary of what was built.

Let me verify the file was created properly:

bash {"command":"ls -la /tmp/ws/index.html"}
toolResult

-rw-r--r--. 1 node node 26892 Aug 13 01:27 /tmp/ws/index.html

assistant
thinking
The file has been created successfully. Let me provide a summary of what was built.

I've created a real-time fluid simulation with swirling colored dye in `/tmp/ws/index.html`. Here's what it features: ## Key Features 1. **Full-screen canvas**: Uses WebGL for hardware-accelerated fluid dynamics 2. **Interactive**: Click and drag to push fluid and add colored dye 3. **Swirling vorticity**: Implements vorticity confinement for realistic swirling motion 4. **Color palette**: Uses a beautiful HSL-based color palette that cycles continuously 5. **Responsive**: Adapts to window resize 6. **Auto-splatting**: Generates random dye splats every 2 seconds when idle ## Technical Implementation - **Grid-based solver**: Uses a stable fluid dynamics algorithm (Stam method) - **Framebuffers**: Implements ping-pong buffers for velocity, pressure, dye, divergence, and curl - **Shaders**: Multiple GLSL shaders for operations like: - Advection (moving fluid properties) - Divergence calculation - Poisson pressure solve - Vorticity confinement - Splatting (adding fluid/color) - Gradient subtraction ## Usage Open the file in a modern web browser with WebGL support. Click and drag anywhere on the screen to interact with the fluid - your mouse movements will create swirling patterns of colored dye that flow naturally through the simulated fluid.

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

modelseed-2.0-code
vendorByteDance · Seed
harnesspi-agent
generated2026-08-13

EVALUATION

4/5 working

Fluid dye simulation reacts vividly to drag/click with colorful swirling trails, though idle blobs are just static and keyboard input barely differs.

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 motion4.1%
on click15.0%
on drag27.6%
on wheel17.7%
on enter + space17.1%
on arrow keys20.3%
on w/a/s/d19.1%
frame spread70.5 / 255
console errors0
js errors none

METRICS

runtime103.4s
tokens in20k
tokens out7.8k
cached12k
cost / run$0.0273