oneshotlm
Compare all models on this prompt →

L-system tree · gpt-4.1-mini

Output generated Cost / run $0.0029 Runtime 33.4s

Prompt for this run

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 ↗

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

modelgpt-4.1-mini
vendorOpenAI
harnesspi-agent
generated2026-08-01

METRICS

runtime33.4s
tokens in3.5k
tokens out1.2k
cached1.2k
cost / run$0.0029
Transcript · 4 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

I will create a self-contained single-page web app named index.html that uses p5.min.js (already present) to draw a procedural L-system fractal tree with recursive branching and gently swaying branches in the wind. The app will show the tree growing step by step and continuously sway later. Now I will write index.html with all code inline per the instructions.

→ write index.html (3045 bytes)
toolResult

Successfully wrote 3045 bytes to index.html

assistant

I created index.html with a p5.js app that grows a recursive L-system fractal tree branch by branch. The branches sway gently in the wind using a sinusoidal function that varies sway over time, branch level, and position for a natural effect. Open the index.html in a browser to watch the tree grow and sway on a dark background. Let me know if you want it adjusted or enhanced!