oneshotlm
Compare all models on this prompt →

L-system tree · gemini-3.1-flash-lite

Using the pre-provided p5.min.js (global p5), grow a procedural L-system fractal tree that branches recursively and sways gently in the wind.

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

Using the pre-provided p5.min.js (global p5), grow a procedural L-system fractal tree that branches recursively and sways gently in the wind.

assistant
thinking
**Generating Fractal Tree**

I'm currently focused on integrating a procedural L-system fractal tree directly into a single `index.html` file. The aim is to incorporate recursive branching and a swaying effect, all while relying solely on the provided `p5.min.js` and avoiding external dependencies.

**Refining Fractal Structure**

I'm now refining the L-system rules and the recursive drawing logic, focusing on precise angle calculations and using a stack for managing branches. The goal is to ensure a clean, self-contained implementation within a single HTML file using `p5.min.js`.

write index.html (1816 bytes)
toolResult

Successfully wrote 1816 bytes to index.html

assistant
bash {"command":"ls -l p5.min.js index.html"}
toolResult

-rw-r--r-- 1 node node 1816 Jul 22 17:50 index.html -rw-r--r-- 1 node node 1034532 Jul 22 17:50 p5.min.js

assistant

The procedural fractal tree is built and ready in `index.html`. It uses a recursive branching method (standard for L-system tree dynamics) and includes a wind sway effect generated by modulating branch angles using a sine wave synced to `frameCount`. To run, simply open `index.html` in your browser.

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

modelgemini-3.1-flash-lite
vendorGoogle
harnesspi-agent
generated2026-07-22

EVALUATION

4/5 working

A branching fractal tree with green leaves sways gently in the wind; no distinct interactive response but visuals are clean.

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 motion2.0%
on click4.1%
on drag4.1%
on wheel3.9%
on enter + space4.0%
on arrow keys4.0%
on w/a/s/d3.9%
frame spread13 / 255
console errors0
js errors none

METRICS

runtime11.5s
tokens in6.5k
tokens out1.5k
cached0
cost / run$0.0038