oneshotlm
Compare all models on this prompt →

3D solar system · glm-5

Output generated Cost / run $0.0085 Runtime 44.1s

Prompt for this run

Using the pre-provided three.min.js (global THREE), build a 3D solar system with the sun and orbiting planets at varied speeds and sizes, orbit-drag camera controls, and a starfield.

⛨ 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

modelglm-5
vendorZ.ai · GLM
harnesspi-agent
generated2026-07-22

METRICS

runtime44.1s
tokens in6.2k
tokens out3.3k
cached3.0k
cost / run$0.0085
Transcript · 4 messages
user

Using the pre-provided three.min.js (global THREE), build a 3D solar system with the sun and orbiting planets at varied speeds and sizes, orbit-drag camera controls, and a starfield.

assistant
thinking
The user wants me to create a 3D solar system visualization using Three.js. I need to:

1. Use the pre-provided three.min.js library (loaded as a local script)
2. Create a sun at the center
3. Add orbiting planets with varied speeds and sizes
4. Implement orbit-drag camera controls (likely OrbitControls behavior)
5. Add a starfield background

Let me create a single index.html file with everything inline - CSS, JavaScript, and HTML.

Since OrbitControls might not be included in three.min.js, I'll need to implement my own camera controls or check if it's available. I'll implement a simple orbit camera control manually.

Let me write the complete HTML file:
→ write index.html (12277 bytes)
toolResult

Successfully wrote 12277 bytes to index.html

assistant
thinking
I've created a complete 3D solar system visualization. Let me verify the file was created properly.

I've created a complete 3D solar system visualization in `index.html`. Here's what's included: **Features:** - **Sun** - Glowing yellow sphere with pulsing animation and subtle glow effect - **8 Planets** - Mercury, Venus, Earth, Mars, Jupiter, Saturn, Uranus, and Neptune, each with: - Accurate relative sizes and distances - Unique orbital speeds (inner planets faster, outer slower) - Individual colors matching real planets - **Saturn's Rings** - Iconic ring system around Saturn - **Earth's Moon** - Orbiting satellite around Earth - **Orbit Paths** - Subtle gray rings showing each planet's orbit - **Starfield** - 8,000 stars scattered in a sphere around the solar system - **Lighting** - Point light from the sun + ambient lighting for realistic illumination **Controls:** - **Drag** - Rotate the camera around the solar system - **Scroll** - Zoom in/out - **Touch support** - Works on mobile devices too The scene uses Three.js loaded from the local `three.min.js` file with all CSS and JavaScript inline in a single self-contained HTML file.